diff --git a/.npmignore b/.npmignore index 35c7fe3c..3d55c8ec 100644 --- a/.npmignore +++ b/.npmignore @@ -6,4 +6,9 @@ node_modules experiments docs coverage -test/__screenshots__ \ No newline at end of file +vite.config.mts +vite.config.components.mts +vitest.config.mts +vitest.config-ui.mts +test +src \ No newline at end of file diff --git a/dist/bootstrap-native.cjs b/dist/bootstrap-native.cjs index 995c353a..6bbd44c0 100644 --- a/dist/bootstrap-native.cjs +++ b/dist/bootstrap-native.cjs @@ -1,2 +1,2 @@ -"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const An="aria-describedby",me="aria-expanded",se="aria-hidden",be="aria-modal",As="aria-pressed",Oe="aria-selected",os="focus",is="focusin",Pn="focusout",Ee="keydown",Oo="keyup",O="click",In="mousedown",ko="hover",we="mouseenter",rs="mouseleave",No="pointerdown",_o="pointermove",Mo="pointerup",as="touchstart",Bo="dragstart",Ro='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',ze="ArrowDown",Ke="ArrowUp",Ps="ArrowLeft",Is="ArrowRight",cs="Escape",Fo="transitionDuration",Wo="transitionDelay",ke="transitionend",Ln="transitionProperty",Vo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},ve=()=>{},jo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},zo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},et=(e,t)=>e.getAttribute(t),Gt=(e,t)=>e.hasAttribute(t),k=(e,t,s)=>e.setAttribute(t,s),Pt=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},m=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),ne=e=>e!=null&&typeof e=="object"||!1,H=e=>ne(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,T=e=>H(e)&&e.nodeType===1||!1,Bt=new Map,Dt={data:Bt,set:(e,t,s)=>{T(e)&&(Bt.has(t)||Bt.set(t,new Map),Bt.get(t).set(e,s))},getAllFor:e=>Bt.get(e)||null,get:(e,t)=>{if(!T(e)||!t)return null;const s=Dt.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=Dt.getAllFor(t);!s||!T(e)||(s.delete(e),s.size===0&&Bt.delete(t))}},W=(e,t)=>Dt.get(e,t),oe=e=>typeof e=="string"||!1,Ko=e=>ne(e)&&e.constructor.name==="Window"||!1,On=e=>H(e)&&e.nodeType===9||!1,E=e=>Ko(e)?e.document:On(e)?e:H(e)?e.ownerDocument:globalThis.document,ct=(e,...t)=>Object.assign(e,...t),Et=e=>{if(!e)return;if(oe(e))return E().createElement(e);const{tagName:t}=e,s=Et(t);if(!s)return;const n={...e};return delete n.tagName,ct(s,n)},b=(e,t)=>e.dispatchEvent(t),z=(e,t)=>{const s=getComputedStyle(e),n=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return s.getPropertyValue(n)},Uo=e=>{const t=z(e,Ln),s=z(e,Wo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},ie=e=>{const t=z(e,Ln),s=z(e,Fo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},A=(e,t)=>{let s=0;const n=new Event(ke),o=ie(e),i=Uo(e);if(o){const r=a=>{a.target===e&&(t.apply(e,[a]),e.removeEventListener(ke,r),s=1)};e.addEventListener(ke,r),setTimeout(()=>{s||b(e,n)},o+i+17)}else t.apply(e,[n])},lt=(e,t)=>e.focus(t),Ls=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,he=e=>Object.entries(e),Wt=e=>e.toLowerCase(),Xo=(e,t,s,n)=>{const o={...s},i={...e.dataset},r={...t},a={},c="title";return he(i).forEach(([l,d])=>{const g=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,$=>Wt($)):l;a[g]=Ls(d)}),he(o).forEach(([l,d])=>{o[l]=Ls(d)}),he(t).forEach(([l,d])=>{l in o?r[l]=o[l]:l in a?r[l]=a[l]:r[l]=l===c?et(e,c):d}),r},Os=e=>Object.keys(e),w=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return ne(t)&&ct(s,t),s},Jt={passive:!0},Ot=e=>e.offsetHeight,P=(e,t)=>{he(t).forEach(([s,n])=>{if(n&&oe(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,ct(e.style,o)}})},Ue=e=>ne(e)&&e.constructor.name==="Map"||!1,qo=e=>typeof e=="number"||!1,mt=new Map,p={set:(e,t,s,n)=>{T(e)&&(n&&n.length?(mt.has(e)||mt.set(e,new Map),mt.get(e).set(n,setTimeout(t,s))):mt.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!T(e))return null;const s=mt.get(e);return t&&s&&Ue(s)?s.get(t)||null:qo(s)?s:null},clear:(e,t)=>{if(!T(e))return;const s=mt.get(e);t&&t.length&&Ue(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&&mt.delete(e)):(clearTimeout(s),mt.delete(e))}},Z=(e,t)=>(H(t)?t:E()).querySelectorAll(e),Xe=new Map;function Yo(e){const{shiftKey:t,code:s}=e,n=E(this),o=[...Z(Ro,this)].filter(a=>!Gt(a,"disabled")&&!et(a,se));if(!o.length)return;const i=o[0],r=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(r.focus(),e.preventDefault()):!t&&n.activeElement===r&&(i.focus(),e.preventDefault()))}const Zo=e=>Xe.has(e)===!0,Te=e=>{const t=Zo(e);(t?zo:jo)(e,"keydown",Yo),t?Xe.delete(e):Xe.set(e,!0)},re=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:r,left:a}=e.getBoundingClientRect();let c=1,l=1;if(t&&T(e)){const{offsetWidth:d,offsetHeight:g}=e;c=d>0?Math.round(s)/d:1,l=g>0?Math.round(n)/g:1}return{width:s/c,height:n/l,top:o/l,right:i/c,bottom:r/l,left:a/c,x:a/c,y:o/l}},$t=e=>E(e).body,dt=e=>E(e).documentElement,kn=e=>H(e)&&e.constructor.name==="ShadowRoot"||!1,Go=e=>e.nodeName==="HTML"?e:T(e)&&e.assignedSlot||H(e)&&e.parentNode||kn(e)&&e.host||dt(e);let ks=0,Ns=0;const Rt=new Map,Nn=(e,t)=>{let s=t?ks:Ns;if(t){const n=Nn(e),o=Rt.get(n)||new Map;Rt.has(n)||Rt.set(n,o),Ue(o)&&!o.has(t)?(o.set(t,s),ks+=1):s=o.get(t)}else{const n=e.id||e;Rt.has(n)?s=Rt.get(n):(Rt.set(n,s),Ns+=1)}return s},Jo=e=>e?On(e)?e.defaultView:H(e)?e?.ownerDocument?.defaultView:e:window,Qo=e=>Array.isArray(e)||!1,_n=e=>{if(!H(e))return!1;const{top:t,bottom:s}=re(e),{clientHeight:n}=dt(e);return t<=n&&s>=0},ti=e=>typeof e=="function"||!1,ei=e=>ne(e)&&e.constructor.name==="NodeList"||!1,yt=e=>dt(e).dir==="rtl",si=e=>H(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,N=(e,t)=>e?e.closest(t)||N(e.getRootNode().host,t):null,D=(e,t)=>T(e)?e:(H(t)?t:E()).querySelector(e),ls=(e,t)=>(H(t)?t:E()).getElementsByTagName(e),rt=(e,t)=>(t&&H(t)?t:E()).getElementsByClassName(e),Mn=(e,t)=>e.matches(t),Ft={},Bn=e=>{const{type:t,currentTarget:s}=e;[...Ft[t]].forEach(([n,o])=>{s===n&&[...o].forEach(([i,r])=>{i.apply(n,[e]),typeof r=="object"&&r.once&&B(n,t,i,r)})})},M=(e,t,s,n)=>{Ft[t]||(Ft[t]=new Map);const o=Ft[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:r}=i;i.set(s,n);r||e.addEventListener(t,Bn,n)},B=(e,t,s,n)=>{const o=Ft[t],i=o&&o.get(e),r=i&&i.get(s),a=r!==void 0?r:n;i&&i.has(s)&&i.delete(s);o&&(!i||!i.size)&&o.delete(e);(!o||!o.size)&&delete Ft[t];(!i||!i.size)&&e.removeEventListener(t,Bn,a)},_="fade",u="show",ye="data-bs-dismiss",$e="alert",Rn="Alert",ni="5.1.0",oi=ni;class st{constructor(t,s){let n;try{if(T(t))n=t;else if(oe(t)){if(n=D(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=Dt.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&Os(this.defaults).length?Xo(n,this.defaults,s||{},"bs"):{},Dt.set(n,this.name,this)}get version(){return oi}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){Dt.remove(this.element,this.name),Os(this).forEach(t=>{delete this[t]})}}const ii=`.${$e}`,ri=`[${ye}="${$e}"]`,ai=e=>W(e,Rn),ci=e=>new ds(e),_s=w(`close.bs.${$e}`),li=w(`closed.bs.${$e}`),Ms=e=>{const{element:t}=e;b(t,li),e._toggleEventListeners(),e.dispose(),t.remove()};class ds extends st{static selector=ii;static init=ci;static getInstance=ai;dismiss;constructor(t){super(t),this.dismiss=D(ri,this.element),this._toggleEventListeners(!0)}get name(){return Rn}close=()=>{const{element:t}=this;t&&f(t,u)&&(b(t,_s),_s.defaultPrevented||(m(t,u),f(t,_)?A(t,()=>Ms(this)):Ms(this)))};_toggleEventListeners=t=>{const s=t?M:B,{dismiss:n,close:o}=this;n&&s(n,O,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const y="active",ot="data-bs-toggle",di="button",Fn="Button",hi=`[${ot}="${di}"]`,fi=e=>W(e,Fn),gi=e=>new hs(e);class hs extends st{static selector=hi;static init=gi;static getInstance=fi;isActive=!1;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,y),k(s,As,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return Fn}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!et(s,"disabled")&&((n?m:h)(s,y),k(s,As,n?"false":"true"),this.isActive=f(s,y))};_toggleEventListeners=t=>{(t?M:B)(this.element,O,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const qe="data-bs-target",Ht="carousel",Wn="Carousel",Bs="data-bs-parent",pi="data-bs-container",U=e=>{const t=[qe,Bs,pi,"href"],s=E(e);return t.map(n=>{const o=et(e,n);return o?n===Bs?N(e,o):D(o,s):null}).filter(n=>n)[0]},ae=`[data-bs-ride="${Ht}"]`,Y=`${Ht}-item`,Ye="data-bs-slide-to",bt="data-bs-slide",wt="paused",Rs={pause:"hover",keyboard:!1,touch:!0,interval:5e3},ht=e=>W(e,Wn),ui=e=>new fs(e);let Zt=0,fe=0,Ne=0;const _e=w(`slide.bs.${Ht}`),Ze=w(`slid.bs.${Ht}`),Fs=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const r=Ge(e),a=s==="left"?"next":"prev",c=s==="left"?"start":"end";h(o[t],y),m(o[t],`${Y}-${a}`),m(o[t],`${Y}-${c}`),m(o[r],y),m(o[r],`${Y}-${c}`),b(n,Ze),p.clear(n,bt),e.cycle&&!E(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function mi(){const e=ht(this);e&&!e.isPaused&&!p.get(this,wt)&&h(this,wt)}function vi(){const e=ht(this);e&&e.isPaused&&!p.get(this,wt)&&e.cycle()}function bi(e){e.preventDefault();const t=N(this,ae)||U(this),s=ht(t);if(s&&!s.isAnimating){const n=+(et(this,Ye)||0);this&&!f(this,y)&&!Number.isNaN(n)&&s.to(n)}}function Ei(e){e.preventDefault();const t=N(this,ae)||U(this),s=ht(t);if(s&&!s.isAnimating){const n=et(this,bt);n==="next"?s.next():n==="prev"&&s.prev()}}const wi=({code:e,target:t})=>{const s=E(t),[n]=[...Z(ae,s)].filter(i=>_n(i)),o=ht(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=yt(n);e===(i?Is:Ps)?o.prev():e===(i?Ps:Is)&&o.next()}};function Ws(e){const{target:t}=e,s=ht(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function Ti(e){const{target:t}=e,s=ht(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(Zt=e.pageX,this.contains(t)&&(s.isTouch=!0,Vn(s,!0)))}}const yi=e=>{fe=e.pageX},$i=e=>{const{target:t}=e,s=E(t),n=[...Z(ae,s)].map(o=>ht(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,r=yt(o);Ne=e.pageX,n.isTouch=!1,Vn(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(Zt-Ne)>120&&(feZt&&n.to(i+(r?1:-1))),Zt=0,fe=0,Ne=0}},Me=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>m(n,y)),e.indicators[t]&&h(s[t],y)},Vn=(e,t)=>{const{element:s}=e,n=t?M:B;n(E(s),_o,yi,Jt),n(E(s),Mo,$i,Jt)},Ge=e=>{const{slides:t,element:s}=e,n=D(`.${Y}.${y}`,s);return T(n)?[...t].indexOf(n):-1};class fs extends st{static selector=ae;static init=ui;static getInstance=ht;constructor(t,s){super(t,s);const{element:n}=this;this.direction=yt(n)?"right":"left",this.isTouch=!1,this.slides=rt(Y,n);const{slides:o}=this;if(o.length>=2){const i=Ge(this),r=[...o].find(l=>Mn(l,`.${Y}-next,.${Y}-next`));this.index=i;const a=E(n);this.controls=[...Z(`[${bt}]`,n),...Z(`[${bt}][${qe}="#${n.id}"]`,a)].filter((l,d,g)=>d===g.indexOf(l)),this.indicator=D(`.${Ht}-indicators`,n),this.indicators=[...this.indicator?Z(`[${Ye}]`,this.indicator):[],...Z(`[${Ye}][${qe}="#${n.id}"]`,a)].filter((l,d,g)=>d===g.indexOf(l));const{options:c}=this;this.options.interval=c.interval===!0?Rs.interval:c.interval,r?this.index=[...o].indexOf(r):i<0&&(this.index=0,h(o[0],y),this.indicators.length&&Me(this,0)),this.indicators.length&&Me(this,this.index),this._toggleEventListeners(!0),c.interval&&this.cycle()}}get name(){return Wn}get defaults(){return Rs}get isPaused(){return f(this.element,wt)}get isAnimating(){return D(`.${Y}-next,.${Y}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;p.clear(t,Ht),n&&(p.clear(t,wt),m(t,wt)),p.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&_n(t)&&this.to(o+1)},s.interval,Ht)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,wt),p.set(t,()=>{},1,wt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Ge(this),r=yt(s);let a=t;if(!this.isAnimating&&i!==a&&!p.get(s,bt)){ia||i===n.length-1&&a===0)&&(this.direction=r?"left":"right");const{direction:c}=this;a<0?a=n.length-1:a>=n.length&&(a=0);const l=c==="left"?"next":"prev",d=c==="left"?"start":"end",g={relatedTarget:n[a],from:i,to:a,direction:c};ct(_e,g),ct(Ze,g),b(s,_e),_e.defaultPrevented||(this.index=a,Me(this,a),ie(n[a])&&f(s,"slide")?p.set(s,()=>{h(n[a],`${Y}-${l}`),Ot(n[a]),h(n[a],`${Y}-${d}`),h(n[i],`${Y}-${d}`),A(n[a],()=>this.slides&&this.slides.length&&Fs(this))},0,bt):(h(n[a],y),m(n[i],y),p.set(s,()=>{p.clear(s,bt),s&&o.interval&&!this.isPaused&&this.cycle(),b(s,Ze)},0,bt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:r}=this,{touch:a,pause:c,interval:l,keyboard:d}=n,g=t?M:B;c&&l&&(g(s,we,mi),g(s,rs,vi)),a&&o.length>2&&(g(s,No,Ti,Jt),g(s,as,Ws,{passive:!1}),g(s,Bo,Ws,{passive:!1})),i.length&&i.forEach($=>{$&&g($,O,Ei)}),r.length&&r.forEach($=>{g($,O,bi)}),d&&g(E(s),Ee,wi)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&A(s.slides[s.index],()=>{Fs(s)})}}const It="collapsing",K="collapse",jn="Collapse",Ci=`.${K}`,zn=`[${ot}="${K}"]`,Si={parent:null},ge=e=>W(e,jn),xi=e=>new gs(e),Vs=w(`show.bs.${K}`),Di=w(`shown.bs.${K}`),js=w(`hide.bs.${K}`),Hi=w(`hidden.bs.${K}`),Ai=e=>{const{element:t,parent:s,triggers:n}=e;b(t,Vs),Vs.defaultPrevented||(p.set(t,ve,17),s&&p.set(s,ve,17),h(t,It),m(t,K),P(t,{height:`${t.scrollHeight}px`}),A(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>k(o,me,"true")),m(t,It),h(t,K),h(t,u),P(t,{height:""}),b(t,Di)}))},zs=e=>{const{element:t,parent:s,triggers:n}=e;b(t,js),js.defaultPrevented||(p.set(t,ve,17),s&&p.set(s,ve,17),P(t,{height:`${t.scrollHeight}px`}),m(t,K),m(t,u),h(t,It),Ot(t),P(t,{height:"0px"}),A(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>k(o,me,"false")),m(t,It),h(t,K),P(t,{height:""}),b(t,Hi)}))},Pi=e=>{const{target:t}=e,s=t&&N(t,zn),n=s&&U(s),o=n&&ge(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class gs extends st{static selector=Ci;static init=xi;static getInstance=ge;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=E(n);this.triggers=[...Z(zn,i)].filter(r=>U(r)===n),this.parent=T(o.parent)?o.parent:oe(o.parent)?U(n)||D(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return jn}get defaults(){return Si}hide(){const{triggers:t,element:s}=this;p.get(s)||(zs(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...Z(`.${K}.${u}`,s)].find(r=>ge(r)),i=o&&ge(o)),(!s||!p.get(s))&&!p.get(t)&&(i&&o!==t&&(zs(i),i.triggers.forEach(r=>{h(r,`${K}d`)})),Ai(this),n.length&&n.forEach(r=>m(r,`${K}d`)))}toggle(){f(this.element,u)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?M:B,{triggers:n}=this;n.length&&n.forEach(o=>s(o,O,Pi))};dispose(){this._toggleEventListeners(),super.dispose()}}const Lt=["dropdown","dropup","dropstart","dropend"],Kn="Dropdown",Un="dropdown-menu",Xn=e=>{const t=N(e,"A");return e.tagName==="A"&&Gt(e,"href")&&et(e,"href").slice(-1)==="#"||t&&Gt(t,"href")&&et(t,"href").slice(-1)==="#"},[tt,Je,Qe,ts]=Lt,qn=`[${ot}="${tt}"]`,Vt=e=>W(e,Kn),Ii=e=>new ps(e),Li=`${Un}-end`,Ks=[tt,Je],Us=[Qe,ts],Xs=["A","BUTTON"],Oi={offset:5,display:"dynamic"},Be=w(`show.bs.${tt}`),qs=w(`shown.bs.${tt}`),Re=w(`hide.bs.${tt}`),Ys=w(`hidden.bs.${tt}`),Yn=w(`updated.bs.${tt}`),Zn=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(z(s,"position")!=="static"){const r=yt(t),a=f(s,Li);["margin","top","bottom","left","right"].forEach(L=>{const gt={};gt[L]="",P(s,gt)});let l=Lt.find(L=>f(n,L))||tt;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:r?[-1,0,0,i]:[-1,i,0],dropend:r?[-1,i,0]:[-1,0,0,i]},g={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:r?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:r?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:r?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:r?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:$,offsetHeight:S}=s,{clientWidth:R,clientHeight:v}=dt(t),{left:V,top:X,width:Nt,height:it}=re(t),C=V-$-i<0,Q=V+$+Nt+i>=R,nt=X+S+i>=v,F=X+S+it+i>=v,j=X-S-i<0,x=(!r&&a||r&&!a)&&V+Nt-$<0,_t=(r&&a||!r&&!a)&&V+$>=R;if(Us.includes(l)&&C&&Q&&(l=tt),l===Qe&&(r?Q:C)&&(l=ts),l===ts&&(r?C:Q)&&(l=Qe),l===Je&&j&&!F&&(l=tt),l===tt&&F&&!j&&(l=Je),Us.includes(l)&&nt&&ct(g[l],{top:"auto",bottom:0}),Ks.includes(l)&&(x||_t)){let L={left:"auto",right:"auto"};!x&&_t&&!r&&(L={left:"auto",right:0}),x&&!_t&&r&&(L={left:0,right:"auto"}),L&&ct(g[l],L)}const ft=d[l];P(s,{...g[l],margin:`${ft.map(L=>L&&`${L}px`).join(" ")}`}),Ks.includes(l)&&a&&a&&P(s,g[!r&&x||r&&_t?"menuStart":"menuEnd"]),b(n,Yn)}},ki=e=>[...e.children].map(t=>{if(t&&Xs.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&Xs.includes(s.tagName)?s:null}).filter(t=>t),Zs=e=>{const{element:t,options:s,menu:n}=e,o=e.open?M:B,i=E(t);o(i,O,Gs),o(i,os,Gs),o(i,Ee,_i),o(i,Oo,Mi),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},Ce=e=>{const t=[...Lt,"btn-group","input-group"].map(s=>rt(`${s} ${u}`,E(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>Lt.some(n=>n===et(s,ot)))},Gs=e=>{const{target:t,type:s}=e;if(t&&T(t)){const n=Ce(t),o=n&&Vt(n);if(o){const{parentElement:i,menu:r}=o,a=i&&i.contains(t)&&(t.tagName==="form"||N(t,"form")!==null);[O,In].includes(s)&&Xn(t)&&e.preventDefault(),!a&&s!==os&&t!==n&&t!==r&&o.hide()}}},Ni=e=>{const{target:t}=e,s=t&&N(t,qn),n=s&&Vt(s);n&&(e.stopPropagation(),n.toggle(),s&&Xn(s)&&e.preventDefault())},_i=e=>{[ze,Ke].includes(e.code)&&e.preventDefault()};function Mi(e){const{code:t}=e,s=Ce(this),n=s&&Vt(s),{activeElement:o}=s&&E(s);if(n&&o){const{menu:i,open:r}=n,a=ki(i);if(a&&a.length&&[ze,Ke].includes(t)){let c=a.indexOf(o);o===s?c=0:t===Ke?c=c>1?c-1:0:t===ze&&(c=cBi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return Kn}get defaults(){return Oi}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(!s){const i=Ce(t),r=i&&Vt(i);r&&r.hide(),[Be,qs,Yn].forEach(a=>{a.relatedTarget=t}),b(o,Be),Be.defaultPrevented||(h(n,u),h(o,u),k(t,me,"true"),Zn(this),this.open=!s,lt(t),Zs(this),b(o,qs))}}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([Re,Ys].forEach(i=>{i.relatedTarget=t}),b(o,Re),Re.defaultPrevented||(m(n,u),m(o,u),k(t,me,"false"),this.open=!s,Zs(this),b(o,Ys)))}_toggleEventListeners=t=>{(t?M:B)(this.element,O,Ni)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const q="modal",us="Modal",ms="Offcanvas",Ri="fixed-top",Fi="fixed-bottom",Gn="sticky-top",Jn="position-sticky",Qn=e=>[...rt(Ri,e),...rt(Fi,e),...rt(Gn,e),...rt(Jn,e),...rt("is-fixed",e)],Wi=e=>{const t=$t(e);P(t,{paddingRight:"",overflow:""});const s=Qn(t);s.length&&s.forEach(n=>{P(n,{paddingRight:"",marginRight:""})})},to=e=>{const{clientWidth:t}=dt(e),{innerWidth:s}=Jo(e);return Math.abs(s-t)},eo=(e,t)=>{const s=$t(e),n=parseInt(z(s,"paddingRight"),10),i=z(s,"overflow")==="hidden"&&n?0:to(e),r=Qn(s);t&&(P(s,{overflow:"hidden",paddingRight:`${n+i}px`}),r.length&&r.forEach(a=>{const c=z(a,"paddingRight");if(a.style.paddingRight=`${parseInt(c,10)+i}px`,[Gn,Jn].some(l=>f(a,l))){const l=z(a,"marginRight");a.style.marginRight=`${parseInt(l,10)-i}px`}}))},G="offcanvas",Tt=Et({tagName:"div",className:"popup-container"}),so=(e,t)=>{const s=H(t)&&t.nodeName==="BODY",n=H(t)&&!s?t:Tt,o=s?t:$t(e);H(e)&&(n===Tt&&o.append(Tt),n.append(e))},no=(e,t)=>{const s=H(t)&&t.nodeName==="BODY",n=H(t)&&!s?t:Tt;H(e)&&(e.remove(),n===Tt&&!Tt.children.length&&Tt.remove())},vs=(e,t)=>{const s=H(t)&&t.nodeName!=="BODY"?t:Tt;return H(e)&&s.contains(e)},oo="backdrop",Js=`${q}-${oo}`,Qs=`${G}-${oo}`,io=`.${q}.${u}`,bs=`.${G}.${u}`,I=Et("div"),kt=e=>D(`${io},${bs}`,E(e)),Es=e=>{const t=e?Js:Qs;[Js,Qs].forEach(s=>{m(I,s)}),h(I,t)},ro=(e,t,s)=>{Es(s),so(I,$t(e)),t&&h(I,_)},ao=()=>{f(I,u)||(h(I,u),Ot(I))},Se=()=>{m(I,u)},co=e=>{kt(e)||(m(I,_),no(I,$t(e)),Wi(e))},lo=e=>T(e)&&z(e,"visibility")!=="hidden"&&e.offsetParent!==null,Vi=`.${q}`,ho=`[${ot}="${q}"]`,ji=`[${ye}="${q}"]`,fo=`${q}-static`,zi={backdrop:!0,keyboard:!0},Qt=e=>W(e,us),Ki=e=>new ws(e),pe=w(`show.bs.${q}`),tn=w(`shown.bs.${q}`),Fe=w(`hide.bs.${q}`),en=w(`hidden.bs.${q}`),go=e=>{const{element:t}=e,s=to(t),{clientHeight:n,scrollHeight:o}=dt(t),{clientHeight:i,scrollHeight:r}=t,a=i!==r;if(!a&&s){const l={[yt(t)?"paddingLeft":"paddingRight"]:`${s}px`};P(t,l)}eo(t,a||n!==o)},po=(e,t)=>{const s=t?M:B,{element:n}=e;s(n,O,qi),s(E(n),Ee,Xi),t?e._observer.observe(n):e._observer.disconnect()},sn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;co(s),P(s,{paddingRight:"",display:""}),po(e);const o=pe.relatedTarget||t.find(lo);o&<(o),en.relatedTarget=n,b(s,en),Te(s)},nn=e=>{const{element:t,relatedTarget:s}=e;lt(t),po(e,!0),tn.relatedTarget=s,b(t,tn),Te(t)},on=e=>{const{element:t,hasFade:s}=e;P(t,{display:"block"}),go(e),kt(t)||P($t(t),{overflow:"hidden"}),h(t,u),Pt(t,se),k(t,be,"true"),s?A(t,()=>nn(e)):nn(e)},rn=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(I,u)&&!kt(t)?(Se(),A(I,()=>sn(e))):sn(e)},Ui=e=>{const{target:t}=e,s=t&&N(t,ho),n=s&&U(s),o=n&&Qt(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Xi=({code:e,target:t})=>{const s=D(io,E(t)),n=s&&Qt(s);if(n){const{options:o}=n;o.keyboard&&e===cs&&f(s,u)&&(n.relatedTarget=null,n.hide())}},qi=e=>{const{currentTarget:t}=e,s=t&&Qt(t);if(s&&t&&!p.get(t)){const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:r}=n,{target:a}=e,c=E(t)?.getSelection()?.toString().length,l=i.contains(a),d=a&&N(a,ji);o&&!l?p.set(t,()=>{h(t,fo),A(i,()=>Yi(s))},17):(d||!c&&!o&&!l&&r)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())}},Yi=e=>{const{element:t,modalDialog:s}=e,n=(ie(s)||0)+17;m(t,fo),p.set(t,()=>p.clear(t),n)};class ws extends st{static selector=Vi;static init=Ki;static getInstance=Qt;constructor(t,s){super(t,s);const{element:n}=this,o=D(`.${q}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...Z(ho,E(n))].filter(i=>U(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,_),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return us}get defaults(){return zi}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let r=0;if(!f(t,u)&&(pe.relatedTarget=o||void 0,b(t,pe),!pe.defaultPrevented)){const a=kt(t);if(a&&a!==t){const c=Qt(a)||W(a,ms);c&&c.hide()}i?(vs(I)?Es(!0):ro(t,n,!0),r=ie(I),ao(),setTimeout(()=>on(this),r)):(on(this),a&&f(I,u)&&Se())}}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,u)&&(Fe.relatedTarget=n||void 0,b(t,Fe),Fe.defaultPrevented||(m(t,u),k(t,se,"true"),Pt(t,be),s?A(t,()=>rn(this)):rn(this)))}update=()=>{f(this.element,u)&&go(this)};_toggleEventListeners=t=>{const s=t?M:B,{triggers:n}=this;n.length&&n.forEach(o=>s(o,O,Ui))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?A(s,o):o()}}const Zi=`.${G}`,Ts=`[${ot}="${G}"]`,Gi=`[${ye}="${G}"]`,xe=`${G}-toggling`,Ji={backdrop:!0,keyboard:!0,scroll:!1},te=e=>W(e,ms),Qi=e=>new ys(e),ue=w(`show.bs.${G}`),uo=w(`shown.bs.${G}`),We=w(`hide.bs.${G}`),mo=w(`hidden.bs.${G}`),tr=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=dt(t);eo(t,s!==n)},vo=(e,t)=>{const s=t?M:B,n=E(e.element);s(n,Ee,or),s(n,O,nr)},an=e=>{const{element:t,options:s}=e;s.scroll||(tr(e),P($t(t),{overflow:"hidden"})),h(t,xe),h(t,u),P(t,{visibility:"visible"}),A(t,()=>ir(e))},er=e=>{const{element:t,options:s}=e,n=kt(t);t.blur(),!n&&s.backdrop&&f(I,u)&&Se(),A(t,()=>rr(e))},sr=e=>{const t=N(e.target,Ts),s=t&&U(t),n=s&&te(s);n&&(n.relatedTarget=t,n.toggle(),t&&t.tagName==="A"&&e.preventDefault())},nr=e=>{const{target:t}=e,s=D(bs,E(t)),n=D(Gi,s),o=s&&te(s);if(o){const{options:i,triggers:r}=o,{backdrop:a}=i,c=N(t,Ts),l=E(s).getSelection();(!I.contains(t)||a!=="static")&&(!(l&&l.toString().length)&&(!s.contains(t)&&a&&(!c||r.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:null,o.hide()),c&&c.tagName==="A"&&e.preventDefault())}},or=({code:e,target:t})=>{const s=D(bs,E(t)),n=s&&te(s);n&&n.options.keyboard&&e===cs&&(n.relatedTarget=null,n.hide())},ir=e=>{const{element:t}=e;m(t,xe),Pt(t,se),k(t,be,"true"),k(t,"role","dialog"),b(t,uo),vo(e,!0),lt(t),Te(t)},rr=e=>{const{element:t,triggers:s}=e;k(t,se,"true"),Pt(t,be),Pt(t,"role"),P(t,{visibility:""});const n=ue.relatedTarget||s.find(lo);n&<(n),co(t),b(t,mo),m(t,xe),Te(t),kt(t)||vo(e)};class ys extends st{static selector=Zi;static init=Qi;static getInstance=te;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...Z(Ts,E(n))].filter(o=>U(o)===n),this.relatedTarget=null,this._toggleEventListeners(!0)}get name(){return ms}get defaults(){return Ji}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(!f(t,u)&&(ue.relatedTarget=n||void 0,uo.relatedTarget=n||void 0,b(t,ue),!ue.defaultPrevented)){const i=kt(t);if(i&&i!==t){const r=te(i)||W(i,us);r&&r.hide()}s.backdrop?(vs(I)?Es():ro(t,!0),o=ie(I),ao(),setTimeout(()=>an(this),o)):(an(this),i&&f(I,u)&&Se())}}hide(){const{element:t,relatedTarget:s}=this;f(t,u)&&(We.relatedTarget=s||void 0,mo.relatedTarget=s||void 0,b(t,We),We.defaultPrevented||(h(t,xe),m(t,u),er(this)))}_toggleEventListeners=t=>{const s=t?M:B;this.triggers.forEach(n=>s(n,O,sr))};dispose(){const{element:t}=this,s=f(t,u),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?A(t,n):n()}}const At="popover",De="Popover",at="tooltip",bo=e=>{const t=e===at,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},Eo={top:"top",bottom:"bottom",left:"start",right:"end"},es=e=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,options:i,arrow:r}=e;if(n){const a={...Eo},c=yt(s);P(n,{top:"",left:"",right:"",bottom:""});const l=e.name===De,{offsetWidth:d,offsetHeight:g}=n,{clientWidth:$,clientHeight:S,offsetWidth:R}=dt(s);let{placement:v}=i;const{clientWidth:V,offsetWidth:X}=o,it=z(o,"position")==="fixed",C=Math.abs(it?V-X:$-R),Q=c&&it?C:0,nt=$-(c?0:C)-1,{width:F,height:j,left:x,right:_t,top:ft}=re(s,!0),{x:L,y:gt}={x,y:ft};P(r,{top:"",left:"",right:"",bottom:""});let Ct=0,zt="",pt=0,Ae="",Mt="",le="",Pe="";const St=r.offsetWidth||0,ut=r.offsetHeight||0,Ie=St/2;let Kt=ft-g-ut<0,Ut=ft+g+j+ut>=S,Xt=x-d-St=nt;const de=["left","right"],Le=["top","bottom"];Kt=de.includes(v)?ft+j/2-g/2-ut<0:Kt,Ut=de.includes(v)?ft+g/2+j/2+ut>=S:Ut,Xt=Le.includes(v)?x+F/2-d/2=nt:qt,v=de.includes(v)&&Xt&&qt?"top":v,v=v==="top"&&Kt?"bottom":v,v=v==="bottom"&&Ut?"top":v,v=v==="left"&&Xt?"right":v,v=v==="right"&&qt?"left":v,n.className.includes(v)||(n.className=n.className.replace(t,a[v])),de.includes(v)?(v==="left"?pt=L-d-(l?St:0):pt=L+F+(l?St:0),Kt&&Ut?(Ct=0,zt=0,Mt=ft+j/2-ut/2):Kt?(Ct=gt,zt="",Mt=j/2-St):Ut?(Ct=gt-g+j,zt="",Mt=g-j/2-St):(Ct=gt-g/2+j/2,Mt=g/2-ut/2)):Le.includes(v)&&(v==="top"?Ct=gt-g-(l?ut:0):Ct=gt+j+(l?ut:0),Xt?(pt=0,le=L+F/2-Ie):qt?(pt="auto",Ae=0,Pe=F/2+nt-_t-Ie):(pt=L-d/2+F/2,le=d/2-Ie)),P(n,{top:`${Ct}px`,bottom:zt===""?"":`${zt}px`,left:pt==="auto"?pt:`${pt}px`,right:Ae!==""?`${Ae}px`:""}),T(r)&&(Mt!==""&&(r.style.top=`${Mt}px`),le!==""?r.style.left=`${le}px`:Pe!==""&&(r.style.right=`${Pe}px`));const Lo=w(`updated.bs.${Wt(e.name)}`);b(s,Lo)}},ss={template:bo(at),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},ar=e=>e!=null&&typeof e=="object"||!1,cr=e=>ar(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,cn=e=>cr(e)&&e.nodeType===1||!1,lr=e=>typeof e=="function"||!1,ln="PositionObserver Error";class wo{entries;_tick;_root;_callback;constructor(t,s){if(!lr(t))throw new Error(`${ln}: ${t} is not a function.`);this.entries=[],this._callback=t,this._root=cn(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!cn(t))throw new Error(`${ln}: ${t} is not an instance of HTMLElement.`);if(!this._root.contains(t))return;const{clientWidth:s,clientHeight:n}=this._root,o=t.getBoundingClientRect(),{left:i,top:r,bottom:a,right:c,width:l,height:d}=o,g=r>1-d&&i>1-l&&a<=n+d-1&&c<=s+l-1;this.entries.push({target:t,boundingBox:o,isVisible:g}),this._tick||(this._tick=requestAnimationFrame(this._runCallback))};unobserve=t=>{const s=this.entries.findIndex(n=>n.target===t);this.entries.splice(s,1)};_runCallback=()=>{if(!this.entries.length)return;const t=[],{clientWidth:s,clientHeight:n}=this._root;this.entries.forEach((o,i)=>{const{target:r,boundingBox:a}=o,c=r.getBoundingClientRect(),{left:l,top:d,bottom:g,right:$,width:S,height:R}=c;if(a.left!==l||a.top!==d||a.right!==$||a.bottom!==g){const v=d>1-R&&l>1-S&&g<=n+R-1&&$<=s+S-1;this.entries[i].boundingBox=c,this.entries[i].isVisible=v,t.push({target:r,boundingBox:c,isVisible:v})}}),t.length&&this._callback(t),requestAnimationFrame(this._runCallback)};disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.length=0,this._tick=0}}const To="data-original-title",xt="Tooltip",vt=(e,t,s)=>{if(oe(t)&&t.length){let n=t.trim();ti(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else T(t)?e.append(t):(ei(t)||Qo(t)&&t.every(H))&&e.append(...t)},dr=e=>{const t=e.name===xt,{id:s,element:n,options:o}=e,{title:i,placement:r,template:a,animation:c,customClass:l,sanitizeFn:d,dismissible:g,content:$,btnClose:S}=o,R=t?at:At,v={...Eo};let V=[],X=[];yt(n)&&(v.left="end",v.right="start");const Nt=`bs-${R}-${v[r]}`;let it;if(T(a))it=a;else{const Q=Et("div");vt(Q,a,d),it=Q.firstChild}e.tooltip=T(it)?it.cloneNode(!0):void 0;const{tooltip:C}=e;if(C){k(C,"id",s),k(C,"role",at);const Q=t?`${at}-inner`:`${At}-body`,nt=t?null:D(`.${At}-header`,C),F=D(`.${Q}`,C);e.arrow=D(`.${R}-arrow`,C);const{arrow:j}=e;if(T(i))V=[i.cloneNode(!0)];else{const x=Et("div");vt(x,i,d),V=[...x.childNodes]}if(T($))X=[$.cloneNode(!0)];else{const x=Et("div");vt(x,$,d),X=[...x.childNodes]}if(g)if(i)if(T(S))V=[...V,S.cloneNode(!0)];else{const x=Et("div");vt(x,S,d),V=[...V,x.firstChild]}else if(nt&&nt.remove(),T(S))X=[...X,S.cloneNode(!0)];else{const x=Et("div");vt(x,S,d),X=[...X,x.firstChild]}t?i&&F&&vt(F,i,d):(i&&nt&&vt(nt,V,d),$&&F&&vt(F,X,d),e.btn=D(".btn-close",C)||void 0),h(C,"position-fixed"),h(j,"position-absolute"),f(C,R)||h(C,R),c&&!f(C,_)&&h(C,_),l&&!f(C,l)&&h(C,l),f(C,Nt)||h(C,Nt)}},hr=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=Go(n),kn(n)||si(n)||s.push(n);return s.find((o,i)=>z(o,"position")!=="relative"&&s.slice(i+1).every(r=>z(r,"position")==="static")?o:null)||E(e).body},fr=`[${ot}="${at}"],[data-tip="${at}"]`,yo="title";let dn=e=>W(e,xt);const gr=e=>new He(e),pr=e=>{const{element:t,tooltip:s,container:n,offsetParent:o}=e;Pt(t,An),no(s,n===o?n:o)},Yt=e=>{const{tooltip:t,container:s,offsetParent:n}=e;return t&&vs(t,s===n?s:n)},ur=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),Gt(s,To)&&e.name===xt&&Co(e),t&&t()},$o=(e,t)=>{const s=t?M:B,{element:n}=e;s(E(n),as,e.handleTouch,Jt)},hn=e=>{const{element:t}=e,s=w(`shown.bs.${Wt(e.name)}`);$o(e,!0),b(t,s),p.clear(t,"in")},fn=e=>{const{element:t}=e,s=w(`hidden.bs.${Wt(e.name)}`);$o(e),pr(e),b(t,s),p.clear(t,"out")},gn=(e,t)=>{const s=t?M:B,{element:n}=e,o=N(n,`.${q}`),i=N(n,`.${G}`);t?e._observer.observe(e.element):e._observer.disconnect(),o&&s(o,`hide.bs.${q}`,e.handleHide),i&&s(i,`hide.bs.${G}`,e.handleHide)},Co=(e,t)=>{const s=[To,yo],{element:n}=e;k(n,s[t?0:1],t||et(n,s[0])||""),Pt(n,s[t?1:0])};class He extends st{static selector=fr;static init=gr;static getInstance=dn;static styleTip=es;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===xt,i=o?at:At,r=o?xt:De;dn=c=>W(c,r),this.enabled=!0,this.id=`${i}-${Nn(n,i)}`;const{options:a}=this;!a.title&&o||!o&&!a.content||(ct(ss,{titleAttr:""}),Gt(n,yo)&&o&&typeof a.title=="string"&&Co(this,a.title),this.container=hr(n),this.offsetParent=["sticky","fixed"].some(c=>z(this.container,"position")===c)?this.container:E(this.element).body,dr(this),this._observer=new wo(()=>this.update()),this._toggleEventListeners(!0))}get name(){return xt}get defaults(){return ss}handleFocus=()=>lt(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,offsetParent:i,id:r}=this,{animation:a}=t,c=p.get(n,"out"),l=o===i?o:i;p.clear(n,"out"),s&&!c&&!Yt(this)&&p.set(n,()=>{const d=w(`show.bs.${Wt(this.name)}`);b(n,d),d.defaultPrevented||(so(s,l),k(n,An,`#${r}`),this.update(),gn(this,!0),f(s,u)||h(s,u),a?A(s,()=>hn(this)):hn(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;p.clear(n,"in"),s&&Yt(this)&&p.set(n,()=>{const r=w(`hide.bs.${Wt(this.name)}`);b(n,r),r.defaultPrevented||(this.update(),m(s,u),gn(this),o?A(s,()=>fn(this)):fn(this))},i+17,"out")}update=()=>{es(this)};toggle=()=>{const{tooltip:t}=this;t&&!Yt(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&Yt(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?M:B,{element:n,options:o,btn:i}=this,{trigger:r}=o,c=!!(this.name!==xt&&o.dismissible);r.includes("manual")||(this.enabled=!!t,r.split(" ").forEach(d=>{d===ko?(s(n,In,this.handleShow),s(n,we,this.handleShow),c||(s(n,rs,this.handleHide),s(E(n),as,this.handleTouch,Jt))):d===O?s(n,d,c?this.handleShow:this.toggle):d===os&&(s(n,is,this.handleShow),c||s(n,Pn,this.handleHide),Vo()&&s(n,O,this.handleFocus)),c&&i&&s(i,O,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>ur(n,()=>super.dispose()),17);s.animation&&Yt(n)?(this.options.delay=0,this.hide(),A(t,o)):o()}}const mr=`[${ot}="${At}"],[data-tip="${At}"]`,vr=ct({},ss,{template:bo(At),content:"",dismissible:!1,btnClose:''}),br=e=>W(e,De),Er=e=>new $s(e);class $s extends He{static selector=mr;static init=Er;static getInstance=br;static styleTip=es;constructor(t,s){super(t,s)}get name(){return De}get defaults(){return vr}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>lt(s),17)}}const wr="scrollspy",So="ScrollSpy",Tr='[data-bs-spy="scroll"]',yr={offset:10,target:null},$r=e=>W(e,So),Cr=e=>new Cs(e),pn=w(`activate.bs.${wr}`),Sr=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:r}=e,{offset:a}=n,c=s!==r,l=t&&ls("A",t),d=E(r),g=s.scrollHeight;if(e.scrollTop=s.scrollTop,l&&(g!==i||o!==l.length)){let $,S,R;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=g,e.maxScroll=e.scrollHeight-Dr(e),Array.from(l).forEach(v=>{$=et(v,"href"),S=$&&$.charAt(0)==="#"&&$.slice(-1)!=="#"&&D($,d),S&&(e.items.push(v),e.targets.push(S),R=re(S),e.offsets.push((c?R.top+e.scrollTop:S.offsetTop)-a))}),e.itemsLength=e.items.length}},un=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},xr=e=>e.scrollHeight,Dr=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:re(e).height,xo=e=>{[...ls("A",e)].forEach(t=>{f(t,y)&&m(t,y)})},mn=(e,t)=>{const{target:s,element:n}=e;T(s)&&xo(s),e.activeItem=t,h(t,y);const o=[];let i=t;for(;i!==$t(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(r=>{const a=r.previousElementSibling;a&&!f(a,y)&&h(a,y)}),pn.relatedTarget=t,b(n,pn)};class Cs extends st{static selector=Tr;static init=Cr;static getInstance=$r;constructor(t,s){super(t,s);const{element:n,options:o}=this;this.target=D(o.target,E(n)),this.target&&(this.scrollTarget=n.clientHeightthis.refresh(),{root:this.scrollTarget}),un(this,!0))}get name(){return So}get defaults(){return yr}refresh=()=>{const{target:t}=this;if(T(t)&&t.offsetHeight>0){Sr(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:r}=this;if(s>=n){const c=i[o-1];r!==c&&mn(this,c);return}const{offsets:a}=this;if(r&&s0){this.activeItem=null,t&&xo(t);return}i.forEach((c,l)=>{r!==c&&s>=a[l]&&(typeof a[l+1]>"u"||sW(e,Do),Hr=e=>new Ss(e),Ve=w(`show.bs.${ce}`),bn=w(`shown.bs.${ce}`),je=w(`hide.bs.${ce}`),En=w(`hidden.bs.${ce}`),ee=new Map,wn=e=>{const{tabContent:t,nav:s}=e;t&&f(t,It)&&(t.style.height="",m(t,It)),s&&p.clear(s)},Tn=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=T(o)&&ee.get(o)||{tab:null};if(s&&n&&f(n,_)){const{currentHeight:r,nextHeight:a}=ee.get(t)||{currentHeight:0,nextHeight:0};r!==a?setTimeout(()=>{s.style.height=`${a}px`,Ot(s),A(s,()=>wn(e))},50):wn(e)}else o&&p.clear(o);bn.relatedTarget=i,b(t,bn)},yn=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:r}=o&&ee.get(o)||{tab:null,content:null};let a=0;if(n&&s&&f(s,_)&&([r,s].forEach(c=>{T(c)&&h(c,"overflow-hidden")}),a=T(r)?r.scrollHeight:0),Ve.relatedTarget=i,En.relatedTarget=t,b(t,Ve),!Ve.defaultPrevented){if(s&&h(s,y),r&&m(r,y),n&&s&&f(s,_)){const c=s.scrollHeight;ee.set(t,{currentHeight:a,nextHeight:c,tab:null,content:null}),h(n,It),n.style.height=`${a}px`,Ot(n),[r,s].forEach(l=>{l&&m(l,"overflow-hidden")})}s&&s&&f(s,_)?setTimeout(()=>{h(s,u),A(s,()=>{Tn(e)})},1):(s&&h(s,u),Tn(e)),i&&b(i,En)}},$n=e=>{const{nav:t}=e;if(!T(t))return{tab:null,content:null};const s=rt(y,t);let n=null;s.length===1&&!Lt.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=T(n)?U(n):null;return{tab:n,content:o}},Cn=e=>{if(!T(e))return null;const t=N(e,`.${Lt.join(",.")}`);return t?D(`.${Lt[0]}-toggle`,t):null},Ar=e=>{const t=Ho(e.target);t&&(e.preventDefault(),t.show())};class Ss extends st{static selector=vn;static init=Hr;static getInstance=Ho;constructor(t){super(t);const{element:s}=this,n=U(s);if(n){const o=N(s,".nav"),i=N(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=Cn(s);const{tab:r}=$n(this);if(o&&!r){const a=D(vn,o),c=a&&U(a);c&&(h(a,y),h(c,u),h(c,y),k(s,Oe,"true"))}this._toggleEventListeners(!0)}}get name(){return Do}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(!(n&&p.get(n))&&!f(t,y)){const{tab:i,content:r}=$n(this);if(n&&ee.set(n,{tab:i,content:r,currentHeight:0,nextHeight:0}),je.relatedTarget=t,T(i)&&(b(i,je),!je.defaultPrevented)){h(t,y),k(t,Oe,"true");const a=T(i)&&Cn(i);if(a&&f(a,y)&&m(a,y),n){const c=()=>{i&&(m(i,y),k(i,Oe,"false")),o&&!f(o,y)&&h(o,y)};r&&(f(r,_)||s&&f(s,_))?p.set(n,c,1):c()}r&&(m(r,u),f(r,_)?A(r,()=>yn(this)):yn(this))}}}_toggleEventListeners=t=>{(t?M:B)(this.element,O,Ar)};dispose(){this._toggleEventListeners(),super.dispose()}}const J="toast",Ao="Toast",Pr=`.${J}`,Ir=`[${ye}="${J}"]`,Po=`[${ot}="${J}"]`,jt="showing",Io="hide",Lr={animation:!0,autohide:!0,delay:5e3},xs=e=>W(e,Ao),Or=e=>new Ds(e),Sn=w(`show.bs.${J}`),kr=w(`shown.bs.${J}`),xn=w(`hide.bs.${J}`),Nr=w(`hidden.bs.${J}`),Dn=e=>{const{element:t,options:s}=e;m(t,jt),p.clear(t,jt),b(t,kr),s.autohide&&p.set(t,()=>e.hide(),s.delay,J)},Hn=e=>{const{element:t}=e;m(t,jt),m(t,u),h(t,Io),p.clear(t,J),b(t,Nr)},_r=e=>{const{element:t,options:s}=e;h(t,jt),s.animation?(Ot(t),A(t,()=>Hn(e))):Hn(e)},Mr=e=>{const{element:t,options:s}=e;p.set(t,()=>{m(t,Io),Ot(t),h(t,u),h(t,jt),s.animation?A(t,()=>Dn(e)):Dn(e)},17,jt)},Br=e=>{const{target:t}=e,s=t&&N(t,Po),n=s&&U(s),o=n&&xs(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},Rr=e=>{const t=e.target,s=xs(t),{type:n,relatedTarget:o}=e;s&&t!==o&&!t.contains(o)&&([we,is].includes(n)?p.clear(t,J):p.set(t,()=>s.hide(),s.options.delay,J))};class Ds extends st{static selector=Pr;static init=Or;static getInstance=xs;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,_)?h(n,_):!o.animation&&f(n,_)&&m(n,_),this.dismiss=D(Ir,n),this.triggers=[...Z(Po,E(n))].filter(i=>U(i)===n),this._toggleEventListeners(!0)}get name(){return Ao}get defaults(){return Lr}get isShown(){return f(this.element,u)}show=()=>{const{element:t,isShown:s}=this;t&&!s&&(b(t,Sn),Sn.defaultPrevented||Mr(this))};hide=()=>{const{element:t,isShown:s}=this;t&&s&&(b(t,xn),xn.defaultPrevented||_r(this))};_toggleEventListeners=t=>{const s=t?M:B,{element:n,triggers:o,dismiss:i,options:r,hide:a}=this;i&&s(i,O,a),r.autohide&&[is,Pn,we,rs].forEach(c=>s(n,c,Rr)),o.length&&o.forEach(c=>s(c,O,Br))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),p.clear(t,J),s&&m(t,u),super.dispose()}}const Hs=new Map;[ds,hs,fs,gs,ps,ws,ys,$s,Cs,Ss,Ds,He].forEach(e=>Hs.set(e.prototype.name,e));const Fr=(e,t)=>{[...t].forEach(s=>e(s))},Wr=(e,t)=>{const s=Dt.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},ns=e=>{const t=e&&e.nodeName?e:document,s=[...ls("*",t)];Hs.forEach(n=>{const{init:o,selector:i}=n;Fr(o,s.filter(r=>Mn(r,i)))})},Vr=e=>{const t=e&&e.nodeName?e:document;Hs.forEach(s=>{Wr(s.prototype.name,t)})};document.body?ns():M(document,"DOMContentLoaded",()=>ns(),{once:!0});exports.Alert=ds;exports.Button=hs;exports.Carousel=fs;exports.Collapse=gs;exports.Dropdown=ps;exports.Modal=ws;exports.Offcanvas=ys;exports.Popover=$s;exports.ScrollSpy=Cs;exports.Tab=Ss;exports.Toast=Ds;exports.Tooltip=He;exports.initCallback=ns;exports.removeDataAPI=Vr; +"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const In="aria-describedby",we="aria-expanded",ie="aria-hidden",Te="aria-modal",Is="aria-pressed",Oe="aria-selected",rs="focus",cs="focusin",Ln="focusout",$e="keydown",Ro="keyup",I="click",_n="mousedown",Bo="hover",ye="mouseenter",as="mouseleave",Fo="pointerdown",Wo="pointermove",jo="pointerup",ls="touchstart",zo="dragstart",Vo='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',qe="ArrowDown",Xe="ArrowUp",Ls="ArrowLeft",_s="ArrowRight",ds="Escape",Ko="transitionDuration",qo="transitionDelay",Ne="transitionend",On="transitionProperty",Xo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},Ee=()=>{},Yo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},Uo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},et=(e,t)=>e.getAttribute(t),te=(e,t)=>e.hasAttribute(t),L=(e,t,s)=>e.setAttribute(t,s),It=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},v=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),re=e=>e!=null&&typeof e=="object"||!1,D=e=>re(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,G=e=>D(e)&&e.nodeType===1||!1,Wt=new Map,Dt={data:Wt,set:(e,t,s)=>{G(e)&&(Wt.has(t)||Wt.set(t,new Map),Wt.get(t).set(e,s))},getAllFor:e=>Wt.get(e)||null,get:(e,t)=>{if(!G(e)||!t)return null;const s=Dt.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=Dt.getAllFor(t);!s||!G(e)||(s.delete(e),s.size===0&&Wt.delete(t))}},j=(e,t)=>Dt.get(e,t),ce=e=>typeof e=="string"||!1,Nn=e=>re(e)&&e.constructor.name==="Window"||!1,Mn=e=>D(e)&&e.nodeType===9||!1,w=e=>Mn(e)?e:D(e)?e.ownerDocument:Nn(e)?e.document:globalThis.document,ct=(e,...t)=>Object.assign(e,...t),vt=e=>{if(!e)return;if(ce(e))return w().createElement(e);const{tagName:t}=e,s=vt(t);if(!s)return;const n={...e};return delete n.tagName,ct(s,n)},b=(e,t)=>e.dispatchEvent(t),W=(e,t,s)=>{const n=getComputedStyle(e,s),o=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return n.getPropertyValue(o)},Go=e=>{const t=W(e,On),s=W(e,qo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},ae=e=>{const t=W(e,On),s=W(e,Ko),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},H=(e,t)=>{let s=0;const n=new Event(Ne),o=ae(e),i=Go(e);if(o){const r=c=>{c.target===e&&(t.apply(e,[c]),e.removeEventListener(Ne,r),s=1)};e.addEventListener(Ne,r),setTimeout(()=>{s||b(e,n)},o+i+17)}else t.apply(e,[n])},at=(e,t)=>e.focus(t),Os=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,ue=e=>Object.entries(e),Vt=e=>e.toLowerCase(),Zo=(e,t,s,n)=>{if(!G(e))return t;const o={...s},i={...e.dataset},r={...t},c={},a="title";return ue(i).forEach(([l,d])=>{const g=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,E=>Vt(E)):l;c[g]=Os(d)}),ue(o).forEach(([l,d])=>{o[l]=Os(d)}),ue(t).forEach(([l,d])=>{l in o?r[l]=o[l]:l in c?r[l]=c[l]:r[l]=l===a?et(e,a):d}),r},Ns=e=>Object.keys(e),T=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return re(t)&&ct(s,t),s},ee={passive:!0},Ot=e=>e.offsetHeight,P=(e,t)=>{ue(t).forEach(([s,n])=>{if(n&&ce(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,ct(e.style,o)}})},Ye=e=>re(e)&&e.constructor.name==="Map"||!1,Qo=e=>typeof e=="number"||!1,ut=new Map,u={set:(e,t,s,n)=>{G(e)&&(n&&n.length?(ut.has(e)||ut.set(e,new Map),ut.get(e).set(n,setTimeout(t,s))):ut.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!G(e))return null;const s=ut.get(e);return t&&s&&Ye(s)?s.get(t)||null:Qo(s)?s:null},clear:(e,t)=>{if(!G(e))return;const s=ut.get(e);t&&t.length&&Ye(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&&ut.delete(e)):(clearTimeout(s),ut.delete(e))}},U=(e,t)=>(D(t)?t:w()).querySelectorAll(e),Ue=new Map;function Jo(e){const{shiftKey:t,code:s}=e,n=w(this),o=[...U(Vo,this)].filter(c=>!te(c,"disabled")&&!et(c,ie));if(!o.length)return;const i=o[0],r=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(r.focus(),e.preventDefault()):!t&&n.activeElement===r&&(i.focus(),e.preventDefault()))}const ti=e=>Ue.has(e)===!0,Ce=e=>{const t=ti(e);(t?Uo:Yo)(e,"keydown",Jo),t?Ue.delete(e):Ue.set(e,!0)},C=e=>G(e)&&"offsetWidth"in e||!1,Et=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:r,left:c}=e.getBoundingClientRect();let a=1,l=1;if(t&&C(e)){const{offsetWidth:d,offsetHeight:g}=e;a=d>0?Math.round(s)/d:1,l=g>0?Math.round(n)/g:1}return{width:s/a,height:n/l,top:o/l,right:i/a,bottom:r/l,left:c/a,x:c/a,y:o/l}},$t=e=>w(e).body,lt=e=>w(e).documentElement,ei=e=>{const t=Nn(e),s=t?e.scrollX:e.scrollLeft,n=t?e.scrollY:e.scrollTop;return{x:s,y:n}},Rn=e=>D(e)&&e.constructor.name==="ShadowRoot"||!1,si=e=>e.nodeName==="HTML"?e:G(e)&&e.assignedSlot||D(e)&&e.parentNode||Rn(e)&&e.host||lt(e),Bn=e=>e?Mn(e)?e.defaultView:D(e)?e?.ownerDocument?.defaultView:e:window,ni=e=>D(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,Fn=(e,t)=>e.matches(t),oi=e=>{if(!C(e))return!1;const{width:t,height:s}=Et(e),{offsetWidth:n,offsetHeight:o}=e;return Math.round(t)!==n||Math.round(s)!==o},ii=(e,t,s)=>{const n=C(t),o=Et(e,n&&oi(t)),i={x:0,y:0};if(n){const r=Et(t,!0);i.x=r.x+t.clientLeft,i.y=r.y+t.clientTop}return{x:o.left+s.x-i.x,y:o.top+s.y-i.y,width:o.width,height:o.height}};let Ms=0,Rs=0;const jt=new Map,Wn=(e,t)=>{let s=t?Ms:Rs;if(t){const n=Wn(e),o=jt.get(n)||new Map;jt.has(n)||jt.set(n,o),Ye(o)&&!o.has(t)?(o.set(t,s),Ms+=1):s=o.get(t)}else{const n=e.id||e;jt.has(n)?s=jt.get(n):(jt.set(n,s),Rs+=1)}return s},ri=e=>Array.isArray(e)||!1,jn=e=>{if(!D(e))return!1;const{top:t,bottom:s}=Et(e),{clientHeight:n}=lt(e);return t<=n&&s>=0},ci=e=>typeof e=="function"||!1,ai=e=>re(e)&&e.constructor.name==="NodeList"||!1,Tt=e=>lt(e).dir==="rtl",_=(e,t)=>!e||!t?null:e.closest(t)||_(e.getRootNode().host,t)||null,x=(e,t)=>G(e)?e:(G(t)?t:w()).querySelector(e),hs=(e,t)=>(D(t)?t:w()).getElementsByTagName(e),it=(e,t)=>(t&&D(t)?t:w()).getElementsByClassName(e),zt={},zn=e=>{const{type:t,currentTarget:s}=e;zt[t].forEach((n,o)=>{s===o&&n.forEach((i,r)=>{r.apply(o,[e]),typeof i=="object"&&i.once&&M(o,t,r,i)})})},N=(e,t,s,n)=>{zt[t]||(zt[t]=new Map);const o=zt[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:r}=i;i.set(s,n),r||e.addEventListener(t,zn,n)},M=(e,t,s,n)=>{const o=zt[t],i=o&&o.get(e),r=i&&i.get(s),c=r!==void 0?r:n;i&&i.has(s)&&i.delete(s),o&&(!i||!i.size)&&o.delete(e),(!o||!o.size)&&delete zt[t],(!i||!i.size)&&e.removeEventListener(t,zn,c)},O="fade",p="show",Se="data-bs-dismiss",xe="alert",Vn="Alert",li="5.1.0",di=li;class st{constructor(t,s){let n;try{if(G(t))n=t;else if(ce(t)){if(n=x(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=Dt.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&Ns(this.defaults).length?Zo(n,this.defaults,s||{},"bs"):{},Dt.set(n,this.name,this)}get version(){return di}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){Dt.remove(this.element,this.name),Ns(this).forEach(t=>{delete this[t]})}}const hi=`.${xe}`,fi=`[${Se}="${xe}"]`,gi=e=>j(e,Vn),ui=e=>new fs(e),Bs=T(`close.bs.${xe}`),pi=T(`closed.bs.${xe}`),Fs=e=>{const{element:t}=e;b(t,pi),e._toggleEventListeners(),e.dispose(),t.remove()};class fs extends st{static selector=hi;static init=ui;static getInstance=gi;dismiss;constructor(t){super(t),this.dismiss=x(fi,this.element),this._toggleEventListeners(!0)}get name(){return Vn}close=()=>{const{element:t}=this;t&&f(t,p)&&(b(t,Bs),Bs.defaultPrevented||(v(t,p),f(t,O)?H(t,()=>Fs(this)):Fs(this)))};_toggleEventListeners=t=>{const s=t?N:M,{dismiss:n,close:o}=this;n&&s(n,I,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const $="active",nt="data-bs-toggle",mi="button",Kn="Button",vi=`[${nt}="${mi}"]`,bi=e=>j(e,Kn),wi=e=>new gs(e);class gs extends st{static selector=vi;static init=wi;static getInstance=bi;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,$),L(s,Is,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return Kn}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!et(s,"disabled")&&((n?v:h)(s,$),L(s,Is,n?"false":"true"),this.isActive=f(s,$))};_toggleEventListeners=t=>{(t?N:M)(this.element,I,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const Ge="data-bs-target",At="carousel",qn="Carousel",Ws="data-bs-parent",Ei="data-bs-container",q=e=>{const t=[Ge,Ws,Ei,"href"],s=w(e);return t.map(n=>{const o=et(e,n);return o?n===Ws?_(e,o):x(o,s):null}).filter(n=>n)[0]},le=`[data-bs-ride="${At}"]`,Y=`${At}-item`,Ze="data-bs-slide-to",mt="data-bs-slide",bt="paused",js={pause:"hover",keyboard:!1,touch:!0,interval:5e3},dt=e=>j(e,qn),Ti=e=>new us(e);let Jt=0,pe=0,Me=0;const Re=T(`slide.bs.${At}`),Qe=T(`slid.bs.${At}`),zs=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const r=Je(e),c=s==="left"?"next":"prev",a=s==="left"?"start":"end";h(o[t],$),v(o[t],`${Y}-${c}`),v(o[t],`${Y}-${a}`),v(o[r],$),v(o[r],`${Y}-${a}`),b(n,Qe),u.clear(n,mt),e.cycle&&!w(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function $i(){const e=dt(this);e&&!e.isPaused&&!u.get(this,bt)&&h(this,bt)}function yi(){const e=dt(this);e&&e.isPaused&&!u.get(this,bt)&&e.cycle()}function Ci(e){e.preventDefault();const t=_(this,le)||q(this),s=dt(t);if(s&&!s.isAnimating){const n=+(et(this,Ze)||0);this&&!f(this,$)&&!Number.isNaN(n)&&s.to(n)}}function Si(e){e.preventDefault();const t=_(this,le)||q(this),s=dt(t);if(s&&!s.isAnimating){const n=et(this,mt);n==="next"?s.next():n==="prev"&&s.prev()}}const xi=({code:e,target:t})=>{const s=w(t),[n]=[...U(le,s)].filter(i=>jn(i)),o=dt(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=Tt(n);e===(i?_s:Ls)?o.prev():e===(i?Ls:_s)&&o.next()}};function Vs(e){const{target:t}=e,s=dt(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function Hi(e){const{target:t}=e,s=dt(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(Jt=e.pageX,this.contains(t)&&(s.isTouch=!0,Xn(s,!0)))}}const Pi=e=>{pe=e.pageX},Di=e=>{const{target:t}=e,s=w(t),n=[...U(le,s)].map(o=>dt(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,r=Tt(o);Me=e.pageX,n.isTouch=!1,Xn(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(Jt-Me)>120&&(peJt&&n.to(i+(r?1:-1))),Jt=0,pe=0,Me=0}},Be=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>v(n,$)),e.indicators[t]&&h(s[t],$)},Xn=(e,t)=>{const{element:s}=e,n=t?N:M;n(w(s),Wo,Pi,ee),n(w(s),jo,Di,ee)},Je=e=>{const{slides:t,element:s}=e,n=x(`.${Y}.${$}`,s);return C(n)?[...t].indexOf(n):-1};class us extends st{static selector=le;static init=Ti;static getInstance=dt;constructor(t,s){super(t,s);const{element:n}=this;this.direction=Tt(n)?"right":"left",this.isTouch=!1,this.slides=it(Y,n);const{slides:o}=this;if(o.length>=2){const i=Je(this),r=[...o].find(l=>Fn(l,`.${Y}-next,.${Y}-next`));this.index=i;const c=w(n);this.controls=[...U(`[${mt}]`,n),...U(`[${mt}][${Ge}="#${n.id}"]`,c)].filter((l,d,g)=>d===g.indexOf(l)),this.indicator=x(`.${At}-indicators`,n),this.indicators=[...this.indicator?U(`[${Ze}]`,this.indicator):[],...U(`[${Ze}][${Ge}="#${n.id}"]`,c)].filter((l,d,g)=>d===g.indexOf(l));const{options:a}=this;this.options.interval=a.interval===!0?js.interval:a.interval,r?this.index=[...o].indexOf(r):i<0&&(this.index=0,h(o[0],$),this.indicators.length&&Be(this,0)),this.indicators.length&&Be(this,this.index),this._toggleEventListeners(!0),a.interval&&this.cycle()}}get name(){return qn}get defaults(){return js}get isPaused(){return f(this.element,bt)}get isAnimating(){return x(`.${Y}-next,.${Y}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;u.clear(t,At),n&&(u.clear(t,bt),v(t,bt)),u.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&jn(t)&&this.to(o+1)},s.interval,At)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,bt),u.set(t,()=>{},1,bt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Je(this),r=Tt(s);let c=t;if(!this.isAnimating&&i!==c&&!u.get(s,mt)){ic||i===n.length-1&&c===0)&&(this.direction=r?"left":"right");const{direction:a}=this;c<0?c=n.length-1:c>=n.length&&(c=0);const l=a==="left"?"next":"prev",d=a==="left"?"start":"end",g={relatedTarget:n[c],from:i,to:c,direction:a};ct(Re,g),ct(Qe,g),b(s,Re),Re.defaultPrevented||(this.index=c,Be(this,c),ae(n[c])&&f(s,"slide")?u.set(s,()=>{h(n[c],`${Y}-${l}`),Ot(n[c]),h(n[c],`${Y}-${d}`),h(n[i],`${Y}-${d}`),H(n[c],()=>this.slides&&this.slides.length&&zs(this))},0,mt):(h(n[c],$),v(n[i],$),u.set(s,()=>{u.clear(s,mt),s&&o.interval&&!this.isPaused&&this.cycle(),b(s,Qe)},0,mt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:r}=this,{touch:c,pause:a,interval:l,keyboard:d}=n,g=t?N:M;a&&l&&(g(s,ye,$i),g(s,as,yi)),c&&o.length>2&&(g(s,Fo,Hi,ee),g(s,ls,Vs,{passive:!1}),g(s,zo,Vs,{passive:!1})),i.length&&i.forEach(E=>{E&&g(E,I,Si)}),r.length&&r.forEach(E=>{g(E,I,Ci)}),d&&g(w(s),$e,xi)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&H(s.slides[s.index],()=>{zs(s)})}}const Lt="collapsing",K="collapse",Yn="Collapse",Ai=`.${K}`,Un=`[${nt}="${K}"]`,ki={parent:null},me=e=>j(e,Yn),Ii=e=>new ps(e),Ks=T(`show.bs.${K}`),Li=T(`shown.bs.${K}`),qs=T(`hide.bs.${K}`),_i=T(`hidden.bs.${K}`),Oi=e=>{const{element:t,parent:s,triggers:n}=e;b(t,Ks),Ks.defaultPrevented||(u.set(t,Ee,17),s&&u.set(s,Ee,17),h(t,Lt),v(t,K),P(t,{height:`${t.scrollHeight}px`}),H(t,()=>{u.clear(t),s&&u.clear(s),n.forEach(o=>L(o,we,"true")),v(t,Lt),h(t,K),h(t,p),P(t,{height:""}),b(t,Li)}))},Xs=e=>{const{element:t,parent:s,triggers:n}=e;b(t,qs),qs.defaultPrevented||(u.set(t,Ee,17),s&&u.set(s,Ee,17),P(t,{height:`${t.scrollHeight}px`}),v(t,K),v(t,p),h(t,Lt),Ot(t),P(t,{height:"0px"}),H(t,()=>{u.clear(t),s&&u.clear(s),n.forEach(o=>L(o,we,"false")),v(t,Lt),h(t,K),P(t,{height:""}),b(t,_i)}))},Ni=e=>{const{target:t}=e,s=t&&_(t,Un),n=s&&q(s),o=n&&me(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class ps extends st{static selector=Ai;static init=Ii;static getInstance=me;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=w(n);this.triggers=[...U(Un,i)].filter(r=>q(r)===n),this.parent=C(o.parent)?o.parent:ce(o.parent)?q(n)||x(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return Yn}get defaults(){return ki}hide(){const{triggers:t,element:s}=this;u.get(s)||(Xs(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...U(`.${K}.${p}`,s)].find(r=>me(r)),i=o&&me(o)),(!s||!u.get(s))&&!u.get(t)&&(i&&o!==t&&(Xs(i),i.triggers.forEach(r=>{h(r,`${K}d`)})),Oi(this),n.length&&n.forEach(r=>v(r,`${K}d`)))}toggle(){f(this.element,p)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?N:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,I,Ni))};dispose(){this._toggleEventListeners(),super.dispose()}}const _t=["dropdown","dropup","dropstart","dropend"],Gn="Dropdown",Zn="dropdown-menu",Qn=e=>{const t=_(e,"A");return e.tagName==="A"&&te(e,"href")&&et(e,"href").slice(-1)==="#"||t&&te(t,"href")&&et(t,"href").slice(-1)==="#"},[tt,ts,es,ss]=_t,Jn=`[${nt}="${tt}"]`,Kt=e=>j(e,Gn),Mi=e=>new ms(e),Ri=`${Zn}-end`,Ys=[tt,ts],Us=[es,ss],Gs=["A","BUTTON"],Bi={offset:5,display:"dynamic"},Fe=T(`show.bs.${tt}`),Zs=T(`shown.bs.${tt}`),We=T(`hide.bs.${tt}`),Qs=T(`hidden.bs.${tt}`),to=T(`updated.bs.${tt}`),eo=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(W(s,"position")!=="static"){const r=Tt(t),c=f(s,Ri);["margin","top","bottom","left","right"].forEach(F=>{const St={};St[F]="",P(s,St)});let l=_t.find(F=>f(n,F))||tt;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:r?[-1,0,0,i]:[-1,i,0],dropend:r?[-1,i,0]:[-1,0,0,i]},g={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:r?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:r?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:r?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:r?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:E,offsetHeight:k}=s,{clientWidth:z,clientHeight:B}=lt(t),{left:m,top:R,width:yt,height:Ct}=Et(t),S=m-E-i<0,ht=m+E+yt+i>=z,ot=R+k+i>=B,J=R+k+Ct+i>=B,Mt=R-k-i<0,y=(!r&&c||r&&!c)&&m+yt-E<0,V=(r&&c||!r&&!c)&&m+E>=z;if(Us.includes(l)&&S&&ht&&(l=tt),l===es&&(r?ht:S)&&(l=ss),l===ss&&(r?S:ht)&&(l=es),l===ts&&Mt&&!J&&(l=tt),l===tt&&J&&!Mt&&(l=ts),Us.includes(l)&&ot&&ct(g[l],{top:"auto",bottom:0}),Ys.includes(l)&&(y||V)){let F={left:"auto",right:"auto"};!y&&V&&!r&&(F={left:"auto",right:0}),y&&!V&&r&&(F={left:0,right:"auto"}),F&&ct(g[l],F)}const Rt=d[l];P(s,{...g[l],margin:`${Rt.map(F=>F&&`${F}px`).join(" ")}`}),Ys.includes(l)&&c&&c&&P(s,g[!r&&y||r&&V?"menuStart":"menuEnd"]),b(n,to)}},Fi=e=>Array.from(e.children).map(t=>{if(t&&Gs.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&Gs.includes(s.tagName)?s:null}).filter(t=>t),Js=e=>{const{element:t,options:s,menu:n}=e,o=e.open?N:M,i=w(t);o(i,I,tn),o(i,rs,tn),o(i,$e,ji),o(i,Ro,zi),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},He=e=>{const t=[..._t,"btn-group","input-group"].map(s=>it(`${s} ${p}`,w(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>_t.some(n=>n===et(s,nt)))},tn=e=>{const{target:t,type:s}=e;if(!C(t))return;const n=He(t),o=n&&Kt(n);if(!o)return;const{parentElement:i,menu:r}=o,c=i&&i.contains(t)&&(t.tagName==="form"||_(t,"form")!==null);[I,_n].includes(s)&&Qn(t)&&e.preventDefault(),!c&&s!==rs&&t!==n&&t!==r&&o.hide()},Wi=e=>{const{target:t}=e,s=t&&_(t,Jn),n=s&&Kt(s);n&&(e.stopPropagation(),n.toggle(),s&&Qn(s)&&e.preventDefault())},ji=e=>{[qe,Xe].includes(e.code)&&e.preventDefault()};function zi(e){const{code:t}=e,s=He(this);if(!s)return;const n=Kt(s),{activeElement:o}=w(s);if(!n||!o)return;const{menu:i,open:r}=n,c=Fi(i);if(c&&c.length&&[qe,Xe].includes(t)){let a=c.indexOf(o);o===s?a=0:t===Xe?a=a>1?a-1:0:t===qe&&(a=aVi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return Gn}get defaults(){return Bi}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(s)return;const i=He(t),r=i&&Kt(i);r&&r.hide(),[Fe,Zs,to].forEach(c=>{c.relatedTarget=t}),b(o,Fe),!Fe.defaultPrevented&&(h(n,p),h(o,p),L(t,we,"true"),eo(this),this.open=!s,at(t),Js(this),b(o,Zs))}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([We,Qs].forEach(i=>{i.relatedTarget=t}),b(o,We),!We.defaultPrevented&&(v(n,p),v(o,p),L(t,we,"false"),this.open=!s,Js(this),b(o,Qs)))}_toggleEventListeners=t=>{(t?N:M)(this.element,I,Wi)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const X="modal",vs="Modal",bs="Offcanvas",Ki="fixed-top",qi="fixed-bottom",so="sticky-top",no="position-sticky",oo=e=>[...it(Ki,e),...it(qi,e),...it(so,e),...it(no,e),...it("is-fixed",e)],Xi=e=>{const t=$t(e);P(t,{paddingRight:"",overflow:""});const s=oo(t);s.length&&s.forEach(n=>{P(n,{paddingRight:"",marginRight:""})})},io=e=>{const{clientWidth:t}=lt(e),{innerWidth:s}=Bn(e);return Math.abs(s-t)},ro=(e,t)=>{const s=$t(e),n=parseInt(W(s,"paddingRight"),10),i=W(s,"overflow")==="hidden"&&n?0:io(e),r=oo(s);t&&(P(s,{overflow:"hidden",paddingRight:`${n+i}px`}),r.length&&r.forEach(c=>{const a=W(c,"paddingRight");if(c.style.paddingRight=`${parseInt(a,10)+i}px`,[so,no].some(l=>f(c,l))){const l=W(c,"marginRight");c.style.marginRight=`${parseInt(l,10)-i}px`}}))},Z="offcanvas",wt=vt({tagName:"div",className:"popup-container"}),co=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt,o=s?t:$t(e);D(e)&&(n===wt&&o.append(wt),n.append(e))},ao=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt;D(e)&&(e.remove(),n===wt&&!wt.children.length&&wt.remove())},ws=(e,t)=>{const s=D(t)&&t.nodeName!=="BODY"?t:wt;return D(e)&&s.contains(e)},lo="backdrop",en=`${X}-${lo}`,sn=`${Z}-${lo}`,ho=`.${X}.${p}`,Es=`.${Z}.${p}`,A=vt("div"),Nt=e=>x(`${ho},${Es}`,w(e)),Ts=e=>{const t=e?en:sn;[en,sn].forEach(s=>{v(A,s)}),h(A,t)},fo=(e,t,s)=>{Ts(s),co(A,$t(e)),t&&h(A,O)},go=()=>{f(A,p)||(h(A,p),Ot(A))},Pe=()=>{v(A,p)},uo=e=>{Nt(e)||(v(A,O),ao(A,$t(e)),Xi(e))},po=e=>C(e)&&W(e,"visibility")!=="hidden"&&e.offsetParent!==null,Yi=`.${X}`,mo=`[${nt}="${X}"]`,Ui=`[${Se}="${X}"]`,vo=`${X}-static`,Gi={backdrop:!0,keyboard:!0},se=e=>j(e,vs),Zi=e=>new $s(e),ve=T(`show.bs.${X}`),nn=T(`shown.bs.${X}`),je=T(`hide.bs.${X}`),on=T(`hidden.bs.${X}`),bo=e=>{const{element:t}=e,s=io(t),{clientHeight:n,scrollHeight:o}=lt(t),{clientHeight:i,scrollHeight:r}=t,c=i!==r;if(!c&&s){const l={[Tt(t)?"paddingLeft":"paddingRight"]:`${s}px`};P(t,l)}ro(t,c||n!==o)},wo=(e,t)=>{const s=t?N:M,{element:n}=e;s(n,I,tr),s(w(n),$e,Ji),t?e._observer.observe(n):e._observer.disconnect()},rn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;uo(s),P(s,{paddingRight:"",display:""}),wo(e);const o=ve.relatedTarget||t.find(po);o&&at(o),on.relatedTarget=n||void 0,b(s,on),Ce(s)},cn=e=>{const{element:t,relatedTarget:s}=e;at(t),wo(e,!0),nn.relatedTarget=s||void 0,b(t,nn),Ce(t)},an=e=>{const{element:t,hasFade:s}=e;P(t,{display:"block"}),bo(e),Nt(t)||P($t(t),{overflow:"hidden"}),h(t,p),It(t,ie),L(t,Te,"true"),s?H(t,()=>cn(e)):cn(e)},ln=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(A,p)&&!Nt(t)?(Pe(),H(A,()=>rn(e))):rn(e)},Qi=e=>{const{target:t}=e,s=t&&_(t,mo),n=s&&q(s),o=n&&se(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Ji=({code:e,target:t})=>{const s=x(ho,w(t)),n=s&&se(s);if(!n)return;const{options:o}=n;o.keyboard&&e===ds&&f(s,p)&&(n.relatedTarget=null,n.hide())},tr=e=>{const{currentTarget:t}=e,s=t&&se(t);if(!s||!t||u.get(t))return;const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:r}=n,{target:c}=e,a=w(t)?.getSelection()?.toString().length,l=i.contains(c),d=c&&_(c,Ui);o&&!l?u.set(t,()=>{h(t,vo),H(i,()=>er(s))},17):(d||!a&&!o&&!l&&r)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())},er=e=>{const{element:t,modalDialog:s}=e,n=(ae(s)||0)+17;v(t,vo),u.set(t,()=>u.clear(t),n)};class $s extends st{static selector=Yi;static init=Zi;static getInstance=se;constructor(t,s){super(t,s);const{element:n}=this,o=x(`.${X}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...U(mo,w(n))].filter(i=>q(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,O),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return vs}get defaults(){return Gi}toggle(){f(this.element,p)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let r=0;if(f(t,p)||(ve.relatedTarget=o||void 0,b(t,ve),ve.defaultPrevented))return;const c=Nt(t);if(c&&c!==t){const a=se(c)||j(c,bs);a&&a.hide()}i?(ws(A)?Ts(!0):fo(t,n,!0),r=ae(A),go(),setTimeout(()=>an(this),r)):(an(this),c&&f(A,p)&&Pe())}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,p)&&(je.relatedTarget=n||void 0,b(t,je),!je.defaultPrevented&&(v(t,p),L(t,ie,"true"),It(t,Te),s?H(t,()=>ln(this)):ln(this)))}update=()=>{f(this.element,p)&&bo(this)};_toggleEventListeners=t=>{const s=t?N:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,I,Qi))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?H(s,o):o()}}const sr=`.${Z}`,ys=`[${nt}="${Z}"]`,nr=`[${Se}="${Z}"]`,De=`${Z}-toggling`,or={backdrop:!0,keyboard:!0,scroll:!1},ne=e=>j(e,bs),ir=e=>new Cs(e),be=T(`show.bs.${Z}`),Eo=T(`shown.bs.${Z}`),ze=T(`hide.bs.${Z}`),To=T(`hidden.bs.${Z}`),rr=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=lt(t);ro(t,s!==n)},$o=(e,t)=>{const s=t?N:M,n=w(e.element);s(n,$e,dr),s(n,I,lr)},dn=e=>{const{element:t,options:s}=e;s.scroll||(rr(e),P($t(t),{overflow:"hidden"})),h(t,De),h(t,p),P(t,{visibility:"visible"}),H(t,()=>hr(e))},cr=e=>{const{element:t,options:s}=e,n=Nt(t);t.blur(),!n&&s.backdrop&&f(A,p)&&Pe(),H(t,()=>fr(e))},ar=e=>{const t=_(e.target,ys),s=t&&q(t),n=s&&ne(s);n&&(n.relatedTarget=t,n.toggle(),t?.tagName==="A"&&e.preventDefault())},lr=e=>{const{target:t}=e,s=x(Es,w(t));if(!s)return;const n=x(nr,s),o=ne(s);if(!o)return;const{options:i,triggers:r}=o,{backdrop:c}=i,a=_(t,ys),l=w(s).getSelection();A.contains(t)&&c==="static"||(!(l&&l.toString().length)&&(!s.contains(t)&&c&&(!a||r.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:void 0,o.hide()),a&&a.tagName==="A"&&e.preventDefault())},dr=({code:e,target:t})=>{const s=x(Es,w(t)),n=s&&ne(s);n&&n.options.keyboard&&e===ds&&(n.relatedTarget=void 0,n.hide())},hr=e=>{const{element:t}=e;v(t,De),It(t,ie),L(t,Te,"true"),L(t,"role","dialog"),b(t,Eo),$o(e,!0),at(t),Ce(t)},fr=e=>{const{element:t,triggers:s}=e;L(t,ie,"true"),It(t,Te),It(t,"role"),P(t,{visibility:""});const n=be.relatedTarget||s.find(po);n&&at(n),uo(t),b(t,To),v(t,De),Ce(t),Nt(t)||$o(e)};class Cs extends st{static selector=sr;static init=ir;static getInstance=ne;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...U(ys,w(n))].filter(o=>q(o)===n),this.relatedTarget=void 0,this._toggleEventListeners(!0)}get name(){return bs}get defaults(){return or}toggle(){f(this.element,p)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(f(t,p)||(be.relatedTarget=n||void 0,Eo.relatedTarget=n||void 0,b(t,be),be.defaultPrevented))return;const i=Nt(t);if(i&&i!==t){const r=ne(i)||j(i,vs);r&&r.hide()}s.backdrop?(ws(A)?Ts():fo(t,!0),o=ae(A),go(),setTimeout(()=>dn(this),o)):(dn(this),i&&f(A,p)&&Pe())}hide(){const{element:t,relatedTarget:s}=this;f(t,p)&&(ze.relatedTarget=s||void 0,To.relatedTarget=s||void 0,b(t,ze),!ze.defaultPrevented&&(h(t,De),v(t,p),cr(this)))}_toggleEventListeners=t=>{const s=t?N:M;this.triggers.forEach(n=>s(n,I,ar))};dispose(){const{element:t}=this,s=f(t,p),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?H(t,n):n()}}const kt="popover",Ss="Popover",rt="tooltip",yo=e=>{const t=e===rt,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},Co={top:"top",bottom:"bottom",left:"start",right:"end"},ns=e=>{requestAnimationFrame(()=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,offsetParent:i,options:r,arrow:c}=e;if(!n)return;const a=Tt(s),{x:l,y:d}=ei(i);P(n,{top:"",left:"",right:"",bottom:""});const{offsetWidth:g,offsetHeight:E}=n,{clientWidth:k,clientHeight:z,offsetWidth:B}=lt(s);let{placement:m}=r;const{clientWidth:R,offsetWidth:yt}=o,S=W(o,"position")==="fixed",ht=Math.abs(S?R-yt:k-B),ot=a&&S?ht:0,J=k-(a?0:ht)-1,Mt=e._observer.getEntry(s),{width:y,height:V,left:Rt,right:F,top:St}=Mt?.boundingClientRect||Et(s,!0),{x:he,y:Bt}=ii(s,i,{x:l,y:d});P(c,{top:"",left:"",right:"",bottom:""});let xt=0,Xt="",ft=0,ke="",Ft="",fe="",Ie="";const Ht=c.offsetWidth||0,gt=c.offsetHeight||0,Le=Ht/2;let Yt=St-E-gt<0,Ut=St+E+V+gt>=z,Gt=Rt-g-Ht=J;const ge=["left","right"],_e=["top","bottom"];Yt=ge.includes(m)?St+V/2-E/2-gt<0:Yt,Ut=ge.includes(m)?St+E/2+V/2+gt>=z:Ut,Gt=_e.includes(m)?Rt+y/2-g/2=J:Zt,m=ge.includes(m)&&Gt&&Zt?"top":m,m=m==="top"&&Yt?"bottom":m,m=m==="bottom"&&Ut?"top":m,m=m==="left"&&Gt?"right":m,m=m==="right"&&Zt?"left":m,n.className.includes(m)||(n.className=n.className.replace(t,Co[m])),ge.includes(m)?(m==="left"?ft=he-g-Ht:ft=he+y+Ht,Yt&&Ut?(xt=0,Xt=0,Ft=Bt+V/2-gt/2):Yt?(xt=Bt,Xt="",Ft=V/2-Ht):Ut?(xt=Bt-E+V,Xt="",Ft=E-V/2-Ht):(xt=Bt-E/2+V/2,Ft=E/2-gt/2)):_e.includes(m)&&(m==="top"?xt=Bt-E-gt:xt=Bt+V+gt,Gt?(ft=0,fe=he+y/2-Le):Zt?(ft="auto",ke=0,Ie=y/2+J-F-Le):(ft=he-g/2+y/2,fe=g/2-Le)),P(n,{top:`${xt}px`,bottom:Xt===""?"":`${Xt}px`,left:ft==="auto"?ft:`${ft}px`,right:ke!==""?`${ke}px`:""}),C(c)&&(Ft!==""&&(c.style.top=`${Ft}px`),fe!==""?c.style.left=`${fe}px`:Ie!==""&&(c.style.right=`${Ie}px`));const Mo=T(`updated.bs.${Vt(e.name)}`);b(s,Mo)})},os={template:yo(rt),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},gr=e=>e!=null&&typeof e=="object"||!1,ur=e=>gr(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,hn=e=>ur(e)&&e.nodeType===1||!1,pr=e=>typeof e=="function"||!1,mr="1.0.2",fn="PositionObserver Error";class So{entries;static version=mr;_tick;_root;_callback;constructor(t,s){if(!pr(t))throw new Error(`${fn}: ${t} is not a function.`);this.entries=new Map,this._callback=t,this._root=hn(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!hn(t))throw new Error(`${fn}: ${t} is not an instance of Element.`);this._root.contains(t)&&this._new(t).then(s=>{this.getEntry(t)||this.entries.set(t,s),this._tick||(this._tick=requestAnimationFrame(this._runCallback))})};unobserve=t=>{this.entries.has(t)&&this.entries.delete(t)};_runCallback=()=>{if(!this.entries.size)return;const t=new Promise(s=>{const n=[];this.entries.forEach(({target:o,boundingClientRect:i})=>{this._root.contains(o)&&this._new(o).then(({boundingClientRect:r,isVisible:c})=>{const{left:a,top:l,bottom:d,right:g}=r;if(i.top!==l||i.left!==a||i.right!==g||i.bottom!==d){const E={target:o,boundingClientRect:r,isVisible:c};this.entries.set(o,E),n.push(E)}})}),s(n)});this._tick=requestAnimationFrame(async()=>{const s=await t;s.length&&this._callback(s,this),this._runCallback()})};_new=t=>{const{clientWidth:s,clientHeight:n}=this._root;return new Promise(o=>{new IntersectionObserver(([{boundingClientRect:i}],r)=>{r.disconnect();const{left:c,top:a,bottom:l,right:d,width:g,height:E}=i,k=a>1-E&&c>1-g&&l<=n+E-1&&d<=s+g-1;o({target:t,isVisible:k,boundingClientRect:i})}).observe(t)})};getEntry=t=>this.entries.get(t);disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.clear(),this._tick=0}}const xo="data-original-title",Pt="Tooltip",pt=(e,t,s)=>{if(ce(t)&&t.length){let n=t.trim();ci(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else C(t)?e.append(t):(ai(t)||ri(t)&&t.every(D))&&e.append(...t)},vr=e=>{const t=e.name===Pt,{id:s,element:n,options:o}=e,{title:i,placement:r,template:c,animation:a,customClass:l,sanitizeFn:d,dismissible:g,content:E,btnClose:k}=o,z=t?rt:kt,B={...Co};let m=[],R=[];Tt(n)&&(B.left="end",B.right="start");const yt=`bs-${z}-${B[r]}`;let Ct;if(C(c))Ct=c;else{const y=vt("div");pt(y,c,d),Ct=y.firstChild}if(!C(Ct))return;e.tooltip=Ct.cloneNode(!0);const{tooltip:S}=e;L(S,"id",s),L(S,"role",rt);const ht=t?`${rt}-inner`:`${kt}-body`,ot=t?null:x(`.${kt}-header`,S),J=x(`.${ht}`,S);e.arrow=x(`.${z}-arrow`,S);const{arrow:Mt}=e;if(C(i))m=[i.cloneNode(!0)];else{const y=vt("div");pt(y,i,d),m=[...y.childNodes]}if(C(E))R=[E.cloneNode(!0)];else{const y=vt("div");pt(y,E,d),R=[...y.childNodes]}if(g)if(i)if(C(k))m=[...m,k.cloneNode(!0)];else{const y=vt("div");pt(y,k,d),m=[...m,y.firstChild]}else if(ot&&ot.remove(),C(k))R=[...R,k.cloneNode(!0)];else{const y=vt("div");pt(y,k,d),R=[...R,y.firstChild]}t?i&&J&&pt(J,i,d):(i&&ot&&pt(ot,m,d),E&&J&&pt(J,R,d),e.btn=x(".btn-close",S)||void 0),h(S,"position-absolute"),h(Mt,"position-absolute"),f(S,z)||h(S,z),a&&!f(S,O)&&h(S,O),l&&!f(S,l)&&h(S,l),f(S,yt)||h(S,yt)},br=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=si(n),Rn(n)||ni(n)||s.push(n);return s.find((o,i)=>(W(o,"position")!=="relative"||W(o,"position")==="relative"&&o.offsetHeight!==o.scrollHeight)&&s.slice(i+1).every(r=>W(r,"position")==="static")?o:null)||w(e).body},wr=`[${nt}="${rt}"],[data-tip="${rt}"]`,Ho="title";let gn=e=>j(e,Pt);const Er=e=>new Ae(e),Tr=e=>{const{element:t,tooltip:s,container:n}=e;It(t,In),ao(s,n)},Qt=e=>{const{tooltip:t,container:s}=e;return t&&ws(t,s)},$r=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),te(s,xo)&&e.name===Pt&&Do(e),t&&t()},Po=(e,t)=>{const s=t?N:M,{element:n}=e;s(w(n),ls,e.handleTouch,ee)},un=e=>{const{element:t}=e,s=T(`shown.bs.${Vt(e.name)}`);Po(e,!0),b(t,s),u.clear(t,"in")},pn=e=>{const{element:t}=e,s=T(`hidden.bs.${Vt(e.name)}`);Po(e),Tr(e),b(t,s),u.clear(t,"out")},mn=(e,t)=>{const s=t?N:M,{element:n,tooltip:o}=e,i=_(n,`.${X}`),r=_(n,`.${Z}`);t?[n,o].forEach(c=>e._observer.observe(c)):e._observer.disconnect(),i&&s(i,`hide.bs.${X}`,e.handleHide),r&&s(r,`hide.bs.${Z}`,e.handleHide)},Do=(e,t)=>{const s=[xo,Ho],{element:n}=e;L(n,s[t?0:1],t||et(n,s[0])||""),It(n,s[t?1:0])};class Ae extends st{static selector=wr;static init=Er;static getInstance=gn;static styleTip=ns;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===Pt,i=o?rt:kt,r=o?Pt:Ss;gn=d=>j(d,r),this.enabled=!0,this.id=`${i}-${Wn(n,i)}`;const{options:c}=this;if(!c.title&&o||!o&&!c.content)return;ct(os,{titleAttr:""}),te(n,Ho)&&o&&typeof c.title=="string"&&Do(this,c.title);const a=br(n),l=["sticky","fixed","relative"].some(d=>W(a,"position")===d)?a:Bn(n);this.container=a,this.offsetParent=l,vr(this),this.tooltip&&(this._observer=new So(d=>{d.some(g=>g.isVisible)&&this.update()}),this._toggleEventListeners(!0))}get name(){return Pt}get defaults(){return os}handleFocus=()=>at(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,id:i}=this,{animation:r}=t,c=u.get(n,"out");u.clear(n,"out"),s&&!c&&!Qt(this)&&u.set(n,()=>{const a=T(`show.bs.${Vt(this.name)}`);b(n,a),a.defaultPrevented||(co(s,o),L(n,In,`#${i}`),this.update(),mn(this,!0),f(s,p)||h(s,p),r?H(s,()=>un(this)):un(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;u.clear(n,"in"),s&&Qt(this)&&u.set(n,()=>{const r=T(`hide.bs.${Vt(this.name)}`);b(n,r),r.defaultPrevented||(this.update(),v(s,p),mn(this),o?H(s,()=>pn(this)):pn(this))},i+17,"out")}update=()=>{ns(this)};toggle=()=>{const{tooltip:t}=this;t&&!Qt(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&Qt(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?N:M,{element:n,options:o,btn:i}=this,{trigger:r}=o,a=!!(this.name!==Pt&&o.dismissible);r.includes("manual")||(this.enabled=!!t,r.split(" ").forEach(d=>{d===Bo?(s(n,_n,this.handleShow),s(n,ye,this.handleShow),a||(s(n,as,this.handleHide),s(w(n),ls,this.handleTouch,ee))):d===I?s(n,d,a?this.handleShow:this.toggle):d===rs&&(s(n,cs,this.handleShow),a||s(n,Ln,this.handleHide),Xo()&&s(n,I,this.handleFocus)),a&&i&&s(i,I,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>$r(n,()=>super.dispose()),17);s.animation&&Qt(n)?(this.options.delay=0,this.hide(),H(t,o)):o()}}const yr=`[${nt}="${kt}"],[data-tip="${kt}"]`,Cr=ct({},os,{template:yo(kt),content:"",dismissible:!1,btnClose:''}),Sr=e=>j(e,Ss),xr=e=>new xs(e);class xs extends Ae{static selector=yr;static init=xr;static getInstance=Sr;static styleTip=ns;constructor(t,s){super(t,s)}get name(){return Ss}get defaults(){return Cr}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>at(s),17)}}const Hr="scrollspy",Ao="ScrollSpy",Pr='[data-bs-spy="scroll"]',Dr={offset:10,target:void 0},Ar=e=>j(e,Ao),kr=e=>new Hs(e),vn=T(`activate.bs.${Hr}`),Ir=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:r,_observer:c}=e,{offset:a}=n,l=s!==r,d=t&&hs("A",t),g=w(r),E=s.scrollHeight;if(e.scrollTop=s.scrollTop,d&&(E!==i||o!==d.length)){let k,z,B,m;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=E,e.maxScroll=e.scrollHeight-_r(e),Array.from(d).forEach(R=>{k=et(R,"href"),z=k?.slice(1),B=z?.length?g.getElementById(z):null,B&&(e.items.push(R),e.targets.push(B),m=c?.getEntry(B)?.boundingClientRect||Et(B),e.offsets.push((l?m.top+e.scrollTop:B.offsetTop)-a))}),e.itemsLength=e.items.length}},bn=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e?.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},Lr=e=>e.scrollHeight,_r=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:Et(e).height,ko=e=>{Array.from(hs("A",e)).forEach(t=>{f(t,$)&&v(t,$)})},wn=(e,t)=>{const{target:s,element:n}=e;C(s)&&ko(s),e.activeItem=t,h(t,$);const o=[];let i=t;for(;i!==$t(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(r=>{const c=r.previousElementSibling;c&&!f(c,$)&&h(c,$)}),vn.relatedTarget=t,b(n,vn)};class Hs extends st{static selector=Pr;static init=kr;static getInstance=Ar;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=x(o.target,w(n));i&&(this.target=i,this.scrollTarget=n.clientHeight{requestAnimationFrame(()=>{r.some(c=>c.isVisible)&&this.refresh()})},{root:this.scrollTarget}),bn(this,!0))}get name(){return Ao}get defaults(){return Dr}refresh=()=>{const{target:t}=this;if(!C(t)||t.offsetHeight===0)return;Ir(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:r}=this;if(s>=n){const a=i[o-1];r!==a&&wn(this,a);return}const{offsets:c}=this;if(r&&s0){this.activeItem=null,t&&ko(t);return}i.forEach((a,l)=>{r!==a&&s>=c[l]&&(typeof c[l+1]>"u"||sj(e,Io),Or=e=>new Ps(e),Ve=T(`show.bs.${de}`),Tn=T(`shown.bs.${de}`),Ke=T(`hide.bs.${de}`),$n=T(`hidden.bs.${de}`),oe=new Map,yn=e=>{const{tabContent:t,nav:s}=e;t&&f(t,Lt)&&(t.style.height="",v(t,Lt)),s&&u.clear(s)},Cn=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=C(o)&&oe.get(o)||{tab:null};if(s&&n&&f(n,O)){const{currentHeight:r,nextHeight:c}=oe.get(t)||{currentHeight:0,nextHeight:0};r!==c?setTimeout(()=>{s.style.height=`${c}px`,Ot(s),H(s,()=>yn(e))},50):yn(e)}else o&&u.clear(o);Tn.relatedTarget=i,b(t,Tn)},Sn=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:r}=o&&oe.get(o)||{tab:null,content:null};let c=0;if(n&&s&&f(s,O)&&([r,s].forEach(a=>{a&&h(a,"overflow-hidden")}),c=r?r.scrollHeight:0),Ve.relatedTarget=i,$n.relatedTarget=t,b(t,Ve),!Ve.defaultPrevented){if(s&&h(s,$),r&&v(r,$),n&&s&&f(s,O)){const a=s.scrollHeight;oe.set(t,{currentHeight:c,nextHeight:a,tab:null,content:null}),h(n,Lt),n.style.height=`${c}px`,Ot(n),[r,s].forEach(l=>{l&&v(l,"overflow-hidden")})}s&&s&&f(s,O)?setTimeout(()=>{h(s,p),H(s,()=>{Cn(e)})},1):(s&&h(s,p),Cn(e)),i&&b(i,$n)}},xn=e=>{const{nav:t}=e;if(!C(t))return{tab:null,content:null};const s=it($,t);let n=null;s.length===1&&!_t.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=C(n)?q(n):null;return{tab:n,content:o}},Hn=e=>{if(!C(e))return null;const t=_(e,`.${_t.join(",.")}`);return t?x(`.${_t[0]}-toggle`,t):null},Nr=e=>{const t=Lo(e.target);e.preventDefault(),t&&t.show()};class Ps extends st{static selector=En;static init=Or;static getInstance=Lo;constructor(t){super(t);const{element:s}=this,n=q(s);if(!n)return;const o=_(s,".nav"),i=_(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=Hn(s);const{tab:r}=xn(this);if(o&&!r){const c=x(En,o),a=c&&q(c);a&&(h(c,$),h(a,p),h(a,$),L(s,Oe,"true"))}this._toggleEventListeners(!0)}get name(){return Io}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(n&&u.get(n)||f(t,$))return;const{tab:i,content:r}=xn(this);if(n&&i&&oe.set(n,{tab:i,content:r,currentHeight:0,nextHeight:0}),Ke.relatedTarget=t,!C(i)||(b(i,Ke),Ke.defaultPrevented))return;h(t,$),L(t,Oe,"true");const c=C(i)&&Hn(i);if(c&&f(c,$)&&v(c,$),n){const a=()=>{i&&(v(i,$),L(i,Oe,"false")),o&&!f(o,$)&&h(o,$)};r&&(f(r,O)||s&&f(s,O))?u.set(n,a,1):a()}r&&(v(r,p),f(r,O)?H(r,()=>Sn(this)):Sn(this))}_toggleEventListeners=t=>{(t?N:M)(this.element,I,Nr)};dispose(){this._toggleEventListeners(),super.dispose()}}const Q="toast",_o="Toast",Mr=`.${Q}`,Rr=`[${Se}="${Q}"]`,Oo=`[${nt}="${Q}"]`,qt="showing",No="hide",Br={animation:!0,autohide:!0,delay:5e3},Ds=e=>j(e,_o),Fr=e=>new As(e),Pn=T(`show.bs.${Q}`),Wr=T(`shown.bs.${Q}`),Dn=T(`hide.bs.${Q}`),jr=T(`hidden.bs.${Q}`),An=e=>{const{element:t,options:s}=e;v(t,qt),u.clear(t,qt),b(t,Wr),s.autohide&&u.set(t,()=>e.hide(),s.delay,Q)},kn=e=>{const{element:t}=e;v(t,qt),v(t,p),h(t,No),u.clear(t,Q),b(t,jr)},zr=e=>{const{element:t,options:s}=e;h(t,qt),s.animation?(Ot(t),H(t,()=>kn(e))):kn(e)},Vr=e=>{const{element:t,options:s}=e;u.set(t,()=>{v(t,No),Ot(t),h(t,p),h(t,qt),s.animation?H(t,()=>An(e)):An(e)},17,qt)},Kr=e=>{const{target:t}=e,s=t&&_(t,Oo),n=s&&q(s),o=n&&Ds(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},qr=e=>{const t=e.target,s=Ds(t),{type:n,relatedTarget:o}=e;!s||t===o||t.contains(o)||([ye,cs].includes(n)?u.clear(t,Q):u.set(t,()=>s.hide(),s.options.delay,Q))};class As extends st{static selector=Mr;static init=Fr;static getInstance=Ds;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,O)?h(n,O):!o.animation&&f(n,O)&&v(n,O),this.dismiss=x(Rr,n),this.triggers=[...U(Oo,w(n))].filter(i=>q(i)===n),this._toggleEventListeners(!0)}get name(){return _o}get defaults(){return Br}get isShown(){return f(this.element,p)}show=()=>{const{element:t,isShown:s}=this;!t||s||(b(t,Pn),Pn.defaultPrevented||Vr(this))};hide=()=>{const{element:t,isShown:s}=this;!t||!s||(b(t,Dn),Dn.defaultPrevented||zr(this))};_toggleEventListeners=t=>{const s=t?N:M,{element:n,triggers:o,dismiss:i,options:r,hide:c}=this;i&&s(i,I,c),r.autohide&&[cs,Ln,ye,as].forEach(a=>s(n,a,qr)),o.length&&o.forEach(a=>s(a,I,Kr))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),u.clear(t,Q),s&&v(t,p),super.dispose()}}const ks=new Map;[fs,gs,us,ps,ms,$s,Cs,xs,Hs,Ps,As,Ae].forEach(e=>ks.set(e.prototype.name,e));const Xr=(e,t)=>{[...t].forEach(s=>e(s))},Yr=(e,t)=>{const s=Dt.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},is=e=>{const t=e&&e.nodeName?e:document,s=[...hs("*",t)];ks.forEach(n=>{const{init:o,selector:i}=n;Xr(o,s.filter(r=>Fn(r,i)))})},Ur=e=>{const t=e&&e.nodeName?e:document;ks.forEach(s=>{Yr(s.prototype.name,t)})};document.body?is():N(document,"DOMContentLoaded",()=>is(),{once:!0});exports.Alert=fs;exports.Button=gs;exports.Carousel=us;exports.Collapse=ps;exports.Dropdown=ms;exports.Modal=$s;exports.Offcanvas=Cs;exports.Popover=xs;exports.ScrollSpy=Hs;exports.Tab=Ps;exports.Toast=As;exports.Tooltip=Ae;exports.initCallback=is;exports.removeDataAPI=Ur; //# sourceMappingURL=bootstrap-native.cjs.map diff --git a/dist/bootstrap-native.cjs.map b/dist/bootstrap-native.cjs.map index 1de48e7e..68b101f1 100644 --- a/dist/bootstrap-native.cjs.map +++ b/dist/bootstrap-native.cjs.map @@ -1 +1 @@ -{"version":3,"file":"bootstrap-native.cjs","sources":["../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.6/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@0.0.3/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const e = {}, f = (t) => {\n const { type: c, currentTarget: i } = t;\n [...e[c]].forEach(([n, s]) => {\n /* istanbul ignore else @preserve */\n i === n && [...s].forEach(([o, a]) => {\n o.apply(n, [t]), typeof a == \"object\" && a.once && r(n, c, o, a);\n });\n });\n}, E = (t, c, i, n) => {\n /* istanbul ignore else @preserve */\n e[c] || (e[c] = /* @__PURE__ */ new Map());\n const s = e[c];\n /* istanbul ignore else @preserve */\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(t), { size: a } = o;\n o.set(i, n);\n /* istanbul ignore else @preserve */\n a || t.addEventListener(c, f, n);\n}, r = (t, c, i, n) => {\n const s = e[c], o = s && s.get(t), a = o && o.get(i), d = a !== void 0 ? a : n;\n /* istanbul ignore else @preserve */\n o && o.has(i) && o.delete(i);\n /* istanbul ignore else @preserve */\n s && (!o || !o.size) && s.delete(t);\n /* istanbul ignore else @preserve */\n (!s || !s.size) && delete e[c];\n /* istanbul ignore else @preserve */\n (!o || !o.size) && t.removeEventListener(\n c,\n f,\n d\n );\n}, g = E, M = r;\nexport {\n E as addListener,\n f as globalListener,\n M as off,\n g as on,\n e as registry,\n r as removeListener\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: HTMLElement) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: ScrollSpyOptions = {\n offset: 10,\n target: null,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: HTMLElement) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: HTMLElement) => Component,\n collection: HTMLCollectionOf | HTMLElement[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","f","t","c","i","s","o","a","r","E","d","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","version","BaseComponent","prevInstance","alertSelector","alertDismissSelector","getAlertInstance","alertInitCallback","Alert","closeAlertEvent","closedAlertEvent","alertTransitionEnd","self","add","action","addListener","removeListener","dismiss","close","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","isActive","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","attValue","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","activeItem","getActiveIndex","orientation","directionClass","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","RTL","carouselDragHandler","carouselPointerDownHandler","controls","indicators","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","activeIndex","transitionItem","ar","isPaused","idx","next","eventProperties","touch","pause","interval","keyboard","arrow","indicator","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","triggers","btn","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","menuEnd","p","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","targetLeft","targetTop","targetWidth","targetHeight","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","dropdownPreventScroll","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","dropdownClickHandler","activeElement","open","menuItems","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","fixedItems","fixed","measureScrollbar","innerWidth","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","appendPopup","customContainer","containerIsBody","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","afterModalShow","beforeModalShow","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","overlayDelay","currentOpen","that","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","tipPositions","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","tooltipDefaults","_","B","m","n","h","l","u","b","g","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","tempDocument","createTip","id","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","position","PositionObserver","outTimer","tipContainer","showTooltipEvent","hideTooltipEvent","enabled","tr","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","isRoot","links","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","_observer","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","scrollTop","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","context","compData","initCallback","lookUp","elemCollection","cs","init","removeDataAPI","comp"],"mappings":"aAAK,OAAA,eAAA,QAAA,OAAA,YAAA,CAAA,MAAA,QAAA,CAAA,EAAA,MAAqEA,GAAkB,mBAAoBC,GAAe,gBAAiDC,G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CAAU,EAAE,QAASppB,GAAMgG,EAAShG,CAAC,CAAC,CAC5C,EAQMqpB,GAAyB,CAAI3nB,EAAmB4nB,IAAwB,CACtE,MAAAC,EAAW9nB,GAAK,UAAUC,CAAS,EAErC6nB,GACD,CAAA,GAAGA,CAAQ,EAAE,QAAQ,CAAC,CAACppB,EAASwB,CAAQ,IAAM,CACzC2nB,EAAQ,SAASnpB,CAAO,GACzBwB,EAAyC,QAAQ,CACpD,CACD,CAEL,EAOa6nB,GAAgBF,GAAyB,CACpD,MAAMG,EAASH,GAAWA,EAAQ,SAAWA,EAAU,SACjDI,EAAiB,CAAC,GAAGtgB,GAAqB,IAAKqgB,CAAM,CAAC,EAE7CP,GAAA,QAASS,GAAO,CACvB,KAAA,CAAE,KAAAC,EAAM,SAAAzjB,CAAA,EAAawjB,EAC3BR,GACES,EACAF,EAAe,OAAQvE,GAAS7b,GAAQ6b,EAAMhf,CAAQ,CAAC,CACzD,CAAA,CACD,CACH,EAOa0jB,GAAiBP,GAAyB,CACrD,MAAMG,EAASH,GAAWA,EAAQ,SAAWA,EAAU,SAExCJ,GAAA,QAASY,GAAS,CACRT,GAAAS,EAAK,UAAU,KAAML,CAAM,CAAA,CACnD,CACH,EAGI,SAAS,KAAmBD,GAAA,EAE9Bne,EAAY,SAAU,mBAAoB,IAAMme,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP,EACH,QAAA,MAAA1e,GAAA,QAAA,OAAAkB,GAAA,QAAA,SAAAkB,GAAA,QAAA,SAAAoD,GAAA,QAAA,SAAA0B,GAAA,QAAA,MAAA2G,GAAA,QAAA,UAAAuC,GAAA,QAAA,QAAAwI,GAAA,QAAA,UAAAO,GAAA,QAAA,IAAAkC,GAAA,QAAA,MAAAkC,GAAA,QAAA,QAAAxG,GAAA,QAAA,aAAA2H,GAAA,QAAA,cAAAK","x_google_ignoreList":[0,1,52]} \ No newline at end of file +{"version":3,"file":"bootstrap-native.cjs","sources":["../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.8/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@https+++codeload.github.com+thednp+position-observer+tar.gz+d693d53_hyk7lpzuqi6vnifksl6nzudy5a/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const g = \"2.0.8\", e = {}, f = (t) => {\n const { type: n, currentTarget: c } = t;\n e[n].forEach((a, s) => {\n c === s && a.forEach((o, i) => {\n i.apply(s, [t]), typeof o == \"object\" && o.once && r(s, n, i, o);\n });\n });\n}, E = (t, n, c, a) => {\n e[n] || (e[n] = /* @__PURE__ */ new Map());\n const s = e[n];\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(\n t\n ), { size: i } = o;\n o.set(c, a), i || t.addEventListener(\n n,\n f,\n a\n );\n}, r = (t, n, c, a) => {\n const s = e[n], o = s && s.get(t), i = o && o.get(c), d = i !== void 0 ? i : a;\n o && o.has(c) && o.delete(c), s && (!o || !o.size) && s.delete(t), (!s || !s.size) && delete e[n], (!o || !o.size) && t.removeEventListener(\n n,\n f,\n d\n );\n}, M = E, p = r;\nexport {\n E as addListener,\n f as globalListener,\n p as off,\n M as on,\n e as registry,\n r as removeListener,\n g as version\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: Element) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: Element) => Component,\n collection: HTMLCollectionOf | Element[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","n","o","s","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","u","h","O","to","k","G","K","d","N","oe","q","g","ae","ie","ro","r","a","i","io","P","T","ue","lo","f","c","p","E","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop","alertSelector","alertDismissSelector","getAlertInstance","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","hasClass","removeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","setAttribute","ariaPressed","isActive","getAttribute","addClass","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","doc","getDocument","att","attValue","closest","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","options","activeItem","getActiveIndex","orientation","directionClass","Timer","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","code","querySelectorAll","isElementInScrollRange","RTL","isRTL","keyArrowRight","keyArrowLeft","carouselDragHandler","carouselPointerDownHandler","controls","indicators","el","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","pointermoveEvent","passiveHandler","pointerupEvent","isHTMLElement","getElementsByClassName","activeIndex","transitionItem","matches","ar","isPaused","idx","next","eventProperties","ObjectAssign","getElementTransitionDuration","reflow","touch","pause","interval","keyboard","mouseenterEvent","mouseleaveEvent","pointerdownEvent","touchstartEvent","dragstartEvent","arrow","indicator","keydownEvent","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","parent","triggers","noop","setElementStyle","btn","ariaExpanded","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","hasAttribute","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","getElementStyle","menuEnd","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","clientHeight","getDocumentElement","targetLeft","targetTop","targetWidth","targetHeight","getBoundingClientRect","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","focusEvent","dropdownPreventScroll","keyupEvent","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","mousedownEvent","dropdownClickHandler","keyArrowDown","keyArrowUp","activeElement","open","menuItems","focus","keyEscape","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","getDocumentBody","fixedItems","fixed","measureScrollbar","innerWidth","getWindow","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","createElement","appendPopup","customContainer","containerIsBody","isNode","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","toggleFocusTrap","afterModalShow","beforeModalShow","removeAttribute","ariaHidden","ariaModal","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","duration","overlayDelay","currentOpen","that","callback","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","offsetParent","scrollLeft","scrollTop","getNodeScroll","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","toLowerCase","tooltipDefaults","_","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","isFunction","tempDocument","isNodeList","isArray","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","ariaDescribedBy","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","getUID","position","PositionObserver","entries","outTimer","showTooltipEvent","delay","hideTooltipEvent","enabled","tr","mousehoverEvent","focusinEvent","focusoutEvent","isApple","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","_observer","isRoot","links","getElementsByTagName","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","spyTarget","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","ariaSelected","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","component","context","compData","instance","initCallback","lookUp","elemCollection","cs","init","selector","removeDataAPI","comp"],"mappings":"gFAAK,MAA6DA,GAAK,mBAAoBC,GAAK,gBAAuCC,GAAI,cAA0DC,GAAK,aAAcC,GAAK,eAAgBC,GAAK,gBAAwPC,GAAK,QAASC,GAAK,UAAWC,GAAK,WAA0EC,GAAK,UAA4BC,GAAK,QAAsBC,EAAK,QAA0BC,GAAK,YAA6BC,GAAK,QAASC,GAAK,aAAcC,GAAK,aAAmKC,GAAK,cAAoCC,GAAK,cAAeC,GAAK,YAAsJC,GAAK,aAmD1mCC,GAAK,YAUuBC,GAAK,oFAoBlCC,GAAK,YAAaC,GAA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KAAA,CAAE,KAAAC,EAAM,SAAAC,CAAA,EAAaF,EAC3BV,GACEW,EACAF,EAAe,OAAQ1E,GAASnZ,GAAQmZ,EAAM6E,CAAQ,CAAC,CACzD,CAAA,CACD,CACH,EAOaC,GAAiBT,GAAyB,CACrD,MAAMI,EAASJ,GAAWA,EAAQ,SAAWA,EAAU,SAExCL,GAAA,QAASe,GAAS,CACRZ,GAAAY,EAAK,UAAU,KAAMN,CAAM,CAAA,CACnD,CACH,EAGI,SAAS,KAAmBD,GAAA,EAE9B9iB,EAAY,SAAU,mBAAoB,IAAM8iB,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP","x_google_ignoreList":[0,1,52]} \ No newline at end of file diff --git a/dist/bootstrap-native.d.ts b/dist/bootstrap-native.d.ts index 98ac520c..8b8d4cdb 100644 --- a/dist/bootstrap-native.d.ts +++ b/dist/bootstrap-native.d.ts @@ -1,12 +1,13 @@ import { default as default_2 } from '@thednp/position-observer'; +import { TouchEvent as TouchEvent_2 } from '@thednp/shorty'; /** Creates a new Alert instance. */ export declare class Alert extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Alert; - static getInstance: (element: HTMLElement) => Alert | null; + static init: (element: Element) => Alert; + static getInstance: (element: Element) => Alert | null; dismiss: HTMLElement | null; - constructor(target: HTMLElement | string); + constructor(target: Element | string); /** Returns component name string. */ get name(): string; /** @@ -27,13 +28,13 @@ export declare class Alert extends BaseComponent { /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -50,13 +51,14 @@ declare interface BaseOptions { /** Creates a new `Button` instance. */ export declare class Button extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Button; - static getInstance: (element: HTMLElement) => Button | null; + static init: (element: Element) => Button; + static getInstance: (element: Element) => Button | null; isActive: boolean; + element: HTMLElement; /** * @param target usually a `.btn` element */ - constructor(target: HTMLElement | string); + constructor(target: Element | string); /** * Returns component name string. */ @@ -80,8 +82,9 @@ export declare class Button extends BaseComponent { /** Creates a new `Carousel` instance. */ export declare class Carousel extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Carousel; - static getInstance: (element: HTMLElement) => Carousel | null; + static init: (element: Element) => Carousel; + static getInstance: (element: Element) => Carousel | null; + element: HTMLElement; options: CarouselOptions; direction: "right" | "left"; index: number; @@ -94,7 +97,7 @@ export declare class Carousel extends BaseComponent { * @param target mostly a `.carousel` element * @param config instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -145,16 +148,17 @@ declare interface CarouselOptions extends BaseOptions { /** Returns a new `Colapse` instance. */ export declare class Collapse extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Collapse; - static getInstance: (element: HTMLElement) => Collapse | null; + static init: (element: Element) => Collapse; + static getInstance: (element: Element) => Collapse | null; + element: HTMLElement; options: CollapseOptions; - parent: HTMLElement | null; - triggers: HTMLElement[]; + parent: Element | null; + triggers: Element[]; /** * @param target and `Element` that matches the selector * @param config instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -188,8 +192,9 @@ declare interface CollapseOptions extends BaseOptions { /** Returns a new Dropdown instance. */ export declare class Dropdown extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Dropdown; - static getInstance: (element: HTMLElement) => Dropdown | null; + static init: (element: Element) => Dropdown; + static getInstance: (element: Element) => Dropdown | null; + element: HTMLElement; options: DropdownOptions; open: boolean; parentElement: HTMLElement; @@ -199,7 +204,7 @@ export declare class Dropdown extends BaseComponent { * @param target Element or string selector * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -242,20 +247,21 @@ export declare const initCallback: (context?: ParentNode) => void; /** Returns a new `Modal` instance. */ export declare class Modal extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Modal; - static getInstance: (element: HTMLElement) => Modal | null; + static init: (element: Element) => Modal; + static getInstance: (element: Element) => Modal | null; + element: HTMLElement; options: ModalOptions; modalDialog: HTMLElement; triggers: HTMLElement[]; isStatic: boolean; hasFade: boolean; - relatedTarget: HTMLElement | null; + relatedTarget: EventTarget & HTMLElement | null; _observer: ResizeObserver; /** * @param target usually the `.modal` element * @param config instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -295,16 +301,17 @@ declare interface ModalOptions extends BaseOptions { /** Returns a new `Offcanvas` instance. */ export declare class Offcanvas extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Offcanvas; - static getInstance: (element: HTMLElement) => Offcanvas | null; + static init: (element: Element) => Offcanvas; + static getInstance: (element: Element) => Offcanvas | null; + element: HTMLElement; options: OffcanvasOptions; triggers: HTMLElement[]; - relatedTarget: HTMLElement | null; + relatedTarget: EventTarget & HTMLElement | undefined; /** * @param target usually an `.offcanvas` element * @param config instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -342,15 +349,15 @@ declare interface OffcanvasOptions extends BaseOptions { /** Returns a new `Popover` instance. */ export declare class Popover extends Tooltip { static selector: string; - static init: (element: HTMLElement) => Popover; - static getInstance: (element: HTMLElement) => Popover | null; - static styleTip: (self: T) => void; + static init: (element: Element) => Popover; + static getInstance: (element: Element) => Popover | null; + static styleTip: (self: Tooltip) => void; options: PopoverOptions; /** * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -379,8 +386,9 @@ export declare const removeDataAPI: (context?: ParentNode) => void; /** Returns a new `ScrollSpy` instance. */ export declare class ScrollSpy extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => ScrollSpy; - static getInstance: (element: HTMLElement) => ScrollSpy | null; + static init: (element: Element) => ScrollSpy; + static getInstance: (element: Element) => ScrollSpy | null; + element: HTMLElement; options: ScrollSpyOptions; target: HTMLElement | null; scrollTarget: HTMLElement; @@ -397,7 +405,7 @@ export declare class ScrollSpy extends BaseComponent { * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -405,7 +413,7 @@ export declare class ScrollSpy extends BaseComponent { /** * Returns component default options. */ - get defaults(): ScrollSpyOptions; + get defaults(): Partial; /** Updates all items. */ refresh: () => void; /** Removes `ScrollSpy` from the target element. */ @@ -414,21 +422,22 @@ export declare class ScrollSpy extends BaseComponent { declare interface ScrollSpyOptions extends BaseOptions { offset: number; - target: HTMLElement | string | null; + target: HTMLElement | string; } /** Creates a new `Tab` instance. */ export declare class Tab extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Tab; - static getInstance: (element: HTMLElement) => Tab | null; + static init: (element: Element) => Tab; + static getInstance: (element: Element) => Tab | null; + element: HTMLElement; nav: HTMLElement | null; content: HTMLElement | null; tabContent: HTMLElement | null; nextContent: HTMLElement | null; dropdown: HTMLElement | null; /** @param target the target element */ - constructor(target: HTMLElement | string); + constructor(target: Element | string); /** * Returns component name string. */ @@ -448,8 +457,9 @@ export declare class Tab extends BaseComponent { /** Creates a new `Toast` instance. */ export declare class Toast extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Toast; - static getInstance: (element: HTMLElement) => Toast | null; + static init: (element: Element) => Toast; + static getInstance: (element: Element) => Toast | null; + element: HTMLElement; options: ToastOptions; dismiss: HTMLElement | null; triggers: HTMLElement[]; @@ -458,7 +468,7 @@ export declare class Toast extends BaseComponent { * @param target the target `.toast` element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -498,15 +508,16 @@ declare interface ToastOptions extends BaseOptions { /** Creates a new `Tooltip` instance. */ export declare class Tooltip extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Tooltip; - static getInstance: (element: HTMLElement) => Tooltip | null; - static styleTip: (self: T) => void; + static init: (element: Element) => Tooltip; + static getInstance: (element: Element) => Tooltip | null; + static styleTip: (self: Tooltip) => void; + element: Element & HTMLOrSVGElement; options: TooltipOptions; btn?: HTMLElement; - tooltip?: HTMLElement; - container: ParentNode; - arrow?: HTMLElement; - offsetParent?: HTMLElement; + tooltip: HTMLElement; + container: HTMLElement; + offsetParent: Element | Window; + arrow: HTMLElement; enabled: boolean; id: string; _observer: default_2; @@ -514,7 +525,7 @@ export declare class Tooltip extends BaseComponent { * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -547,7 +558,7 @@ export declare class Tooltip extends BaseComponent { * @this {Tooltip} * @param {TouchEvent} e the `Event` object */ - handleTouch: ({ target }: TouchEvent) => void; + handleTouch: ({ target }: TouchEvent_2) => void; /** * Toggles on/off the `Tooltip` event listeners. * diff --git a/dist/bootstrap-native.js b/dist/bootstrap-native.js index bff96e7d..3d50cf89 100644 --- a/dist/bootstrap-native.js +++ b/dist/bootstrap-native.js @@ -1,2 +1,2 @@ -var BSN=function(R){"use strict";const xs="aria-describedby",de="aria-expanded",Kt="aria-hidden",he="aria-modal",Is="aria-pressed",xe="aria-selected",Ie="focus",Le="focusin",Ls="focusout",fe="keydown",Oo="keyup",L="click",Os="mousedown",No="hover",ge="mouseenter",Oe="mouseleave",ko="pointerdown",_o="pointermove",Mo="pointerup",Ne="touchstart",Bo="dragstart",Ro='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',ke="ArrowDown",_e="ArrowUp",Ns="ArrowLeft",ks="ArrowRight",Me="Escape",Fo="transitionDuration",Wo="transitionDelay",Be="transitionend",_s="transitionProperty",Vo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},pe=()=>{},jo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},zo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},tt=(e,t)=>e.getAttribute(t),Ut=(e,t)=>e.hasAttribute(t),O=(e,t,s)=>e.setAttribute(t,s),St=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},m=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),Xt=e=>e!=null&&typeof e=="object"||!1,A=e=>Xt(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,T=e=>A(e)&&e.nodeType===1||!1,_t=new Map,Dt={data:_t,set:(e,t,s)=>{T(e)&&(_t.has(t)||_t.set(t,new Map),_t.get(t).set(e,s))},getAllFor:e=>_t.get(e)||null,get:(e,t)=>{if(!T(e)||!t)return null;const s=Dt.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=Dt.getAllFor(t);!s||!T(e)||(s.delete(e),s.size===0&&_t.delete(t))}},F=(e,t)=>Dt.get(e,t),qt=e=>typeof e=="string"||!1,Ko=e=>Xt(e)&&e.constructor.name==="Window"||!1,Ms=e=>A(e)&&e.nodeType===9||!1,b=e=>Ko(e)?e.document:Ms(e)?e:A(e)?e.ownerDocument:globalThis.document,at=(e,...t)=>Object.assign(e,...t),gt=e=>{if(!e)return;if(qt(e))return b().createElement(e);const{tagName:t}=e,s=gt(t);if(!s)return;const n={...e};return delete n.tagName,at(s,n)},E=(e,t)=>e.dispatchEvent(t),j=(e,t)=>{const s=getComputedStyle(e),n=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return s.getPropertyValue(n)},Uo=e=>{const t=j(e,_s),s=j(e,Wo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},Yt=e=>{const t=j(e,_s),s=j(e,Fo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},P=(e,t)=>{let s=0;const n=new Event(Be),o=Yt(e),i=Uo(e);if(o){const a=r=>{r.target===e&&(t.apply(e,[r]),e.removeEventListener(Be,a),s=1)};e.addEventListener(Be,a),setTimeout(()=>{s||E(e,n)},o+i+17)}else t.apply(e,[n])},rt=(e,t)=>e.focus(t),Bs=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,ue=e=>Object.entries(e),Mt=e=>e.toLowerCase(),Xo=(e,t,s,n)=>{const o={...s},i={...e.dataset},a={...t},r={},c="title";return ue(i).forEach(([l,d])=>{const g=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,$=>Mt($)):l;r[g]=Bs(d)}),ue(o).forEach(([l,d])=>{o[l]=Bs(d)}),ue(t).forEach(([l,d])=>{l in o?a[l]=o[l]:l in r?a[l]=r[l]:a[l]=l===c?tt(e,c):d}),a},Rs=e=>Object.keys(e),w=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return Xt(t)&&at(s,t),s},Zt={passive:!0},Ht=e=>e.offsetHeight,x=(e,t)=>{ue(t).forEach(([s,n])=>{if(n&&qt(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,at(e.style,o)}})},Re=e=>Xt(e)&&e.constructor.name==="Map"||!1,qo=e=>typeof e=="number"||!1,pt=new Map,p={set:(e,t,s,n)=>{T(e)&&(n&&n.length?(pt.has(e)||pt.set(e,new Map),pt.get(e).set(n,setTimeout(t,s))):pt.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!T(e))return null;const s=pt.get(e);return t&&s&&Re(s)?s.get(t)||null:qo(s)?s:null},clear:(e,t)=>{if(!T(e))return;const s=pt.get(e);t&&t.length&&Re(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&&pt.delete(e)):(clearTimeout(s),pt.delete(e))}},Z=(e,t)=>(A(t)?t:b()).querySelectorAll(e),Fe=new Map;function Yo(e){const{shiftKey:t,code:s}=e,n=b(this),o=[...Z(Ro,this)].filter(r=>!Ut(r,"disabled")&&!tt(r,Kt));if(!o.length)return;const i=o[0],a=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(a.focus(),e.preventDefault()):!t&&n.activeElement===a&&(i.focus(),e.preventDefault()))}const Zo=e=>Fe.has(e)===!0,me=e=>{const t=Zo(e);(t?zo:jo)(e,"keydown",Yo),t?Fe.delete(e):Fe.set(e,!0)},Gt=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:a,left:r}=e.getBoundingClientRect();let c=1,l=1;if(t&&T(e)){const{offsetWidth:d,offsetHeight:g}=e;c=d>0?Math.round(s)/d:1,l=g>0?Math.round(n)/g:1}return{width:s/c,height:n/l,top:o/l,right:i/c,bottom:a/l,left:r/c,x:r/c,y:o/l}},ut=e=>b(e).body,ct=e=>b(e).documentElement,Fs=e=>A(e)&&e.constructor.name==="ShadowRoot"||!1,Go=e=>e.nodeName==="HTML"?e:T(e)&&e.assignedSlot||A(e)&&e.parentNode||Fs(e)&&e.host||ct(e);let Ws=0,Vs=0;const Bt=new Map,js=(e,t)=>{let s=t?Ws:Vs;if(t){const n=js(e),o=Bt.get(n)||new Map;Bt.has(n)||Bt.set(n,o),Re(o)&&!o.has(t)?(o.set(t,s),Ws+=1):s=o.get(t)}else{const n=e.id||e;Bt.has(n)?s=Bt.get(n):(Bt.set(n,s),Vs+=1)}return s},Jo=e=>e?Ms(e)?e.defaultView:A(e)?e?.ownerDocument?.defaultView:e:window,Qo=e=>Array.isArray(e)||!1,zs=e=>{if(!A(e))return!1;const{top:t,bottom:s}=Gt(e),{clientHeight:n}=ct(e);return t<=n&&s>=0},ti=e=>typeof e=="function"||!1,ei=e=>Xt(e)&&e.constructor.name==="NodeList"||!1,mt=e=>ct(e).dir==="rtl",si=e=>A(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,N=(e,t)=>e?e.closest(t)||N(e.getRootNode().host,t):null,S=(e,t)=>T(e)?e:(A(t)?t:b()).querySelector(e),We=(e,t)=>(A(t)?t:b()).getElementsByTagName(e),lt=(e,t)=>(t&&A(t)?t:b()).getElementsByClassName(e),Ks=(e,t)=>e.matches(t),Rt={},Us=e=>{const{type:t,currentTarget:s}=e;[...Rt[t]].forEach(([n,o])=>{s===n&&[...o].forEach(([i,a])=>{i.apply(n,[e]),typeof a=="object"&&a.once&&M(n,t,i,a)})})},_=(e,t,s,n)=>{Rt[t]||(Rt[t]=new Map);const o=Rt[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:a}=i;i.set(s,n);a||e.addEventListener(t,Us,n)},M=(e,t,s,n)=>{const o=Rt[t],i=o&&o.get(e),a=i&&i.get(s),r=a!==void 0?a:n;i&&i.has(s)&&i.delete(s);o&&(!i||!i.size)&&o.delete(e);(!o||!o.size)&&delete Rt[t];(!i||!i.size)&&e.removeEventListener(t,Us,r)},B="fade",u="show",ve="data-bs-dismiss",be="alert",Xs="Alert",ni="5.1.0";class et{constructor(t,s){let n;try{if(T(t))n=t;else if(qt(t)){if(n=S(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=Dt.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&Rs(this.defaults).length?Xo(n,this.defaults,s||{},"bs"):{},Dt.set(n,this.name,this)}get version(){return ni}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){Dt.remove(this.element,this.name),Rs(this).forEach(t=>{delete this[t]})}}const oi=`.${be}`,ii=`[${ve}="${be}"]`,ai=e=>F(e,Xs),ri=e=>new Ve(e),qs=w(`close.bs.${be}`),ci=w(`closed.bs.${be}`),Ys=e=>{const{element:t}=e;E(t,ci),e._toggleEventListeners(),e.dispose(),t.remove()};class Ve extends et{static selector=oi;static init=ri;static getInstance=ai;dismiss;constructor(t){super(t),this.dismiss=S(ii,this.element),this._toggleEventListeners(!0)}get name(){return Xs}close=()=>{const{element:t}=this;t&&f(t,u)&&(E(t,qs),qs.defaultPrevented||(m(t,u),f(t,B)?P(t,()=>Ys(this)):Ys(this)))};_toggleEventListeners=t=>{const s=t?_:M,{dismiss:n,close:o}=this;n&&s(n,L,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const y="active",ot="data-bs-toggle",li="button",Zs="Button",di=`[${ot}="${li}"]`,hi=e=>F(e,Zs),fi=e=>new je(e);class je extends et{static selector=di;static init=fi;static getInstance=hi;isActive=!1;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,y),O(s,Is,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return Zs}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!tt(s,"disabled")&&((n?m:h)(s,y),O(s,Is,n?"false":"true"),this.isActive=f(s,y))};_toggleEventListeners=t=>{(t?_:M)(this.element,L,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const ze="data-bs-target",At="carousel",Gs="Carousel",Js="data-bs-parent",gi="data-bs-container",z=e=>{const t=[ze,Js,gi,"href"],s=b(e);return t.map(n=>{const o=tt(e,n);return o?n===Js?N(e,o):S(o,s):null}).filter(n=>n)[0]},Jt=`[data-bs-ride="${At}"]`,G=`${At}-item`,Ke="data-bs-slide-to",vt="data-bs-slide",bt="paused",Qs={pause:"hover",keyboard:!1,touch:!0,interval:5e3},dt=e=>F(e,Gs),pi=e=>new Ge(e);let Qt=0,Ee=0,Ue=0;const Xe=w(`slide.bs.${At}`),qe=w(`slid.bs.${At}`),tn=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const a=Ze(e),r=s==="left"?"next":"prev",c=s==="left"?"start":"end";h(o[t],y),m(o[t],`${G}-${r}`),m(o[t],`${G}-${c}`),m(o[a],y),m(o[a],`${G}-${c}`),E(n,qe),p.clear(n,vt),e.cycle&&!b(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function ui(){const e=dt(this);e&&!e.isPaused&&!p.get(this,bt)&&h(this,bt)}function mi(){const e=dt(this);e&&e.isPaused&&!p.get(this,bt)&&e.cycle()}function vi(e){e.preventDefault();const t=N(this,Jt)||z(this),s=dt(t);if(s&&!s.isAnimating){const n=+(tt(this,Ke)||0);this&&!f(this,y)&&!Number.isNaN(n)&&s.to(n)}}function bi(e){e.preventDefault();const t=N(this,Jt)||z(this),s=dt(t);if(s&&!s.isAnimating){const n=tt(this,vt);n==="next"?s.next():n==="prev"&&s.prev()}}const Ei=({code:e,target:t})=>{const s=b(t),[n]=[...Z(Jt,s)].filter(i=>zs(i)),o=dt(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=mt(n);e===(i?ks:Ns)?o.prev():e===(i?Ns:ks)&&o.next()}};function en(e){const{target:t}=e,s=dt(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function wi(e){const{target:t}=e,s=dt(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(Qt=e.pageX,this.contains(t)&&(s.isTouch=!0,sn(s,!0)))}}const Ti=e=>{Ee=e.pageX},yi=e=>{const{target:t}=e,s=b(t),n=[...Z(Jt,s)].map(o=>dt(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,a=mt(o);Ue=e.pageX,n.isTouch=!1,sn(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(Qt-Ue)>120&&(EeQt&&n.to(i+(a?1:-1))),Qt=0,Ee=0,Ue=0}},Ye=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>m(n,y)),e.indicators[t]&&h(s[t],y)},sn=(e,t)=>{const{element:s}=e,n=t?_:M;n(b(s),_o,Ti,Zt),n(b(s),Mo,yi,Zt)},Ze=e=>{const{slides:t,element:s}=e,n=S(`.${G}.${y}`,s);return T(n)?[...t].indexOf(n):-1};class Ge extends et{static selector=Jt;static init=pi;static getInstance=dt;constructor(t,s){super(t,s);const{element:n}=this;this.direction=mt(n)?"right":"left",this.isTouch=!1,this.slides=lt(G,n);const{slides:o}=this;if(o.length>=2){const i=Ze(this),a=[...o].find(l=>Ks(l,`.${G}-next,.${G}-next`));this.index=i;const r=b(n);this.controls=[...Z(`[${vt}]`,n),...Z(`[${vt}][${ze}="#${n.id}"]`,r)].filter((l,d,g)=>d===g.indexOf(l)),this.indicator=S(`.${At}-indicators`,n),this.indicators=[...this.indicator?Z(`[${Ke}]`,this.indicator):[],...Z(`[${Ke}][${ze}="#${n.id}"]`,r)].filter((l,d,g)=>d===g.indexOf(l));const{options:c}=this;this.options.interval=c.interval===!0?Qs.interval:c.interval,a?this.index=[...o].indexOf(a):i<0&&(this.index=0,h(o[0],y),this.indicators.length&&Ye(this,0)),this.indicators.length&&Ye(this,this.index),this._toggleEventListeners(!0),c.interval&&this.cycle()}}get name(){return Gs}get defaults(){return Qs}get isPaused(){return f(this.element,bt)}get isAnimating(){return S(`.${G}-next,.${G}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;p.clear(t,At),n&&(p.clear(t,bt),m(t,bt)),p.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&zs(t)&&this.to(o+1)},s.interval,At)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,bt),p.set(t,()=>{},1,bt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Ze(this),a=mt(s);let r=t;if(!this.isAnimating&&i!==r&&!p.get(s,vt)){ir||i===n.length-1&&r===0)&&(this.direction=a?"left":"right");const{direction:c}=this;r<0?r=n.length-1:r>=n.length&&(r=0);const l=c==="left"?"next":"prev",d=c==="left"?"start":"end",g={relatedTarget:n[r],from:i,to:r,direction:c};at(Xe,g),at(qe,g),E(s,Xe),Xe.defaultPrevented||(this.index=r,Ye(this,r),Yt(n[r])&&f(s,"slide")?p.set(s,()=>{h(n[r],`${G}-${l}`),Ht(n[r]),h(n[r],`${G}-${d}`),h(n[i],`${G}-${d}`),P(n[r],()=>this.slides&&this.slides.length&&tn(this))},0,vt):(h(n[r],y),m(n[i],y),p.set(s,()=>{p.clear(s,vt),s&&o.interval&&!this.isPaused&&this.cycle(),E(s,qe)},0,vt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:a}=this,{touch:r,pause:c,interval:l,keyboard:d}=n,g=t?_:M;c&&l&&(g(s,ge,ui),g(s,Oe,mi)),r&&o.length>2&&(g(s,ko,wi,Zt),g(s,Ne,en,{passive:!1}),g(s,Bo,en,{passive:!1})),i.length&&i.forEach($=>{$&&g($,L,bi)}),a.length&&a.forEach($=>{g($,L,vi)}),d&&g(b(s),fe,Ei)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&P(s.slides[s.index],()=>{tn(s)})}}const Pt="collapsing",K="collapse",nn="Collapse",$i=`.${K}`,on=`[${ot}="${K}"]`,Ci={parent:null},we=e=>F(e,nn),Si=e=>new Je(e),an=w(`show.bs.${K}`),Di=w(`shown.bs.${K}`),rn=w(`hide.bs.${K}`),Hi=w(`hidden.bs.${K}`),Ai=e=>{const{element:t,parent:s,triggers:n}=e;E(t,an),an.defaultPrevented||(p.set(t,pe,17),s&&p.set(s,pe,17),h(t,Pt),m(t,K),x(t,{height:`${t.scrollHeight}px`}),P(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>O(o,de,"true")),m(t,Pt),h(t,K),h(t,u),x(t,{height:""}),E(t,Di)}))},cn=e=>{const{element:t,parent:s,triggers:n}=e;E(t,rn),rn.defaultPrevented||(p.set(t,pe,17),s&&p.set(s,pe,17),x(t,{height:`${t.scrollHeight}px`}),m(t,K),m(t,u),h(t,Pt),Ht(t),x(t,{height:"0px"}),P(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>O(o,de,"false")),m(t,Pt),h(t,K),x(t,{height:""}),E(t,Hi)}))},Pi=e=>{const{target:t}=e,s=t&&N(t,on),n=s&&z(s),o=n&&we(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class Je extends et{static selector=$i;static init=Si;static getInstance=we;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=b(n);this.triggers=[...Z(on,i)].filter(a=>z(a)===n),this.parent=T(o.parent)?o.parent:qt(o.parent)?z(n)||S(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return nn}get defaults(){return Ci}hide(){const{triggers:t,element:s}=this;p.get(s)||(cn(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...Z(`.${K}.${u}`,s)].find(a=>we(a)),i=o&&we(o)),(!s||!p.get(s))&&!p.get(t)&&(i&&o!==t&&(cn(i),i.triggers.forEach(a=>{h(a,`${K}d`)})),Ai(this),n.length&&n.forEach(a=>m(a,`${K}d`)))}toggle(){f(this.element,u)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?_:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,L,Pi))};dispose(){this._toggleEventListeners(),super.dispose()}}const xt=["dropdown","dropup","dropstart","dropend"],ln="Dropdown",dn="dropdown-menu",hn=e=>{const t=N(e,"A");return e.tagName==="A"&&Ut(e,"href")&&tt(e,"href").slice(-1)==="#"||t&&Ut(t,"href")&&tt(t,"href").slice(-1)==="#"},[st,Qe,ts,es]=xt,fn=`[${ot}="${st}"]`,Ft=e=>F(e,ln),xi=e=>new os(e),Ii=`${dn}-end`,gn=[st,Qe],pn=[ts,es],un=["A","BUTTON"],Li={offset:5,display:"dynamic"},ss=w(`show.bs.${st}`),mn=w(`shown.bs.${st}`),ns=w(`hide.bs.${st}`),vn=w(`hidden.bs.${st}`),bn=w(`updated.bs.${st}`),En=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(j(s,"position")!=="static"){const a=mt(t),r=f(s,Ii);["margin","top","bottom","left","right"].forEach(k=>{const yt={};yt[k]="",x(s,yt)});let l=xt.find(k=>f(n,k))||st;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:a?[-1,0,0,i]:[-1,i,0],dropend:a?[-1,i,0]:[-1,0,0,i]},g={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:a?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:a?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:a?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:a?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:$,offsetHeight:D}=s,{clientWidth:W,clientHeight:v}=ct(t),{left:U,top:Y,width:Vt,height:ft}=Gt(t),C=U-$-i<0,nt=U+$+Vt+i>=W,it=Y+D+i>=v,V=Y+D+ft+i>=v,X=Y-D-i<0,H=(!a&&r||a&&!r)&&U+Vt-$<0,jt=(a&&r||!a&&!r)&&U+$>=W;if(pn.includes(l)&&C&&nt&&(l=st),l===ts&&(a?nt:C)&&(l=es),l===es&&(a?C:nt)&&(l=ts),l===Qe&&X&&!V&&(l=st),l===st&&V&&!X&&(l=Qe),pn.includes(l)&&it&&at(g[l],{top:"auto",bottom:0}),gn.includes(l)&&(H||jt)){let k={left:"auto",right:"auto"};!H&&jt&&!a&&(k={left:"auto",right:0}),H&&!jt&&a&&(k={left:0,right:"auto"}),k&&at(g[l],k)}const Tt=d[l];x(s,{...g[l],margin:`${Tt.map(k=>k&&`${k}px`).join(" ")}`}),gn.includes(l)&&r&&r&&x(s,g[!a&&H||a&&jt?"menuStart":"menuEnd"]),E(n,bn)}},Oi=e=>[...e.children].map(t=>{if(t&&un.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&un.includes(s.tagName)?s:null}).filter(t=>t),wn=e=>{const{element:t,options:s,menu:n}=e,o=e.open?_:M,i=b(t);o(i,L,Tn),o(i,Ie,Tn),o(i,fe,ki),o(i,Oo,_i),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},Te=e=>{const t=[...xt,"btn-group","input-group"].map(s=>lt(`${s} ${u}`,b(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>xt.some(n=>n===tt(s,ot)))},Tn=e=>{const{target:t,type:s}=e;if(t&&T(t)){const n=Te(t),o=n&&Ft(n);if(o){const{parentElement:i,menu:a}=o,r=i&&i.contains(t)&&(t.tagName==="form"||N(t,"form")!==null);[L,Os].includes(s)&&hn(t)&&e.preventDefault(),!r&&s!==Ie&&t!==n&&t!==a&&o.hide()}}},Ni=e=>{const{target:t}=e,s=t&&N(t,fn),n=s&&Ft(s);n&&(e.stopPropagation(),n.toggle(),s&&hn(s)&&e.preventDefault())},ki=e=>{[ke,_e].includes(e.code)&&e.preventDefault()};function _i(e){const{code:t}=e,s=Te(this),n=s&&Ft(s),{activeElement:o}=s&&b(s);if(n&&o){const{menu:i,open:a}=n,r=Oi(i);if(r&&r.length&&[ke,_e].includes(t)){let c=r.indexOf(o);o===s?c=0:t===_e?c=c>1?c-1:0:t===ke&&(c=cMi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return ln}get defaults(){return Li}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(!s){const i=Te(t),a=i&&Ft(i);a&&a.hide(),[ss,mn,bn].forEach(r=>{r.relatedTarget=t}),E(o,ss),ss.defaultPrevented||(h(n,u),h(o,u),O(t,de,"true"),En(this),this.open=!s,rt(t),wn(this),E(o,mn))}}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([ns,vn].forEach(i=>{i.relatedTarget=t}),E(o,ns),ns.defaultPrevented||(m(n,u),m(o,u),O(t,de,"false"),this.open=!s,wn(this),E(o,vn)))}_toggleEventListeners=t=>{(t?_:M)(this.element,L,Ni)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const q="modal",is="Modal",as="Offcanvas",Bi="fixed-top",Ri="fixed-bottom",yn="sticky-top",$n="position-sticky",Cn=e=>[...lt(Bi,e),...lt(Ri,e),...lt(yn,e),...lt($n,e),...lt("is-fixed",e)],Fi=e=>{const t=ut(e);x(t,{paddingRight:"",overflow:""});const s=Cn(t);s.length&&s.forEach(n=>{x(n,{paddingRight:"",marginRight:""})})},Sn=e=>{const{clientWidth:t}=ct(e),{innerWidth:s}=Jo(e);return Math.abs(s-t)},Dn=(e,t)=>{const s=ut(e),n=parseInt(j(s,"paddingRight"),10),i=j(s,"overflow")==="hidden"&&n?0:Sn(e),a=Cn(s);t&&(x(s,{overflow:"hidden",paddingRight:`${n+i}px`}),a.length&&a.forEach(r=>{const c=j(r,"paddingRight");if(r.style.paddingRight=`${parseInt(c,10)+i}px`,[yn,$n].some(l=>f(r,l))){const l=j(r,"marginRight");r.style.marginRight=`${parseInt(l,10)-i}px`}}))},J="offcanvas",Et=gt({tagName:"div",className:"popup-container"}),Hn=(e,t)=>{const s=A(t)&&t.nodeName==="BODY",n=A(t)&&!s?t:Et,o=s?t:ut(e);A(e)&&(n===Et&&o.append(Et),n.append(e))},An=(e,t)=>{const s=A(t)&&t.nodeName==="BODY",n=A(t)&&!s?t:Et;A(e)&&(e.remove(),n===Et&&!Et.children.length&&Et.remove())},rs=(e,t)=>{const s=A(t)&&t.nodeName!=="BODY"?t:Et;return A(e)&&s.contains(e)},Pn="backdrop",xn=`${q}-${Pn}`,In=`${J}-${Pn}`,Ln=`.${q}.${u}`,cs=`.${J}.${u}`,I=gt("div"),It=e=>S(`${Ln},${cs}`,b(e)),ls=e=>{const t=e?xn:In;[xn,In].forEach(s=>{m(I,s)}),h(I,t)},On=(e,t,s)=>{ls(s),Hn(I,ut(e)),t&&h(I,B)},Nn=()=>{f(I,u)||(h(I,u),Ht(I))},ye=()=>{m(I,u)},kn=e=>{It(e)||(m(I,B),An(I,ut(e)),Fi(e))},_n=e=>T(e)&&j(e,"visibility")!=="hidden"&&e.offsetParent!==null,Wi=`.${q}`,Mn=`[${ot}="${q}"]`,Vi=`[${ve}="${q}"]`,Bn=`${q}-static`,ji={backdrop:!0,keyboard:!0},te=e=>F(e,is),zi=e=>new hs(e),$e=w(`show.bs.${q}`),Rn=w(`shown.bs.${q}`),ds=w(`hide.bs.${q}`),Fn=w(`hidden.bs.${q}`),Wn=e=>{const{element:t}=e,s=Sn(t),{clientHeight:n,scrollHeight:o}=ct(t),{clientHeight:i,scrollHeight:a}=t,r=i!==a;if(!r&&s){const l={[mt(t)?"paddingLeft":"paddingRight"]:`${s}px`};x(t,l)}Dn(t,r||n!==o)},Vn=(e,t)=>{const s=t?_:M,{element:n}=e;s(n,L,Xi),s(b(n),fe,Ui),t?e._observer.observe(n):e._observer.disconnect()},jn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;kn(s),x(s,{paddingRight:"",display:""}),Vn(e);const o=$e.relatedTarget||t.find(_n);o&&rt(o),Fn.relatedTarget=n,E(s,Fn),me(s)},zn=e=>{const{element:t,relatedTarget:s}=e;rt(t),Vn(e,!0),Rn.relatedTarget=s,E(t,Rn),me(t)},Kn=e=>{const{element:t,hasFade:s}=e;x(t,{display:"block"}),Wn(e),It(t)||x(ut(t),{overflow:"hidden"}),h(t,u),St(t,Kt),O(t,he,"true"),s?P(t,()=>zn(e)):zn(e)},Un=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(I,u)&&!It(t)?(ye(),P(I,()=>jn(e))):jn(e)},Ki=e=>{const{target:t}=e,s=t&&N(t,Mn),n=s&&z(s),o=n&&te(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Ui=({code:e,target:t})=>{const s=S(Ln,b(t)),n=s&&te(s);if(n){const{options:o}=n;o.keyboard&&e===Me&&f(s,u)&&(n.relatedTarget=null,n.hide())}},Xi=e=>{const{currentTarget:t}=e,s=t&&te(t);if(s&&t&&!p.get(t)){const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:a}=n,{target:r}=e,c=b(t)?.getSelection()?.toString().length,l=i.contains(r),d=r&&N(r,Vi);o&&!l?p.set(t,()=>{h(t,Bn),P(i,()=>qi(s))},17):(d||!c&&!o&&!l&&a)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())}},qi=e=>{const{element:t,modalDialog:s}=e,n=(Yt(s)||0)+17;m(t,Bn),p.set(t,()=>p.clear(t),n)};class hs extends et{static selector=Wi;static init=zi;static getInstance=te;constructor(t,s){super(t,s);const{element:n}=this,o=S(`.${q}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...Z(Mn,b(n))].filter(i=>z(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,B),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return is}get defaults(){return ji}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let a=0;if(!f(t,u)&&($e.relatedTarget=o||void 0,E(t,$e),!$e.defaultPrevented)){const r=It(t);if(r&&r!==t){const c=te(r)||F(r,as);c&&c.hide()}i?(rs(I)?ls(!0):On(t,n,!0),a=Yt(I),Nn(),setTimeout(()=>Kn(this),a)):(Kn(this),r&&f(I,u)&&ye())}}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,u)&&(ds.relatedTarget=n||void 0,E(t,ds),ds.defaultPrevented||(m(t,u),O(t,Kt,"true"),St(t,he),s?P(t,()=>Un(this)):Un(this)))}update=()=>{f(this.element,u)&&Wn(this)};_toggleEventListeners=t=>{const s=t?_:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,L,Ki))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?P(s,o):o()}}const Yi=`.${J}`,fs=`[${ot}="${J}"]`,Zi=`[${ve}="${J}"]`,Ce=`${J}-toggling`,Gi={backdrop:!0,keyboard:!0,scroll:!1},ee=e=>F(e,as),Ji=e=>new ps(e),Se=w(`show.bs.${J}`),Xn=w(`shown.bs.${J}`),gs=w(`hide.bs.${J}`),qn=w(`hidden.bs.${J}`),Qi=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=ct(t);Dn(t,s!==n)},Yn=(e,t)=>{const s=t?_:M,n=b(e.element);s(n,fe,na),s(n,L,sa)},Zn=e=>{const{element:t,options:s}=e;s.scroll||(Qi(e),x(ut(t),{overflow:"hidden"})),h(t,Ce),h(t,u),x(t,{visibility:"visible"}),P(t,()=>oa(e))},ta=e=>{const{element:t,options:s}=e,n=It(t);t.blur(),!n&&s.backdrop&&f(I,u)&&ye(),P(t,()=>ia(e))},ea=e=>{const t=N(e.target,fs),s=t&&z(t),n=s&&ee(s);n&&(n.relatedTarget=t,n.toggle(),t&&t.tagName==="A"&&e.preventDefault())},sa=e=>{const{target:t}=e,s=S(cs,b(t)),n=S(Zi,s),o=s&&ee(s);if(o){const{options:i,triggers:a}=o,{backdrop:r}=i,c=N(t,fs),l=b(s).getSelection();(!I.contains(t)||r!=="static")&&(!(l&&l.toString().length)&&(!s.contains(t)&&r&&(!c||a.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:null,o.hide()),c&&c.tagName==="A"&&e.preventDefault())}},na=({code:e,target:t})=>{const s=S(cs,b(t)),n=s&&ee(s);n&&n.options.keyboard&&e===Me&&(n.relatedTarget=null,n.hide())},oa=e=>{const{element:t}=e;m(t,Ce),St(t,Kt),O(t,he,"true"),O(t,"role","dialog"),E(t,Xn),Yn(e,!0),rt(t),me(t)},ia=e=>{const{element:t,triggers:s}=e;O(t,Kt,"true"),St(t,he),St(t,"role"),x(t,{visibility:""});const n=Se.relatedTarget||s.find(_n);n&&rt(n),kn(t),E(t,qn),m(t,Ce),me(t),It(t)||Yn(e)};class ps extends et{static selector=Yi;static init=Ji;static getInstance=ee;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...Z(fs,b(n))].filter(o=>z(o)===n),this.relatedTarget=null,this._toggleEventListeners(!0)}get name(){return as}get defaults(){return Gi}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(!f(t,u)&&(Se.relatedTarget=n||void 0,Xn.relatedTarget=n||void 0,E(t,Se),!Se.defaultPrevented)){const i=It(t);if(i&&i!==t){const a=ee(i)||F(i,is);a&&a.hide()}s.backdrop?(rs(I)?ls():On(t,!0),o=Yt(I),Nn(),setTimeout(()=>Zn(this),o)):(Zn(this),i&&f(I,u)&&ye())}}hide(){const{element:t,relatedTarget:s}=this;f(t,u)&&(gs.relatedTarget=s||void 0,qn.relatedTarget=s||void 0,E(t,gs),gs.defaultPrevented||(h(t,Ce),m(t,u),ta(this)))}_toggleEventListeners=t=>{const s=t?_:M;this.triggers.forEach(n=>s(n,L,ea))};dispose(){const{element:t}=this,s=f(t,u),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?P(t,n):n()}}const Lt="popover",De="Popover",ht="tooltip",Gn=e=>{const t=e===ht,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},Jn={top:"top",bottom:"bottom",left:"start",right:"end"},us=e=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,options:i,arrow:a}=e;if(n){const r={...Jn},c=mt(s);x(n,{top:"",left:"",right:"",bottom:""});const l=e.name===De,{offsetWidth:d,offsetHeight:g}=n,{clientWidth:$,clientHeight:D,offsetWidth:W}=ct(s);let{placement:v}=i;const{clientWidth:U,offsetWidth:Y}=o,ft=j(o,"position")==="fixed",C=Math.abs(ft?U-Y:$-W),nt=c&&ft?C:0,it=$-(c?0:C)-1,{width:V,height:X,left:H,right:jt,top:Tt}=Gt(s,!0),{x:k,y:yt}={x:H,y:Tt};x(a,{top:"",left:"",right:"",bottom:""});let Nt=0,ie="",$t=0,Ds="",zt="",Ae="",Hs="";const kt=a.offsetWidth||0,Ct=a.offsetHeight||0,As=kt/2;let ae=Tt-g-Ct<0,re=Tt+g+X+Ct>=D,ce=H-d-kt=it;const Pe=["left","right"],Ps=["top","bottom"];ae=Pe.includes(v)?Tt+X/2-g/2-Ct<0:ae,re=Pe.includes(v)?Tt+g/2+X/2+Ct>=D:re,ce=Ps.includes(v)?H+V/2-d/2=it:le,v=Pe.includes(v)&&ce&&le?"top":v,v=v==="top"&&ae?"bottom":v,v=v==="bottom"&&re?"top":v,v=v==="left"&&ce?"right":v,v=v==="right"&&le?"left":v,n.className.includes(v)||(n.className=n.className.replace(t,r[v])),Pe.includes(v)?(v==="left"?$t=k-d-(l?kt:0):$t=k+V+(l?kt:0),ae&&re?(Nt=0,ie=0,zt=Tt+X/2-Ct/2):ae?(Nt=yt,ie="",zt=X/2-kt):re?(Nt=yt-g+X,ie="",zt=g-X/2-kt):(Nt=yt-g/2+X/2,zt=g/2-Ct/2)):Ps.includes(v)&&(v==="top"?Nt=yt-g-(l?Ct:0):Nt=yt+X+(l?Ct:0),ce?($t=0,Ae=k+V/2-As):le?($t="auto",Ds=0,Hs=V/2+it-jt-As):($t=k-d/2+V/2,Ae=d/2-As)),x(n,{top:`${Nt}px`,bottom:ie===""?"":`${ie}px`,left:$t==="auto"?$t:`${$t}px`,right:Ds!==""?`${Ds}px`:""}),T(a)&&(zt!==""&&(a.style.top=`${zt}px`),Ae!==""?a.style.left=`${Ae}px`:Hs!==""&&(a.style.right=`${Hs}px`));const Va=w(`updated.bs.${Mt(e.name)}`);E(s,Va)}},ms={template:Gn(ht),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},aa=e=>e!=null&&typeof e=="object"||!1,ra=e=>aa(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,Qn=e=>ra(e)&&e.nodeType===1||!1,ca=e=>typeof e=="function"||!1,to="PositionObserver Error";class eo{entries;_tick;_root;_callback;constructor(t,s){if(!ca(t))throw new Error(`${to}: ${t} is not a function.`);this.entries=[],this._callback=t,this._root=Qn(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!Qn(t))throw new Error(`${to}: ${t} is not an instance of HTMLElement.`);if(!this._root.contains(t))return;const{clientWidth:s,clientHeight:n}=this._root,o=t.getBoundingClientRect(),{left:i,top:a,bottom:r,right:c,width:l,height:d}=o,g=a>1-d&&i>1-l&&r<=n+d-1&&c<=s+l-1;this.entries.push({target:t,boundingBox:o,isVisible:g}),this._tick||(this._tick=requestAnimationFrame(this._runCallback))};unobserve=t=>{const s=this.entries.findIndex(n=>n.target===t);this.entries.splice(s,1)};_runCallback=()=>{if(!this.entries.length)return;const t=[],{clientWidth:s,clientHeight:n}=this._root;this.entries.forEach((o,i)=>{const{target:a,boundingBox:r}=o,c=a.getBoundingClientRect(),{left:l,top:d,bottom:g,right:$,width:D,height:W}=c;if(r.left!==l||r.top!==d||r.right!==$||r.bottom!==g){const v=d>1-W&&l>1-D&&g<=n+W-1&&$<=s+D-1;this.entries[i].boundingBox=c,this.entries[i].isVisible=v,t.push({target:a,boundingBox:c,isVisible:v})}}),t.length&&this._callback(t),requestAnimationFrame(this._runCallback)};disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.length=0,this._tick=0}}const so="data-original-title",Ot="Tooltip",wt=(e,t,s)=>{if(qt(t)&&t.length){let n=t.trim();ti(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else T(t)?e.append(t):(ei(t)||Qo(t)&&t.every(A))&&e.append(...t)},la=e=>{const t=e.name===Ot,{id:s,element:n,options:o}=e,{title:i,placement:a,template:r,animation:c,customClass:l,sanitizeFn:d,dismissible:g,content:$,btnClose:D}=o,W=t?ht:Lt,v={...Jn};let U=[],Y=[];mt(n)&&(v.left="end",v.right="start");const Vt=`bs-${W}-${v[a]}`;let ft;if(T(r))ft=r;else{const nt=gt("div");wt(nt,r,d),ft=nt.firstChild}e.tooltip=T(ft)?ft.cloneNode(!0):void 0;const{tooltip:C}=e;if(C){O(C,"id",s),O(C,"role",ht);const nt=t?`${ht}-inner`:`${Lt}-body`,it=t?null:S(`.${Lt}-header`,C),V=S(`.${nt}`,C);e.arrow=S(`.${W}-arrow`,C);const{arrow:X}=e;if(T(i))U=[i.cloneNode(!0)];else{const H=gt("div");wt(H,i,d),U=[...H.childNodes]}if(T($))Y=[$.cloneNode(!0)];else{const H=gt("div");wt(H,$,d),Y=[...H.childNodes]}if(g)if(i)if(T(D))U=[...U,D.cloneNode(!0)];else{const H=gt("div");wt(H,D,d),U=[...U,H.firstChild]}else if(it&&it.remove(),T(D))Y=[...Y,D.cloneNode(!0)];else{const H=gt("div");wt(H,D,d),Y=[...Y,H.firstChild]}t?i&&V&&wt(V,i,d):(i&&it&&wt(it,U,d),$&&V&&wt(V,Y,d),e.btn=S(".btn-close",C)||void 0),h(C,"position-fixed"),h(X,"position-absolute"),f(C,W)||h(C,W),c&&!f(C,B)&&h(C,B),l&&!f(C,l)&&h(C,l),f(C,Vt)||h(C,Vt)}},da=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=Go(n),Fs(n)||si(n)||s.push(n);return s.find((o,i)=>j(o,"position")!=="relative"&&s.slice(i+1).every(a=>j(a,"position")==="static")?o:null)||b(e).body},ha=`[${ot}="${ht}"],[data-tip="${ht}"]`,no="title";let oo=e=>F(e,Ot);const fa=e=>new He(e),ga=e=>{const{element:t,tooltip:s,container:n,offsetParent:o}=e;St(t,xs),An(s,n===o?n:o)},se=e=>{const{tooltip:t,container:s,offsetParent:n}=e;return t&&rs(t,s===n?s:n)},pa=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),Ut(s,so)&&e.name===Ot&&lo(e),t&&t()},io=(e,t)=>{const s=t?_:M,{element:n}=e;s(b(n),Ne,e.handleTouch,Zt)},ao=e=>{const{element:t}=e,s=w(`shown.bs.${Mt(e.name)}`);io(e,!0),E(t,s),p.clear(t,"in")},ro=e=>{const{element:t}=e,s=w(`hidden.bs.${Mt(e.name)}`);io(e),ga(e),E(t,s),p.clear(t,"out")},co=(e,t)=>{const s=t?_:M,{element:n}=e,o=N(n,`.${q}`),i=N(n,`.${J}`);t?e._observer.observe(e.element):e._observer.disconnect(),o&&s(o,`hide.bs.${q}`,e.handleHide),i&&s(i,`hide.bs.${J}`,e.handleHide)},lo=(e,t)=>{const s=[so,no],{element:n}=e;O(n,s[t?0:1],t||tt(n,s[0])||""),St(n,s[t?1:0])};class He extends et{static selector=ha;static init=fa;static getInstance=oo;static styleTip=us;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===Ot,i=o?ht:Lt,a=o?Ot:De;oo=c=>F(c,a),this.enabled=!0,this.id=`${i}-${js(n,i)}`;const{options:r}=this;!r.title&&o||!o&&!r.content||(at(ms,{titleAttr:""}),Ut(n,no)&&o&&typeof r.title=="string"&&lo(this,r.title),this.container=da(n),this.offsetParent=["sticky","fixed"].some(c=>j(this.container,"position")===c)?this.container:b(this.element).body,la(this),this._observer=new eo(()=>this.update()),this._toggleEventListeners(!0))}get name(){return Ot}get defaults(){return ms}handleFocus=()=>rt(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,offsetParent:i,id:a}=this,{animation:r}=t,c=p.get(n,"out"),l=o===i?o:i;p.clear(n,"out"),s&&!c&&!se(this)&&p.set(n,()=>{const d=w(`show.bs.${Mt(this.name)}`);E(n,d),d.defaultPrevented||(Hn(s,l),O(n,xs,`#${a}`),this.update(),co(this,!0),f(s,u)||h(s,u),r?P(s,()=>ao(this)):ao(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;p.clear(n,"in"),s&&se(this)&&p.set(n,()=>{const a=w(`hide.bs.${Mt(this.name)}`);E(n,a),a.defaultPrevented||(this.update(),m(s,u),co(this),o?P(s,()=>ro(this)):ro(this))},i+17,"out")}update=()=>{us(this)};toggle=()=>{const{tooltip:t}=this;t&&!se(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&se(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?_:M,{element:n,options:o,btn:i}=this,{trigger:a}=o,c=!!(this.name!==Ot&&o.dismissible);a.includes("manual")||(this.enabled=!!t,a.split(" ").forEach(d=>{d===No?(s(n,Os,this.handleShow),s(n,ge,this.handleShow),c||(s(n,Oe,this.handleHide),s(b(n),Ne,this.handleTouch,Zt))):d===L?s(n,d,c?this.handleShow:this.toggle):d===Ie&&(s(n,Le,this.handleShow),c||s(n,Ls,this.handleHide),Vo()&&s(n,L,this.handleFocus)),c&&i&&s(i,L,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>pa(n,()=>super.dispose()),17);s.animation&&se(n)?(this.options.delay=0,this.hide(),P(t,o)):o()}}const ua=`[${ot}="${Lt}"],[data-tip="${Lt}"]`,ma=at({},ms,{template:Gn(Lt),content:"",dismissible:!1,btnClose:''}),va=e=>F(e,De),ba=e=>new vs(e);class vs extends He{static selector=ua;static init=ba;static getInstance=va;static styleTip=us;constructor(t,s){super(t,s)}get name(){return De}get defaults(){return ma}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>rt(s),17)}}const Ea="scrollspy",ho="ScrollSpy",wa='[data-bs-spy="scroll"]',Ta={offset:10,target:null},ya=e=>F(e,ho),$a=e=>new bs(e),fo=w(`activate.bs.${Ea}`),Ca=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:a}=e,{offset:r}=n,c=s!==a,l=t&&We("A",t),d=b(a),g=s.scrollHeight;if(e.scrollTop=s.scrollTop,l&&(g!==i||o!==l.length)){let $,D,W;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=g,e.maxScroll=e.scrollHeight-Da(e),Array.from(l).forEach(v=>{$=tt(v,"href"),D=$&&$.charAt(0)==="#"&&$.slice(-1)!=="#"&&S($,d),D&&(e.items.push(v),e.targets.push(D),W=Gt(D),e.offsets.push((c?W.top+e.scrollTop:D.offsetTop)-r))}),e.itemsLength=e.items.length}},go=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},Sa=e=>e.scrollHeight,Da=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:Gt(e).height,po=e=>{[...We("A",e)].forEach(t=>{f(t,y)&&m(t,y)})},uo=(e,t)=>{const{target:s,element:n}=e;T(s)&&po(s),e.activeItem=t,h(t,y);const o=[];let i=t;for(;i!==ut(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(a=>{const r=a.previousElementSibling;r&&!f(r,y)&&h(r,y)}),fo.relatedTarget=t,E(n,fo)};class bs extends et{static selector=wa;static init=$a;static getInstance=ya;constructor(t,s){super(t,s);const{element:n,options:o}=this;this.target=S(o.target,b(n)),this.target&&(this.scrollTarget=n.clientHeightthis.refresh(),{root:this.scrollTarget}),go(this,!0))}get name(){return ho}get defaults(){return Ta}refresh=()=>{const{target:t}=this;if(T(t)&&t.offsetHeight>0){Ca(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:a}=this;if(s>=n){const c=i[o-1];a!==c&&uo(this,c);return}const{offsets:r}=this;if(a&&s0){this.activeItem=null,t&&po(t);return}i.forEach((c,l)=>{a!==c&&s>=r[l]&&(typeof r[l+1]>"u"||sF(e,mo),Ha=e=>new Ts(e),Es=w(`show.bs.${ne}`),Eo=w(`shown.bs.${ne}`),ws=w(`hide.bs.${ne}`),wo=w(`hidden.bs.${ne}`),oe=new Map,To=e=>{const{tabContent:t,nav:s}=e;t&&f(t,Pt)&&(t.style.height="",m(t,Pt)),s&&p.clear(s)},yo=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=T(o)&&oe.get(o)||{tab:null};if(s&&n&&f(n,B)){const{currentHeight:a,nextHeight:r}=oe.get(t)||{currentHeight:0,nextHeight:0};a!==r?setTimeout(()=>{s.style.height=`${r}px`,Ht(s),P(s,()=>To(e))},50):To(e)}else o&&p.clear(o);Eo.relatedTarget=i,E(t,Eo)},$o=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:a}=o&&oe.get(o)||{tab:null,content:null};let r=0;if(n&&s&&f(s,B)&&([a,s].forEach(c=>{T(c)&&h(c,"overflow-hidden")}),r=T(a)?a.scrollHeight:0),Es.relatedTarget=i,wo.relatedTarget=t,E(t,Es),!Es.defaultPrevented){if(s&&h(s,y),a&&m(a,y),n&&s&&f(s,B)){const c=s.scrollHeight;oe.set(t,{currentHeight:r,nextHeight:c,tab:null,content:null}),h(n,Pt),n.style.height=`${r}px`,Ht(n),[a,s].forEach(l=>{l&&m(l,"overflow-hidden")})}s&&s&&f(s,B)?setTimeout(()=>{h(s,u),P(s,()=>{yo(e)})},1):(s&&h(s,u),yo(e)),i&&E(i,wo)}},Co=e=>{const{nav:t}=e;if(!T(t))return{tab:null,content:null};const s=lt(y,t);let n=null;s.length===1&&!xt.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=T(n)?z(n):null;return{tab:n,content:o}},So=e=>{if(!T(e))return null;const t=N(e,`.${xt.join(",.")}`);return t?S(`.${xt[0]}-toggle`,t):null},Aa=e=>{const t=bo(e.target);t&&(e.preventDefault(),t.show())};class Ts extends et{static selector=vo;static init=Ha;static getInstance=bo;constructor(t){super(t);const{element:s}=this,n=z(s);if(n){const o=N(s,".nav"),i=N(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=So(s);const{tab:a}=Co(this);if(o&&!a){const r=S(vo,o),c=r&&z(r);c&&(h(r,y),h(c,u),h(c,y),O(s,xe,"true"))}this._toggleEventListeners(!0)}}get name(){return mo}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(!(n&&p.get(n))&&!f(t,y)){const{tab:i,content:a}=Co(this);if(n&&oe.set(n,{tab:i,content:a,currentHeight:0,nextHeight:0}),ws.relatedTarget=t,T(i)&&(E(i,ws),!ws.defaultPrevented)){h(t,y),O(t,xe,"true");const r=T(i)&&So(i);if(r&&f(r,y)&&m(r,y),n){const c=()=>{i&&(m(i,y),O(i,xe,"false")),o&&!f(o,y)&&h(o,y)};a&&(f(a,B)||s&&f(s,B))?p.set(n,c,1):c()}a&&(m(a,u),f(a,B)?P(a,()=>$o(this)):$o(this))}}}_toggleEventListeners=t=>{(t?_:M)(this.element,L,Aa)};dispose(){this._toggleEventListeners(),super.dispose()}}const Q="toast",Do="Toast",Pa=`.${Q}`,xa=`[${ve}="${Q}"]`,Ho=`[${ot}="${Q}"]`,Wt="showing",Ao="hide",Ia={animation:!0,autohide:!0,delay:5e3},ys=e=>F(e,Do),La=e=>new $s(e),Po=w(`show.bs.${Q}`),Oa=w(`shown.bs.${Q}`),xo=w(`hide.bs.${Q}`),Na=w(`hidden.bs.${Q}`),Io=e=>{const{element:t,options:s}=e;m(t,Wt),p.clear(t,Wt),E(t,Oa),s.autohide&&p.set(t,()=>e.hide(),s.delay,Q)},Lo=e=>{const{element:t}=e;m(t,Wt),m(t,u),h(t,Ao),p.clear(t,Q),E(t,Na)},ka=e=>{const{element:t,options:s}=e;h(t,Wt),s.animation?(Ht(t),P(t,()=>Lo(e))):Lo(e)},_a=e=>{const{element:t,options:s}=e;p.set(t,()=>{m(t,Ao),Ht(t),h(t,u),h(t,Wt),s.animation?P(t,()=>Io(e)):Io(e)},17,Wt)},Ma=e=>{const{target:t}=e,s=t&&N(t,Ho),n=s&&z(s),o=n&&ys(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},Ba=e=>{const t=e.target,s=ys(t),{type:n,relatedTarget:o}=e;s&&t!==o&&!t.contains(o)&&([ge,Le].includes(n)?p.clear(t,Q):p.set(t,()=>s.hide(),s.options.delay,Q))};class $s extends et{static selector=Pa;static init=La;static getInstance=ys;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,B)?h(n,B):!o.animation&&f(n,B)&&m(n,B),this.dismiss=S(xa,n),this.triggers=[...Z(Ho,b(n))].filter(i=>z(i)===n),this._toggleEventListeners(!0)}get name(){return Do}get defaults(){return Ia}get isShown(){return f(this.element,u)}show=()=>{const{element:t,isShown:s}=this;t&&!s&&(E(t,Po),Po.defaultPrevented||_a(this))};hide=()=>{const{element:t,isShown:s}=this;t&&s&&(E(t,xo),xo.defaultPrevented||ka(this))};_toggleEventListeners=t=>{const s=t?_:M,{element:n,triggers:o,dismiss:i,options:a,hide:r}=this;i&&s(i,L,r),a.autohide&&[Le,Ls,ge,Oe].forEach(c=>s(n,c,Ba)),o.length&&o.forEach(c=>s(c,L,Ma))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),p.clear(t,Q),s&&m(t,u),super.dispose()}}const Cs=new Map;[Ve,je,Ge,Je,os,hs,ps,vs,bs,Ts,$s,He].forEach(e=>Cs.set(e.prototype.name,e));const Ra=(e,t)=>{[...t].forEach(s=>e(s))},Fa=(e,t)=>{const s=Dt.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},Ss=e=>{const t=e&&e.nodeName?e:document,s=[...We("*",t)];Cs.forEach(n=>{const{init:o,selector:i}=n;Ra(o,s.filter(a=>Ks(a,i)))})},Wa=e=>{const t=e&&e.nodeName?e:document;Cs.forEach(s=>{Fa(s.prototype.name,t)})};return document.body?Ss():_(document,"DOMContentLoaded",()=>Ss(),{once:!0}),R.Alert=Ve,R.Button=je,R.Carousel=Ge,R.Collapse=Je,R.Dropdown=os,R.Modal=hs,R.Offcanvas=ps,R.Popover=vs,R.ScrollSpy=bs,R.Tab=Ts,R.Toast=$s,R.Tooltip=He,R.initCallback=Ss,R.removeDataAPI=Wa,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"}),R}({}); +var BSN=function(R){"use strict";const Ls="aria-describedby",fe="aria-expanded",Yt="aria-hidden",ge="aria-modal",_s="aria-pressed",Ie="aria-selected",Le="focus",_e="focusin",Os="focusout",ue="keydown",Ro="keyup",k="click",Ns="mousedown",Bo="hover",pe="mouseenter",Oe="mouseleave",Fo="pointerdown",Wo="pointermove",jo="pointerup",Ne="touchstart",zo="dragstart",Vo='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',Me="ArrowDown",Re="ArrowUp",Ms="ArrowLeft",Rs="ArrowRight",Be="Escape",Ko="transitionDuration",qo="transitionDelay",Fe="transitionend",Bs="transitionProperty",Xo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},me=()=>{},Yo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},Uo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},tt=(e,t)=>e.getAttribute(t),Ut=(e,t)=>e.hasAttribute(t),I=(e,t,s)=>e.setAttribute(t,s),Ct=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},v=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),Gt=e=>e!=null&&typeof e=="object"||!1,D=e=>Gt(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,U=e=>D(e)&&e.nodeType===1||!1,Rt=new Map,St={data:Rt,set:(e,t,s)=>{U(e)&&(Rt.has(t)||Rt.set(t,new Map),Rt.get(t).set(e,s))},getAllFor:e=>Rt.get(e)||null,get:(e,t)=>{if(!U(e)||!t)return null;const s=St.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=St.getAllFor(t);!s||!U(e)||(s.delete(e),s.size===0&&Rt.delete(t))}},F=(e,t)=>St.get(e,t),Zt=e=>typeof e=="string"||!1,Fs=e=>Gt(e)&&e.constructor.name==="Window"||!1,Ws=e=>D(e)&&e.nodeType===9||!1,w=e=>Ws(e)?e:D(e)?e.ownerDocument:Fs(e)?e.document:globalThis.document,it=(e,...t)=>Object.assign(e,...t),ft=e=>{if(!e)return;if(Zt(e))return w().createElement(e);const{tagName:t}=e,s=ft(t);if(!s)return;const n={...e};return delete n.tagName,it(s,n)},b=(e,t)=>e.dispatchEvent(t),W=(e,t,s)=>{const n=getComputedStyle(e,s),o=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return n.getPropertyValue(o)},Go=e=>{const t=W(e,Bs),s=W(e,qo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},Qt=e=>{const t=W(e,Bs),s=W(e,Ko),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},H=(e,t)=>{let s=0;const n=new Event(Fe),o=Qt(e),i=Go(e);if(o){const r=c=>{c.target===e&&(t.apply(e,[c]),e.removeEventListener(Fe,r),s=1)};e.addEventListener(Fe,r),setTimeout(()=>{s||b(e,n)},o+i+17)}else t.apply(e,[n])},rt=(e,t)=>e.focus(t),js=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,ve=e=>Object.entries(e),Bt=e=>e.toLowerCase(),Zo=(e,t,s,n)=>{if(!U(e))return t;const o={...s},i={...e.dataset},r={...t},c={},a="title";return ve(i).forEach(([l,d])=>{const p=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,T=>Bt(T)):l;c[p]=js(d)}),ve(o).forEach(([l,d])=>{o[l]=js(d)}),ve(t).forEach(([l,d])=>{l in o?r[l]=o[l]:l in c?r[l]=c[l]:r[l]=l===a?tt(e,a):d}),r},zs=e=>Object.keys(e),E=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return Gt(t)&&it(s,t),s},Jt={passive:!0},Ht=e=>e.offsetHeight,x=(e,t)=>{ve(t).forEach(([s,n])=>{if(n&&Zt(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,it(e.style,o)}})},We=e=>Gt(e)&&e.constructor.name==="Map"||!1,Qo=e=>typeof e=="number"||!1,gt=new Map,g={set:(e,t,s,n)=>{U(e)&&(n&&n.length?(gt.has(e)||gt.set(e,new Map),gt.get(e).set(n,setTimeout(t,s))):gt.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!U(e))return null;const s=gt.get(e);return t&&s&&We(s)?s.get(t)||null:Qo(s)?s:null},clear:(e,t)=>{if(!U(e))return;const s=gt.get(e);t&&t.length&&We(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&>.delete(e)):(clearTimeout(s),gt.delete(e))}},G=(e,t)=>(D(t)?t:w()).querySelectorAll(e),je=new Map;function Jo(e){const{shiftKey:t,code:s}=e,n=w(this),o=[...G(Vo,this)].filter(c=>!Ut(c,"disabled")&&!tt(c,Yt));if(!o.length)return;const i=o[0],r=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(r.focus(),e.preventDefault()):!t&&n.activeElement===r&&(i.focus(),e.preventDefault()))}const ti=e=>je.has(e)===!0,be=e=>{const t=ti(e);(t?Uo:Yo)(e,"keydown",Jo),t?je.delete(e):je.set(e,!0)},C=e=>U(e)&&"offsetWidth"in e||!1,ut=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:r,left:c}=e.getBoundingClientRect();let a=1,l=1;if(t&&C(e)){const{offsetWidth:d,offsetHeight:p}=e;a=d>0?Math.round(s)/d:1,l=p>0?Math.round(n)/p:1}return{width:s/a,height:n/l,top:o/l,right:i/a,bottom:r/l,left:c/a,x:c/a,y:o/l}},pt=e=>w(e).body,ct=e=>w(e).documentElement,ei=e=>{const t=Fs(e),s=t?e.scrollX:e.scrollLeft,n=t?e.scrollY:e.scrollTop;return{x:s,y:n}},Vs=e=>D(e)&&e.constructor.name==="ShadowRoot"||!1,si=e=>e.nodeName==="HTML"?e:U(e)&&e.assignedSlot||D(e)&&e.parentNode||Vs(e)&&e.host||ct(e),Ks=e=>e?Ws(e)?e.defaultView:D(e)?e?.ownerDocument?.defaultView:e:window,ni=e=>D(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,qs=(e,t)=>e.matches(t),oi=e=>{if(!C(e))return!1;const{width:t,height:s}=ut(e),{offsetWidth:n,offsetHeight:o}=e;return Math.round(t)!==n||Math.round(s)!==o},ii=(e,t,s)=>{const n=C(t),o=ut(e,n&&oi(t)),i={x:0,y:0};if(n){const r=ut(t,!0);i.x=r.x+t.clientLeft,i.y=r.y+t.clientTop}return{x:o.left+s.x-i.x,y:o.top+s.y-i.y,width:o.width,height:o.height}};let Xs=0,Ys=0;const Ft=new Map,Us=(e,t)=>{let s=t?Xs:Ys;if(t){const n=Us(e),o=Ft.get(n)||new Map;Ft.has(n)||Ft.set(n,o),We(o)&&!o.has(t)?(o.set(t,s),Xs+=1):s=o.get(t)}else{const n=e.id||e;Ft.has(n)?s=Ft.get(n):(Ft.set(n,s),Ys+=1)}return s},ri=e=>Array.isArray(e)||!1,Gs=e=>{if(!D(e))return!1;const{top:t,bottom:s}=ut(e),{clientHeight:n}=ct(e);return t<=n&&s>=0},ci=e=>typeof e=="function"||!1,ai=e=>Gt(e)&&e.constructor.name==="NodeList"||!1,mt=e=>ct(e).dir==="rtl",L=(e,t)=>!e||!t?null:e.closest(t)||L(e.getRootNode().host,t)||null,P=(e,t)=>U(e)?e:(U(t)?t:w()).querySelector(e),ze=(e,t)=>(D(t)?t:w()).getElementsByTagName(e),at=(e,t)=>(t&&D(t)?t:w()).getElementsByClassName(e),Wt={},Zs=e=>{const{type:t,currentTarget:s}=e;Wt[t].forEach((n,o)=>{s===o&&n.forEach((i,r)=>{r.apply(o,[e]),typeof i=="object"&&i.once&&N(o,t,r,i)})})},O=(e,t,s,n)=>{Wt[t]||(Wt[t]=new Map);const o=Wt[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:r}=i;i.set(s,n),r||e.addEventListener(t,Zs,n)},N=(e,t,s,n)=>{const o=Wt[t],i=o&&o.get(e),r=i&&i.get(s),c=r!==void 0?r:n;i&&i.has(s)&&i.delete(s),o&&(!i||!i.size)&&o.delete(e),(!o||!o.size)&&delete Wt[t],(!i||!i.size)&&e.removeEventListener(t,Zs,c)},M="fade",u="show",we="data-bs-dismiss",Ee="alert",Qs="Alert",li="5.1.0";class et{constructor(t,s){let n;try{if(U(t))n=t;else if(Zt(t)){if(n=P(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=St.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&zs(this.defaults).length?Zo(n,this.defaults,s||{},"bs"):{},St.set(n,this.name,this)}get version(){return li}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){St.remove(this.element,this.name),zs(this).forEach(t=>{delete this[t]})}}const di=`.${Ee}`,hi=`[${we}="${Ee}"]`,fi=e=>F(e,Qs),gi=e=>new Ve(e),Js=E(`close.bs.${Ee}`),ui=E(`closed.bs.${Ee}`),tn=e=>{const{element:t}=e;b(t,ui),e._toggleEventListeners(),e.dispose(),t.remove()};class Ve extends et{static selector=di;static init=gi;static getInstance=fi;dismiss;constructor(t){super(t),this.dismiss=P(hi,this.element),this._toggleEventListeners(!0)}get name(){return Qs}close=()=>{const{element:t}=this;t&&f(t,u)&&(b(t,Js),Js.defaultPrevented||(v(t,u),f(t,M)?H(t,()=>tn(this)):tn(this)))};_toggleEventListeners=t=>{const s=t?O:N,{dismiss:n,close:o}=this;n&&s(n,k,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const $="active",ot="data-bs-toggle",pi="button",en="Button",mi=`[${ot}="${pi}"]`,vi=e=>F(e,en),bi=e=>new Ke(e);class Ke extends et{static selector=mi;static init=bi;static getInstance=vi;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,$),I(s,_s,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return en}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!tt(s,"disabled")&&((n?v:h)(s,$),I(s,_s,n?"false":"true"),this.isActive=f(s,$))};_toggleEventListeners=t=>{(t?O:N)(this.element,k,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const qe="data-bs-target",xt="carousel",sn="Carousel",nn="data-bs-parent",wi="data-bs-container",V=e=>{const t=[qe,nn,wi,"href"],s=w(e);return t.map(n=>{const o=tt(e,n);return o?n===nn?L(e,o):P(o,s):null}).filter(n=>n)[0]},te=`[data-bs-ride="${xt}"]`,Z=`${xt}-item`,Xe="data-bs-slide-to",vt="data-bs-slide",bt="paused",on={pause:"hover",keyboard:!1,touch:!0,interval:5e3},lt=e=>F(e,sn),Ei=e=>new Je(e);let ee=0,Te=0,Ye=0;const Ue=E(`slide.bs.${xt}`),Ge=E(`slid.bs.${xt}`),rn=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const r=Qe(e),c=s==="left"?"next":"prev",a=s==="left"?"start":"end";h(o[t],$),v(o[t],`${Z}-${c}`),v(o[t],`${Z}-${a}`),v(o[r],$),v(o[r],`${Z}-${a}`),b(n,Ge),g.clear(n,vt),e.cycle&&!w(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function Ti(){const e=lt(this);e&&!e.isPaused&&!g.get(this,bt)&&h(this,bt)}function $i(){const e=lt(this);e&&e.isPaused&&!g.get(this,bt)&&e.cycle()}function yi(e){e.preventDefault();const t=L(this,te)||V(this),s=lt(t);if(s&&!s.isAnimating){const n=+(tt(this,Xe)||0);this&&!f(this,$)&&!Number.isNaN(n)&&s.to(n)}}function Ci(e){e.preventDefault();const t=L(this,te)||V(this),s=lt(t);if(s&&!s.isAnimating){const n=tt(this,vt);n==="next"?s.next():n==="prev"&&s.prev()}}const Si=({code:e,target:t})=>{const s=w(t),[n]=[...G(te,s)].filter(i=>Gs(i)),o=lt(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=mt(n);e===(i?Rs:Ms)?o.prev():e===(i?Ms:Rs)&&o.next()}};function cn(e){const{target:t}=e,s=lt(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function Hi(e){const{target:t}=e,s=lt(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(ee=e.pageX,this.contains(t)&&(s.isTouch=!0,an(s,!0)))}}const xi=e=>{Te=e.pageX},Pi=e=>{const{target:t}=e,s=w(t),n=[...G(te,s)].map(o=>lt(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,r=mt(o);Ye=e.pageX,n.isTouch=!1,an(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(ee-Ye)>120&&(Teee&&n.to(i+(r?1:-1))),ee=0,Te=0,Ye=0}},Ze=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>v(n,$)),e.indicators[t]&&h(s[t],$)},an=(e,t)=>{const{element:s}=e,n=t?O:N;n(w(s),Wo,xi,Jt),n(w(s),jo,Pi,Jt)},Qe=e=>{const{slides:t,element:s}=e,n=P(`.${Z}.${$}`,s);return C(n)?[...t].indexOf(n):-1};class Je extends et{static selector=te;static init=Ei;static getInstance=lt;constructor(t,s){super(t,s);const{element:n}=this;this.direction=mt(n)?"right":"left",this.isTouch=!1,this.slides=at(Z,n);const{slides:o}=this;if(o.length>=2){const i=Qe(this),r=[...o].find(l=>qs(l,`.${Z}-next,.${Z}-next`));this.index=i;const c=w(n);this.controls=[...G(`[${vt}]`,n),...G(`[${vt}][${qe}="#${n.id}"]`,c)].filter((l,d,p)=>d===p.indexOf(l)),this.indicator=P(`.${xt}-indicators`,n),this.indicators=[...this.indicator?G(`[${Xe}]`,this.indicator):[],...G(`[${Xe}][${qe}="#${n.id}"]`,c)].filter((l,d,p)=>d===p.indexOf(l));const{options:a}=this;this.options.interval=a.interval===!0?on.interval:a.interval,r?this.index=[...o].indexOf(r):i<0&&(this.index=0,h(o[0],$),this.indicators.length&&Ze(this,0)),this.indicators.length&&Ze(this,this.index),this._toggleEventListeners(!0),a.interval&&this.cycle()}}get name(){return sn}get defaults(){return on}get isPaused(){return f(this.element,bt)}get isAnimating(){return P(`.${Z}-next,.${Z}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;g.clear(t,xt),n&&(g.clear(t,bt),v(t,bt)),g.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&Gs(t)&&this.to(o+1)},s.interval,xt)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,bt),g.set(t,()=>{},1,bt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Qe(this),r=mt(s);let c=t;if(!this.isAnimating&&i!==c&&!g.get(s,vt)){ic||i===n.length-1&&c===0)&&(this.direction=r?"left":"right");const{direction:a}=this;c<0?c=n.length-1:c>=n.length&&(c=0);const l=a==="left"?"next":"prev",d=a==="left"?"start":"end",p={relatedTarget:n[c],from:i,to:c,direction:a};it(Ue,p),it(Ge,p),b(s,Ue),Ue.defaultPrevented||(this.index=c,Ze(this,c),Qt(n[c])&&f(s,"slide")?g.set(s,()=>{h(n[c],`${Z}-${l}`),Ht(n[c]),h(n[c],`${Z}-${d}`),h(n[i],`${Z}-${d}`),H(n[c],()=>this.slides&&this.slides.length&&rn(this))},0,vt):(h(n[c],$),v(n[i],$),g.set(s,()=>{g.clear(s,vt),s&&o.interval&&!this.isPaused&&this.cycle(),b(s,Ge)},0,vt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:r}=this,{touch:c,pause:a,interval:l,keyboard:d}=n,p=t?O:N;a&&l&&(p(s,pe,Ti),p(s,Oe,$i)),c&&o.length>2&&(p(s,Fo,Hi,Jt),p(s,Ne,cn,{passive:!1}),p(s,zo,cn,{passive:!1})),i.length&&i.forEach(T=>{T&&p(T,k,Ci)}),r.length&&r.forEach(T=>{p(T,k,yi)}),d&&p(w(s),ue,Si)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&H(s.slides[s.index],()=>{rn(s)})}}const Pt="collapsing",K="collapse",ln="Collapse",Di=`.${K}`,dn=`[${ot}="${K}"]`,Ai={parent:null},$e=e=>F(e,ln),ki=e=>new ts(e),hn=E(`show.bs.${K}`),Ii=E(`shown.bs.${K}`),fn=E(`hide.bs.${K}`),Li=E(`hidden.bs.${K}`),_i=e=>{const{element:t,parent:s,triggers:n}=e;b(t,hn),hn.defaultPrevented||(g.set(t,me,17),s&&g.set(s,me,17),h(t,Pt),v(t,K),x(t,{height:`${t.scrollHeight}px`}),H(t,()=>{g.clear(t),s&&g.clear(s),n.forEach(o=>I(o,fe,"true")),v(t,Pt),h(t,K),h(t,u),x(t,{height:""}),b(t,Ii)}))},gn=e=>{const{element:t,parent:s,triggers:n}=e;b(t,fn),fn.defaultPrevented||(g.set(t,me,17),s&&g.set(s,me,17),x(t,{height:`${t.scrollHeight}px`}),v(t,K),v(t,u),h(t,Pt),Ht(t),x(t,{height:"0px"}),H(t,()=>{g.clear(t),s&&g.clear(s),n.forEach(o=>I(o,fe,"false")),v(t,Pt),h(t,K),x(t,{height:""}),b(t,Li)}))},Oi=e=>{const{target:t}=e,s=t&&L(t,dn),n=s&&V(s),o=n&&$e(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class ts extends et{static selector=Di;static init=ki;static getInstance=$e;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=w(n);this.triggers=[...G(dn,i)].filter(r=>V(r)===n),this.parent=C(o.parent)?o.parent:Zt(o.parent)?V(n)||P(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return ln}get defaults(){return Ai}hide(){const{triggers:t,element:s}=this;g.get(s)||(gn(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...G(`.${K}.${u}`,s)].find(r=>$e(r)),i=o&&$e(o)),(!s||!g.get(s))&&!g.get(t)&&(i&&o!==t&&(gn(i),i.triggers.forEach(r=>{h(r,`${K}d`)})),_i(this),n.length&&n.forEach(r=>v(r,`${K}d`)))}toggle(){f(this.element,u)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?O:N,{triggers:n}=this;n.length&&n.forEach(o=>s(o,k,Oi))};dispose(){this._toggleEventListeners(),super.dispose()}}const Dt=["dropdown","dropup","dropstart","dropend"],un="Dropdown",pn="dropdown-menu",mn=e=>{const t=L(e,"A");return e.tagName==="A"&&Ut(e,"href")&&tt(e,"href").slice(-1)==="#"||t&&Ut(t,"href")&&tt(t,"href").slice(-1)==="#"},[st,es,ss,ns]=Dt,vn=`[${ot}="${st}"]`,jt=e=>F(e,un),Ni=e=>new rs(e),Mi=`${pn}-end`,bn=[st,es],wn=[ss,ns],En=["A","BUTTON"],Ri={offset:5,display:"dynamic"},os=E(`show.bs.${st}`),Tn=E(`shown.bs.${st}`),is=E(`hide.bs.${st}`),$n=E(`hidden.bs.${st}`),yn=E(`updated.bs.${st}`),Cn=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(W(s,"position")!=="static"){const r=mt(t),c=f(s,Mi);["margin","top","bottom","left","right"].forEach(z=>{const Ot={};Ot[z]="",x(s,Ot)});let l=Dt.find(z=>f(n,z))||st;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:r?[-1,0,0,i]:[-1,i,0],dropend:r?[-1,i,0]:[-1,0,0,i]},p={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:r?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:r?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:r?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:r?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:T,offsetHeight:_}=s,{clientWidth:q,clientHeight:j}=ct(t),{left:m,top:B,width:Lt,height:_t}=ut(t),S=m-T-i<0,Tt=m+T+Lt+i>=q,ht=B+_+i>=j,nt=B+_+_t+i>=j,Vt=B-_-i<0,y=(!r&&c||r&&!c)&&m+Lt-T<0,X=(r&&c||!r&&!c)&&m+T>=q;if(wn.includes(l)&&S&&Tt&&(l=st),l===ss&&(r?Tt:S)&&(l=ns),l===ns&&(r?S:Tt)&&(l=ss),l===es&&Vt&&!nt&&(l=st),l===st&&nt&&!Vt&&(l=es),wn.includes(l)&&ht&&it(p[l],{top:"auto",bottom:0}),bn.includes(l)&&(y||X)){let z={left:"auto",right:"auto"};!y&&X&&!r&&(z={left:"auto",right:0}),y&&!X&&r&&(z={left:0,right:"auto"}),z&&it(p[l],z)}const Kt=d[l];x(s,{...p[l],margin:`${Kt.map(z=>z&&`${z}px`).join(" ")}`}),bn.includes(l)&&c&&c&&x(s,p[!r&&y||r&&X?"menuStart":"menuEnd"]),b(n,yn)}},Bi=e=>Array.from(e.children).map(t=>{if(t&&En.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&En.includes(s.tagName)?s:null}).filter(t=>t),Sn=e=>{const{element:t,options:s,menu:n}=e,o=e.open?O:N,i=w(t);o(i,k,Hn),o(i,Le,Hn),o(i,ue,Wi),o(i,Ro,ji),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},ye=e=>{const t=[...Dt,"btn-group","input-group"].map(s=>at(`${s} ${u}`,w(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>Dt.some(n=>n===tt(s,ot)))},Hn=e=>{const{target:t,type:s}=e;if(!C(t))return;const n=ye(t),o=n&&jt(n);if(!o)return;const{parentElement:i,menu:r}=o,c=i&&i.contains(t)&&(t.tagName==="form"||L(t,"form")!==null);[k,Ns].includes(s)&&mn(t)&&e.preventDefault(),!c&&s!==Le&&t!==n&&t!==r&&o.hide()},Fi=e=>{const{target:t}=e,s=t&&L(t,vn),n=s&&jt(s);n&&(e.stopPropagation(),n.toggle(),s&&mn(s)&&e.preventDefault())},Wi=e=>{[Me,Re].includes(e.code)&&e.preventDefault()};function ji(e){const{code:t}=e,s=ye(this);if(!s)return;const n=jt(s),{activeElement:o}=w(s);if(!n||!o)return;const{menu:i,open:r}=n,c=Bi(i);if(c&&c.length&&[Me,Re].includes(t)){let a=c.indexOf(o);o===s?a=0:t===Re?a=a>1?a-1:0:t===Me&&(a=azi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return un}get defaults(){return Ri}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(s)return;const i=ye(t),r=i&&jt(i);r&&r.hide(),[os,Tn,yn].forEach(c=>{c.relatedTarget=t}),b(o,os),!os.defaultPrevented&&(h(n,u),h(o,u),I(t,fe,"true"),Cn(this),this.open=!s,rt(t),Sn(this),b(o,Tn))}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([is,$n].forEach(i=>{i.relatedTarget=t}),b(o,is),!is.defaultPrevented&&(v(n,u),v(o,u),I(t,fe,"false"),this.open=!s,Sn(this),b(o,$n)))}_toggleEventListeners=t=>{(t?O:N)(this.element,k,Fi)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const Y="modal",cs="Modal",as="Offcanvas",Vi="fixed-top",Ki="fixed-bottom",xn="sticky-top",Pn="position-sticky",Dn=e=>[...at(Vi,e),...at(Ki,e),...at(xn,e),...at(Pn,e),...at("is-fixed",e)],qi=e=>{const t=pt(e);x(t,{paddingRight:"",overflow:""});const s=Dn(t);s.length&&s.forEach(n=>{x(n,{paddingRight:"",marginRight:""})})},An=e=>{const{clientWidth:t}=ct(e),{innerWidth:s}=Ks(e);return Math.abs(s-t)},kn=(e,t)=>{const s=pt(e),n=parseInt(W(s,"paddingRight"),10),i=W(s,"overflow")==="hidden"&&n?0:An(e),r=Dn(s);t&&(x(s,{overflow:"hidden",paddingRight:`${n+i}px`}),r.length&&r.forEach(c=>{const a=W(c,"paddingRight");if(c.style.paddingRight=`${parseInt(a,10)+i}px`,[xn,Pn].some(l=>f(c,l))){const l=W(c,"marginRight");c.style.marginRight=`${parseInt(l,10)-i}px`}}))},Q="offcanvas",wt=ft({tagName:"div",className:"popup-container"}),In=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt,o=s?t:pt(e);D(e)&&(n===wt&&o.append(wt),n.append(e))},Ln=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt;D(e)&&(e.remove(),n===wt&&!wt.children.length&&wt.remove())},ls=(e,t)=>{const s=D(t)&&t.nodeName!=="BODY"?t:wt;return D(e)&&s.contains(e)},_n="backdrop",On=`${Y}-${_n}`,Nn=`${Q}-${_n}`,Mn=`.${Y}.${u}`,ds=`.${Q}.${u}`,A=ft("div"),At=e=>P(`${Mn},${ds}`,w(e)),hs=e=>{const t=e?On:Nn;[On,Nn].forEach(s=>{v(A,s)}),h(A,t)},Rn=(e,t,s)=>{hs(s),In(A,pt(e)),t&&h(A,M)},Bn=()=>{f(A,u)||(h(A,u),Ht(A))},Ce=()=>{v(A,u)},Fn=e=>{At(e)||(v(A,M),Ln(A,pt(e)),qi(e))},Wn=e=>C(e)&&W(e,"visibility")!=="hidden"&&e.offsetParent!==null,Xi=`.${Y}`,jn=`[${ot}="${Y}"]`,Yi=`[${we}="${Y}"]`,zn=`${Y}-static`,Ui={backdrop:!0,keyboard:!0},se=e=>F(e,cs),Gi=e=>new gs(e),Se=E(`show.bs.${Y}`),Vn=E(`shown.bs.${Y}`),fs=E(`hide.bs.${Y}`),Kn=E(`hidden.bs.${Y}`),qn=e=>{const{element:t}=e,s=An(t),{clientHeight:n,scrollHeight:o}=ct(t),{clientHeight:i,scrollHeight:r}=t,c=i!==r;if(!c&&s){const l={[mt(t)?"paddingLeft":"paddingRight"]:`${s}px`};x(t,l)}kn(t,c||n!==o)},Xn=(e,t)=>{const s=t?O:N,{element:n}=e;s(n,k,Ji),s(w(n),ue,Qi),t?e._observer.observe(n):e._observer.disconnect()},Yn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;Fn(s),x(s,{paddingRight:"",display:""}),Xn(e);const o=Se.relatedTarget||t.find(Wn);o&&rt(o),Kn.relatedTarget=n||void 0,b(s,Kn),be(s)},Un=e=>{const{element:t,relatedTarget:s}=e;rt(t),Xn(e,!0),Vn.relatedTarget=s||void 0,b(t,Vn),be(t)},Gn=e=>{const{element:t,hasFade:s}=e;x(t,{display:"block"}),qn(e),At(t)||x(pt(t),{overflow:"hidden"}),h(t,u),Ct(t,Yt),I(t,ge,"true"),s?H(t,()=>Un(e)):Un(e)},Zn=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(A,u)&&!At(t)?(Ce(),H(A,()=>Yn(e))):Yn(e)},Zi=e=>{const{target:t}=e,s=t&&L(t,jn),n=s&&V(s),o=n&&se(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Qi=({code:e,target:t})=>{const s=P(Mn,w(t)),n=s&&se(s);if(!n)return;const{options:o}=n;o.keyboard&&e===Be&&f(s,u)&&(n.relatedTarget=null,n.hide())},Ji=e=>{const{currentTarget:t}=e,s=t&&se(t);if(!s||!t||g.get(t))return;const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:r}=n,{target:c}=e,a=w(t)?.getSelection()?.toString().length,l=i.contains(c),d=c&&L(c,Yi);o&&!l?g.set(t,()=>{h(t,zn),H(i,()=>tr(s))},17):(d||!a&&!o&&!l&&r)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())},tr=e=>{const{element:t,modalDialog:s}=e,n=(Qt(s)||0)+17;v(t,zn),g.set(t,()=>g.clear(t),n)};class gs extends et{static selector=Xi;static init=Gi;static getInstance=se;constructor(t,s){super(t,s);const{element:n}=this,o=P(`.${Y}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...G(jn,w(n))].filter(i=>V(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,M),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return cs}get defaults(){return Ui}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let r=0;if(f(t,u)||(Se.relatedTarget=o||void 0,b(t,Se),Se.defaultPrevented))return;const c=At(t);if(c&&c!==t){const a=se(c)||F(c,as);a&&a.hide()}i?(ls(A)?hs(!0):Rn(t,n,!0),r=Qt(A),Bn(),setTimeout(()=>Gn(this),r)):(Gn(this),c&&f(A,u)&&Ce())}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,u)&&(fs.relatedTarget=n||void 0,b(t,fs),!fs.defaultPrevented&&(v(t,u),I(t,Yt,"true"),Ct(t,ge),s?H(t,()=>Zn(this)):Zn(this)))}update=()=>{f(this.element,u)&&qn(this)};_toggleEventListeners=t=>{const s=t?O:N,{triggers:n}=this;n.length&&n.forEach(o=>s(o,k,Zi))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?H(s,o):o()}}const er=`.${Q}`,us=`[${ot}="${Q}"]`,sr=`[${we}="${Q}"]`,He=`${Q}-toggling`,nr={backdrop:!0,keyboard:!0,scroll:!1},ne=e=>F(e,as),or=e=>new ms(e),xe=E(`show.bs.${Q}`),Qn=E(`shown.bs.${Q}`),ps=E(`hide.bs.${Q}`),Jn=E(`hidden.bs.${Q}`),ir=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=ct(t);kn(t,s!==n)},to=(e,t)=>{const s=t?O:N,n=w(e.element);s(n,ue,lr),s(n,k,ar)},eo=e=>{const{element:t,options:s}=e;s.scroll||(ir(e),x(pt(t),{overflow:"hidden"})),h(t,He),h(t,u),x(t,{visibility:"visible"}),H(t,()=>dr(e))},rr=e=>{const{element:t,options:s}=e,n=At(t);t.blur(),!n&&s.backdrop&&f(A,u)&&Ce(),H(t,()=>hr(e))},cr=e=>{const t=L(e.target,us),s=t&&V(t),n=s&&ne(s);n&&(n.relatedTarget=t,n.toggle(),t?.tagName==="A"&&e.preventDefault())},ar=e=>{const{target:t}=e,s=P(ds,w(t));if(!s)return;const n=P(sr,s),o=ne(s);if(!o)return;const{options:i,triggers:r}=o,{backdrop:c}=i,a=L(t,us),l=w(s).getSelection();A.contains(t)&&c==="static"||(!(l&&l.toString().length)&&(!s.contains(t)&&c&&(!a||r.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:void 0,o.hide()),a&&a.tagName==="A"&&e.preventDefault())},lr=({code:e,target:t})=>{const s=P(ds,w(t)),n=s&&ne(s);n&&n.options.keyboard&&e===Be&&(n.relatedTarget=void 0,n.hide())},dr=e=>{const{element:t}=e;v(t,He),Ct(t,Yt),I(t,ge,"true"),I(t,"role","dialog"),b(t,Qn),to(e,!0),rt(t),be(t)},hr=e=>{const{element:t,triggers:s}=e;I(t,Yt,"true"),Ct(t,ge),Ct(t,"role"),x(t,{visibility:""});const n=xe.relatedTarget||s.find(Wn);n&&rt(n),Fn(t),b(t,Jn),v(t,He),be(t),At(t)||to(e)};class ms extends et{static selector=er;static init=or;static getInstance=ne;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...G(us,w(n))].filter(o=>V(o)===n),this.relatedTarget=void 0,this._toggleEventListeners(!0)}get name(){return as}get defaults(){return nr}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(f(t,u)||(xe.relatedTarget=n||void 0,Qn.relatedTarget=n||void 0,b(t,xe),xe.defaultPrevented))return;const i=At(t);if(i&&i!==t){const r=ne(i)||F(i,cs);r&&r.hide()}s.backdrop?(ls(A)?hs():Rn(t,!0),o=Qt(A),Bn(),setTimeout(()=>eo(this),o)):(eo(this),i&&f(A,u)&&Ce())}hide(){const{element:t,relatedTarget:s}=this;f(t,u)&&(ps.relatedTarget=s||void 0,Jn.relatedTarget=s||void 0,b(t,ps),!ps.defaultPrevented&&(h(t,He),v(t,u),rr(this)))}_toggleEventListeners=t=>{const s=t?O:N;this.triggers.forEach(n=>s(n,k,cr))};dispose(){const{element:t}=this,s=f(t,u),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?H(t,n):n()}}const kt="popover",vs="Popover",dt="tooltip",so=e=>{const t=e===dt,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},no={top:"top",bottom:"bottom",left:"start",right:"end"},bs=e=>{requestAnimationFrame(()=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,offsetParent:i,options:r,arrow:c}=e;if(!n)return;const a=mt(s),{x:l,y:d}=ei(i);x(n,{top:"",left:"",right:"",bottom:""});const{offsetWidth:p,offsetHeight:T}=n,{clientWidth:_,clientHeight:q,offsetWidth:j}=ct(s);let{placement:m}=r;const{clientWidth:B,offsetWidth:Lt}=o,S=W(o,"position")==="fixed",Tt=Math.abs(S?B-Lt:_-j),ht=a&&S?Tt:0,nt=_-(a?0:Tt)-1,Vt=e._observer.getEntry(s),{width:y,height:X,left:Kt,right:z,top:Ot}=Vt?.boundingClientRect||ut(s,!0),{x:De,y:qt}=ii(s,i,{x:l,y:d});x(c,{top:"",left:"",right:"",bottom:""});let Nt=0,ce="",$t=0,Ds="",Xt="",Ae="",As="";const Mt=c.offsetWidth||0,yt=c.offsetHeight||0,ks=Mt/2;let ae=Ot-T-yt<0,le=Ot+T+X+yt>=q,de=Kt-p-Mt=nt;const ke=["left","right"],Is=["top","bottom"];ae=ke.includes(m)?Ot+X/2-T/2-yt<0:ae,le=ke.includes(m)?Ot+T/2+X/2+yt>=q:le,de=Is.includes(m)?Kt+y/2-p/2=nt:he,m=ke.includes(m)&&de&&he?"top":m,m=m==="top"&&ae?"bottom":m,m=m==="bottom"&&le?"top":m,m=m==="left"&&de?"right":m,m=m==="right"&&he?"left":m,n.className.includes(m)||(n.className=n.className.replace(t,no[m])),ke.includes(m)?(m==="left"?$t=De-p-Mt:$t=De+y+Mt,ae&&le?(Nt=0,ce=0,Xt=qt+X/2-yt/2):ae?(Nt=qt,ce="",Xt=X/2-Mt):le?(Nt=qt-T+X,ce="",Xt=T-X/2-Mt):(Nt=qt-T/2+X/2,Xt=T/2-yt/2)):Is.includes(m)&&(m==="top"?Nt=qt-T-yt:Nt=qt+X+yt,de?($t=0,Ae=De+y/2-ks):he?($t="auto",Ds=0,As=y/2+nt-z-ks):($t=De-p/2+y/2,Ae=p/2-ks)),x(n,{top:`${Nt}px`,bottom:ce===""?"":`${ce}px`,left:$t==="auto"?$t:`${$t}px`,right:Ds!==""?`${Ds}px`:""}),C(c)&&(Xt!==""&&(c.style.top=`${Xt}px`),Ae!==""?c.style.left=`${Ae}px`:As!==""&&(c.style.right=`${As}px`));const Ur=E(`updated.bs.${Bt(e.name)}`);b(s,Ur)})},ws={template:so(dt),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},fr=e=>e!=null&&typeof e=="object"||!1,gr=e=>fr(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,oo=e=>gr(e)&&e.nodeType===1||!1,ur=e=>typeof e=="function"||!1,pr="1.0.2",io="PositionObserver Error";class ro{entries;static version=pr;_tick;_root;_callback;constructor(t,s){if(!ur(t))throw new Error(`${io}: ${t} is not a function.`);this.entries=new Map,this._callback=t,this._root=oo(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!oo(t))throw new Error(`${io}: ${t} is not an instance of Element.`);this._root.contains(t)&&this._new(t).then(s=>{this.getEntry(t)||this.entries.set(t,s),this._tick||(this._tick=requestAnimationFrame(this._runCallback))})};unobserve=t=>{this.entries.has(t)&&this.entries.delete(t)};_runCallback=()=>{if(!this.entries.size)return;const t=new Promise(s=>{const n=[];this.entries.forEach(({target:o,boundingClientRect:i})=>{this._root.contains(o)&&this._new(o).then(({boundingClientRect:r,isVisible:c})=>{const{left:a,top:l,bottom:d,right:p}=r;if(i.top!==l||i.left!==a||i.right!==p||i.bottom!==d){const T={target:o,boundingClientRect:r,isVisible:c};this.entries.set(o,T),n.push(T)}})}),s(n)});this._tick=requestAnimationFrame(async()=>{const s=await t;s.length&&this._callback(s,this),this._runCallback()})};_new=t=>{const{clientWidth:s,clientHeight:n}=this._root;return new Promise(o=>{new IntersectionObserver(([{boundingClientRect:i}],r)=>{r.disconnect();const{left:c,top:a,bottom:l,right:d,width:p,height:T}=i,_=a>1-T&&c>1-p&&l<=n+T-1&&d<=s+p-1;o({target:t,isVisible:_,boundingClientRect:i})}).observe(t)})};getEntry=t=>this.entries.get(t);disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.clear(),this._tick=0}}const co="data-original-title",It="Tooltip",Et=(e,t,s)=>{if(Zt(t)&&t.length){let n=t.trim();ci(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else C(t)?e.append(t):(ai(t)||ri(t)&&t.every(D))&&e.append(...t)},mr=e=>{const t=e.name===It,{id:s,element:n,options:o}=e,{title:i,placement:r,template:c,animation:a,customClass:l,sanitizeFn:d,dismissible:p,content:T,btnClose:_}=o,q=t?dt:kt,j={...no};let m=[],B=[];mt(n)&&(j.left="end",j.right="start");const Lt=`bs-${q}-${j[r]}`;let _t;if(C(c))_t=c;else{const y=ft("div");Et(y,c,d),_t=y.firstChild}if(!C(_t))return;e.tooltip=_t.cloneNode(!0);const{tooltip:S}=e;I(S,"id",s),I(S,"role",dt);const Tt=t?`${dt}-inner`:`${kt}-body`,ht=t?null:P(`.${kt}-header`,S),nt=P(`.${Tt}`,S);e.arrow=P(`.${q}-arrow`,S);const{arrow:Vt}=e;if(C(i))m=[i.cloneNode(!0)];else{const y=ft("div");Et(y,i,d),m=[...y.childNodes]}if(C(T))B=[T.cloneNode(!0)];else{const y=ft("div");Et(y,T,d),B=[...y.childNodes]}if(p)if(i)if(C(_))m=[...m,_.cloneNode(!0)];else{const y=ft("div");Et(y,_,d),m=[...m,y.firstChild]}else if(ht&&ht.remove(),C(_))B=[...B,_.cloneNode(!0)];else{const y=ft("div");Et(y,_,d),B=[...B,y.firstChild]}t?i&&nt&&Et(nt,i,d):(i&&ht&&Et(ht,m,d),T&&nt&&Et(nt,B,d),e.btn=P(".btn-close",S)||void 0),h(S,"position-absolute"),h(Vt,"position-absolute"),f(S,q)||h(S,q),a&&!f(S,M)&&h(S,M),l&&!f(S,l)&&h(S,l),f(S,Lt)||h(S,Lt)},vr=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=si(n),Vs(n)||ni(n)||s.push(n);return s.find((o,i)=>(W(o,"position")!=="relative"||W(o,"position")==="relative"&&o.offsetHeight!==o.scrollHeight)&&s.slice(i+1).every(r=>W(r,"position")==="static")?o:null)||w(e).body},br=`[${ot}="${dt}"],[data-tip="${dt}"]`,ao="title";let lo=e=>F(e,It);const wr=e=>new Pe(e),Er=e=>{const{element:t,tooltip:s,container:n}=e;Ct(t,Ls),Ln(s,n)},oe=e=>{const{tooltip:t,container:s}=e;return t&&ls(t,s)},Tr=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),Ut(s,co)&&e.name===It&&po(e),t&&t()},ho=(e,t)=>{const s=t?O:N,{element:n}=e;s(w(n),Ne,e.handleTouch,Jt)},fo=e=>{const{element:t}=e,s=E(`shown.bs.${Bt(e.name)}`);ho(e,!0),b(t,s),g.clear(t,"in")},go=e=>{const{element:t}=e,s=E(`hidden.bs.${Bt(e.name)}`);ho(e),Er(e),b(t,s),g.clear(t,"out")},uo=(e,t)=>{const s=t?O:N,{element:n,tooltip:o}=e,i=L(n,`.${Y}`),r=L(n,`.${Q}`);t?[n,o].forEach(c=>e._observer.observe(c)):e._observer.disconnect(),i&&s(i,`hide.bs.${Y}`,e.handleHide),r&&s(r,`hide.bs.${Q}`,e.handleHide)},po=(e,t)=>{const s=[co,ao],{element:n}=e;I(n,s[t?0:1],t||tt(n,s[0])||""),Ct(n,s[t?1:0])};class Pe extends et{static selector=br;static init=wr;static getInstance=lo;static styleTip=bs;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===It,i=o?dt:kt,r=o?It:vs;lo=d=>F(d,r),this.enabled=!0,this.id=`${i}-${Us(n,i)}`;const{options:c}=this;if(!c.title&&o||!o&&!c.content)return;it(ws,{titleAttr:""}),Ut(n,ao)&&o&&typeof c.title=="string"&&po(this,c.title);const a=vr(n),l=["sticky","fixed","relative"].some(d=>W(a,"position")===d)?a:Ks(n);this.container=a,this.offsetParent=l,mr(this),this.tooltip&&(this._observer=new ro(d=>{d.some(p=>p.isVisible)&&this.update()}),this._toggleEventListeners(!0))}get name(){return It}get defaults(){return ws}handleFocus=()=>rt(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,id:i}=this,{animation:r}=t,c=g.get(n,"out");g.clear(n,"out"),s&&!c&&!oe(this)&&g.set(n,()=>{const a=E(`show.bs.${Bt(this.name)}`);b(n,a),a.defaultPrevented||(In(s,o),I(n,Ls,`#${i}`),this.update(),uo(this,!0),f(s,u)||h(s,u),r?H(s,()=>fo(this)):fo(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;g.clear(n,"in"),s&&oe(this)&&g.set(n,()=>{const r=E(`hide.bs.${Bt(this.name)}`);b(n,r),r.defaultPrevented||(this.update(),v(s,u),uo(this),o?H(s,()=>go(this)):go(this))},i+17,"out")}update=()=>{bs(this)};toggle=()=>{const{tooltip:t}=this;t&&!oe(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&oe(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?O:N,{element:n,options:o,btn:i}=this,{trigger:r}=o,a=!!(this.name!==It&&o.dismissible);r.includes("manual")||(this.enabled=!!t,r.split(" ").forEach(d=>{d===Bo?(s(n,Ns,this.handleShow),s(n,pe,this.handleShow),a||(s(n,Oe,this.handleHide),s(w(n),Ne,this.handleTouch,Jt))):d===k?s(n,d,a?this.handleShow:this.toggle):d===Le&&(s(n,_e,this.handleShow),a||s(n,Os,this.handleHide),Xo()&&s(n,k,this.handleFocus)),a&&i&&s(i,k,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>Tr(n,()=>super.dispose()),17);s.animation&&oe(n)?(this.options.delay=0,this.hide(),H(t,o)):o()}}const $r=`[${ot}="${kt}"],[data-tip="${kt}"]`,yr=it({},ws,{template:so(kt),content:"",dismissible:!1,btnClose:''}),Cr=e=>F(e,vs),Sr=e=>new Es(e);class Es extends Pe{static selector=$r;static init=Sr;static getInstance=Cr;static styleTip=bs;constructor(t,s){super(t,s)}get name(){return vs}get defaults(){return yr}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>rt(s),17)}}const Hr="scrollspy",mo="ScrollSpy",xr='[data-bs-spy="scroll"]',Pr={offset:10,target:void 0},Dr=e=>F(e,mo),Ar=e=>new Ts(e),vo=E(`activate.bs.${Hr}`),kr=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:r,_observer:c}=e,{offset:a}=n,l=s!==r,d=t&&ze("A",t),p=w(r),T=s.scrollHeight;if(e.scrollTop=s.scrollTop,d&&(T!==i||o!==d.length)){let _,q,j,m;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=T,e.maxScroll=e.scrollHeight-Lr(e),Array.from(d).forEach(B=>{_=tt(B,"href"),q=_?.slice(1),j=q?.length?p.getElementById(q):null,j&&(e.items.push(B),e.targets.push(j),m=c?.getEntry(j)?.boundingClientRect||ut(j),e.offsets.push((l?m.top+e.scrollTop:j.offsetTop)-a))}),e.itemsLength=e.items.length}},bo=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e?.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},Ir=e=>e.scrollHeight,Lr=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:ut(e).height,wo=e=>{Array.from(ze("A",e)).forEach(t=>{f(t,$)&&v(t,$)})},Eo=(e,t)=>{const{target:s,element:n}=e;C(s)&&wo(s),e.activeItem=t,h(t,$);const o=[];let i=t;for(;i!==pt(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(r=>{const c=r.previousElementSibling;c&&!f(c,$)&&h(c,$)}),vo.relatedTarget=t,b(n,vo)};class Ts extends et{static selector=xr;static init=Ar;static getInstance=Dr;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=P(o.target,w(n));i&&(this.target=i,this.scrollTarget=n.clientHeight{requestAnimationFrame(()=>{r.some(c=>c.isVisible)&&this.refresh()})},{root:this.scrollTarget}),bo(this,!0))}get name(){return mo}get defaults(){return Pr}refresh=()=>{const{target:t}=this;if(!C(t)||t.offsetHeight===0)return;kr(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:r}=this;if(s>=n){const a=i[o-1];r!==a&&Eo(this,a);return}const{offsets:c}=this;if(r&&s0){this.activeItem=null,t&&wo(t);return}i.forEach((a,l)=>{r!==a&&s>=c[l]&&(typeof c[l+1]>"u"||sF(e,To),_r=e=>new Cs(e),$s=E(`show.bs.${ie}`),Co=E(`shown.bs.${ie}`),ys=E(`hide.bs.${ie}`),So=E(`hidden.bs.${ie}`),re=new Map,Ho=e=>{const{tabContent:t,nav:s}=e;t&&f(t,Pt)&&(t.style.height="",v(t,Pt)),s&&g.clear(s)},xo=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=C(o)&&re.get(o)||{tab:null};if(s&&n&&f(n,M)){const{currentHeight:r,nextHeight:c}=re.get(t)||{currentHeight:0,nextHeight:0};r!==c?setTimeout(()=>{s.style.height=`${c}px`,Ht(s),H(s,()=>Ho(e))},50):Ho(e)}else o&&g.clear(o);Co.relatedTarget=i,b(t,Co)},Po=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:r}=o&&re.get(o)||{tab:null,content:null};let c=0;if(n&&s&&f(s,M)&&([r,s].forEach(a=>{a&&h(a,"overflow-hidden")}),c=r?r.scrollHeight:0),$s.relatedTarget=i,So.relatedTarget=t,b(t,$s),!$s.defaultPrevented){if(s&&h(s,$),r&&v(r,$),n&&s&&f(s,M)){const a=s.scrollHeight;re.set(t,{currentHeight:c,nextHeight:a,tab:null,content:null}),h(n,Pt),n.style.height=`${c}px`,Ht(n),[r,s].forEach(l=>{l&&v(l,"overflow-hidden")})}s&&s&&f(s,M)?setTimeout(()=>{h(s,u),H(s,()=>{xo(e)})},1):(s&&h(s,u),xo(e)),i&&b(i,So)}},Do=e=>{const{nav:t}=e;if(!C(t))return{tab:null,content:null};const s=at($,t);let n=null;s.length===1&&!Dt.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=C(n)?V(n):null;return{tab:n,content:o}},Ao=e=>{if(!C(e))return null;const t=L(e,`.${Dt.join(",.")}`);return t?P(`.${Dt[0]}-toggle`,t):null},Or=e=>{const t=yo(e.target);e.preventDefault(),t&&t.show()};class Cs extends et{static selector=$o;static init=_r;static getInstance=yo;constructor(t){super(t);const{element:s}=this,n=V(s);if(!n)return;const o=L(s,".nav"),i=L(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=Ao(s);const{tab:r}=Do(this);if(o&&!r){const c=P($o,o),a=c&&V(c);a&&(h(c,$),h(a,u),h(a,$),I(s,Ie,"true"))}this._toggleEventListeners(!0)}get name(){return To}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(n&&g.get(n)||f(t,$))return;const{tab:i,content:r}=Do(this);if(n&&i&&re.set(n,{tab:i,content:r,currentHeight:0,nextHeight:0}),ys.relatedTarget=t,!C(i)||(b(i,ys),ys.defaultPrevented))return;h(t,$),I(t,Ie,"true");const c=C(i)&&Ao(i);if(c&&f(c,$)&&v(c,$),n){const a=()=>{i&&(v(i,$),I(i,Ie,"false")),o&&!f(o,$)&&h(o,$)};r&&(f(r,M)||s&&f(s,M))?g.set(n,a,1):a()}r&&(v(r,u),f(r,M)?H(r,()=>Po(this)):Po(this))}_toggleEventListeners=t=>{(t?O:N)(this.element,k,Or)};dispose(){this._toggleEventListeners(),super.dispose()}}const J="toast",ko="Toast",Nr=`.${J}`,Mr=`[${we}="${J}"]`,Io=`[${ot}="${J}"]`,zt="showing",Lo="hide",Rr={animation:!0,autohide:!0,delay:5e3},Ss=e=>F(e,ko),Br=e=>new Hs(e),_o=E(`show.bs.${J}`),Fr=E(`shown.bs.${J}`),Oo=E(`hide.bs.${J}`),Wr=E(`hidden.bs.${J}`),No=e=>{const{element:t,options:s}=e;v(t,zt),g.clear(t,zt),b(t,Fr),s.autohide&&g.set(t,()=>e.hide(),s.delay,J)},Mo=e=>{const{element:t}=e;v(t,zt),v(t,u),h(t,Lo),g.clear(t,J),b(t,Wr)},jr=e=>{const{element:t,options:s}=e;h(t,zt),s.animation?(Ht(t),H(t,()=>Mo(e))):Mo(e)},zr=e=>{const{element:t,options:s}=e;g.set(t,()=>{v(t,Lo),Ht(t),h(t,u),h(t,zt),s.animation?H(t,()=>No(e)):No(e)},17,zt)},Vr=e=>{const{target:t}=e,s=t&&L(t,Io),n=s&&V(s),o=n&&Ss(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},Kr=e=>{const t=e.target,s=Ss(t),{type:n,relatedTarget:o}=e;!s||t===o||t.contains(o)||([pe,_e].includes(n)?g.clear(t,J):g.set(t,()=>s.hide(),s.options.delay,J))};class Hs extends et{static selector=Nr;static init=Br;static getInstance=Ss;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,M)?h(n,M):!o.animation&&f(n,M)&&v(n,M),this.dismiss=P(Mr,n),this.triggers=[...G(Io,w(n))].filter(i=>V(i)===n),this._toggleEventListeners(!0)}get name(){return ko}get defaults(){return Rr}get isShown(){return f(this.element,u)}show=()=>{const{element:t,isShown:s}=this;!t||s||(b(t,_o),_o.defaultPrevented||zr(this))};hide=()=>{const{element:t,isShown:s}=this;!t||!s||(b(t,Oo),Oo.defaultPrevented||jr(this))};_toggleEventListeners=t=>{const s=t?O:N,{element:n,triggers:o,dismiss:i,options:r,hide:c}=this;i&&s(i,k,c),r.autohide&&[_e,Os,pe,Oe].forEach(a=>s(n,a,Kr)),o.length&&o.forEach(a=>s(a,k,Vr))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),g.clear(t,J),s&&v(t,u),super.dispose()}}const xs=new Map;[Ve,Ke,Je,ts,rs,gs,ms,Es,Ts,Cs,Hs,Pe].forEach(e=>xs.set(e.prototype.name,e));const qr=(e,t)=>{[...t].forEach(s=>e(s))},Xr=(e,t)=>{const s=St.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},Ps=e=>{const t=e&&e.nodeName?e:document,s=[...ze("*",t)];xs.forEach(n=>{const{init:o,selector:i}=n;qr(o,s.filter(r=>qs(r,i)))})},Yr=e=>{const t=e&&e.nodeName?e:document;xs.forEach(s=>{Xr(s.prototype.name,t)})};return document.body?Ps():O(document,"DOMContentLoaded",()=>Ps(),{once:!0}),R.Alert=Ve,R.Button=Ke,R.Carousel=Je,R.Collapse=ts,R.Dropdown=rs,R.Modal=gs,R.Offcanvas=ms,R.Popover=Es,R.ScrollSpy=Ts,R.Tab=Cs,R.Toast=Hs,R.Tooltip=Pe,R.initCallback=Ps,R.removeDataAPI=Yr,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"}),R}({}); //# sourceMappingURL=bootstrap-native.js.map diff --git a/dist/bootstrap-native.js.map b/dist/bootstrap-native.js.map index b49fc64f..dc1de01b 100644 --- a/dist/bootstrap-native.js.map +++ b/dist/bootstrap-native.js.map @@ -1 +1 @@ -{"version":3,"file":"bootstrap-native.js","sources":["../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.6/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@0.0.3/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const e = {}, f = (t) => {\n const { type: c, currentTarget: i } = t;\n [...e[c]].forEach(([n, s]) => {\n /* istanbul ignore else @preserve */\n i === n && [...s].forEach(([o, a]) => {\n o.apply(n, [t]), typeof a == \"object\" && a.once && r(n, c, o, a);\n });\n });\n}, E = (t, c, i, n) => {\n /* istanbul ignore else @preserve */\n e[c] || (e[c] = /* @__PURE__ */ new Map());\n const s = e[c];\n /* istanbul ignore else @preserve */\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(t), { size: a } = o;\n o.set(i, n);\n /* istanbul ignore else @preserve */\n a || t.addEventListener(c, f, n);\n}, r = (t, c, i, n) => {\n const s = e[c], o = s && s.get(t), a = o && o.get(i), d = a !== void 0 ? a : n;\n /* istanbul ignore else @preserve */\n o && o.has(i) && o.delete(i);\n /* istanbul ignore else @preserve */\n s && (!o || !o.size) && s.delete(t);\n /* istanbul ignore else @preserve */\n (!s || !s.size) && delete e[c];\n /* istanbul ignore else @preserve */\n (!o || !o.size) && t.removeEventListener(\n c,\n f,\n d\n );\n}, g = E, M = r;\nexport {\n E as addListener,\n f as globalListener,\n M as off,\n g as on,\n e as registry,\n r as removeListener\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: HTMLElement) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: ScrollSpyOptions = {\n offset: 10,\n target: null,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: HTMLElement) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: HTMLElement) => Component,\n collection: HTMLCollectionOf | HTMLElement[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["exports","ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","f","t","c","i","s","o","r","E","d","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","BaseComponent","prevInstance","alertSelector","alertDismissSelector","getAlertInstance","alertInitCallback","Alert","closeAlertEvent","closedAlertEvent","alertTransitionEnd","self","add","action","addListener","removeListener","dismiss","close","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","isActive","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","attValue","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","activeItem","getActiveIndex","orientation","directionClass","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","RTL","carouselDragHandler","carouselPointerDownHandler","controls","indicators","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","activeIndex","transitionItem","ar","isPaused","idx","next","eventProperties","touch","pause","interval","keyboard","arrow","indicator","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","triggers","btn","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","menuEnd","p","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","targetLeft","targetTop","targetWidth","targetHeight","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","dropdownPreventScroll","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","dropdownClickHandler","activeElement","open","menuItems","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","fixedItems","fixed","measureScrollbar","innerWidth","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","appendPopup","customContainer","containerIsBody","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","afterModalShow","beforeModalShow","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","overlayDelay","currentOpen","that","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","tipPositions","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","tooltipDefaults","_","B","m","n","h","l","u","a","b","g","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","tempDocument","createTip","id","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","position","PositionObserver","outTimer","tipContainer","showTooltipEvent","hideTooltipEvent","enabled","tr","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","isRoot","links","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","_observer","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","scrollTop","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","context","compData","initCallback","lookUp","elemCollection","cs","init","removeDataAPI","comp"],"mappings":"AAAK,IAAA,IAAA,SAAAA,EAAA,CAAA,aAAA,MAAqEC,GAAkB,mBAAoBC,GAAe,gBAAiDC,GAAa,cAA6EC,GAAY,aAAcC,GAAc,eAAgBC,GAAe,gBAAqYC,GAAa,QAASC,GAAe,UAAWC,GAAgB,WAAsHC,GAAe,UAAuCC,GAAa,QAA6BC,EAAkB,QAA0CC,GAAiB,YAAuCC,GAAkB,QAASC,GAAkB,aAAcC,GAAkB,aAAwQC,GAAmB,cAAmDC,GAAmB,cAAeC,GAAiB,YAA+OC,GAAkB,aAmDxxDC,GAAiB,YAaaC,GAAoB,oFAuCtDC,GAAe,YAAaC,GAAa,UAAWC,GAAe,YAAaC,GAAgB,aAAsKC,GAAY,SAA6SC,GAAqB,qBAAsBC,GAAkB,kBAAmBC,GAAqB,gBAAiBC,GAAqB,qBA+B1tBC,GAAU,IAAM,CACjB,MAAMC,EAAc,qBACpB,OAAO,WAAW,eAAe,OAAO,KACrCC,GAAMD,EAAY,KAAKC,EAAE,KAAK,CAChC,GACDD,EAAY,KACV,WAAW,SACZ,GAAI,EACP,EAC2GE,GAAO,IAAM,CACxH,EAAGC,GAAK,CAACC,EAASC,EAAWC,EAAUC,IAAY,CACjD,MAAMC,EAAMD,GAAW,GACvBH,EAAQ,iBACNC,EACAC,EACAE,CACD,CACH,EAAGC,GAAM,CAACL,EAASC,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SAAS,KAAmBD,GAAA,EAE9Bpe,EAAY,SAAU,mBAAoB,IAAMoe,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP,EACHzrB,EAAA,MAAA8M,GAAA9M,EAAA,OAAAgO,GAAAhO,EAAA,SAAAkP,GAAAlP,EAAA,SAAAsS,GAAAtS,EAAA,SAAAgU,GAAAhU,EAAA,MAAA2a,GAAA3a,EAAA,UAAAkd,GAAAld,EAAA,QAAA2lB,GAAA3lB,EAAA,UAAAkmB,GAAAlmB,EAAA,IAAAooB,GAAApoB,EAAA,MAAAsqB,GAAAtqB,EAAA,QAAA8jB,GAAA9jB,EAAA,aAAAyrB,GAAAzrB,EAAA,cAAA8rB,GAAA,OAAA,eAAA9rB,EAAA,OAAA,YAAA,CAAA,MAAA,QAAA,CAAA,EAAAA,CAAA,EAAA,CAAA,CAAA","x_google_ignoreList":[0,1,52]} \ No newline at end of file +{"version":3,"file":"bootstrap-native.js","sources":["../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.8/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@https+++codeload.github.com+thednp+position-observer+tar.gz+d693d53_hyk7lpzuqi6vnifksl6nzudy5a/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const g = \"2.0.8\", e = {}, f = (t) => {\n const { type: n, currentTarget: c } = t;\n e[n].forEach((a, s) => {\n c === s && a.forEach((o, i) => {\n i.apply(s, [t]), typeof o == \"object\" && o.once && r(s, n, i, o);\n });\n });\n}, E = (t, n, c, a) => {\n e[n] || (e[n] = /* @__PURE__ */ new Map());\n const s = e[n];\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(\n t\n ), { size: i } = o;\n o.set(c, a), i || t.addEventListener(\n n,\n f,\n a\n );\n}, r = (t, n, c, a) => {\n const s = e[n], o = s && s.get(t), i = o && o.get(c), d = i !== void 0 ? i : a;\n o && o.has(c) && o.delete(c), s && (!o || !o.size) && s.delete(t), (!s || !s.size) && delete e[n], (!o || !o.size) && t.removeEventListener(\n n,\n f,\n d\n );\n}, M = E, p = r;\nexport {\n E as addListener,\n f as globalListener,\n p as off,\n M as on,\n e as registry,\n r as removeListener,\n g as version\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: Element) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: Element) => Component,\n collection: HTMLCollectionOf | Element[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","n","o","s","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","u","h","O","to","k","G","K","d","N","oe","q","g","ae","ie","ro","r","a","i","io","P","T","ue","lo","f","c","p","E","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop","alertSelector","alertDismissSelector","getAlertInstance","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","hasClass","removeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","setAttribute","ariaPressed","isActive","getAttribute","addClass","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","doc","getDocument","att","attValue","closest","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","options","activeItem","getActiveIndex","orientation","directionClass","Timer","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","code","querySelectorAll","isElementInScrollRange","RTL","isRTL","keyArrowRight","keyArrowLeft","carouselDragHandler","carouselPointerDownHandler","controls","indicators","el","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","pointermoveEvent","passiveHandler","pointerupEvent","isHTMLElement","getElementsByClassName","activeIndex","transitionItem","matches","ar","isPaused","idx","next","eventProperties","ObjectAssign","getElementTransitionDuration","reflow","touch","pause","interval","keyboard","mouseenterEvent","mouseleaveEvent","pointerdownEvent","touchstartEvent","dragstartEvent","arrow","indicator","keydownEvent","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","parent","triggers","noop","setElementStyle","btn","ariaExpanded","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","hasAttribute","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","getElementStyle","menuEnd","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","clientHeight","getDocumentElement","targetLeft","targetTop","targetWidth","targetHeight","getBoundingClientRect","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","focusEvent","dropdownPreventScroll","keyupEvent","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","mousedownEvent","dropdownClickHandler","keyArrowDown","keyArrowUp","activeElement","open","menuItems","focus","keyEscape","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","getDocumentBody","fixedItems","fixed","measureScrollbar","innerWidth","getWindow","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","createElement","appendPopup","customContainer","containerIsBody","isNode","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","toggleFocusTrap","afterModalShow","beforeModalShow","removeAttribute","ariaHidden","ariaModal","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","duration","overlayDelay","currentOpen","that","callback","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","offsetParent","scrollLeft","scrollTop","getNodeScroll","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","toLowerCase","tooltipDefaults","_","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","isFunction","tempDocument","isNodeList","isArray","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","ariaDescribedBy","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","getUID","position","PositionObserver","entries","outTimer","showTooltipEvent","delay","hideTooltipEvent","enabled","tr","mousehoverEvent","focusinEvent","focusoutEvent","isApple","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","_observer","isRoot","links","getElementsByTagName","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","spyTarget","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","ariaSelected","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","component","context","compData","instance","initCallback","lookUp","elemCollection","cs","init","selector","removeDataAPI","comp"],"mappings":"iCAAK,MAA6DA,GAAK,mBAAoBC,GAAK,gBAAuCC,GAAI,cAA0DC,GAAK,aAAcC,GAAK,eAAgBC,GAAK,gBAAwPC,GAAK,QAASC,GAAK,UAAWC,GAAK,WAA0EC,GAAK,UAA4BC,GAAK,QAAsBC,EAAK,QAA0BC,GAAK,YAA6BC,GAAK,QAASC,GAAK,aAAcC,GAAK,aAAmKC,GAAK,cAAoCC,GAAK,cAAeC,GAAK,YAAsJC,GAAK,aAmD1mCC,GAAK,YAUuBC,GAAK,oFAoBlCC,GAAK,YAAaC,GAAK,UAAWC,GAAK,YAAaC,GAAK,aAAkHC,GAAK,SAAyMC,GAAK,qBAAsBC,GAAK,kBAAmBC,GAAI,gBAAiBC,GAAI,qBA+BjdC,GAAK,IAAM,CACZ,MAAMC,EAAI,qBACV,OAAO,WAAW,eAAe,OAAO,KACrCC,GAAMD,EAAE,KAAKC,EAAE,KAAK,CACtB,GAAID,EAAE,KACL,WAAW,SACZ,GAAI,EACP,EAA2PE,GAAK,IAAM,CACtQ,EAAGC,GAAI,CAACH,EAAGC,EAAGG,EAAGC,IAAM,CACrB,MAAMC,EAAID,GAAK,GACfL,EAAE,iBACAC,EACAG,EACAE,CACD,CACH,EAAGC,GAAI,CAACP,EAAGC,EAAGG,EAAGC,IAAM,CACrB,MAAMC,EAAID,GAAK,GACfL,EAAE,oBACAC,EACAG,EACAE,CACD,CACH,EAesUE,GAAI,CAACR,EAAGC,IAAMD,EAAE,aAAaC,CAAC,EAA6CQ,GAAK,CAACT,EAAGC,IAAMD,EAAE,aAAaC,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C,GACAmC,GACAjH,EACF,EAAE,QAAStf,GAAMonB,GAAe,IAAIpnB,EAAE,UAAU,KAAMA,CAAC,CAAC,EAQxD,MAAMqnB,GAAuB,CAC3BxP,EACAyP,IACG,CACF,CAAA,GAAGA,CAAU,EAAE,QAAS7mB,GAAMoX,EAASpX,CAAC,CAAC,CAC5C,EAQM8mB,GAAyB,CAAIC,EAAmBC,IAAwB,CACtE,MAAAC,EAAWjkB,GAAK,UAAU+jB,CAAS,EAErCE,GACD,CAAA,GAAGA,CAAQ,EAAE,QAAQ,CAAC,CAACtkB,EAASukB,CAAQ,IAAM,CACzCF,EAAQ,SAASrkB,CAAO,GACzBukB,EAAyC,QAAQ,CACpD,CACD,CAEL,EAOaC,GAAgBH,GAAyB,CACpD,MAAMI,EAASJ,GAAWA,EAAQ,SAAWA,EAAU,SACjDK,EAAiB,CAAC,GAAGtF,GAA8B,IAAKqF,CAAM,CAAC,EAEtDT,GAAA,QAASW,GAAO,CACvB,KAAA,CAAE,KAAAC,EAAM,SAAAC,CAAA,EAAaF,EAC3BV,GACEW,EACAF,EAAe,OAAQ1E,GAASnZ,GAAQmZ,EAAM6E,CAAQ,CAAC,CACzD,CAAA,CACD,CACH,EAOaC,GAAiBT,GAAyB,CACrD,MAAMI,EAASJ,GAAWA,EAAQ,SAAWA,EAAU,SAExCL,GAAA,QAASe,GAAS,CACRZ,GAAAY,EAAK,UAAU,KAAMN,CAAM,CAAA,CACnD,CACH,EAGA,OAAI,SAAS,KAAmBD,GAAA,EAE9B9iB,EAAY,SAAU,mBAAoB,IAAM8iB,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP","x_google_ignoreList":[0,1,52]} \ No newline at end of file diff --git a/dist/bootstrap-native.mjs b/dist/bootstrap-native.mjs index 0ce1c9e8..467321fd 100644 --- a/dist/bootstrap-native.mjs +++ b/dist/bootstrap-native.mjs @@ -1,34 +1,33 @@ -const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "aria-modal", vs = "aria-pressed", Le = "aria-selected", ss = "focus", ns = "focusin", En = "focusout", Ee = "keydown", No = "keyup", N = "click", wn = "mousedown", Oo = "hover", we = "mouseenter", os = "mouseleave", ko = "pointerdown", _o = "pointermove", Mo = "pointerup", is = "touchstart", Bo = "dragstart", Ro = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]', je = "ArrowDown", ze = "ArrowUp", bs = "ArrowLeft", Es = "ArrowRight", rs = "Escape", Fo = "transitionDuration", Wo = "transitionDelay", Ne = "transitionend", Tn = "transitionProperty", Vo = () => { +const $n = "aria-describedby", we = "aria-expanded", ie = "aria-hidden", $e = "aria-modal", Es = "aria-pressed", _e = "aria-selected", os = "focus", is = "focusin", Tn = "focusout", Te = "keydown", Ro = "keyup", I = "click", yn = "mousedown", Bo = "hover", ye = "mouseenter", rs = "mouseleave", Fo = "pointerdown", Wo = "pointermove", jo = "pointerup", cs = "touchstart", zo = "dragstart", Vo = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]', Ke = "ArrowDown", qe = "ArrowUp", $s = "ArrowLeft", Ts = "ArrowRight", as = "Escape", Ko = "transitionDuration", qo = "transitionDelay", Oe = "transitionend", Cn = "transitionProperty", Xo = () => { const e = /(iPhone|iPod|iPad)/; return navigator?.userAgentData?.brands.some( (t) => e.test(t.brand) - ) || /* istanbul ignore next @preserve */ - e.test( + ) || e.test( navigator?.userAgent ) || !1; -}, ve = () => { -}, jo = (e, t, s, n) => { +}, Ee = () => { +}, Yo = (e, t, s, n) => { const o = n || !1; e.addEventListener( t, s, o ); -}, zo = (e, t, s, n) => { +}, Uo = (e, t, s, n) => { const o = n || !1; e.removeEventListener( t, s, o ); -}, et = (e, t) => e.getAttribute(t), Gt = (e, t) => e.hasAttribute(t), O = (e, t, s) => e.setAttribute(t, s), Pt = (e, t) => e.removeAttribute(t), h = (e, ...t) => { +}, et = (e, t) => e.getAttribute(t), te = (e, t) => e.hasAttribute(t), L = (e, t, s) => e.setAttribute(t, s), It = (e, t) => e.removeAttribute(t), h = (e, ...t) => { e.classList.add(...t); -}, m = (e, ...t) => { +}, v = (e, ...t) => { e.classList.remove(...t); -}, f = (e, t) => e.classList.contains(t), ne = (e) => e != null && typeof e == "object" || !1, H = (e) => ne(e) && typeof e.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( +}, f = (e, t) => e.classList.contains(t), re = (e) => e != null && typeof e == "object" || !1, D = (e) => re(e) && typeof e.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( (t) => e.nodeType === t -) || !1, T = (e) => H(e) && e.nodeType === 1 || !1, Bt = /* @__PURE__ */ new Map(), Dt = { - data: Bt, +) || !1, G = (e) => D(e) && e.nodeType === 1 || !1, Wt = /* @__PURE__ */ new Map(), Dt = { + data: Wt, /** * Sets web components data. * @@ -37,7 +36,7 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @param instance the component instance */ set: (e, t, s) => { - T(e) && (Bt.has(t) || Bt.set(t, /* @__PURE__ */ new Map()), Bt.get(t).set(e, s)); + G(e) && (Wt.has(t) || Wt.set(t, /* @__PURE__ */ new Map()), Wt.get(t).set(e, s)); }, /** * Returns all instances for specified component. @@ -45,7 +44,7 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @param component the component's name or a unique key * @returns all the component instances */ - getAllFor: (e) => Bt.get(e) || null, + getAllFor: (e) => Wt.get(e) || null, /** * Returns the instance associated with the target. * @@ -54,7 +53,7 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @returns the instance */ get: (e, t) => { - if (!T(e) || !t) return null; + if (!G(e) || !t) return null; const s = Dt.getAllFor(t); return e && s && s.get(e) || null; }, @@ -66,87 +65,67 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a */ remove: (e, t) => { const s = Dt.getAllFor(t); - !s || !T(e) || (s.delete(e), s.size === 0 && Bt.delete(t)); + !s || !G(e) || (s.delete(e), s.size === 0 && Wt.delete(t)); } -}, W = (e, t) => Dt.get(e, t), oe = (e) => typeof e == "string" || !1, Ko = (e) => ne(e) && e.constructor.name === "Window" || !1, $n = (e) => H(e) && e.nodeType === 9 || !1, E = (e) => Ko(e) ? e.document : $n(e) ? e : H(e) ? e.ownerDocument : globalThis.document, ct = (e, ...t) => Object.assign(e, ...t), Et = (e) => { +}, j = (e, t) => Dt.get(e, t), ce = (e) => typeof e == "string" || !1, xn = (e) => re(e) && e.constructor.name === "Window" || !1, Sn = (e) => D(e) && e.nodeType === 9 || !1, w = (e) => Sn(e) ? e : D(e) ? e.ownerDocument : xn(e) ? e.document : globalThis.document, ct = (e, ...t) => Object.assign(e, ...t), vt = (e) => { if (!e) return; - if (oe(e)) - return E().createElement(e); - const { tagName: t } = e, s = Et(t); + if (ce(e)) + return w().createElement(e); + const { tagName: t } = e, s = vt(t); if (!s) return; const n = { ...e }; return delete n.tagName, ct(s, n); -}, b = (e, t) => e.dispatchEvent(t), z = (e, t) => { - const s = getComputedStyle(e), n = t.replace("webkit", "Webkit").replace(/([A-Z])/g, "-$1").toLowerCase(); - return s.getPropertyValue(n); -}, Uo = (e) => { - const t = z(e, Tn), s = z(e, Wo), n = s.includes("ms") ? ( - /* istanbul ignore next */ - 1 - ) : 1e3, o = t && t !== "none" ? parseFloat(s) * n : ( - /* istanbul ignore next */ - 0 - ); - return Number.isNaN(o) ? ( - /* istanbul ignore next */ - 0 - ) : o; -}, ie = (e) => { - const t = z(e, Tn), s = z(e, Fo), n = s.includes("ms") ? ( - /* istanbul ignore next */ - 1 - ) : 1e3, o = t && t !== "none" ? parseFloat(s) * n : ( - /* istanbul ignore next */ - 0 - ); - return Number.isNaN(o) ? ( - /* istanbul ignore next */ - 0 - ) : o; -}, A = (e, t) => { +}, b = (e, t) => e.dispatchEvent(t), W = (e, t, s) => { + const n = getComputedStyle(e, s), o = t.replace("webkit", "Webkit").replace(/([A-Z])/g, "-$1").toLowerCase(); + return n.getPropertyValue(o); +}, Go = (e) => { + const t = W(e, Cn), s = W(e, qo), n = s.includes("ms") ? 1 : 1e3, o = t && t !== "none" ? parseFloat(s) * n : 0; + return Number.isNaN(o) ? 0 : o; +}, ae = (e) => { + const t = W(e, Cn), s = W(e, Ko), n = s.includes("ms") ? 1 : 1e3, o = t && t !== "none" ? parseFloat(s) * n : 0; + return Number.isNaN(o) ? 0 : o; +}, H = (e, t) => { let s = 0; - const n = new Event(Ne), o = ie(e), i = Uo(e); + const n = new Event(Oe), o = ae(e), i = Go(e); if (o) { - const r = (a) => { - a.target === e && (t.apply(e, [a]), e.removeEventListener(Ne, r), s = 1); + const r = (c) => { + c.target === e && (t.apply(e, [c]), e.removeEventListener(Oe, r), s = 1); }; - e.addEventListener(Ne, r), setTimeout(() => { + e.addEventListener(Oe, r), setTimeout(() => { s || b(e, n); }, o + i + 17); } else t.apply(e, [n]); -}, lt = (e, t) => e.focus(t), ws = (e) => ["true", !0].includes(e) ? !0 : ["false", !1].includes(e) ? !1 : ["null", "", null, void 0].includes(e) ? null : e !== "" && !Number.isNaN(+e) ? +e : e, he = (e) => Object.entries(e), Wt = (e) => e.toLowerCase(), Xo = (e, t, s, n) => { - const o = { ...s }, i = { ...e.dataset }, r = { ...t }, a = {}, c = "title"; - return he(i).forEach(([l, d]) => { +}, at = (e, t) => e.focus(t), ys = (e) => ["true", !0].includes(e) ? !0 : ["false", !1].includes(e) ? !1 : ["null", "", null, void 0].includes(e) ? null : e !== "" && !Number.isNaN(+e) ? +e : e, ue = (e) => Object.entries(e), Vt = (e) => e.toLowerCase(), Zo = (e, t, s, n) => { + if (!G(e)) return t; + const o = { ...s }, i = { ...e.dataset }, r = { ...t }, c = {}, a = "title"; + return ue(i).forEach(([l, d]) => { const g = typeof l == "string" && l.includes(n) ? l.replace(n, "").replace( /[A-Z]/g, - (y) => Wt(y) - ) : ( - /* istanbul ignore next @preserve */ - l - ); - a[g] = ws(d); - }), he(o).forEach(([l, d]) => { - o[l] = ws(d); - }), he(t).forEach(([l, d]) => { - l in o ? r[l] = o[l] : l in a ? r[l] = a[l] : r[l] = l === c ? et(e, c) : d; + (E) => Vt(E) + ) : l; + c[g] = ys(d); + }), ue(o).forEach(([l, d]) => { + o[l] = ys(d); + }), ue(t).forEach(([l, d]) => { + l in o ? r[l] = o[l] : l in c ? r[l] = c[l] : r[l] = l === a ? et(e, a) : d; }), r; -}, Ts = (e) => Object.keys(e), w = (e, t) => { +}, Cs = (e) => Object.keys(e), $ = (e, t) => { const s = new CustomEvent(e, { cancelable: !0, bubbles: !0 }); - return ne(t) && ct(s, t), s; -}, Jt = { passive: !0 }, Nt = (e) => e.offsetHeight, P = (e, t) => { - he(t).forEach(([s, n]) => { - if (n && oe(s) && s.includes("--")) + return re(t) && ct(s, t), s; +}, ee = { passive: !0 }, Ot = (e) => e.offsetHeight, P = (e, t) => { + ue(t).forEach(([s, n]) => { + if (n && ce(s) && s.includes("--")) e.style.setProperty(s, n); else { const o = {}; o[s] = n, ct(e.style, o); } }); -}, Ke = (e) => ne(e) && e.constructor.name === "Map" || !1, qo = (e) => typeof e == "number" || !1, mt = /* @__PURE__ */ new Map(), p = { +}, Xe = (e) => re(e) && e.constructor.name === "Map" || !1, Qo = (e) => typeof e == "number" || !1, ut = /* @__PURE__ */ new Map(), u = { /** * Sets a new timeout timer for an element, or element -> key association. * @@ -156,7 +135,7 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @param key a unique key */ set: (e, t, s, n) => { - T(e) && (n && n.length ? (mt.has(e) || mt.set(e, /* @__PURE__ */ new Map()), mt.get(e).set(n, setTimeout(t, s))) : mt.set(e, setTimeout(t, s))); + G(e) && (n && n.length ? (ut.has(e) || ut.set(e, /* @__PURE__ */ new Map()), ut.get(e).set(n, setTimeout(t, s))) : ut.set(e, setTimeout(t, s))); }, /** * Returns the timer associated with the target. @@ -166,10 +145,9 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @returns the timer */ get: (e, t) => { - if (!T(e)) return null; - const s = mt.get(e); - return t && s && Ke(s) ? s.get(t) || /* istanbul ignore next @preserve */ - null : qo(s) ? s : null; + if (!G(e)) return null; + const s = ut.get(e); + return t && s && Xe(s) ? s.get(t) || null : Qo(s) ? s : null; }, /** * Clears the element's timer. @@ -178,161 +156,169 @@ const bn = "aria-describedby", me = "aria-expanded", se = "aria-hidden", be = "a * @param key a unique key */ clear: (e, t) => { - if (!T(e)) return; - const s = mt.get(e); - t && t.length && Ke(s) ? (clearTimeout(s.get(t)), s.delete(t), s.size === 0 && mt.delete(e)) : (clearTimeout(s), mt.delete(e)); - } -}, Z = (e, t) => (H(t) ? t : E()).querySelectorAll(e), Ue = /* @__PURE__ */ new Map(); -function Yo(e) { - const { shiftKey: t, code: s } = e, n = E(this), o = [ - ...Z(Ro, this) + if (!G(e)) return; + const s = ut.get(e); + t && t.length && Xe(s) ? (clearTimeout(s.get(t)), s.delete(t), s.size === 0 && ut.delete(e)) : (clearTimeout(s), ut.delete(e)); + } +}, U = (e, t) => (D(t) ? t : w()).querySelectorAll(e), Ye = /* @__PURE__ */ new Map(); +function Jo(e) { + const { shiftKey: t, code: s } = e, n = w(this), o = [ + ...U(Vo, this) ].filter( - (a) => !Gt(a, "disabled") && !et(a, se) + (c) => !te(c, "disabled") && !et(c, ie) ); if (!o.length) return; const i = o[0], r = o[o.length - 1]; s === "Tab" && (t && n.activeElement === i ? (r.focus(), e.preventDefault()) : !t && n.activeElement === r && (i.focus(), e.preventDefault())); } -const Zo = (e) => Ue.has(e) === !0, Te = (e) => { - const t = Zo(e); - (t ? zo : jo)(e, "keydown", Yo), t ? Ue.delete(e) : Ue.set(e, !0); -}, re = (e, t) => { - const { width: s, height: n, top: o, right: i, bottom: r, left: a } = e.getBoundingClientRect(); - let c = 1, l = 1; - if (t && T(e)) { +const ti = (e) => Ye.has(e) === !0, Ce = (e) => { + const t = ti(e); + (t ? Uo : Yo)(e, "keydown", Jo), t ? Ye.delete(e) : Ye.set(e, !0); +}, C = (e) => G(e) && "offsetWidth" in e || !1, Et = (e, t) => { + const { width: s, height: n, top: o, right: i, bottom: r, left: c } = e.getBoundingClientRect(); + let a = 1, l = 1; + if (t && C(e)) { const { offsetWidth: d, offsetHeight: g } = e; - c = d > 0 ? Math.round(s) / d : ( - /* istanbul ignore next @preserve */ - 1 - ), l = g > 0 ? Math.round(n) / g : ( - /* istanbul ignore next @preserve */ - 1 - ); + a = d > 0 ? Math.round(s) / d : 1, l = g > 0 ? Math.round(n) / g : 1; } return { - width: s / c, + width: s / a, height: n / l, top: o / l, - right: i / c, + right: i / a, bottom: r / l, - left: a / c, - x: a / c, + left: c / a, + x: c / a, y: o / l }; -}, yt = (e) => E(e).body, dt = (e) => E(e).documentElement, yn = (e) => H(e) && e.constructor.name === "ShadowRoot" || !1, Go = (e) => e.nodeName === "HTML" ? e : T(e) && e.assignedSlot || // step into the shadow DOM of the parent of a slotted node -H(e) && e.parentNode || // DOM Element detected -yn(e) && e.host || // ShadowRoot detected -dt(e); -let $s = 0, ys = 0; -const Rt = /* @__PURE__ */ new Map(), Cn = (e, t) => { - let s = t ? $s : ys; +}, Tt = (e) => w(e).body, lt = (e) => w(e).documentElement, ei = (e) => { + const t = xn(e), s = t ? e.scrollX : e.scrollLeft, n = t ? e.scrollY : e.scrollTop; + return { x: s, y: n }; +}, Hn = (e) => D(e) && e.constructor.name === "ShadowRoot" || !1, si = (e) => e.nodeName === "HTML" ? e : G(e) && e.assignedSlot || D(e) && e.parentNode || Hn(e) && e.host || lt(e), Pn = (e) => e ? Sn(e) ? e.defaultView : D(e) ? e?.ownerDocument?.defaultView : e : window, ni = (e) => D(e) && ["TABLE", "TD", "TH"].includes(e.nodeName) || !1, Dn = (e, t) => e.matches(t), oi = (e) => { + if (!C(e)) return !1; + const { width: t, height: s } = Et(e), { offsetWidth: n, offsetHeight: o } = e; + return Math.round(t) !== n || Math.round(s) !== o; +}, ii = (e, t, s) => { + const n = C(t), o = Et( + e, + n && oi(t) + ), i = { x: 0, y: 0 }; + if (n) { + const r = Et(t, !0); + i.x = r.x + t.clientLeft, i.y = r.y + t.clientTop; + } + return { + x: o.left + s.x - i.x, + y: o.top + s.y - i.y, + width: o.width, + height: o.height + }; +}; +let xs = 0, Ss = 0; +const jt = /* @__PURE__ */ new Map(), An = (e, t) => { + let s = t ? xs : Ss; if (t) { - const n = Cn(e), o = Rt.get(n) || /* @__PURE__ */ new Map(); - Rt.has(n) || Rt.set(n, o), Ke(o) && !o.has(t) ? (o.set(t, s), $s += 1) : s = o.get(t); + const n = An(e), o = jt.get(n) || /* @__PURE__ */ new Map(); + jt.has(n) || jt.set(n, o), Xe(o) && !o.has(t) ? (o.set(t, s), xs += 1) : s = o.get(t); } else { const n = e.id || e; - Rt.has(n) ? s = Rt.get(n) : (Rt.set(n, s), ys += 1); + jt.has(n) ? s = jt.get(n) : (jt.set(n, s), Ss += 1); } return s; -}, Jo = (e) => e ? $n(e) ? e.defaultView : H(e) ? e?.ownerDocument?.defaultView : e : window, Qo = (e) => Array.isArray(e) || !1, Sn = (e) => { - if (!H(e)) return !1; - const { top: t, bottom: s } = re(e), { clientHeight: n } = dt(e); +}, ri = (e) => Array.isArray(e) || !1, kn = (e) => { + if (!D(e)) return !1; + const { top: t, bottom: s } = Et(e), { clientHeight: n } = lt(e); return t <= n && s >= 0; -}, ti = (e) => typeof e == "function" || !1, ei = (e) => ne(e) && e.constructor.name === "NodeList" || !1, $t = (e) => dt(e).dir === "rtl", si = (e) => H(e) && ["TABLE", "TD", "TH"].includes(e.nodeName) || !1, k = (e, t) => e ? e.closest(t) || // break out of `ShadowRoot` -k(e.getRootNode().host, t) : null, D = (e, t) => T(e) ? e : (H(t) ? t : E()).querySelector(e), as = (e, t) => (H(t) ? t : E()).getElementsByTagName( +}, ci = (e) => typeof e == "function" || !1, ai = (e) => re(e) && e.constructor.name === "NodeList" || !1, $t = (e) => lt(e).dir === "rtl", _ = (e, t) => !e || !t ? null : e.closest(t) || _(e.getRootNode().host, t) || null, S = (e, t) => G(e) ? e : (G(t) ? t : w()).querySelector(e), ls = (e, t) => (D(t) ? t : w()).getElementsByTagName( e -), rt = (e, t) => (t && H(t) ? t : E()).getElementsByClassName( +), it = (e, t) => (t && D(t) ? t : w()).getElementsByClassName( e -), xn = (e, t) => e.matches(t), Ft = {}, Dn = (e) => { +), zt = {}, In = (e) => { const { type: t, currentTarget: s } = e; - [...Ft[t]].forEach(([n, o]) => { - s === n && [...o].forEach(([i, r]) => { - i.apply(n, [e]), typeof r == "object" && r.once && B(n, t, i, r); + zt[t].forEach((n, o) => { + s === o && n.forEach((i, r) => { + r.apply(o, [e]), typeof i == "object" && i.once && M(o, t, r, i); }); }); -}, M = (e, t, s, n) => { - Ft[t] || (Ft[t] = /* @__PURE__ */ new Map()); - const o = Ft[t]; +}, N = (e, t, s, n) => { + zt[t] || (zt[t] = /* @__PURE__ */ new Map()); + const o = zt[t]; o.has(e) || o.set(e, /* @__PURE__ */ new Map()); - const i = o.get(e), { size: r } = i; - i.set(s, n); - r || e.addEventListener(t, Dn, n); -}, B = (e, t, s, n) => { - const o = Ft[t], i = o && o.get(e), r = i && i.get(s), a = r !== void 0 ? r : n; - i && i.has(s) && i.delete(s); - o && (!i || !i.size) && o.delete(e); - (!o || !o.size) && delete Ft[t]; - (!i || !i.size) && e.removeEventListener( + const i = o.get( + e + ), { size: r } = i; + i.set(s, n), r || e.addEventListener( + t, + In, + n + ); +}, M = (e, t, s, n) => { + const o = zt[t], i = o && o.get(e), r = i && i.get(s), c = r !== void 0 ? r : n; + i && i.has(s) && i.delete(s), o && (!i || !i.size) && o.delete(e), (!o || !o.size) && delete zt[t], (!i || !i.size) && e.removeEventListener( t, - Dn, - a + In, + c ); -}, _ = "fade", u = "show", $e = "data-bs-dismiss", ye = "alert", Hn = "Alert", ni = "5.1.0", oi = ni; +}, O = "fade", p = "show", xe = "data-bs-dismiss", Se = "alert", Ln = "Alert", li = "5.1.0", di = li; class st { /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ constructor(t, s) { let n; try { - if (T(t)) + if (G(t)) n = t; - else if (oe(t)) { - if (n = D(t), !n) throw Error(`"${t}" is not a valid selector.`); + else if (ce(t)) { + if (n = S(t), !n) throw Error(`"${t}" is not a valid selector.`); } else throw Error("your target is not an instance of HTMLElement."); } catch (i) { throw Error(`${this.name} Error: ${i.message}`); } const o = Dt.get(n, this.name); - o && o._toggleEventListeners(), this.element = n, this.options = this.defaults && Ts(this.defaults).length ? Xo(n, this.defaults, s || {}, "bs") : {}, Dt.set(n, this.name, this); + o && o._toggleEventListeners(), this.element = n, this.options = this.defaults && Cs(this.defaults).length ? Zo(n, this.defaults, s || {}, "bs") : {}, Dt.set(n, this.name, this); } - // istanbul ignore next @preserve get version() { - return oi; + return di; } - // istanbul ignore next @preserve get name() { return "BaseComponent"; } - // istanbul ignore next @preserve get defaults() { return {}; } - /** just to have something to extend from */ - // istanbul ignore next @preserve coverage wise this isn't important _toggleEventListeners = () => { }; - /** Removes component from target element. */ dispose() { - Dt.remove(this.element, this.name), Ts(this).forEach((t) => { + Dt.remove(this.element, this.name), Cs(this).forEach((t) => { delete this[t]; }); } } -const ii = `.${ye}`, ri = `[${$e}="${ye}"]`, ai = (e) => W(e, Hn), ci = (e) => new An(e), Cs = w( - `close.bs.${ye}` -), li = w( - `closed.bs.${ye}` -), Ss = (e) => { +const hi = `.${Se}`, fi = `[${xe}="${Se}"]`, gi = (e) => j(e, Ln), ui = (e) => new _n(e), Hs = $( + `close.bs.${Se}` +), pi = $( + `closed.bs.${Se}` +), Ps = (e) => { const { element: t } = e; - b(t, li), e._toggleEventListeners(), e.dispose(), t.remove(); + b(t, pi), e._toggleEventListeners(), e.dispose(), t.remove(); }; -class An extends st { - static selector = ii; - static init = ci; - static getInstance = ai; +class _n extends st { + static selector = hi; + static init = ui; + static getInstance = gi; dismiss; constructor(t) { - super(t), this.dismiss = D(ri, this.element), this._toggleEventListeners(!0); + super(t), this.dismiss = S( + fi, + this.element + ), this._toggleEventListeners(!0); } - /** Returns component name string. */ get name() { - return Hn; + return Ln; } - // ALERT PUBLIC METHODS - // ==================== /** * Public method that hides the `.alert` element from the user, * disposes the instance once animation is complete, then @@ -340,7 +326,7 @@ class An extends st { */ close = () => { const { element: t } = this; - t && f(t, u) && (b(t, Cs), Cs.defaultPrevented || (m(t, u), f(t, _) ? A(t, () => Ss(this)) : Ss(this))); + t && f(t, p) && (b(t, Hs), Hs.defaultPrevented || (v(t, p), f(t, O) ? H(t, () => Ps(this)) : Ps(this))); }; /** * Toggle on / off the `click` event listener. @@ -348,36 +334,32 @@ class An extends st { * @param add when `true`, event listener is added */ _toggleEventListeners = (t) => { - const s = t ? M : B, { dismiss: n, close: o } = this; - n && s(n, N, o); + const s = t ? N : M, { dismiss: n, close: o } = this; + n && s(n, I, o); }; - /** Remove the component from target element. */ dispose() { this._toggleEventListeners(), super.dispose(); } } -const $ = "active", ot = "data-bs-toggle", di = "button", Pn = "Button", hi = `[${ot}="${di}"]`, fi = (e) => W(e, Pn), gi = (e) => new In(e); -class In extends st { - static selector = hi; - static init = gi; - static getInstance = fi; - isActive = !1; +const T = "active", nt = "data-bs-toggle", mi = "button", On = "Button", vi = `[${nt}="${mi}"]`, bi = (e) => j(e, On), wi = (e) => new Nn(e); +class Nn extends st { + static selector = vi; + static init = wi; + static getInstance = bi; /** * @param target usually a `.btn` element */ constructor(t) { super(t); const { element: s } = this; - this.isActive = f(s, $), O(s, vs, String(!!this.isActive)), this._toggleEventListeners(!0); + this.isActive = f(s, T), L(s, Es, String(!!this.isActive)), this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return Pn; + return On; } - // BUTTON PUBLIC METHODS - // ===================== /** * Toggles the state of the target button. * @@ -386,123 +368,116 @@ class In extends st { toggle = (t) => { t && t.preventDefault(); const { element: s, isActive: n } = this; - !f(s, "disabled") && !et(s, "disabled") && ((n ? m : h)(s, $), O(s, vs, n ? "false" : "true"), this.isActive = f(s, $)); + !f(s, "disabled") && !et(s, "disabled") && ((n ? v : h)(s, T), L(s, Es, n ? "false" : "true"), this.isActive = f(s, T)); }; - // BUTTON PRIVATE METHOD - // ===================== /** * Toggles on/off the `click` event listener. * * @param add when `true`, event listener is added */ _toggleEventListeners = (t) => { - (t ? M : B)(this.element, N, this.toggle); + (t ? N : M)(this.element, I, this.toggle); }; - /** Removes the `Button` component from the target element. */ dispose() { this._toggleEventListeners(), super.dispose(); } } -const Xe = "data-bs-target", Ht = "carousel", Ln = "Carousel", xs = "data-bs-parent", pi = "data-bs-container", U = (e) => { - const t = [Xe, xs, pi, "href"], s = E(e); +const Ue = "data-bs-target", At = "carousel", Mn = "Carousel", Ds = "data-bs-parent", Ei = "data-bs-container", q = (e) => { + const t = [Ue, Ds, Ei, "href"], s = w(e); return t.map((n) => { const o = et(e, n); - return o ? n === xs ? k(e, o) : D(o, s) : null; + return o ? n === Ds ? _(e, o) : S(o, s) : null; }).filter((n) => n)[0]; -}, ae = `[data-bs-ride="${Ht}"]`, Y = `${Ht}-item`, qe = "data-bs-slide-to", bt = "data-bs-slide", wt = "paused", Ds = { +}, le = `[data-bs-ride="${At}"]`, Y = `${At}-item`, Ge = "data-bs-slide-to", mt = "data-bs-slide", bt = "paused", As = { pause: "hover", keyboard: !1, touch: !0, interval: 5e3 -}, ht = (e) => W(e, Ln), ui = (e) => new On(e); -let Zt = 0, fe = 0, Oe = 0; -const ke = w(`slide.bs.${Ht}`), Ye = w(`slid.bs.${Ht}`), Hs = (e) => { +}, dt = (e) => j(e, Mn), $i = (e) => new Bn(e); +let Jt = 0, pe = 0, Ne = 0; +const Me = $(`slide.bs.${At}`), Ze = $(`slid.bs.${At}`), ks = (e) => { const { index: t, direction: s, element: n, slides: o, options: i } = e; if (e.isAnimating) { - const r = Ze(e), a = s === "left" ? "next" : "prev", c = s === "left" ? "start" : "end"; - h(o[t], $), m(o[t], `${Y}-${a}`), m(o[t], `${Y}-${c}`), m(o[r], $), m(o[r], `${Y}-${c}`), b(n, Ye), p.clear(n, bt), e.cycle && !E(n).hidden && i.interval && !e.isPaused && e.cycle(); + const r = Qe(e), c = s === "left" ? "next" : "prev", a = s === "left" ? "start" : "end"; + h(o[t], T), v(o[t], `${Y}-${c}`), v(o[t], `${Y}-${a}`), v(o[r], T), v(o[r], `${Y}-${a}`), b(n, Ze), u.clear(n, mt), e.cycle && !w(n).hidden && i.interval && !e.isPaused && e.cycle(); } }; -function mi() { - const e = ht(this); - e && !e.isPaused && !p.get(this, wt) && h(this, wt); +function Ti() { + const e = dt(this); + e && !e.isPaused && !u.get(this, bt) && h(this, bt); } -function vi() { - const e = ht(this); - e && e.isPaused && !p.get(this, wt) && e.cycle(); +function yi() { + const e = dt(this); + e && e.isPaused && !u.get(this, bt) && e.cycle(); } -function bi(e) { +function Ci(e) { e.preventDefault(); - const t = k(this, ae) || U(this), s = ht(t); + const t = _(this, le) || q(this), s = dt(t); if (s && !s.isAnimating) { - const n = +(et(this, qe) || // istanbul ignore next @preserve - 0); - this && !f(this, $) && // event target is not active - !Number.isNaN(n) && s.to(n); + const n = +(et(this, Ge) || 0); + this && !f(this, T) && !Number.isNaN(n) && s.to(n); } } -function Ei(e) { +function xi(e) { e.preventDefault(); - const t = k(this, ae) || U(this), s = ht(t); + const t = _(this, le) || q(this), s = dt(t); if (s && !s.isAnimating) { - const n = et(this, bt); + const n = et(this, mt); n === "next" ? s.next() : n === "prev" && s.prev(); } } -const wi = ({ code: e, target: t }) => { - const s = E(t), [n] = [...Z(ae, s)].filter( - (i) => Sn(i) - ), o = ht(n); +const Si = ({ code: e, target: t }) => { + const s = w(t), [n] = [...U(le, s)].filter((i) => kn(i)), o = dt(n); if (o && !o.isAnimating && !/textarea|input/i.test(t.nodeName)) { const i = $t(n); - e === (i ? Es : bs) ? o.prev() : e === (i ? bs : Es) && o.next(); + e === (i ? Ts : $s) ? o.prev() : e === (i ? $s : Ts) && o.next(); } }; -function As(e) { - const { target: t } = e, s = ht(this); +function Is(e) { + const { target: t } = e, s = dt(this); s && s.isTouch && (s.indicator && !s.indicator.contains(t) || !s.controls.includes(t)) && (e.stopImmediatePropagation(), e.stopPropagation(), e.preventDefault()); } -function Ti(e) { - const { target: t } = e, s = ht(this); +function Hi(e) { + const { target: t } = e, s = dt(this); if (s && !s.isAnimating && !s.isTouch) { const { controls: n, indicators: o } = s; [...n, ...o].every( (i) => i === t || i.contains(t) - ) || (Zt = e.pageX, this.contains(t) && (s.isTouch = !0, Nn(s, !0))); + ) || (Jt = e.pageX, this.contains(t) && (s.isTouch = !0, Rn(s, !0))); } } -const $i = (e) => { - fe = e.pageX; -}, yi = (e) => { - const { target: t } = e, s = E(t), n = [...Z(ae, s)].map((o) => ht(o)).find((o) => o.isTouch); +const Pi = (e) => { + pe = e.pageX; +}, Di = (e) => { + const { target: t } = e, s = w(t), n = [...U(le, s)].map((o) => dt(o)).find((o) => o.isTouch); if (n) { const { element: o, index: i } = n, r = $t(o); - Oe = e.pageX, n.isTouch = !1, Nn(n), !s.getSelection()?.toString().length && o.contains(t) && Math.abs(Zt - Oe) > 120 && (fe < Zt ? n.to(i + (r ? -1 : 1)) : fe > Zt && n.to(i + (r ? 1 : -1))), Zt = 0, fe = 0, Oe = 0; + Ne = e.pageX, n.isTouch = !1, Rn(n), !s.getSelection()?.toString().length && o.contains(t) && Math.abs(Jt - Ne) > 120 && (pe < Jt ? n.to(i + (r ? -1 : 1)) : pe > Jt && n.to(i + (r ? 1 : -1))), Jt = 0, pe = 0, Ne = 0; } -}, _e = (e, t) => { +}, Re = (e, t) => { const { indicators: s } = e; - [...s].forEach((n) => m(n, $)), e.indicators[t] && h(s[t], $); -}, Nn = (e, t) => { - const { element: s } = e, n = t ? M : B; + [...s].forEach((n) => v(n, T)), e.indicators[t] && h(s[t], T); +}, Rn = (e, t) => { + const { element: s } = e, n = t ? N : M; n( - E(s), - _o, - $i, - Jt + w(s), + Wo, + Pi, + ee ), n( - E(s), - Mo, - yi, - Jt + w(s), + jo, + Di, + ee ); -}, Ze = (e) => { - const { slides: t, element: s } = e, n = D(`.${Y}.${$}`, s); - return T(n) ? [...t].indexOf(n) : -1; +}, Qe = (e) => { + const { slides: t, element: s } = e, n = S(`.${Y}.${T}`, s); + return C(n) ? [...t].indexOf(n) : -1; }; -class On extends st { - static selector = ae; - static init = ui; - static getInstance = ht; +class Bn extends st { + static selector = le; + static init = $i; + static getInstance = dt; /** * @param target mostly a `.carousel` element * @param config instance options @@ -510,88 +485,85 @@ class On extends st { constructor(t, s) { super(t, s); const { element: n } = this; - this.direction = $t(n) ? "right" : "left", this.isTouch = !1, this.slides = rt(Y, n); + this.direction = $t(n) ? "right" : "left", this.isTouch = !1, this.slides = it(Y, n); const { slides: o } = this; if (o.length >= 2) { - const i = Ze(this), r = [...o].find( - (l) => xn(l, `.${Y}-next,.${Y}-next`) + const i = Qe(this), r = [...o].find( + (l) => Dn(l, `.${Y}-next,.${Y}-next`) ); this.index = i; - const a = E(n); + const c = w(n); this.controls = [ - ...Z(`[${bt}]`, n), - ...Z( - `[${bt}][${Xe}="#${n.id}"]`, - a + ...U(`[${mt}]`, n), + ...U( + `[${mt}][${Ue}="#${n.id}"]`, + c ) - ].filter((l, d, g) => d === g.indexOf(l)), this.indicator = D(`.${Ht}-indicators`, n), this.indicators = [ - ...this.indicator ? Z(`[${qe}]`, this.indicator) : [], - ...Z( - `[${qe}][${Xe}="#${n.id}"]`, - a + ].filter((l, d, g) => d === g.indexOf(l)), this.indicator = S( + `.${At}-indicators`, + n + ), this.indicators = [ + ...this.indicator ? U(`[${Ge}]`, this.indicator) : [], + ...U( + `[${Ge}][${Ue}="#${n.id}"]`, + c ) ].filter((l, d, g) => d === g.indexOf(l)); - const { options: c } = this; - this.options.interval = c.interval === !0 ? Ds.interval : c.interval, r ? this.index = [...o].indexOf(r) : i < 0 && (this.index = 0, h(o[0], $), this.indicators.length && _e(this, 0)), this.indicators.length && _e(this, this.index), this._toggleEventListeners(!0), c.interval && this.cycle(); + const { options: a } = this; + this.options.interval = a.interval === !0 ? As.interval : a.interval, r ? this.index = [...o].indexOf(r) : i < 0 && (this.index = 0, h(o[0], T), this.indicators.length && Re(this, 0)), this.indicators.length && Re(this, this.index), this._toggleEventListeners(!0), a.interval && this.cycle(); } } /** * Returns component name string. */ get name() { - return Ln; + return Mn; } /** * Returns component default options. */ get defaults() { - return Ds; + return As; } /** * Check if instance is paused. */ get isPaused() { - return f(this.element, wt); + return f(this.element, bt); } /** * Check if instance is animating. */ get isAnimating() { - return D( + return S( `.${Y}-next,.${Y}-prev`, this.element ) !== null; } - // CAROUSEL PUBLIC METHODS - // ======================= - /** Slide automatically through items. */ cycle() { const { element: t, options: s, isPaused: n, index: o } = this; - p.clear(t, Ht), n && (p.clear(t, wt), m(t, wt)), p.set( + u.clear(t, At), n && (u.clear(t, bt), v(t, bt)), u.set( t, () => { - this.element && !this.isPaused && !this.isTouch && Sn(t) && this.to(o + 1); + this.element && !this.isPaused && !this.isTouch && kn(t) && this.to(o + 1); }, s.interval, - Ht + At ); } - /** Pause the automatic cycle. */ pause() { const { element: t, options: s } = this; - !this.isPaused && s.interval && (h(t, wt), p.set( + !this.isPaused && s.interval && (h(t, bt), u.set( t, () => { }, 1, - wt + bt )); } - /** Slide to the next item. */ next() { this.isAnimating || this.to(this.index + 1); } - /** Slide to the previous item. */ prev() { this.isAnimating || this.to(this.index - 1); } @@ -601,35 +573,35 @@ class On extends st { * @param idx the index of the item to jump to */ to(t) { - const { element: s, slides: n, options: o } = this, i = Ze(this), r = $t(s); - let a = t; - if (!this.isAnimating && i !== a && !p.get(s, bt)) { - i < a || i === 0 && a === n.length - 1 ? this.direction = r ? "right" : "left" : (i > a || i === n.length - 1 && a === 0) && (this.direction = r ? "left" : "right"); - const { direction: c } = this; - a < 0 ? a = n.length - 1 : a >= n.length && (a = 0); - const l = c === "left" ? "next" : "prev", d = c === "left" ? "start" : "end", g = { - relatedTarget: n[a], + const { element: s, slides: n, options: o } = this, i = Qe(this), r = $t(s); + let c = t; + if (!this.isAnimating && i !== c && !u.get(s, mt)) { + i < c || i === 0 && c === n.length - 1 ? this.direction = r ? "right" : "left" : (i > c || i === n.length - 1 && c === 0) && (this.direction = r ? "left" : "right"); + const { direction: a } = this; + c < 0 ? c = n.length - 1 : c >= n.length && (c = 0); + const l = a === "left" ? "next" : "prev", d = a === "left" ? "start" : "end", g = { + relatedTarget: n[c], from: i, - to: a, - direction: c + to: c, + direction: a }; - ct(ke, g), ct(Ye, g), b(s, ke), ke.defaultPrevented || (this.index = a, _e(this, a), ie(n[a]) && f(s, "slide") ? p.set( + ct(Me, g), ct(Ze, g), b(s, Me), Me.defaultPrevented || (this.index = c, Re(this, c), ae(n[c]) && f(s, "slide") ? u.set( s, () => { - h(n[a], `${Y}-${l}`), Nt(n[a]), h(n[a], `${Y}-${d}`), h(n[i], `${Y}-${d}`), A( - n[a], - () => this.slides && this.slides.length && Hs(this) + h(n[c], `${Y}-${l}`), Ot(n[c]), h(n[c], `${Y}-${d}`), h(n[i], `${Y}-${d}`), H( + n[c], + () => this.slides && this.slides.length && ks(this) ); }, 0, - bt - ) : (h(n[a], $), m(n[i], $), p.set( + mt + ) : (h(n[c], T), v(n[i], T), u.set( s, () => { - p.clear(s, bt), s && o.interval && !this.isPaused && this.cycle(), b(s, Ye); + u.clear(s, mt), s && o.interval && !this.isPaused && this.cycle(), b(s, Ze); }, 0, - bt + mt ))); } } @@ -639,90 +611,84 @@ class On extends st { * @param add when `TRUE` event listeners are added */ _toggleEventListeners = (t) => { - const { element: s, options: n, slides: o, controls: i, indicators: r } = this, { touch: a, pause: c, interval: l, keyboard: d } = n, g = t ? M : B; - c && l && (g(s, we, mi), g(s, os, vi)), a && o.length > 2 && (g( + const { element: s, options: n, slides: o, controls: i, indicators: r } = this, { touch: c, pause: a, interval: l, keyboard: d } = n, g = t ? N : M; + a && l && (g(s, ye, Ti), g(s, rs, yi)), c && o.length > 2 && (g( s, - ko, - Ti, - Jt - ), g(s, is, As, { passive: !1 }), g(s, Bo, As, { passive: !1 })), i.length && i.forEach((y) => { - y && g(y, N, Ei); - }), r.length && r.forEach((y) => { - g(y, N, bi); - }), d && g(E(s), Ee, wi); + Fo, + Hi, + ee + ), g(s, cs, Is, { passive: !1 }), g(s, zo, Is, { passive: !1 })), i.length && i.forEach((E) => { + E && g(E, I, xi); + }), r.length && r.forEach((E) => { + g(E, I, Ci); + }), d && g(w(s), Te, Si); }; - /** Remove `Carousel` component from target. */ dispose() { const { isAnimating: t } = this, s = { ...this, isAnimating: t }; - this._toggleEventListeners(), super.dispose(), s.isAnimating && A(s.slides[s.index], () => { - Hs(s); + this._toggleEventListeners(), super.dispose(), s.isAnimating && H(s.slides[s.index], () => { + ks(s); }); } } -const It = "collapsing", K = "collapse", kn = "Collapse", Ci = `.${K}`, _n = `[${ot}="${K}"]`, Si = { parent: null }, ge = (e) => W(e, kn), xi = (e) => new Mn(e), Ps = w(`show.bs.${K}`), Di = w(`shown.bs.${K}`), Is = w(`hide.bs.${K}`), Hi = w(`hidden.bs.${K}`), Ai = (e) => { +const Lt = "collapsing", K = "collapse", Fn = "Collapse", Ai = `.${K}`, Wn = `[${nt}="${K}"]`, ki = { parent: null }, me = (e) => j(e, Fn), Ii = (e) => new jn(e), Ls = $(`show.bs.${K}`), Li = $(`shown.bs.${K}`), _s = $(`hide.bs.${K}`), _i = $(`hidden.bs.${K}`), Oi = (e) => { const { element: t, parent: s, triggers: n } = e; - b(t, Ps), Ps.defaultPrevented || (p.set(t, ve, 17), s && p.set(s, ve, 17), h(t, It), m(t, K), P(t, { height: `${t.scrollHeight}px` }), A(t, () => { - p.clear(t), s && p.clear(s), n.forEach((o) => O(o, me, "true")), m(t, It), h(t, K), h(t, u), P(t, { height: "" }), b(t, Di); + b(t, Ls), Ls.defaultPrevented || (u.set(t, Ee, 17), s && u.set(s, Ee, 17), h(t, Lt), v(t, K), P(t, { height: `${t.scrollHeight}px` }), H(t, () => { + u.clear(t), s && u.clear(s), n.forEach((o) => L(o, we, "true")), v(t, Lt), h(t, K), h(t, p), P(t, { height: "" }), b(t, Li); })); -}, Ls = (e) => { +}, Os = (e) => { const { element: t, parent: s, triggers: n } = e; - b(t, Is), Is.defaultPrevented || (p.set(t, ve, 17), s && p.set(s, ve, 17), P(t, { height: `${t.scrollHeight}px` }), m(t, K), m(t, u), h(t, It), Nt(t), P(t, { height: "0px" }), A(t, () => { - p.clear(t), s && p.clear(s), n.forEach((o) => O(o, me, "false")), m(t, It), h(t, K), P(t, { height: "" }), b(t, Hi); + b(t, _s), _s.defaultPrevented || (u.set(t, Ee, 17), s && u.set(s, Ee, 17), P(t, { height: `${t.scrollHeight}px` }), v(t, K), v(t, p), h(t, Lt), Ot(t), P(t, { height: "0px" }), H(t, () => { + u.clear(t), s && u.clear(s), n.forEach((o) => L(o, we, "false")), v(t, Lt), h(t, K), P(t, { height: "" }), b(t, _i); })); -}, Pi = (e) => { - const { target: t } = e, s = t && k(t, _n), n = s && U(s), o = n && ge(n); +}, Ni = (e) => { + const { target: t } = e, s = t && _(t, Wn), n = s && q(s), o = n && me(n); o && o.toggle(), s && s.tagName === "A" && e.preventDefault(); }; -class Mn extends st { - static selector = Ci; - static init = xi; - static getInstance = ge; +class jn extends st { + static selector = Ai; + static init = Ii; + static getInstance = me; /** * @param target and `Element` that matches the selector * @param config instance options */ constructor(t, s) { super(t, s); - const { element: n, options: o } = this, i = E(n); - this.triggers = [...Z(_n, i)].filter( - (r) => U(r) === n - ), this.parent = T(o.parent) ? o.parent : oe(o.parent) ? U(n) || D(o.parent, i) : null, this._toggleEventListeners(!0); + const { element: n, options: o } = this, i = w(n); + this.triggers = [...U(Wn, i)].filter( + (r) => q(r) === n + ), this.parent = C(o.parent) ? o.parent : ce(o.parent) ? q(n) || S(o.parent, i) : null, this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return kn; + return Fn; } /** * Returns component default options. */ get defaults() { - return Si; + return ki; } - // COLLAPSE PUBLIC METHODS - // ======================= - /** Hides the collapse. */ hide() { const { triggers: t, element: s } = this; - p.get(s) || (Ls(this), t.length && t.forEach((n) => h(n, `${K}d`))); + u.get(s) || (Os(this), t.length && t.forEach((n) => h(n, `${K}d`))); } - /** Shows the collapse. */ show() { const { element: t, parent: s, triggers: n } = this; let o, i; s && (o = [ - ...Z(`.${K}.${u}`, s) - ].find((r) => ge(r)), i = o && ge(o)), (!s || !p.get(s)) && !p.get(t) && (i && o !== t && (Ls(i), i.triggers.forEach((r) => { + ...U(`.${K}.${p}`, s) + ].find((r) => me(r)), i = o && me(o)), (!s || !u.get(s)) && !u.get(t) && (i && o !== t && (Os(i), i.triggers.forEach((r) => { h(r, `${K}d`); - })), Ai(this), n.length && n.forEach((r) => m(r, `${K}d`))); + })), Oi(this), n.length && n.forEach((r) => v(r, `${K}d`))); } - /** Toggles the visibility of the collapse. */ toggle() { - f(this.element, u) ? this.hide() : this.show(); + f(this.element, p) ? this.hide() : this.show(); } /** * Toggles on/off the event listener(s) of the `Collapse` instance. @@ -730,44 +696,38 @@ class Mn extends st { * @param add when `true`, the event listener is added */ _toggleEventListeners = (t) => { - const s = t ? M : B, { triggers: n } = this; + const s = t ? N : M, { triggers: n } = this; n.length && n.forEach( - (o) => s(o, N, Pi) + (o) => s(o, I, Ni) ); }; - /** Remove the `Collapse` component from the target `Element`. */ dispose() { this._toggleEventListeners(), super.dispose(); } } -const Lt = ["dropdown", "dropup", "dropstart", "dropend"], Bn = "Dropdown", Rn = "dropdown-menu", Fn = (e) => { - const t = k(e, "A"); - return e.tagName === "A" && // anchor href starts with # - Gt(e, "href") && et(e, "href").slice(-1) === "#" || // OR a child of an anchor with href starts with # - t && Gt(t, "href") && et(t, "href").slice(-1) === "#"; -}, [tt, Ge, Je, Qe] = Lt, Wn = `[${ot}="${tt}"]`, Vt = (e) => W(e, Bn), Ii = (e) => new zn(e), Li = `${Rn}-end`, Ns = [tt, Ge], Os = [Je, Qe], ks = ["A", "BUTTON"], Ni = { +const _t = ["dropdown", "dropup", "dropstart", "dropend"], zn = "Dropdown", Vn = "dropdown-menu", Kn = (e) => { + const t = _(e, "A"); + return e.tagName === "A" && te(e, "href") && et(e, "href").slice(-1) === "#" || t && te(t, "href") && et(t, "href").slice(-1) === "#"; +}, [tt, Je, ts, es] = _t, qn = `[${nt}="${tt}"]`, Kt = (e) => j(e, zn), Mi = (e) => new Un(e), Ri = `${Vn}-end`, Ns = [tt, Je], Ms = [ts, es], Rs = ["A", "BUTTON"], Bi = { offset: 5, - // [number] 5(px) display: "dynamic" - // [dynamic|static] -}, Me = w( +}, Be = $( `show.bs.${tt}` -), _s = w( +), Bs = $( `shown.bs.${tt}` -), Be = w( +), Fe = $( `hide.bs.${tt}` -), Ms = w(`hidden.bs.${tt}`), Vn = w(`updated.bs.${tt}`), jn = (e) => { +), Fs = $(`hidden.bs.${tt}`), Xn = $(`updated.bs.${tt}`), Yn = (e) => { const { element: t, menu: s, parentElement: n, options: o } = e, { offset: i } = o; - if (z(s, "position") !== "static") { - const r = $t(t), a = f(s, Li); - ["margin", "top", "bottom", "left", "right"].forEach((L) => { - const gt = {}; - gt[L] = "", P(s, gt); + if (W(s, "position") !== "static") { + const r = $t(t), c = f(s, Ri); + ["margin", "top", "bottom", "left", "right"].forEach((F) => { + const xt = {}; + xt[F] = "", P(s, xt); }); - let l = Lt.find( - (L) => f(n, L) - ) || // istanbul ignore next @preserve: fallback position - tt; + let l = _t.find( + (F) => f(n, F) + ) || tt; const d = { dropdown: [i, 0, 0], dropup: [0, 0, i], @@ -780,86 +740,85 @@ const Lt = ["dropdown", "dropup", "dropstart", "dropend"], Bn = "Dropdown", Rn = dropend: r ? { left: "auto", right: "100%" } : { left: "100%", right: "auto" }, menuStart: r ? { right: "0", left: "auto" } : { right: "auto", left: "0" }, menuEnd: r ? { right: "auto", left: "0" } : { right: "0", left: "auto" } - }, { offsetWidth: y, offsetHeight: S } = s, { clientWidth: R, clientHeight: v } = dt(t), { - left: V, - top: X, - width: kt, - height: it - } = re(t), C = V - y - i < 0, Q = V + y + kt + i >= R, nt = X + S + i >= v, F = X + S + it + i >= v, j = X - S - i < 0, x = (!r && a || r && !a) && V + kt - y < 0, _t = (r && a || !r && !a) && V + y >= R; - if (Os.includes(l) && C && Q && (l = tt), l === Je && (r ? Q : C) && (l = Qe), l === Qe && (r ? C : Q) && (l = Je), l === Ge && j && !F && (l = tt), l === tt && F && !j && (l = Ge), Os.includes(l) && nt && ct(g[l], { + }, { offsetWidth: E, offsetHeight: k } = s, { clientWidth: z, clientHeight: B } = lt(t), { + left: m, + top: R, + width: yt, + height: Ct + } = Et(t), x = m - E - i < 0, ht = m + E + yt + i >= z, ot = R + k + i >= B, J = R + k + Ct + i >= B, Mt = R - k - i < 0, y = (!r && c || r && !c) && m + yt - E < 0, V = (r && c || !r && !c) && m + E >= z; + if (Ms.includes(l) && x && ht && (l = tt), l === ts && (r ? ht : x) && (l = es), l === es && (r ? x : ht) && (l = ts), l === Je && Mt && !J && (l = tt), l === tt && J && !Mt && (l = Je), Ms.includes(l) && ot && ct(g[l], { top: "auto", bottom: 0 - }), Ns.includes(l) && (x || _t)) { - let L = { left: "auto", right: "auto" }; - !x && _t && !r && (L = { left: "auto", right: 0 }), x && !_t && r && (L = { left: 0, right: "auto" }), L && ct(g[l], L); + }), Ns.includes(l) && (y || V)) { + let F = { left: "auto", right: "auto" }; + !y && V && !r && (F = { left: "auto", right: 0 }), y && !V && r && (F = { left: 0, right: "auto" }), F && ct(g[l], F); } - const ft = d[l]; + const Rt = d[l]; P(s, { ...g[l], - margin: `${ft.map((L) => L && `${L}px`).join(" ")}` - }), Ns.includes(l) && a && a && P(s, g[!r && x || r && _t ? "menuStart" : "menuEnd"]), b(n, Vn); + margin: `${Rt.map((F) => F && `${F}px`).join(" ")}` + }), Ns.includes(l) && c && c && P(s, g[!r && y || r && V ? "menuStart" : "menuEnd"]), b(n, Xn); } -}, Oi = (e) => [...e.children].map((t) => { - if (t && ks.includes(t.tagName)) return t; +}, Fi = (e) => Array.from(e.children).map((t) => { + if (t && Rs.includes(t.tagName)) return t; const { firstElementChild: s } = t; - return s && ks.includes(s.tagName) ? s : null; -}).filter((t) => t), Bs = (e) => { - const { element: t, options: s, menu: n } = e, o = e.open ? M : B, i = E(t); - o(i, N, Rs), o(i, ss, Rs), o(i, Ee, _i), o(i, No, Mi), s.display === "dynamic" && (e.open ? e._observer.observe(n) : e._observer.disconnect()); -}, Ce = (e) => { - const t = [...Lt, "btn-group", "input-group"].map( - (s) => rt(`${s} ${u}`, E(e)) + return s && Rs.includes(s.tagName) ? s : null; +}).filter((t) => t), Ws = (e) => { + const { element: t, options: s, menu: n } = e, o = e.open ? N : M, i = w(t); + o(i, I, js), o(i, os, js), o(i, Te, ji), o(i, Ro, zi), s.display === "dynamic" && (e.open ? e._observer.observe(n) : e._observer.disconnect()); +}, He = (e) => { + const t = [..._t, "btn-group", "input-group"].map( + (s) => it(`${s} ${p}`, w(e)) ).find((s) => s.length); if (t && t.length) return [...t[0].children].find( - (s) => Lt.some((n) => n === et(s, ot)) + (s) => _t.some((n) => n === et(s, nt)) ); -}, Rs = (e) => { +}, js = (e) => { const { target: t, type: s } = e; - if (t && T(t)) { - const n = Ce(t), o = n && Vt(n); - if (o) { - const { parentElement: i, menu: r } = o, a = i && i.contains(t) && (t.tagName === "form" || k(t, "form") !== null); - [N, wn].includes(s) && Fn(t) && e.preventDefault(), !a && s !== ss && t !== n && t !== r && o.hide(); - } - } -}, ki = (e) => { - const { target: t } = e, s = t && k(t, Wn), n = s && Vt(s); - n && (e.stopPropagation(), n.toggle(), s && Fn(s) && e.preventDefault()); -}, _i = (e) => { - [je, ze].includes(e.code) && e.preventDefault(); + if (!C(t)) return; + const n = He(t), o = n && Kt(n); + if (!o) return; + const { parentElement: i, menu: r } = o, c = i && i.contains(t) && (t.tagName === "form" || _(t, "form") !== null); + [I, yn].includes(s) && Kn(t) && e.preventDefault(), !c && s !== os && t !== n && t !== r && o.hide(); +}, Wi = (e) => { + const { target: t } = e, s = t && _(t, qn), n = s && Kt(s); + n && (e.stopPropagation(), n.toggle(), s && Kn(s) && e.preventDefault()); +}, ji = (e) => { + [Ke, qe].includes(e.code) && e.preventDefault(); }; -function Mi(e) { - const { code: t } = e, s = Ce(this), n = s && Vt(s), { activeElement: o } = s && E(s); - if (n && o) { - const { menu: i, open: r } = n, a = Oi(i); - if (a && a.length && [je, ze].includes(t)) { - let c = a.indexOf(o); - o === s ? c = 0 : t === ze ? c = c > 1 ? c - 1 : 0 : t === je && (c = c < a.length - 1 ? c + 1 : c), a[c] && lt(a[c]); - } - rs === t && r && (n.toggle(), lt(s)); - } +function zi(e) { + const { code: t } = e, s = He(this); + if (!s) return; + const n = Kt(s), { activeElement: o } = w(s); + if (!n || !o) return; + const { menu: i, open: r } = n, c = Fi(i); + if (c && c.length && [Ke, qe].includes(t)) { + let a = c.indexOf(o); + o === s ? a = 0 : t === qe ? a = a > 1 ? a - 1 : 0 : t === Ke && (a = a < c.length - 1 ? a + 1 : a), c[a] && at(c[a]); + } + as === t && r && (n.toggle(), at(s)); } -function Bi(e) { - const t = Ce(e), s = t && Vt(t); - s && s.open && jn(s); +function Vi(e) { + const t = He(e), s = t && Kt(t); + s && s.open && Yn(s); } -class zn extends st { - static selector = Wn; - static init = Ii; - static getInstance = Vt; +class Un extends st { + static selector = qn; + static init = Mi; + static getInstance = Kt; /** * @param target Element or string selector * @param config the instance options */ constructor(t, s) { super(t, s); - const { parentElement: n } = this.element, [o] = rt( - Rn, + const { parentElement: n } = this.element, [o] = it( + Vn, n ); o && (this.parentElement = n, this.menu = o, this._observer = new IntersectionObserver( - ([i]) => Bi(i.target), + ([i]) => Vi(i.target), { threshold: 1 } ), this._toggleEventListeners(!0)); } @@ -867,38 +826,32 @@ class zn extends st { * Returns component name string. */ get name() { - return Bn; + return zn; } /** * Returns component default options. */ get defaults() { - return Ni; + return Bi; } - // DROPDOWN PUBLIC METHODS - // ======================= - /** Shows/hides the dropdown menu to the user. */ toggle() { this.open ? this.hide() : this.show(); } - /** Shows the dropdown menu to the user. */ show() { const { element: t, open: s, menu: n, parentElement: o } = this; - if (!s) { - const i = Ce(t), r = i && Vt(i); - r && r.hide(), [Me, _s, Vn].forEach( - (a) => { - a.relatedTarget = t; - } - ), b(o, Me), Me.defaultPrevented || (h(n, u), h(o, u), O(t, me, "true"), jn(this), this.open = !s, lt(t), Bs(this), b(o, _s)); - } + if (s) return; + const i = He(t), r = i && Kt(i); + r && r.hide(), [Be, Bs, Xn].forEach( + (c) => { + c.relatedTarget = t; + } + ), b(o, Be), !Be.defaultPrevented && (h(n, p), h(o, p), L(t, we, "true"), Yn(this), this.open = !s, at(t), Ws(this), b(o, Bs)); } - /** Hides the dropdown menu from the user. */ hide() { const { element: t, open: s, menu: n, parentElement: o } = this; - s && ([Be, Ms].forEach((i) => { + s && ([Fe, Fs].forEach((i) => { i.relatedTarget = t; - }), b(o, Be), Be.defaultPrevented || (m(n, u), m(o, u), O(t, me, "false"), this.open = !s, Bs(this), b(o, Ms))); + }), b(o, Fe), !Fe.defaultPrevented && (v(n, p), v(o, p), L(t, we, "false"), this.open = !s, Ws(this), b(o, Fs))); } /** * Toggles on/off the `click` event listener of the `Dropdown`. @@ -906,198 +859,193 @@ class zn extends st { * @param add when `true`, it will add the event listener */ _toggleEventListeners = (t) => { - (t ? M : B)(this.element, N, ki); + (t ? N : M)(this.element, I, Wi); }; - /** Removes the `Dropdown` component from the target element. */ dispose() { this.open && this.hide(), this._toggleEventListeners(), super.dispose(); } } -const q = "modal", cs = "Modal", ls = "Offcanvas", Ri = "fixed-top", Fi = "fixed-bottom", Kn = "sticky-top", Un = "position-sticky", Xn = (e) => [ - ...rt(Ri, e), - ...rt(Fi, e), - ...rt(Kn, e), - ...rt(Un, e), - ...rt("is-fixed", e) -], Wi = (e) => { - const t = yt(e); +const X = "modal", ds = "Modal", hs = "Offcanvas", Ki = "fixed-top", qi = "fixed-bottom", Gn = "sticky-top", Zn = "position-sticky", Qn = (e) => [ + ...it(Ki, e), + ...it(qi, e), + ...it(Gn, e), + ...it(Zn, e), + ...it("is-fixed", e) +], Xi = (e) => { + const t = Tt(e); P(t, { paddingRight: "", overflow: "" }); - const s = Xn(t); + const s = Qn(t); s.length && s.forEach((n) => { P(n, { paddingRight: "", marginRight: "" }); }); -}, qn = (e) => { - const { clientWidth: t } = dt(e), { innerWidth: s } = Jo(e); +}, Jn = (e) => { + const { clientWidth: t } = lt(e), { innerWidth: s } = Pn(e); return Math.abs(s - t); -}, Yn = (e, t) => { - const s = yt(e), n = parseInt(z(s, "paddingRight"), 10), i = z(s, "overflow") === "hidden" && n ? 0 : qn(e), r = Xn(s); +}, to = (e, t) => { + const s = Tt(e), n = parseInt(W(s, "paddingRight"), 10), i = W(s, "overflow") === "hidden" && n ? 0 : Jn(e), r = Qn(s); t && (P(s, { overflow: "hidden", paddingRight: `${n + i}px` - }), r.length && r.forEach((a) => { - const c = z(a, "paddingRight"); - if (a.style.paddingRight = `${parseInt(c, 10) + i}px`, [Kn, Un].some((l) => f(a, l))) { - const l = z(a, "marginRight"); - a.style.marginRight = `${parseInt(l, 10) - i}px`; + }), r.length && r.forEach((c) => { + const a = W(c, "paddingRight"); + if (c.style.paddingRight = `${parseInt(a, 10) + i}px`, [Gn, Zn].some((l) => f(c, l))) { + const l = W(c, "marginRight"); + c.style.marginRight = `${parseInt(l, 10) - i}px`; } })); -}, G = "offcanvas", Tt = Et({ +}, Z = "offcanvas", wt = vt({ tagName: "div", className: "popup-container" -}), Zn = (e, t) => { - const s = H(t) && t.nodeName === "BODY", n = H(t) && !s ? t : Tt, o = s ? t : yt(e); - H(e) && (n === Tt && o.append(Tt), n.append(e)); -}, Gn = (e, t) => { - const s = H(t) && t.nodeName === "BODY", n = H(t) && !s ? t : Tt; - H(e) && (e.remove(), n === Tt && !Tt.children.length && Tt.remove()); -}, ds = (e, t) => { - const s = H(t) && t.nodeName !== "BODY" ? t : Tt; - return H(e) && s.contains(e); -}, Jn = "backdrop", Fs = `${q}-${Jn}`, Ws = `${G}-${Jn}`, Qn = `.${q}.${u}`, hs = `.${G}.${u}`, I = Et("div"), Ot = (e) => D( - `${Qn},${hs}`, - E(e) -), fs = (e) => { - const t = e ? Fs : Ws; - [Fs, Ws].forEach((s) => { - m(I, s); - }), h(I, t); -}, to = (e, t, s) => { - fs(s), Zn(I, yt(e)), t && h(I, _); -}, eo = () => { - f(I, u) || (h(I, u), Nt(I)); -}, Se = () => { - m(I, u); -}, so = (e) => { - Ot(e) || (m(I, _), Gn(I, yt(e)), Wi(e)); -}, no = (e) => T(e) && z(e, "visibility") !== "hidden" && e.offsetParent !== null, Vi = `.${q}`, oo = `[${ot}="${q}"]`, ji = `[${$e}="${q}"]`, io = `${q}-static`, zi = { +}), eo = (e, t) => { + const s = D(t) && t.nodeName === "BODY", n = D(t) && !s ? t : wt, o = s ? t : Tt(e); + D(e) && (n === wt && o.append(wt), n.append(e)); +}, so = (e, t) => { + const s = D(t) && t.nodeName === "BODY", n = D(t) && !s ? t : wt; + D(e) && (e.remove(), n === wt && !wt.children.length && wt.remove()); +}, fs = (e, t) => { + const s = D(t) && t.nodeName !== "BODY" ? t : wt; + return D(e) && s.contains(e); +}, no = "backdrop", zs = `${X}-${no}`, Vs = `${Z}-${no}`, oo = `.${X}.${p}`, gs = `.${Z}.${p}`, A = vt("div"), Nt = (e) => S( + `${oo},${gs}`, + w(e) +), us = (e) => { + const t = e ? zs : Vs; + [zs, Vs].forEach((s) => { + v(A, s); + }), h(A, t); +}, io = (e, t, s) => { + us(s), eo(A, Tt(e)), t && h(A, O); +}, ro = () => { + f(A, p) || (h(A, p), Ot(A)); +}, Pe = () => { + v(A, p); +}, co = (e) => { + Nt(e) || (v(A, O), so(A, Tt(e)), Xi(e)); +}, ao = (e) => C(e) && W(e, "visibility") !== "hidden" && e.offsetParent !== null, Yi = `.${X}`, lo = `[${nt}="${X}"]`, Ui = `[${xe}="${X}"]`, ho = `${X}-static`, Gi = { backdrop: !0, keyboard: !0 -}, Qt = (e) => W(e, cs), Ki = (e) => new co(e), pe = w( - `show.bs.${q}` -), Vs = w( - `shown.bs.${q}` -), Re = w( - `hide.bs.${q}` -), js = w( - `hidden.bs.${q}` -), ro = (e) => { - const { element: t } = e, s = qn(t), { clientHeight: n, scrollHeight: o } = dt(t), { clientHeight: i, scrollHeight: r } = t, a = i !== r; - if (!a && s) { +}, se = (e) => j(e, ds), Zi = (e) => new uo(e), ve = $( + `show.bs.${X}` +), Ks = $( + `shown.bs.${X}` +), We = $( + `hide.bs.${X}` +), qs = $( + `hidden.bs.${X}` +), fo = (e) => { + const { element: t } = e, s = Jn(t), { clientHeight: n, scrollHeight: o } = lt(t), { clientHeight: i, scrollHeight: r } = t, c = i !== r; + if (!c && s) { const l = { [$t(t) ? "paddingLeft" : "paddingRight"]: `${s}px` }; P(t, l); } - Yn(t, a || n !== o); -}, ao = (e, t) => { - const s = t ? M : B, { element: n } = e; - s(n, N, qi), s(E(n), Ee, Xi), t ? e._observer.observe(n) : e._observer.disconnect(); -}, zs = (e) => { + to(t, c || n !== o); +}, go = (e, t) => { + const s = t ? N : M, { element: n } = e; + s(n, I, tr), s(w(n), Te, Ji), t ? e._observer.observe(n) : e._observer.disconnect(); +}, Xs = (e) => { const { triggers: t, element: s, relatedTarget: n } = e; - so(s), P(s, { paddingRight: "", display: "" }), ao(e); - const o = pe.relatedTarget || t.find(no); - o && lt(o), js.relatedTarget = n, b(s, js), Te(s); -}, Ks = (e) => { + co(s), P(s, { paddingRight: "", display: "" }), go(e); + const o = ve.relatedTarget || t.find(ao); + o && at(o), qs.relatedTarget = n || void 0, b(s, qs), Ce(s); +}, Ys = (e) => { const { element: t, relatedTarget: s } = e; - lt(t), ao(e, !0), Vs.relatedTarget = s, b(t, Vs), Te(t); + at(t), go(e, !0), Ks.relatedTarget = s || void 0, b(t, Ks), Ce(t); }, Us = (e) => { const { element: t, hasFade: s } = e; - P(t, { display: "block" }), ro(e), Ot(t) || P(yt(t), { overflow: "hidden" }), h(t, u), Pt(t, se), O(t, be, "true"), s ? A(t, () => Ks(e)) : Ks(e); -}, Xs = (e) => { + P(t, { display: "block" }), fo(e), Nt(t) || P(Tt(t), { overflow: "hidden" }), h(t, p), It(t, ie), L(t, $e, "true"), s ? H(t, () => Ys(e)) : Ys(e); +}, Gs = (e) => { const { element: t, options: s, hasFade: n } = e; - s.backdrop && n && f(I, u) && !Ot(t) ? (Se(), A(I, () => zs(e))) : zs(e); -}, Ui = (e) => { - const { target: t } = e, s = t && k(t, oo), n = s && U(s), o = n && Qt(n); + s.backdrop && n && f(A, p) && !Nt(t) ? (Pe(), H(A, () => Xs(e))) : Xs(e); +}, Qi = (e) => { + const { target: t } = e, s = t && _(t, lo), n = s && q(s), o = n && se(n); o && (s && s.tagName === "A" && e.preventDefault(), o.relatedTarget = s, o.toggle()); -}, Xi = ({ code: e, target: t }) => { - const s = D(Qn, E(t)), n = s && Qt(s); - if (n) { - const { options: o } = n; - o.keyboard && e === rs && // the keyboard option is enabled and the key is 27 - f(s, u) && (n.relatedTarget = null, n.hide()); - } -}, qi = (e) => { - const { currentTarget: t } = e, s = t && Qt(t); - if (s && t && !p.get(t)) { - const { options: n, isStatic: o, modalDialog: i } = s, { backdrop: r } = n, { target: a } = e, c = E(t)?.getSelection()?.toString().length, l = i.contains(a), d = a && k(a, ji); - o && !l ? p.set( - t, - () => { - h(t, io), A(i, () => Yi(s)); - }, - 17 - ) : (d || !c && !o && !l && r) && (s.relatedTarget = d || null, s.hide(), e.preventDefault()); - } -}, Yi = (e) => { - const { element: t, modalDialog: s } = e, n = (ie(s) || 0) + 17; - m(t, io), p.set(t, () => p.clear(t), n); +}, Ji = ({ code: e, target: t }) => { + const s = S(oo, w(t)), n = s && se(s); + if (!n) return; + const { options: o } = n; + o.keyboard && e === as && f(s, p) && (n.relatedTarget = null, n.hide()); +}, tr = (e) => { + const { currentTarget: t } = e, s = t && se(t); + if (!s || !t || u.get(t)) return; + const { options: n, isStatic: o, modalDialog: i } = s, { backdrop: r } = n, { target: c } = e, a = w(t)?.getSelection()?.toString().length, l = i.contains(c), d = c && _(c, Ui); + o && !l ? u.set( + t, + () => { + h(t, ho), H(i, () => er(s)); + }, + 17 + ) : (d || !a && !o && !l && r) && (s.relatedTarget = d || null, s.hide(), e.preventDefault()); +}, er = (e) => { + const { element: t, modalDialog: s } = e, n = (ae(s) || 0) + 17; + v(t, ho), u.set(t, () => u.clear(t), n); }; -class co extends st { - static selector = Vi; - static init = Ki; - static getInstance = Qt; +class uo extends st { + static selector = Yi; + static init = Zi; + static getInstance = se; /** * @param target usually the `.modal` element * @param config instance options */ constructor(t, s) { super(t, s); - const { element: n } = this, o = D(`.${q}-dialog`, n); + const { element: n } = this, o = S( + `.${X}-dialog`, + n + ); o && (this.modalDialog = o, this.triggers = [ - ...Z(oo, E(n)) + ...U( + lo, + w(n) + ) ].filter( - (i) => U(i) === n - ), this.isStatic = this.options.backdrop === "static", this.hasFade = f(n, _), this.relatedTarget = null, this._observer = new ResizeObserver(() => this.update()), this._toggleEventListeners(!0)); + (i) => q(i) === n + ), this.isStatic = this.options.backdrop === "static", this.hasFade = f(n, O), this.relatedTarget = null, this._observer = new ResizeObserver(() => this.update()), this._toggleEventListeners(!0)); } /** * Returns component name string. */ get name() { - return cs; + return ds; } /** * Returns component default options. */ get defaults() { - return zi; + return Gi; } - // MODAL PUBLIC METHODS - // ==================== - /** Toggles the visibility of the modal. */ toggle() { - f(this.element, u) ? this.hide() : this.show(); + f(this.element, p) ? this.hide() : this.show(); } - /** Shows the modal to the user. */ show() { const { element: t, options: s, hasFade: n, relatedTarget: o } = this, { backdrop: i } = s; let r = 0; - if (!f(t, u) && (pe.relatedTarget = o || void 0, b(t, pe), !pe.defaultPrevented)) { - const a = Ot(t); - if (a && a !== t) { - const c = Qt(a) || // istanbul ignore next @preserve - W( - a, - ls - ); - c && c.hide(); - } - i ? (ds(I) ? fs(!0) : to(t, n, !0), r = ie(I), eo(), setTimeout(() => Us(this), r)) : (Us(this), a && f(I, u) && Se()); + if (f(t, p) || (ve.relatedTarget = o || void 0, b(t, ve), ve.defaultPrevented)) return; + const c = Nt(t); + if (c && c !== t) { + const a = se(c) || j( + c, + hs + ); + a && a.hide(); } + i ? (fs(A) ? us(!0) : io(t, n, !0), r = ae(A), ro(), setTimeout(() => Us(this), r)) : (Us(this), c && f(A, p) && Pe()); } - /** Hide the modal from the user. */ hide() { const { element: t, hasFade: s, relatedTarget: n } = this; - f(t, u) && (Re.relatedTarget = n || void 0, b(t, Re), Re.defaultPrevented || (m(t, u), O(t, se, "true"), Pt(t, be), s ? A(t, () => Xs(this)) : Xs(this))); + f(t, p) && (We.relatedTarget = n || void 0, b(t, We), !We.defaultPrevented && (v(t, p), L(t, ie, "true"), It(t, $e), s ? H(t, () => Gs(this)) : Gs(this))); } /** * Updates the modal layout. */ update = () => { - f(this.element, u) && ro(this); + f(this.element, p) && fo(this); }; /** * Toggles on/off the `click` event listener of the `Modal` instance. @@ -1105,71 +1053,65 @@ class co extends st { * @param add when `true`, event listener(s) is/are added */ _toggleEventListeners = (t) => { - const s = t ? M : B, { triggers: n } = this; - n.length && n.forEach( - (o) => s(o, N, Ui) - ); + const s = t ? N : M, { triggers: n } = this; + n.length && n.forEach((o) => s(o, I, Qi)); }; - /** Removes the `Modal` component from target element. */ dispose() { const t = { ...this }, { modalDialog: s, hasFade: n } = t, o = () => setTimeout(() => super.dispose(), 17); - this.hide(), this._toggleEventListeners(), n ? A(s, o) : o(); + this.hide(), this._toggleEventListeners(), n ? H(s, o) : o(); } } -const Zi = `.${G}`, gs = `[${ot}="${G}"]`, Gi = `[${$e}="${G}"]`, xe = `${G}-toggling`, Ji = { +const sr = `.${Z}`, ps = `[${nt}="${Z}"]`, nr = `[${xe}="${Z}"]`, De = `${Z}-toggling`, or = { backdrop: !0, - // boolean keyboard: !0, - // boolean scroll: !1 - // boolean -}, te = (e) => W(e, ls), Qi = (e) => new go(e), ue = w(`show.bs.${G}`), lo = w(`shown.bs.${G}`), Fe = w(`hide.bs.${G}`), ho = w(`hidden.bs.${G}`), tr = (e) => { - const { element: t } = e, { clientHeight: s, scrollHeight: n } = dt(t); - Yn(t, s !== n); -}, fo = (e, t) => { - const s = t ? M : B, n = E(e.element); - s(n, Ee, or), s(n, N, nr); -}, qs = (e) => { +}, ne = (e) => j(e, hs), ir = (e) => new bo(e), be = $(`show.bs.${Z}`), po = $(`shown.bs.${Z}`), je = $(`hide.bs.${Z}`), mo = $(`hidden.bs.${Z}`), rr = (e) => { + const { element: t } = e, { clientHeight: s, scrollHeight: n } = lt(t); + to(t, s !== n); +}, vo = (e, t) => { + const s = t ? N : M, n = w(e.element); + s(n, Te, dr), s(n, I, lr); +}, Zs = (e) => { const { element: t, options: s } = e; - s.scroll || (tr(e), P(yt(t), { overflow: "hidden" })), h(t, xe), h(t, u), P(t, { visibility: "visible" }), A(t, () => ir(e)); -}, er = (e) => { - const { element: t, options: s } = e, n = Ot(t); - t.blur(), !n && s.backdrop && f(I, u) && Se(), A(t, () => rr(e)); -}, sr = (e) => { - const t = k(e.target, gs), s = t && U(t), n = s && te(s); - n && (n.relatedTarget = t, n.toggle(), t && t.tagName === "A" && e.preventDefault()); -}, nr = (e) => { - const { target: t } = e, s = D( - hs, - E(t) - ), n = D( - Gi, + s.scroll || (rr(e), P(Tt(t), { overflow: "hidden" })), h(t, De), h(t, p), P(t, { visibility: "visible" }), H(t, () => hr(e)); +}, cr = (e) => { + const { element: t, options: s } = e, n = Nt(t); + t.blur(), !n && s.backdrop && f(A, p) && Pe(), H(t, () => fr(e)); +}, ar = (e) => { + const t = _(e.target, ps), s = t && q(t), n = s && ne(s); + n && (n.relatedTarget = t, n.toggle(), t?.tagName === "A" && e.preventDefault()); +}, lr = (e) => { + const { target: t } = e, s = S( + gs, + w(t) + ); + if (!s) return; + const n = S( + nr, s - ), o = s && te(s); - if (o) { - const { options: i, triggers: r } = o, { backdrop: a } = i, c = k(t, gs), l = E(s).getSelection(); - (!I.contains(t) || a !== "static") && (!(l && l.toString().length) && (!s.contains(t) && a && // istanbul ignore next @preserve - (!c || r.includes(t)) || n && n.contains(t)) && (o.relatedTarget = n && n.contains(t) ? n : null, o.hide()), c && c.tagName === "A" && e.preventDefault()); - } -}, or = ({ code: e, target: t }) => { - const s = D( - hs, - E(t) - ), n = s && te(s); - n && n.options.keyboard && e === rs && (n.relatedTarget = null, n.hide()); -}, ir = (e) => { + ), o = ne(s); + if (!o) return; + const { options: i, triggers: r } = o, { backdrop: c } = i, a = _(t, ps), l = w(s).getSelection(); + A.contains(t) && c === "static" || (!(l && l.toString().length) && (!s.contains(t) && c && (!a || r.includes(t)) || n && n.contains(t)) && (o.relatedTarget = n && n.contains(t) ? n : void 0, o.hide()), a && a.tagName === "A" && e.preventDefault()); +}, dr = ({ code: e, target: t }) => { + const s = S( + gs, + w(t) + ), n = s && ne(s); + n && n.options.keyboard && e === as && (n.relatedTarget = void 0, n.hide()); +}, hr = (e) => { const { element: t } = e; - m(t, xe), Pt(t, se), O(t, be, "true"), O(t, "role", "dialog"), b(t, lo), fo(e, !0), lt(t), Te(t); -}, rr = (e) => { + v(t, De), It(t, ie), L(t, $e, "true"), L(t, "role", "dialog"), b(t, po), vo(e, !0), at(t), Ce(t); +}, fr = (e) => { const { element: t, triggers: s } = e; - O(t, se, "true"), Pt(t, be), Pt(t, "role"), P(t, { visibility: "" }); - const n = ue.relatedTarget || s.find(no); - n && lt(n), so(t), b(t, ho), m(t, xe), Te(t), Ot(t) || fo(e); + L(t, ie, "true"), It(t, $e), It(t, "role"), P(t, { visibility: "" }); + const n = be.relatedTarget || s.find(ao); + n && at(n), co(t), b(t, mo), v(t, De), Ce(t), Nt(t) || vo(e); }; -class go extends st { - static selector = Zi; - static init = Qi; - static getInstance = te; +class bo extends st { + static selector = sr; + static init = ir; + static getInstance = ne; /** * @param target usually an `.offcanvas` element * @param config instance options @@ -1178,50 +1120,46 @@ class go extends st { super(t, s); const { element: n } = this; this.triggers = [ - ...Z(gs, E(n)) + ...U( + ps, + w(n) + ) ].filter( - (o) => U(o) === n - ), this.relatedTarget = null, this._toggleEventListeners(!0); + (o) => q(o) === n + ), this.relatedTarget = void 0, this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return ls; + return hs; } /** * Returns component default options. */ get defaults() { - return Ji; + return or; } - // OFFCANVAS PUBLIC METHODS - // ======================== - /** Shows or hides the offcanvas from the user. */ toggle() { - f(this.element, u) ? this.hide() : this.show(); + f(this.element, p) ? this.hide() : this.show(); } - /** Shows the offcanvas to the user. */ show() { const { element: t, options: s, relatedTarget: n } = this; let o = 0; - if (!f(t, u) && (ue.relatedTarget = n || void 0, lo.relatedTarget = n || void 0, b(t, ue), !ue.defaultPrevented)) { - const i = Ot(t); - if (i && i !== t) { - const r = te(i) || // istanbul ignore next @preserve - W( - i, - cs - ); - r && r.hide(); - } - s.backdrop ? (ds(I) ? fs() : to(t, !0), o = ie(I), eo(), setTimeout(() => qs(this), o)) : (qs(this), i && f(I, u) && Se()); + if (f(t, p) || (be.relatedTarget = n || void 0, po.relatedTarget = n || void 0, b(t, be), be.defaultPrevented)) return; + const i = Nt(t); + if (i && i !== t) { + const r = ne(i) || j( + i, + ds + ); + r && r.hide(); } + s.backdrop ? (fs(A) ? us() : io(t, !0), o = ae(A), ro(), setTimeout(() => Zs(this), o)) : (Zs(this), i && f(A, p) && Pe()); } - /** Hides the offcanvas from the user. */ hide() { const { element: t, relatedTarget: s } = this; - f(t, u) && (Fe.relatedTarget = s || void 0, ho.relatedTarget = s || void 0, b(t, Fe), Fe.defaultPrevented || (h(t, xe), m(t, u), er(this))); + f(t, p) && (je.relatedTarget = s || void 0, mo.relatedTarget = s || void 0, b(t, je), !je.defaultPrevented && (h(t, De), v(t, p), cr(this))); } /** * Toggles on/off the `click` event listeners. @@ -1230,77 +1168,80 @@ class go extends st { * @param add when *true*, listeners are added */ _toggleEventListeners = (t) => { - const s = t ? M : B; + const s = t ? N : M; this.triggers.forEach( - (n) => s(n, N, sr) + (n) => s(n, I, ar) ); }; - /** Removes the `Offcanvas` from the target element. */ dispose() { - const { element: t } = this, s = f(t, u), n = () => setTimeout(() => super.dispose(), 1); - this.hide(), this._toggleEventListeners(), s ? A(t, n) : n(); + const { element: t } = this, s = f(t, p), n = () => setTimeout(() => super.dispose(), 1); + this.hide(), this._toggleEventListeners(), s ? H(t, n) : n(); } } -const At = "popover", De = "Popover", at = "tooltip", po = (e) => { - const t = e === at, s = t ? `${e}-inner` : `${e}-body`, n = t ? "" : `

`, o = `
`, i = `
`; - return `
${n + o + i}
`; -}, uo = { +const kt = "popover", ms = "Popover", rt = "tooltip", wo = (e) => { + const t = e === rt, s = t ? `${e}-inner` : `${e}-body`, n = t ? "" : `

`, o = `
`, i = `
`; + return `
${n + o + i}
`; +}, Eo = { top: "top", bottom: "bottom", left: "start", right: "end" -}, ts = (e) => { - const t = /\b(top|bottom|start|end)+/, { element: s, tooltip: n, container: o, options: i, arrow: r } = e; - if (n) { - const a = { ...uo }, c = $t(s); +}, ss = (e) => { + requestAnimationFrame(() => { + const t = /\b(top|bottom|start|end)+/, { element: s, tooltip: n, container: o, offsetParent: i, options: r, arrow: c } = e; + if (!n) return; + const a = $t(s), { x: l, y: d } = ei(i); P(n, { - // top: '0px', left: '0px', right: '', bottom: '', top: "", left: "", right: "", bottom: "" }); - const l = e.name === De, { offsetWidth: d, offsetHeight: g } = n, { clientWidth: y, clientHeight: S, offsetWidth: R } = dt(s); - let { placement: v } = i; - const { clientWidth: V, offsetWidth: X } = o, it = z( + const { offsetWidth: g, offsetHeight: E } = n, { clientWidth: k, clientHeight: z, offsetWidth: B } = lt(s); + let { placement: m } = r; + const { clientWidth: R, offsetWidth: yt } = o, x = W( o, "position" - ) === "fixed", C = Math.abs(it ? V - X : y - R), Q = c && it ? C : 0, nt = y - (c ? 0 : C) - 1, { - width: F, - height: j, - left: x, - right: _t, - top: ft - } = re(s, !0), { x: L, y: gt } = { - x, - y: ft - }; - P(r, { + ) === "fixed", ht = Math.abs(x ? R - yt : k - B), ot = a && x ? ht : 0, J = k - (a ? 0 : ht) - 1, Mt = e._observer.getEntry(s), { + width: y, + height: V, + left: Rt, + right: F, + top: xt + } = Mt?.boundingClientRect || Et(s, !0), { + x: he, + y: Bt + } = ii( + s, + i, + { x: l, y: d } + ); + P(c, { top: "", left: "", right: "", bottom: "" }); - let Ct = 0, zt = "", pt = 0, He = "", Mt = "", le = "", Ae = ""; - const St = r.offsetWidth || 0, ut = r.offsetHeight || 0, Pe = St / 2; - let Kt = ft - g - ut < 0, Ut = ft + g + j + ut >= S, Xt = x - d - St < Q, qt = x + d + F + St >= nt; - const de = ["left", "right"], Ie = ["top", "bottom"]; - Kt = de.includes(v) ? ft + j / 2 - g / 2 - ut < 0 : Kt, Ut = de.includes(v) ? ft + g / 2 + j / 2 + ut >= S : Ut, Xt = Ie.includes(v) ? x + F / 2 - d / 2 < Q : Xt, qt = Ie.includes(v) ? x + d / 2 + F / 2 >= nt : qt, v = de.includes(v) && Xt && qt ? "top" : v, v = v === "top" && Kt ? "bottom" : v, v = v === "bottom" && Ut ? "top" : v, v = v === "left" && Xt ? "right" : v, v = v === "right" && qt ? "left" : v, n.className.includes(v) || (n.className = n.className.replace( + let St = 0, Xt = "", ft = 0, Ae = "", Ft = "", fe = "", ke = ""; + const Ht = c.offsetWidth || 0, gt = c.offsetHeight || 0, Ie = Ht / 2; + let Yt = xt - E - gt < 0, Ut = xt + E + V + gt >= z, Gt = Rt - g - Ht < ot, Zt = Rt + g + y + Ht >= J; + const ge = ["left", "right"], Le = ["top", "bottom"]; + Yt = ge.includes(m) ? xt + V / 2 - E / 2 - gt < 0 : Yt, Ut = ge.includes(m) ? xt + E / 2 + V / 2 + gt >= z : Ut, Gt = Le.includes(m) ? Rt + y / 2 - g / 2 < ot : Gt, Zt = Le.includes(m) ? Rt + g / 2 + y / 2 >= J : Zt, m = ge.includes(m) && Gt && Zt ? "top" : m, m = m === "top" && Yt ? "bottom" : m, m = m === "bottom" && Ut ? "top" : m, m = m === "left" && Gt ? "right" : m, m = m === "right" && Zt ? "left" : m, n.className.includes(m) || (n.className = n.className.replace( t, - a[v] - )), de.includes(v) ? (v === "left" ? pt = L - d - (l ? St : 0) : pt = L + F + (l ? St : 0), Kt && Ut ? (Ct = 0, zt = 0, Mt = ft + j / 2 - ut / 2) : Kt ? (Ct = gt, zt = "", Mt = j / 2 - St) : Ut ? (Ct = gt - g + j, zt = "", Mt = g - j / 2 - St) : (Ct = gt - g / 2 + j / 2, Mt = g / 2 - ut / 2)) : Ie.includes(v) && (v === "top" ? Ct = gt - g - (l ? ut : 0) : Ct = gt + j + (l ? ut : 0), Xt ? (pt = 0, le = L + F / 2 - Pe) : qt ? (pt = "auto", He = 0, Ae = F / 2 + nt - _t - Pe) : (pt = L - d / 2 + F / 2, le = d / 2 - Pe)), P(n, { - top: `${Ct}px`, - bottom: zt === "" ? "" : `${zt}px`, - left: pt === "auto" ? pt : `${pt}px`, - right: He !== "" ? `${He}px` : "" - }), T(r) && (Mt !== "" && (r.style.top = `${Mt}px`), le !== "" ? r.style.left = `${le}px` : Ae !== "" && (r.style.right = `${Ae}px`)); - const Lo = w( - `updated.bs.${Wt(e.name)}` + Eo[m] + )), ge.includes(m) ? (m === "left" ? ft = he - g - Ht : ft = he + y + Ht, Yt && Ut ? (St = 0, Xt = 0, Ft = Bt + V / 2 - gt / 2) : Yt ? (St = Bt, Xt = "", Ft = V / 2 - Ht) : Ut ? (St = Bt - E + V, Xt = "", Ft = E - V / 2 - Ht) : (St = Bt - E / 2 + V / 2, Ft = E / 2 - gt / 2)) : Le.includes(m) && (m === "top" ? St = Bt - E - gt : St = Bt + V + gt, Gt ? (ft = 0, fe = he + y / 2 - Ie) : Zt ? (ft = "auto", Ae = 0, ke = y / 2 + J - F - Ie) : (ft = he - g / 2 + y / 2, fe = g / 2 - Ie)), P(n, { + top: `${St}px`, + bottom: Xt === "" ? "" : `${Xt}px`, + left: ft === "auto" ? ft : `${ft}px`, + right: Ae !== "" ? `${Ae}px` : "" + }), C(c) && (Ft !== "" && (c.style.top = `${Ft}px`), fe !== "" ? c.style.left = `${fe}px` : ke !== "" && (c.style.right = `${ke}px`)); + const Mo = $( + `updated.bs.${Vt(e.name)}` ); - b(s, Lo); - } -}, es = { - template: po(at), + b(s, Mo); + }); +}, ns = { + template: wo(rt), title: "", customClass: "", trigger: "hover focus", @@ -1312,11 +1253,12 @@ const At = "popover", De = "Popover", at = "tooltip", po = (e) => { content: "", dismissible: !1, btnClose: "" -}, ar = (e) => e != null && typeof e == "object" || !1, cr = (e) => ar(e) && typeof e.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( +}, gr = (e) => e != null && typeof e == "object" || !1, ur = (e) => gr(e) && typeof e.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( (t) => e.nodeType === t -) || !1, Ys = (e) => cr(e) && e.nodeType === 1 || !1, lr = (e) => typeof e == "function" || !1, Zs = "PositionObserver Error"; -class mo { +) || !1, Qs = (e) => ur(e) && e.nodeType === 1 || !1, pr = (e) => typeof e == "function" || !1, mr = "1.0.2", Js = "PositionObserver Error"; +class $o { entries; + static version = mr; _tick; _root; _callback; @@ -1330,256 +1272,291 @@ class mo { * @param options the options of this observer */ constructor(t, s) { - if (!lr(t)) - throw new Error(`${Zs}: ${t} is not a function.`); - this.entries = [], this._callback = t, this._root = Ys(s?.root) ? s.root : document?.documentElement, this._tick = 0; + if (!pr(t)) + throw new Error(`${Js}: ${t} is not a function.`); + this.entries = /* @__PURE__ */ new Map(), this._callback = t, this._root = Qs(s?.root) ? s.root : document?.documentElement, this._tick = 0; } /** * Start observing the position of the specified element. * If the element is not currently attached to the DOM, * it will NOT be added to the entries. - * @param target + * + * @param target an `Element` target */ observe = (t) => { - if (!Ys(t)) + if (!Qs(t)) throw new Error( - `${Zs}: ${t} is not an instance of HTMLElement.` + `${Js}: ${t} is not an instance of Element.` ); - if (!this._root.contains(t)) return; - const { clientWidth: s, clientHeight: n } = this._root, o = t.getBoundingClientRect(), { left: i, top: r, bottom: a, right: c, width: l, height: d } = o, g = r > 1 - d && i > 1 - l && a <= n + d - 1 && c <= s + l - 1; - this.entries.push({ target: t, boundingBox: o, isVisible: g }), this._tick || (this._tick = requestAnimationFrame(this._runCallback)); + this._root.contains(t) && this._new(t).then((s) => { + this.getEntry(t) || this.entries.set(t, s), this._tick || (this._tick = requestAnimationFrame(this._runCallback)); + }); }; /** * Stop observing the position of the specified element. - * @param target + * + * @param target an `HTMLElement` target */ unobserve = (t) => { - const s = this.entries.findIndex((n) => n.target === t); - this.entries.splice(s, 1); + this.entries.has(t) && this.entries.delete(t); }; /** - * Private method responsible for all the heavy duty. + * Private method responsible for all the heavy duty, + * the observer's runtime. */ _runCallback = () => { - if (!this.entries.length) return; - const t = [], { clientWidth: s, clientHeight: n } = this._root; - this.entries.forEach((o, i) => { - const { target: r, boundingBox: a } = o, c = r.getBoundingClientRect(), { left: l, top: d, bottom: g, right: y, width: S, height: R } = c; - if (a.left !== l || a.top !== d || a.right !== y || a.bottom !== g) { - const v = d > 1 - R && l > 1 - S && g <= n + R - 1 && y <= s + S - 1; - this.entries[i].boundingBox = c, this.entries[i].isVisible = v, t.push({ target: r, boundingBox: c, isVisible: v }); - } - }), t.length && this._callback(t), requestAnimationFrame(this._runCallback); + if (!this.entries.size) return; + const t = new Promise((s) => { + const n = []; + this.entries.forEach( + ({ target: o, boundingClientRect: i }) => { + this._root.contains(o) && this._new(o).then(({ boundingClientRect: r, isVisible: c }) => { + const { left: a, top: l, bottom: d, right: g } = r; + if (i.top !== l || i.left !== a || i.right !== g || i.bottom !== d) { + const E = { target: o, boundingClientRect: r, isVisible: c }; + this.entries.set(o, E), n.push(E); + } + }); + } + ), s(n); + }); + this._tick = requestAnimationFrame(async () => { + const s = await t; + s.length && this._callback(s, this), this._runCallback(); + }); + }; + /** + * Calculate the target bounding box and determine + * the value of `isVisible`. + * + * @param target an `Element` target + */ + _new = (t) => { + const { clientWidth: s, clientHeight: n } = this._root; + return new Promise((o) => { + new IntersectionObserver( + ([{ boundingClientRect: i }], r) => { + r.disconnect(); + const { left: c, top: a, bottom: l, right: d, width: g, height: E } = i, k = a > 1 - E && c > 1 - g && l <= n + E - 1 && d <= s + g - 1; + o({ + target: t, + isVisible: k, + boundingClientRect: i + }); + } + ).observe(t); + }); }; + /** + * Find the entry for a given target. + * + * @param target an `HTMLElement` target + */ + getEntry = (t) => this.entries.get(t); /** * Immediately stop observing all elements. */ disconnect = () => { - cancelAnimationFrame(this._tick), this.entries.length = 0, this._tick = 0; + cancelAnimationFrame(this._tick), this.entries.clear(), this._tick = 0; }; } -const vo = "data-original-title", xt = "Tooltip", vt = (e, t, s) => { - if (oe(t) && t.length) { +const To = "data-original-title", Pt = "Tooltip", pt = (e, t, s) => { + if (ce(t) && t.length) { let n = t.trim(); - ti(s) && (n = s(n)); + ci(s) && (n = s(n)); const i = new DOMParser().parseFromString(n, "text/html"); e.append(...i.body.childNodes); - } else T(t) ? e.append(t) : (ei(t) || Qo(t) && t.every(H)) && e.append(...t); -}, dr = (e) => { - const t = e.name === xt, { id: s, element: n, options: o } = e, { + } else C(t) ? e.append(t) : (ai(t) || ri(t) && t.every(D)) && e.append(...t); +}, vr = (e) => { + const t = e.name === Pt, { id: s, element: n, options: o } = e, { title: i, placement: r, - template: a, - animation: c, + template: c, + animation: a, customClass: l, sanitizeFn: d, dismissible: g, - content: y, - btnClose: S - } = o, R = t ? at : At, v = { ...uo }; - let V = [], X = []; - $t(n) && (v.left = "end", v.right = "start"); - const kt = `bs-${R}-${v[r]}`; - let it; - if (T(a)) - it = a; + content: E, + btnClose: k + } = o, z = t ? rt : kt, B = { ...Eo }; + let m = [], R = []; + $t(n) && (B.left = "end", B.right = "start"); + const yt = `bs-${z}-${B[r]}`; + let Ct; + if (C(c)) + Ct = c; else { - const Q = Et("div"); - vt(Q, a, d), it = Q.firstChild; - } - e.tooltip = T(it) ? it.cloneNode(!0) : void 0; - const { tooltip: C } = e; - if (C) { - O(C, "id", s), O(C, "role", at); - const Q = t ? `${at}-inner` : `${At}-body`, nt = t ? null : D(`.${At}-header`, C), F = D(`.${Q}`, C); - e.arrow = D(`.${R}-arrow`, C); - const { arrow: j } = e; - if (T(i)) V = [i.cloneNode(!0)]; - else { - const x = Et("div"); - vt(x, i, d), V = [...x.childNodes]; - } - if (T(y)) X = [y.cloneNode(!0)]; - else { - const x = Et("div"); - vt(x, y, d), X = [...x.childNodes]; - } - if (g) - if (i) - if (T(S)) - V = [...V, S.cloneNode(!0)]; - else { - const x = Et("div"); - vt(x, S, d), V = [...V, x.firstChild]; - } - else if (nt && nt.remove(), T(S)) - X = [...X, S.cloneNode(!0)]; + const y = vt("div"); + pt(y, c, d), Ct = y.firstChild; + } + if (!C(Ct)) return; + e.tooltip = Ct.cloneNode(!0); + const { tooltip: x } = e; + L(x, "id", s), L(x, "role", rt); + const ht = t ? `${rt}-inner` : `${kt}-body`, ot = t ? null : S(`.${kt}-header`, x), J = S(`.${ht}`, x); + e.arrow = S( + `.${z}-arrow`, + x + ); + const { arrow: Mt } = e; + if (C(i)) m = [i.cloneNode(!0)]; + else { + const y = vt("div"); + pt(y, i, d), m = [...y.childNodes]; + } + if (C(E)) R = [E.cloneNode(!0)]; + else { + const y = vt("div"); + pt(y, E, d), R = [...y.childNodes]; + } + if (g) + if (i) + if (C(k)) + m = [...m, k.cloneNode(!0)]; else { - const x = Et("div"); - vt(x, S, d), X = [...X, x.firstChild]; + const y = vt("div"); + pt(y, k, d), m = [...m, y.firstChild]; } - t ? i && F && vt(F, i, d) : (i && nt && vt(nt, V, d), y && F && vt(F, X, d), e.btn = D(".btn-close", C) || void 0), h(C, "position-fixed"), h(j, "position-absolute"), f(C, R) || h(C, R), c && !f(C, _) && h(C, _), l && !f(C, l) && h(C, l), f(C, kt) || h(C, kt); - } -}, hr = (e) => { + else if (ot && ot.remove(), C(k)) + R = [...R, k.cloneNode(!0)]; + else { + const y = vt("div"); + pt(y, k, d), R = [...R, y.firstChild]; + } + t ? i && J && pt(J, i, d) : (i && ot && pt(ot, m, d), E && J && pt(J, R, d), e.btn = S(".btn-close", x) || void 0), h(x, "position-absolute"), h(Mt, "position-absolute"), f(x, z) || h(x, z), a && !f(x, O) && h(x, O), l && !f(x, l) && h(x, l), f(x, yt) || h(x, yt); +}, br = (e) => { const t = ["HTML", "BODY"], s = []; let { parentNode: n } = e; for (; n && !t.includes(n.nodeName); ) - n = Go(n), yn(n) || si(n) || s.push(n); - return s.find((o, i) => z(o, "position") !== "relative" && s.slice(i + 1).every( - (r) => z(r, "position") === "static" - ) ? o : null) || // istanbul ignore next: optional guard - E(e).body; -}, fr = `[${ot}="${at}"],[data-tip="${at}"]`, bo = "title"; -let Gs = (e) => W(e, xt); -const gr = (e) => new ps(e), pr = (e) => { - const { element: t, tooltip: s, container: n, offsetParent: o } = e; - Pt(t, bn), Gn( + n = si(n), Hn(n) || ni(n) || s.push(n); + return s.find((o, i) => (W(o, "position") !== "relative" || W(o, "position") === "relative" && o.offsetHeight !== o.scrollHeight) && s.slice(i + 1).every( + (r) => W(r, "position") === "static" + ) ? o : null) || w(e).body; +}, wr = `[${nt}="${rt}"],[data-tip="${rt}"]`, yo = "title"; +let tn = (e) => j(e, Pt); +const Er = (e) => new vs(e), $r = (e) => { + const { element: t, tooltip: s, container: n } = e; + It(t, $n), so( s, - n === o ? n : o + n ); -}, Yt = (e) => { - const { tooltip: t, container: s, offsetParent: n } = e; - return t && ds(t, s === n ? s : n); -}, ur = (e, t) => { +}, Qt = (e) => { + const { tooltip: t, container: s } = e; + return t && fs(t, s); +}, Tr = (e, t) => { const { element: s } = e; - e._toggleEventListeners(), Gt(s, vo) && e.name === xt && wo(e), t && t(); -}, Eo = (e, t) => { - const s = t ? M : B, { element: n } = e; + e._toggleEventListeners(), te(s, To) && e.name === Pt && xo(e), t && t(); +}, Co = (e, t) => { + const s = t ? N : M, { element: n } = e; s( - E(n), - is, + w(n), + cs, e.handleTouch, - Jt + ee ); -}, Js = (e) => { - const { element: t } = e, s = w( - `shown.bs.${Wt(e.name)}` +}, en = (e) => { + const { element: t } = e, s = $( + `shown.bs.${Vt(e.name)}` ); - Eo(e, !0), b(t, s), p.clear(t, "in"); -}, Qs = (e) => { - const { element: t } = e, s = w( - `hidden.bs.${Wt(e.name)}` + Co(e, !0), b(t, s), u.clear(t, "in"); +}, sn = (e) => { + const { element: t } = e, s = $( + `hidden.bs.${Vt(e.name)}` ); - Eo(e), pr(e), b(t, s), p.clear(t, "out"); -}, tn = (e, t) => { - const s = t ? M : B, { element: n } = e, o = k(n, `.${q}`), i = k(n, `.${G}`); - t ? e._observer.observe(e.element) : e._observer.disconnect(), o && s(o, `hide.bs.${q}`, e.handleHide), i && s(i, `hide.bs.${G}`, e.handleHide); -}, wo = (e, t) => { - const s = [vo, bo], { element: n } = e; - O( + Co(e), $r(e), b(t, s), u.clear(t, "out"); +}, nn = (e, t) => { + const s = t ? N : M, { element: n, tooltip: o } = e, i = _(n, `.${X}`), r = _(n, `.${Z}`); + t ? [n, o].forEach((c) => e._observer.observe(c)) : e._observer.disconnect(), i && s(i, `hide.bs.${X}`, e.handleHide), r && s(r, `hide.bs.${Z}`, e.handleHide); +}, xo = (e, t) => { + const s = [To, yo], { element: n } = e; + L( n, s[t ? 0 : 1], - t || et(n, s[0]) || // istanbul ignore next @preserve - "" - ), Pt(n, s[t ? 1 : 0]); + t || et(n, s[0]) || "" + ), It(n, s[t ? 1 : 0]); }; -class ps extends st { - static selector = fr; - static init = gr; - static getInstance = Gs; - static styleTip = ts; +class vs extends st { + static selector = wr; + static init = Er; + static getInstance = tn; + static styleTip = ss; /** * @param target the target element * @param config the instance options */ constructor(t, s) { super(t, s); - const { element: n } = this, o = this.name === xt, i = o ? at : At, r = o ? xt : De; - Gs = (c) => W(c, r), this.enabled = !0, this.id = `${i}-${Cn(n, i)}`; - const { options: a } = this; - !a.title && o || !o && !a.content || (ct(es, { titleAttr: "" }), Gt(n, bo) && o && typeof a.title == "string" && wo(this, a.title), this.container = hr(n), this.offsetParent = ["sticky", "fixed"].some( - (c) => z(this.container, "position") === c - ) ? this.container : E(this.element).body, dr(this), this._observer = new mo(() => this.update()), this._toggleEventListeners(!0)); + const { element: n } = this, o = this.name === Pt, i = o ? rt : kt, r = o ? Pt : ms; + tn = (d) => j(d, r), this.enabled = !0, this.id = `${i}-${An(n, i)}`; + const { options: c } = this; + if (!c.title && o || !o && !c.content) + return; + ct(ns, { titleAttr: "" }), te(n, yo) && o && typeof c.title == "string" && xo(this, c.title); + const a = br(n), l = ["sticky", "fixed", "relative"].some( + (d) => W(a, "position") === d + ) ? a : Pn(n); + this.container = a, this.offsetParent = l, vr(this), this.tooltip && (this._observer = new $o((d) => { + d.some((g) => g.isVisible) && this.update(); + }), this._toggleEventListeners(!0)); } /** * Returns component name string. */ get name() { - return xt; + return Pt; } /** * Returns component default options. */ get defaults() { - return es; - } - // TOOLTIP PUBLIC METHODS - // ====================== - /** Handles the focus event on iOS. */ - // istanbul ignore next @preserve - impossible to test without Apple device - handleFocus = () => lt(this.element); - /** Shows the tooltip. */ + return ns; + } + handleFocus = () => at(this.element); handleShow = () => this.show(); show() { - const { options: t, tooltip: s, element: n, container: o, offsetParent: i, id: r } = this, { animation: a } = t, c = p.get(n, "out"), l = o === i ? o : i; - p.clear(n, "out"), s && !c && !Yt(this) && p.set( + const { options: t, tooltip: s, element: n, container: o, id: i } = this, { animation: r } = t, c = u.get(n, "out"); + u.clear(n, "out"), s && !c && !Qt(this) && u.set( n, () => { - const d = w( - `show.bs.${Wt(this.name)}` + const a = $( + `show.bs.${Vt(this.name)}` ); - b(n, d), d.defaultPrevented || (Zn(s, l), O(n, bn, `#${r}`), this.update(), tn(this, !0), f(s, u) || h(s, u), a ? A(s, () => Js(this)) : Js(this)); + b(n, a), a.defaultPrevented || (eo(s, o), L(n, $n, `#${i}`), this.update(), nn(this, !0), f(s, p) || h(s, p), r ? H(s, () => en(this)) : en(this)); }, 17, "in" ); } - /** Hides the tooltip. */ handleHide = () => this.hide(); hide() { const { options: t, tooltip: s, element: n } = this, { animation: o, delay: i } = t; - p.clear(n, "in"), s && Yt(this) && p.set( + u.clear(n, "in"), s && Qt(this) && u.set( n, () => { - const r = w( - `hide.bs.${Wt(this.name)}` + const r = $( + `hide.bs.${Vt(this.name)}` ); - b(n, r), r.defaultPrevented || (this.update(), m(s, u), tn(this), o ? A(s, () => Qs(this)) : Qs(this)); + b(n, r), r.defaultPrevented || (this.update(), v(s, p), nn(this), o ? H(s, () => sn(this)) : sn(this)); }, i + 17, "out" ); } - /** Updates the tooltip position. */ update = () => { - ts(this); + ss(this); }; - /** Toggles the tooltip visibility. */ toggle = () => { const { tooltip: t } = this; - t && !Yt(this) ? this.show() : this.hide(); + t && !Qt(this) ? this.show() : this.hide(); }; - /** Enables the tooltip. */ enable() { const { enabled: t } = this; t || (this._toggleEventListeners(!0), this.enabled = !t); } - /** Disables the tooltip. */ disable() { const { tooltip: t, enabled: s } = this; - s && (t && Yt(this) && this.hide(), this._toggleEventListeners(), this.enabled = !s); + s && (t && Qt(this) && this.hide(), this._toggleEventListeners(), this.enabled = !s); } - /** Toggles the `disabled` property. */ toggleEnabled() { this.enabled ? this.disable() : this.enable(); } @@ -1599,36 +1576,35 @@ class ps extends st { * @param add when `true`, event listeners are added */ _toggleEventListeners = (t) => { - const s = t ? M : B, { element: n, options: o, btn: i } = this, { trigger: r } = o, c = !!(this.name !== xt && o.dismissible); + const s = t ? N : M, { element: n, options: o, btn: i } = this, { trigger: r } = o, a = !!(this.name !== Pt && o.dismissible); r.includes("manual") || (this.enabled = !!t, r.split(" ").forEach((d) => { - d === Oo ? (s(n, wn, this.handleShow), s(n, we, this.handleShow), c || (s(n, os, this.handleHide), s( - E(n), - is, + d === Bo ? (s(n, yn, this.handleShow), s(n, ye, this.handleShow), a || (s(n, rs, this.handleHide), s( + w(n), + cs, this.handleTouch, - Jt - ))) : d === N ? s(n, d, c ? this.handleShow : this.toggle) : d === ss && (s(n, ns, this.handleShow), c || s(n, En, this.handleHide), Vo() && s(n, N, this.handleFocus)), c && i && s(i, N, this.handleHide); + ee + ))) : d === I ? s(n, d, a ? this.handleShow : this.toggle) : d === os && (s(n, is, this.handleShow), a || s(n, Tn, this.handleHide), Xo() && s(n, I, this.handleFocus)), a && i && s(i, I, this.handleHide); })); }; - /** Removes the `Tooltip` from the target element. */ dispose() { const { tooltip: t, options: s } = this, n = { ...this, name: this.name }, o = () => setTimeout( - () => ur(n, () => super.dispose()), + () => Tr(n, () => super.dispose()), 17 ); - s.animation && Yt(n) ? (this.options.delay = 0, this.hide(), A(t, o)) : o(); + s.animation && Qt(n) ? (this.options.delay = 0, this.hide(), H(t, o)) : o(); } } -const mr = `[${ot}="${At}"],[data-tip="${At}"]`, vr = ct({}, es, { - template: po(At), +const yr = `[${nt}="${kt}"],[data-tip="${kt}"]`, Cr = ct({}, ns, { + template: wo(kt), content: "", dismissible: !1, btnClose: '' -}), br = (e) => W(e, De), Er = (e) => new To(e); -class To extends ps { - static selector = mr; - static init = Er; - static getInstance = br; - static styleTip = ts; +}), xr = (e) => j(e, ms), Sr = (e) => new So(e); +class So extends vs { + static selector = yr; + static init = Sr; + static getInstance = xr; + static styleTip = ss; /** * @param target the target element * @param config the instance options @@ -1640,222 +1616,224 @@ class To extends ps { * Returns component name string. */ get name() { - return De; + return ms; } /** * Returns component default options. */ get defaults() { - return vr; + return Cr; } - /* extend original `show()` */ show = () => { super.show(); const { options: t, btn: s } = this; - t.dismissible && s && setTimeout(() => lt(s), 17); + t.dismissible && s && setTimeout(() => at(s), 17); }; } -const wr = "scrollspy", $o = "ScrollSpy", Tr = '[data-bs-spy="scroll"]', $r = { +const Hr = "scrollspy", Ho = "ScrollSpy", Pr = '[data-bs-spy="scroll"]', Dr = { offset: 10, - target: null -}, yr = (e) => W(e, $o), Cr = (e) => new Co(e), en = w(`activate.bs.${wr}`), Sr = (e) => { - const { target: t, scrollTarget: s, options: n, itemsLength: o, scrollHeight: i, element: r } = e, { offset: a } = n, c = s !== r, l = t && as("A", t), d = E(r), g = s.scrollHeight; - if (e.scrollTop = s.scrollTop, l && (g !== i || o !== l.length)) { - let y, S, R; - e.items = [], e.targets = [], e.offsets = [], e.scrollHeight = g, e.maxScroll = e.scrollHeight - Dr(e), Array.from(l).forEach((v) => { - y = et(v, "href"), S = y && y.charAt(0) === "#" && y.slice(-1) !== "#" && D(y, d), S && (e.items.push(v), e.targets.push(S), R = re(S), e.offsets.push( - (c ? R.top + e.scrollTop : S.offsetTop) - a + target: void 0 +}, Ar = (e) => j(e, Ho), kr = (e) => new Do(e), on = $(`activate.bs.${Hr}`), Ir = (e) => { + const { + target: t, + scrollTarget: s, + options: n, + itemsLength: o, + scrollHeight: i, + element: r, + _observer: c + } = e, { offset: a } = n, l = s !== r, d = t && ls("A", t), g = w(r), E = s.scrollHeight; + if (e.scrollTop = s.scrollTop, d && (E !== i || o !== d.length)) { + let k, z, B, m; + e.items = [], e.targets = [], e.offsets = [], e.scrollHeight = E, e.maxScroll = e.scrollHeight - _r(e), Array.from(d).forEach((R) => { + k = et(R, "href"), z = k?.slice(1), B = z?.length ? g.getElementById(z) : null, B && (e.items.push(R), e.targets.push(B), m = c?.getEntry(B)?.boundingClientRect || Et(B), e.offsets.push( + (l ? m.top + e.scrollTop : B.offsetTop) - a )); }), e.itemsLength = e.items.length; } -}, sn = ({ targets: e, scrollTarget: t, element: s, _observer: n }, o) => { - o ? t === s ? e.forEach((i) => n.observe(i)) : n.observe(s) : n.disconnect(); -}, xr = (e) => e.scrollHeight, Dr = ({ element: e, scrollTarget: t }) => t !== e ? t.clientHeight : re(e).height, yo = (e) => { - [...as("A", e)].forEach((t) => { - f(t, $) && m(t, $); - }); -}, nn = (e, t) => { +}, rn = ({ targets: e, scrollTarget: t, element: s, _observer: n }, o) => { + o ? t === s ? e?.forEach((i) => n.observe(i)) : n.observe(s) : n.disconnect(); +}, Lr = (e) => e.scrollHeight, _r = ({ element: e, scrollTarget: t }) => t !== e ? t.clientHeight : Et(e).height, Po = (e) => { + Array.from(ls("A", e)).forEach( + (t) => { + f(t, T) && v(t, T); + } + ); +}, cn = (e, t) => { const { target: s, element: n } = e; - T(s) && yo(s), e.activeItem = t, h(t, $); + C(s) && Po(s), e.activeItem = t, h(t, T); const o = []; let i = t; - for (; i !== yt(n); ) + for (; i !== Tt(n); ) i = i.parentElement, (f(i, "nav") || f(i, "dropdown-menu")) && o.push(i); o.forEach((r) => { - const a = r.previousElementSibling; - a && !f(a, $) && h(a, $); - }), en.relatedTarget = t, b(n, en); + const c = r.previousElementSibling; + c && !f(c, T) && h(c, T); + }), on.relatedTarget = t, b(n, on); }; -class Co extends st { - static selector = Tr; - static init = Cr; - static getInstance = yr; +class Do extends st { + static selector = Pr; + static init = kr; + static getInstance = Ar; /** * @param target the target element * @param config the instance options */ constructor(t, s) { super(t, s); - const { element: n, options: o } = this; - this.target = D( + const { element: n, options: o } = this, i = S( o.target, - E(n) - ), this.target && (this.scrollTarget = n.clientHeight < n.scrollHeight ? n : dt(n), this.scrollHeight = xr(this.scrollTarget), this.refresh(), this._observer = new mo(() => this.refresh(), { + w(n) + ); + i && (this.target = i, this.scrollTarget = n.clientHeight < n.scrollHeight ? n : lt(n), this.scrollHeight = Lr(this.scrollTarget), this.refresh(), this._observer = new $o((r) => { + requestAnimationFrame(() => { + r.some((c) => c.isVisible) && this.refresh(); + }); + }, { root: this.scrollTarget - }), sn(this, !0)); + }), rn(this, !0)); } - /* eslint-disable */ /** * Returns component name string. */ get name() { - return $o; + return Ho; } /** * Returns component default options. */ get defaults() { - return $r; + return Dr; } - /* eslint-enable */ - // SCROLLSPY PUBLIC METHODS - // ======================== - /** Updates all items. */ refresh = () => { const { target: t } = this; - if (T(t) && t.offsetHeight > 0) { - Sr(this); - const { scrollTop: s, maxScroll: n, itemsLength: o, items: i, activeItem: r } = this; - if (s >= n) { - const c = i[o - 1]; - r !== c && nn(this, c); - return; - } - const { offsets: a } = this; - if (r && s < a[0] && a[0] > 0) { - this.activeItem = null, t && yo(t); - return; - } - i.forEach((c, l) => { - r !== c && s >= a[l] && (typeof a[l + 1] > "u" || s < a[l + 1]) && nn(this, c); - }); + if (!C(t) || t.offsetHeight === 0) return; + Ir(this); + const { scrollTop: s, maxScroll: n, itemsLength: o, items: i, activeItem: r } = this; + if (s >= n) { + const a = i[o - 1]; + r !== a && cn(this, a); + return; } + const { offsets: c } = this; + if (r && s < c[0] && c[0] > 0) { + this.activeItem = null, t && Po(t); + return; + } + i.forEach((a, l) => { + r !== a && s >= c[l] && (typeof c[l + 1] > "u" || s < c[l + 1]) && cn(this, a); + }); }; - /** Removes `ScrollSpy` from the target element. */ dispose() { const t = { ...this }; - sn(t), super.dispose(); + rn(t), super.dispose(); } } -const ce = "tab", So = "Tab", on = `[${ot}="${ce}"]`, xo = (e) => W(e, So), Hr = (e) => new Do(e), We = w( - `show.bs.${ce}` -), rn = w( - `shown.bs.${ce}` -), Ve = w( - `hide.bs.${ce}` -), an = w( - `hidden.bs.${ce}` -), ee = /* @__PURE__ */ new Map(), cn = (e) => { +const de = "tab", Ao = "Tab", an = `[${nt}="${de}"]`, ko = (e) => j(e, Ao), Or = (e) => new Io(e), ze = $( + `show.bs.${de}` +), ln = $( + `shown.bs.${de}` +), Ve = $( + `hide.bs.${de}` +), dn = $( + `hidden.bs.${de}` +), oe = /* @__PURE__ */ new Map(), hn = (e) => { const { tabContent: t, nav: s } = e; - t && f(t, It) && (t.style.height = "", m(t, It)), s && p.clear(s); -}, ln = (e) => { - const { element: t, tabContent: s, content: n, nav: o } = e, { tab: i } = T(o) && ee.get(o) || // istanbul ignore next @preserve - { tab: null }; - if (s && n && f(n, _)) { - const { currentHeight: r, nextHeight: a } = ee.get(t) || // istanbul ignore next @preserve - { currentHeight: 0, nextHeight: 0 }; - r !== a ? setTimeout(() => { - s.style.height = `${a}px`, Nt(s), A(s, () => cn(e)); - }, 50) : cn(e); - } else o && p.clear(o); - rn.relatedTarget = i, b(t, rn); -}, dn = (e) => { - const { element: t, content: s, tabContent: n, nav: o } = e, { tab: i, content: r } = o && ee.get(o) || // istanbul ignore next @preserve - { tab: null, content: null }; - let a = 0; - if (n && s && f(s, _) && ([r, s].forEach((c) => { - T(c) && h(c, "overflow-hidden"); - }), a = T(r) ? r.scrollHeight : 0), We.relatedTarget = i, an.relatedTarget = t, b(t, We), !We.defaultPrevented) { - if (s && h(s, $), r && m(r, $), n && s && f(s, _)) { - const c = s.scrollHeight; - ee.set(t, { - currentHeight: a, - nextHeight: c, + t && f(t, Lt) && (t.style.height = "", v(t, Lt)), s && u.clear(s); +}, fn = (e) => { + const { element: t, tabContent: s, content: n, nav: o } = e, { tab: i } = C(o) && oe.get(o) || { tab: null }; + if (s && n && f(n, O)) { + const { currentHeight: r, nextHeight: c } = oe.get(t) || { currentHeight: 0, nextHeight: 0 }; + r !== c ? setTimeout(() => { + s.style.height = `${c}px`, Ot(s), H(s, () => hn(e)); + }, 50) : hn(e); + } else o && u.clear(o); + ln.relatedTarget = i, b(t, ln); +}, gn = (e) => { + const { element: t, content: s, tabContent: n, nav: o } = e, { tab: i, content: r } = o && oe.get(o) || { tab: null, content: null }; + let c = 0; + if (n && s && f(s, O) && ([r, s].forEach((a) => { + a && h(a, "overflow-hidden"); + }), c = r ? r.scrollHeight : 0), ze.relatedTarget = i, dn.relatedTarget = t, b(t, ze), !ze.defaultPrevented) { + if (s && h(s, T), r && v(r, T), n && s && f(s, O)) { + const a = s.scrollHeight; + oe.set(t, { + currentHeight: c, + nextHeight: a, tab: null, content: null - }), h(n, It), n.style.height = `${a}px`, Nt(n), [r, s].forEach((l) => { - l && m(l, "overflow-hidden"); + }), h(n, Lt), n.style.height = `${c}px`, Ot(n), [r, s].forEach((l) => { + l && v(l, "overflow-hidden"); }); } - s && s && f(s, _) ? setTimeout(() => { - h(s, u), A(s, () => { - ln(e); + s && s && f(s, O) ? setTimeout(() => { + h(s, p), H(s, () => { + fn(e); }); - }, 1) : (s && h(s, u), ln(e)), i && b(i, an); + }, 1) : (s && h(s, p), fn(e)), i && b(i, dn); } -}, hn = (e) => { +}, un = (e) => { const { nav: t } = e; - if (!T(t)) + if (!C(t)) return { tab: null, content: null }; - const s = rt($, t); + const s = it( + T, + t + ); let n = null; - s.length === 1 && !Lt.some( + s.length === 1 && !_t.some( (i) => f(s[0].parentElement, i) ) ? [n] = s : s.length > 1 && (n = s[s.length - 1]); - const o = T(n) ? U(n) : null; + const o = C(n) ? q(n) : null; return { tab: n, content: o }; -}, fn = (e) => { - if (!T(e)) return null; - const t = k(e, `.${Lt.join(",.")}`); - return t ? D(`.${Lt[0]}-toggle`, t) : null; -}, Ar = (e) => { - const t = xo(e.target); - t && (e.preventDefault(), t.show()); +}, pn = (e) => { + if (!C(e)) return null; + const t = _(e, `.${_t.join(",.")}`); + return t ? S(`.${_t[0]}-toggle`, t) : null; +}, Nr = (e) => { + const t = ko(e.target); + e.preventDefault(), t && t.show(); }; -class Do extends st { - static selector = on; - static init = Hr; - static getInstance = xo; - /** @param target the target element */ +class Io extends st { + static selector = an; + static init = Or; + static getInstance = ko; constructor(t) { super(t); - const { element: s } = this, n = U(s); - if (n) { - const o = k(s, ".nav"), i = k(n, ".tab-content"); - this.nav = o, this.content = n, this.tabContent = i, this.dropdown = fn(s); - const { tab: r } = hn(this); - if (o && !r) { - const a = D(on, o), c = a && U(a); - c && (h(a, $), h(c, u), h(c, $), O(s, Le, "true")); - } - this._toggleEventListeners(!0); + const { element: s } = this, n = q(s); + if (!n) return; + const o = _(s, ".nav"), i = _( + n, + ".tab-content" + ); + this.nav = o, this.content = n, this.tabContent = i, this.dropdown = pn(s); + const { tab: r } = un(this); + if (o && !r) { + const c = S(an, o), a = c && q(c); + a && (h(c, T), h(a, p), h(a, T), L(s, _e, "true")); } + this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return So; + return Ao; } - // TAB PUBLIC METHODS - // ================== - /** Shows the tab to the user. */ show() { const { element: t, content: s, nav: n, dropdown: o } = this; - if (!(n && p.get(n)) && !f(t, $)) { - const { tab: i, content: r } = hn(this); - if (n && ee.set(n, { tab: i, content: r, currentHeight: 0, nextHeight: 0 }), Ve.relatedTarget = t, T(i) && (b(i, Ve), !Ve.defaultPrevented)) { - h(t, $), O(t, Le, "true"); - const a = T(i) && fn(i); - if (a && f(a, $) && m(a, $), n) { - const c = () => { - i && (m(i, $), O(i, Le, "false")), o && !f(o, $) && h(o, $); - }; - r && (f(r, _) || s && f(s, _)) ? p.set(n, c, 1) : c(); - } - r && (m(r, u), f(r, _) ? A(r, () => dn(this)) : dn(this)); - } + if (n && u.get(n) || f(t, T)) return; + const { tab: i, content: r } = un(this); + if (n && i && oe.set(n, { tab: i, content: r, currentHeight: 0, nextHeight: 0 }), Ve.relatedTarget = t, !C(i) || (b(i, Ve), Ve.defaultPrevented)) return; + h(t, T), L(t, _e, "true"); + const c = C(i) && pn(i); + if (c && f(c, T) && v(c, T), n) { + const a = () => { + i && (v(i, T), L(i, _e, "false")), o && !f(o, T) && h(o, T); + }; + r && (f(r, O) || s && f(s, O)) ? u.set(n, a, 1) : a(); } + r && (v(r, p), f(r, O) ? H(r, () => gn(this)) : gn(this)); } /** * Toggles on/off the `click` event listener. @@ -1863,55 +1841,54 @@ class Do extends st { * @param add when `true`, event listener is added */ _toggleEventListeners = (t) => { - (t ? M : B)(this.element, N, Ar); + (t ? N : M)(this.element, I, Nr); }; - /** Removes the `Tab` component from the target element. */ dispose() { this._toggleEventListeners(), super.dispose(); } } -const J = "toast", Ho = "Toast", Pr = `.${J}`, Ir = `[${$e}="${J}"]`, Ao = `[${ot}="${J}"]`, jt = "showing", Po = "hide", Lr = { +const Q = "toast", Lo = "Toast", Mr = `.${Q}`, Rr = `[${xe}="${Q}"]`, _o = `[${nt}="${Q}"]`, qt = "showing", Oo = "hide", Br = { animation: !0, autohide: !0, delay: 5e3 -}, us = (e) => W(e, Ho), Nr = (e) => new Io(e), gn = w( - `show.bs.${J}` -), Or = w( - `shown.bs.${J}` -), pn = w( - `hide.bs.${J}` -), kr = w( - `hidden.bs.${J}` -), un = (e) => { +}, bs = (e) => j(e, Lo), Fr = (e) => new No(e), mn = $( + `show.bs.${Q}` +), Wr = $( + `shown.bs.${Q}` +), vn = $( + `hide.bs.${Q}` +), jr = $( + `hidden.bs.${Q}` +), bn = (e) => { const { element: t, options: s } = e; - m(t, jt), p.clear(t, jt), b(t, Or), s.autohide && p.set(t, () => e.hide(), s.delay, J); -}, mn = (e) => { + v(t, qt), u.clear(t, qt), b(t, Wr), s.autohide && u.set(t, () => e.hide(), s.delay, Q); +}, wn = (e) => { const { element: t } = e; - m(t, jt), m(t, u), h(t, Po), p.clear(t, J), b(t, kr); -}, _r = (e) => { + v(t, qt), v(t, p), h(t, Oo), u.clear(t, Q), b(t, jr); +}, zr = (e) => { const { element: t, options: s } = e; - h(t, jt), s.animation ? (Nt(t), A(t, () => mn(e))) : mn(e); -}, Mr = (e) => { + h(t, qt), s.animation ? (Ot(t), H(t, () => wn(e))) : wn(e); +}, Vr = (e) => { const { element: t, options: s } = e; - p.set( + u.set( t, () => { - m(t, Po), Nt(t), h(t, u), h(t, jt), s.animation ? A(t, () => un(e)) : un(e); + v(t, Oo), Ot(t), h(t, p), h(t, qt), s.animation ? H(t, () => bn(e)) : bn(e); }, 17, - jt + qt ); -}, Br = (e) => { - const { target: t } = e, s = t && k(t, Ao), n = s && U(s), o = n && us(n); +}, Kr = (e) => { + const { target: t } = e, s = t && _(t, _o), n = s && q(s), o = n && bs(n); o && (s && s.tagName === "A" && e.preventDefault(), o.relatedTarget = s, o.show()); -}, Rr = (e) => { - const t = e.target, s = us(t), { type: n, relatedTarget: o } = e; - s && t !== o && !t.contains(o) && ([we, ns].includes(n) ? p.clear(t, J) : p.set(t, () => s.hide(), s.options.delay, J)); +}, qr = (e) => { + const t = e.target, s = bs(t), { type: n, relatedTarget: o } = e; + !s || t === o || t.contains(o) || ([ye, is].includes(n) ? u.clear(t, Q) : u.set(t, () => s.hide(), s.options.delay, Q)); }; -class Io extends st { - static selector = Pr; - static init = Nr; - static getInstance = us; +class No extends st { + static selector = Mr; + static init = Fr; + static getInstance = bs; /** * @param target the target `.toast` element * @param config the instance options @@ -1919,41 +1896,40 @@ class Io extends st { constructor(t, s) { super(t, s); const { element: n, options: o } = this; - o.animation && !f(n, _) ? h(n, _) : !o.animation && f(n, _) && m(n, _), this.dismiss = D(Ir, n), this.triggers = [ - ...Z(Ao, E(n)) + o.animation && !f(n, O) ? h(n, O) : !o.animation && f(n, O) && v(n, O), this.dismiss = S(Rr, n), this.triggers = [ + ...U( + _o, + w(n) + ) ].filter( - (i) => U(i) === n + (i) => q(i) === n ), this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return Ho; + return Lo; } /** * Returns component default options. */ get defaults() { - return Lr; + return Br; } /** * Returns *true* when toast is visible. */ get isShown() { - return f(this.element, u); + return f(this.element, p); } - // TOAST PUBLIC METHODS - // ==================== - /** Shows the toast. */ show = () => { const { element: t, isShown: s } = this; - t && !s && (b(t, gn), gn.defaultPrevented || Mr(this)); + !t || s || (b(t, mn), mn.defaultPrevented || Vr(this)); }; - /** Hides the toast. */ hide = () => { const { element: t, isShown: s } = this; - t && s && (b(t, pn), pn.defaultPrevented || _r(this)); + !t || !s || (b(t, vn), vn.defaultPrevented || zr(this)); }; /** * Toggles on/off the `click` event listener. @@ -1961,73 +1937,72 @@ class Io extends st { * @param add when `true`, it will add the listener */ _toggleEventListeners = (t) => { - const s = t ? M : B, { element: n, triggers: o, dismiss: i, options: r, hide: a } = this; - i && s(i, N, a), r.autohide && [ns, En, we, os].forEach( - (c) => s(n, c, Rr) + const s = t ? N : M, { element: n, triggers: o, dismiss: i, options: r, hide: c } = this; + i && s(i, I, c), r.autohide && [is, Tn, ye, rs].forEach( + (a) => s(n, a, qr) ), o.length && o.forEach( - (c) => s(c, N, Br) + (a) => s(a, I, Kr) ); }; - /** Removes the `Toast` component from the target element. */ dispose() { const { element: t, isShown: s } = this; - this._toggleEventListeners(), p.clear(t, J), s && m(t, u), super.dispose(); + this._toggleEventListeners(), u.clear(t, Q), s && v(t, p), super.dispose(); } } -const ms = /* @__PURE__ */ new Map(); +const ws = /* @__PURE__ */ new Map(); [ - An, - In, - On, - Mn, - zn, - co, - go, - To, - Co, + _n, + Nn, + Bn, + jn, + Un, + uo, + bo, + So, Do, Io, - ps -].forEach((e) => ms.set(e.prototype.name, e)); -const Fr = (e, t) => { + No, + vs +].forEach((e) => ws.set(e.prototype.name, e)); +const Xr = (e, t) => { [...t].forEach((s) => e(s)); -}, Wr = (e, t) => { +}, Yr = (e, t) => { const s = Dt.getAllFor(e); s && [...s].forEach(([n, o]) => { t.contains(n) && o.dispose(); }); -}, vn = (e) => { - const t = e && e.nodeName ? e : document, s = [...as("*", t)]; - ms.forEach((n) => { +}, En = (e) => { + const t = e && e.nodeName ? e : document, s = [...ls("*", t)]; + ws.forEach((n) => { const { init: o, selector: i } = n; - Fr( + Xr( o, - s.filter((r) => xn(r, i)) + s.filter((r) => Dn(r, i)) ); }); -}, Vr = (e) => { +}, Ur = (e) => { const t = e && e.nodeName ? e : document; - ms.forEach((s) => { - Wr(s.prototype.name, t); + ws.forEach((s) => { + Yr(s.prototype.name, t); }); }; -document.body ? vn() : M(document, "DOMContentLoaded", () => vn(), { +document.body ? En() : N(document, "DOMContentLoaded", () => En(), { once: !0 }); export { - An as Alert, - In as Button, - On as Carousel, - Mn as Collapse, - zn as Dropdown, - co as Modal, - go as Offcanvas, - To as Popover, - Co as ScrollSpy, - Do as Tab, - Io as Toast, - ps as Tooltip, - vn as initCallback, - Vr as removeDataAPI + _n as Alert, + Nn as Button, + Bn as Carousel, + jn as Collapse, + Un as Dropdown, + uo as Modal, + bo as Offcanvas, + So as Popover, + Do as ScrollSpy, + Io as Tab, + No as Toast, + vs as Tooltip, + En as initCallback, + Ur as removeDataAPI }; //# sourceMappingURL=bootstrap-native.mjs.map diff --git a/dist/bootstrap-native.mjs.map b/dist/bootstrap-native.mjs.map index 447c6b02..c5145b04 100644 --- a/dist/bootstrap-native.mjs.map +++ b/dist/bootstrap-native.mjs.map @@ -1 +1 @@ -{"version":3,"file":"bootstrap-native.mjs","sources":["../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.6/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@0.0.3/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const e = {}, f = (t) => {\n const { type: c, currentTarget: i } = t;\n [...e[c]].forEach(([n, s]) => {\n /* istanbul ignore else @preserve */\n i === n && [...s].forEach(([o, a]) => {\n o.apply(n, [t]), typeof a == \"object\" && a.once && r(n, c, o, a);\n });\n });\n}, E = (t, c, i, n) => {\n /* istanbul ignore else @preserve */\n e[c] || (e[c] = /* @__PURE__ */ new Map());\n const s = e[c];\n /* istanbul ignore else @preserve */\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(t), { size: a } = o;\n o.set(i, n);\n /* istanbul ignore else @preserve */\n a || t.addEventListener(c, f, n);\n}, r = (t, c, i, n) => {\n const s = e[c], o = s && s.get(t), a = o && o.get(i), d = a !== void 0 ? a : n;\n /* istanbul ignore else @preserve */\n o && o.has(i) && o.delete(i);\n /* istanbul ignore else @preserve */\n s && (!o || !o.size) && s.delete(t);\n /* istanbul ignore else @preserve */\n (!s || !s.size) && delete e[c];\n /* istanbul ignore else @preserve */\n (!o || !o.size) && t.removeEventListener(\n c,\n f,\n d\n );\n}, g = E, M = r;\nexport {\n E as addListener,\n f as globalListener,\n M as off,\n g as on,\n e as registry,\n r as removeListener\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: HTMLElement) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: ScrollSpyOptions = {\n offset: 10,\n target: null,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: HTMLElement) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: HTMLElement) => Component,\n collection: HTMLCollectionOf | HTMLElement[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","f","t","c","i","s","o","a","r","E","d","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","version","BaseComponent","prevInstance","alertSelector","alertDismissSelector","getAlertInstance","alertInitCallback","Alert","closeAlertEvent","closedAlertEvent","alertTransitionEnd","self","add","action","addListener","removeListener","dismiss","close","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","isActive","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","attValue","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","activeItem","getActiveIndex","orientation","directionClass","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","RTL","carouselDragHandler","carouselPointerDownHandler","controls","indicators","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","activeIndex","transitionItem","ar","isPaused","idx","next","eventProperties","touch","pause","interval","keyboard","arrow","indicator","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","triggers","btn","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","menuEnd","p","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","targetLeft","targetTop","targetWidth","targetHeight","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","dropdownPreventScroll","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","dropdownClickHandler","activeElement","open","menuItems","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","fixedItems","fixed","measureScrollbar","innerWidth","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","appendPopup","customContainer","containerIsBody","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","afterModalShow","beforeModalShow","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","overlayDelay","currentOpen","that","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","tipPositions","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","tooltipDefaults","_","B","m","n","h","l","u","b","g","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","tempDocument","createTip","id","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","position","PositionObserver","outTimer","tipContainer","showTooltipEvent","hideTooltipEvent","enabled","tr","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","isRoot","links","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","_observer","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","scrollTop","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","context","compData","initCallback","lookUp","elemCollection","cs","init","removeDataAPI","comp"],"mappings":"AAAK,MAAqEA,KAAkB,oBAAoBC,KAAe,iBAAiDC,KAAa,eAA6EC,KAAY,cAAcC,KA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C3B,IAAAR;AAAA,MACES;AAAA,MACAF,EAAe,OAAO,CAACvE,MAAS7b,GAAQ6b,GAAMhf,CAAQ,CAAC;AAAA,IACzD;AAAA,EAAA,CACD;AACH,GAOa0jB,KAAgB,CAACP,MAAyB;AACrD,QAAMG,IAASH,KAAWA,EAAQ,WAAWA,IAAU;AAExC,EAAAJ,GAAA,QAAQ,CAACY,MAAS;AACR,IAAAT,GAAAS,EAAK,UAAU,MAAML,CAAM;AAAA,EAAA,CACnD;AACH;AAGI,SAAS,OAAmBD,GAAA,IAE9Bne,EAAY,UAAU,oBAAoB,MAAMme,GAAA,GAAgB;AAAA,EAC9D,MAAM;AAAA,CACP;","x_google_ignoreList":[0,1,52]} \ No newline at end of file +{"version":3,"file":"bootstrap-native.mjs","sources":["../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.8/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@https+++codeload.github.com+thednp+position-observer+tar.gz+d693d53_hyk7lpzuqi6vnifksl6nzudy5a/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const g = \"2.0.8\", e = {}, f = (t) => {\n const { type: n, currentTarget: c } = t;\n e[n].forEach((a, s) => {\n c === s && a.forEach((o, i) => {\n i.apply(s, [t]), typeof o == \"object\" && o.once && r(s, n, i, o);\n });\n });\n}, E = (t, n, c, a) => {\n e[n] || (e[n] = /* @__PURE__ */ new Map());\n const s = e[n];\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(\n t\n ), { size: i } = o;\n o.set(c, a), i || t.addEventListener(\n n,\n f,\n a\n );\n}, r = (t, n, c, a) => {\n const s = e[n], o = s && s.get(t), i = o && o.get(c), d = i !== void 0 ? i : a;\n o && o.has(c) && o.delete(c), s && (!o || !o.size) && s.delete(t), (!s || !s.size) && delete e[n], (!o || !o.size) && t.removeEventListener(\n n,\n f,\n d\n );\n}, M = E, p = r;\nexport {\n E as addListener,\n f as globalListener,\n p as off,\n M as on,\n e as registry,\n r as removeListener,\n g as version\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: Element) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: Element) => Component,\n collection: HTMLCollectionOf | Element[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","n","o","s","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","u","h","O","to","k","G","K","d","N","oe","q","g","ae","ie","ro","r","a","i","io","P","T","ue","lo","f","c","p","E","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop","alertSelector","alertDismissSelector","getAlertInstance","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","hasClass","removeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","setAttribute","ariaPressed","isActive","getAttribute","addClass","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","doc","getDocument","att","attValue","closest","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","options","activeItem","getActiveIndex","orientation","directionClass","Timer","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","code","querySelectorAll","isElementInScrollRange","RTL","isRTL","keyArrowRight","keyArrowLeft","carouselDragHandler","carouselPointerDownHandler","controls","indicators","el","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","pointermoveEvent","passiveHandler","pointerupEvent","isHTMLElement","getElementsByClassName","activeIndex","transitionItem","matches","ar","isPaused","idx","next","eventProperties","ObjectAssign","getElementTransitionDuration","reflow","touch","pause","interval","keyboard","mouseenterEvent","mouseleaveEvent","pointerdownEvent","touchstartEvent","dragstartEvent","arrow","indicator","keydownEvent","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","parent","triggers","noop","setElementStyle","btn","ariaExpanded","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","hasAttribute","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","getElementStyle","menuEnd","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","clientHeight","getDocumentElement","targetLeft","targetTop","targetWidth","targetHeight","getBoundingClientRect","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","focusEvent","dropdownPreventScroll","keyupEvent","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","mousedownEvent","dropdownClickHandler","keyArrowDown","keyArrowUp","activeElement","open","menuItems","focus","keyEscape","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","getDocumentBody","fixedItems","fixed","measureScrollbar","innerWidth","getWindow","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","createElement","appendPopup","customContainer","containerIsBody","isNode","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","toggleFocusTrap","afterModalShow","beforeModalShow","removeAttribute","ariaHidden","ariaModal","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","duration","overlayDelay","currentOpen","that","callback","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","offsetParent","scrollLeft","scrollTop","getNodeScroll","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","toLowerCase","tooltipDefaults","_","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","isFunction","tempDocument","isNodeList","isArray","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","ariaDescribedBy","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","getUID","position","PositionObserver","entries","outTimer","showTooltipEvent","delay","hideTooltipEvent","enabled","tr","mousehoverEvent","focusinEvent","focusoutEvent","isApple","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","_observer","isRoot","links","getElementsByTagName","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","spyTarget","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","ariaSelected","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","component","context","compData","instance","initCallback","lookUp","elemCollection","cs","init","selector","removeDataAPI","comp"],"mappings":"AAAK,MAA6DA,KAAK,oBAAoBC,KAAK,iBAAuCC,KAAI,eAA0DC,KAAK,cAAcC,KAAK,gBAAgBC,KAAK,iBAAwPC,KAAK,SAASC,KAAK,WAAWC,KAAK,YAA0EC,KAAK,WAA4BC,KAAK,SAAsBC,IAAK,SAA0BC,KAAK,aAA6BC,KAAK,SAASC,KAAK,cAAcC,KAAK,cAAmKC,KAAK,eAAoCC,KAAK,eAAeC,KAAK,aAAsJC,KAAK,cAmD1mCC,KAAK,aAUuBC,KAAK,qFAoBlCC,KAAK,aAAaC,KAAK,WAAWC,KAAK,aAAaC,KAAK,cAAkHC,KAAK,UAAyMC,KAAK,sBAAsBC,KAAK,mBAAmBC,KAAI,iBAAiBC,KAAI,sBA+BjdC,KAAK,MAAM;AACZ,QAAMC,IAAI;AACV,SAAO,WAAW,eAAe,OAAO;AAAA,IACtC,CAACC,MAAMD,EAAE,KAAKC,EAAE,KAAK;AAAA,EACtB,KAAID,EAAE;AAAA,IACL,WAAW;AAAA,EACZ,KAAI;AACP,GAA2PE,KAAK,MAAM;AACtQ,GAAGC,KAAI,CAACH,GAAGC,GAAGG,GAAGC,MAAM;AACrB,QAAMC,IAAID,KAAK;AACf,EAAAL,EAAE;AAAA,IACAC;AAAA,IACAG;AAAA,IACAE;AAAA,EACD;AACH,GAAGC,KAAI,CAACP,GAAGC,GAAGG,GAAGC,MAAM;AACrB,QAAMC,IAAID,KAAK;AACf,EAAAL,EAAE;AAAA,IACAC;AAAA,IACAG;AAAA,IACAE;AAAA,EACD;AACH,GAesUE,KAAI,CAACR,GAAGC,MAAMD,EAAE,aAAaC,CAAC,GAA6CQ,KAAK,CAACT,GAAGC,MAAMD,EAAE,aAAaC,CAAC,GAA6CS,I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EW;AAAA,MACAF,EAAe,OAAO,CAAC1E,MAASnZ,GAAQmZ,GAAM6E,CAAQ,CAAC;AAAA,IACzD;AAAA,EAAA,CACD;AACH,GAOaC,KAAgB,CAACT,MAAyB;AACrD,QAAMI,IAASJ,KAAWA,EAAQ,WAAWA,IAAU;AAExC,EAAAL,GAAA,QAAQ,CAACe,MAAS;AACR,IAAAZ,GAAAY,EAAK,UAAU,MAAMN,CAAM;AAAA,EAAA,CACnD;AACH;AAGI,SAAS,OAAmBD,GAAA,IAE9B9iB,EAAY,UAAU,oBAAoB,MAAM8iB,GAAA,GAAgB;AAAA,EAC9D,MAAM;AAAA,CACP;","x_google_ignoreList":[0,1,52]} \ No newline at end of file diff --git a/dist/components/alert.cjs b/dist/components/alert.cjs index 0b461f2d..626292ce 100644 --- a/dist/components/alert.cjs +++ b/dist/components/alert.cjs @@ -1,2 +1,2 @@ -"use strict";const s=require("./base-component-D3rSrWwH.js"),i=require("./event-listener-W3RGkfJ6.js"),h=require("./fadeClass-Co6nOzNJ.js"),r=require("./showClass-D_Ms1FgG.js"),v=require("./dataBsDismiss-CMHF7If_.js"),n="alert",l="Alert",C=`.${n}`,E=`[${v.dataBsDismiss}="${n}"]`,g=t=>s.getInstance(t,l),p=t=>new d(t),c=s.createCustomEvent(`close.bs.${n}`),q=s.createCustomEvent(`closed.bs.${n}`),a=t=>{const{element:e}=t;s.dispatchEvent(e,q),t._toggleEventListeners(),t.dispose(),e.remove()};class d extends s.BaseComponent{static selector=C;static init=p;static getInstance=g;dismiss;constructor(e){super(e),this.dismiss=s.querySelector(E,this.element),this._toggleEventListeners(!0)}get name(){return l}close=()=>{const{element:e}=this;e&&s.hasClass(e,r.showClass)&&(s.dispatchEvent(e,c),c.defaultPrevented||(s.removeClass(e,r.showClass),s.hasClass(e,h.fadeClass)?s.emulateTransitionEnd(e,()=>a(this)):a(this)))};_toggleEventListeners=e=>{const m=e?i.E:i.r,{dismiss:o,close:u}=this;o&&m(o,s.mouseclickEvent,u)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=d; +"use strict";const e=require("./base-component-DaZCwW-u.js"),i=require("./event-listener-BQdA_KAC.js"),u=require("./fadeClass-Co6nOzNJ.js"),r=require("./showClass-D_Ms1FgG.js"),h=require("./dataBsDismiss-CMHF7If_.js"),n="alert",a="Alert",v=`.${n}`,p=`[${h.dataBsDismiss}="${n}"]`,C=t=>e.to(t,a),E=t=>new d(t),c=e.vo(`close.bs.${n}`),q=e.vo(`closed.bs.${n}`),l=t=>{const{element:s}=t;e.q(s,q),t._toggleEventListeners(),t.dispose(),s.remove()};class d extends e.BaseComponent{static selector=v;static init=E;static getInstance=C;dismiss;constructor(s){super(s),this.dismiss=e.Ro(p,this.element),this._toggleEventListeners(!0)}get name(){return a}close=()=>{const{element:s}=this;s&&e.Yn(s,r.showClass)&&(e.q(s,c),c.defaultPrevented||(e.Zn(s,r.showClass),e.Yn(s,u.fadeClass)?e.ro(s,()=>l(this)):l(this)))};_toggleEventListeners=s=>{const m=s?i.E:i.r,{dismiss:o,close:g}=this;o&&m(o,e.mt,g)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=d; //# sourceMappingURL=alert.cjs.map diff --git a/dist/components/alert.cjs.map b/dist/components/alert.cjs.map index 2f51fc2f..0b7e6b5e 100644 --- a/dist/components/alert.cjs.map +++ b/dist/components/alert.cjs.map @@ -1 +1 @@ -{"version":3,"file":"alert.cjs","sources":["../../src/strings/alertString.ts","../../src/strings/alertComponent.ts","../../src/components/alert.ts"],"sourcesContent":["/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["alertString","alertComponent","alertSelector","alertDismissSelector","dataBsDismiss","getAlertInstance","element","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","BaseComponent","target","querySelector","hasClass","showClass","removeClass","fadeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent"],"mappings":"0NACMA,EAAc,QCAdC,EAAiB,QCyBjBC,EAAgB,IAAIF,CAAW,GAC/BG,EAAuB,IAAIC,EAAAA,aAAa,KAAKJ,CAAW,KAMxDK,EAAoBC,GACxBC,cAAmBD,EAASL,CAAc,EAKtCO,EAAqBF,GAAyB,IAAIG,EAAMH,CAAO,EAI/DI,EAAkBC,EAAA,kBACtB,YAAYX,CAAW,EACzB,EACMY,EAAmBD,EAAA,kBACvB,aAAaX,CAAW,EAC1B,EASMa,EAAsBC,GAAgB,CACpC,KAAA,CAAE,QAAAR,GAAYQ,EACpBC,EAAA,cAAcT,EAASM,CAAgB,EAEvCE,EAAK,sBAAsB,EAC3BA,EAAK,QAAQ,EACbR,EAAQ,OAAO,CACjB,EAKA,MAAqBG,UAAcO,EAAAA,aAAc,CAC/C,OAAO,SAAWd,EAClB,OAAO,KAAOM,EACd,OAAO,YAAcH,EACrB,QAEA,YAAYY,EAA8B,CACxC,MAAMA,CAAM,EAGZ,KAAK,QAAUC,EAAAA,cAAcf,EAAsB,KAAK,OAAO,EAG/D,KAAK,sBAAsB,EAAI,CAAA,CAIjC,IAAI,MAAO,CACF,OAAAF,CAAA,CAUT,MAAQ,IAAM,CACN,KAAA,CAAE,QAAAK,GAAY,KAGhBA,GAAWa,EAAAA,SAASb,EAASc,EAAS,SAAA,IACxCL,EAAA,cAAcT,EAASI,CAAe,EAEjCA,EAAgB,mBACnBW,EAAA,YAAYf,EAASc,WAAS,EAE1BD,EAAA,SAASb,EAASgB,EAAAA,SAAS,EAC7BC,EAAAA,qBAAqBjB,EAAS,IAAMO,EAAmB,IAAI,CAAC,IACpC,IAAI,GAGpC,EAMA,sBAAyBW,GAAkB,CACnC,MAAAC,EAASD,EAAME,EAAAA,EAAcC,EAAA,EAC7B,CAAE,QAAAC,EAAS,MAAAC,CAAA,EAAU,KAEvBD,GAASH,EAAOG,EAASE,EAAAA,gBAAiBD,CAAK,CACrD,EAGA,SAAU,CACR,KAAK,sBAAsB,EAC3B,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file +{"version":3,"file":"alert.cjs","sources":["../../src/strings/alertString.ts","../../src/strings/alertComponent.ts","../../src/components/alert.ts"],"sourcesContent":["/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["alertString","alertComponent","alertSelector","alertDismissSelector","dataBsDismiss","getAlertInstance","element","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","BaseComponent","target","querySelector","hasClass","showClass","removeClass","fadeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent"],"mappings":"0NACMA,EAAc,QCAdC,EAAiB,QCyBjBC,EAAgB,IAAIF,CAAW,GAC/BG,EAAuB,IAAIC,EAAAA,aAAa,KAAKJ,CAAW,KAMxDK,EAAoBC,GACxBC,KAAmBD,EAASL,CAAc,EAKtCO,EAAqBF,GAAqB,IAAIG,EAAMH,CAAO,EAI3DI,EAAkBC,EAAA,GACtB,YAAYX,CAAW,EACzB,EACMY,EAAmBD,EAAA,GACvB,aAAaX,CAAW,EAC1B,EASMa,EAAsBC,GAAgB,CACpC,KAAA,CAAE,QAAAR,GAAYQ,EACpBC,EAAA,EAAcT,EAASM,CAAgB,EAEvCE,EAAK,sBAAsB,EAC3BA,EAAK,QAAQ,EACbR,EAAQ,OAAO,CACjB,EAKA,MAAqBG,UAAcO,EAAAA,aAAc,CAC/C,OAAO,SAAWd,EAClB,OAAO,KAAOM,EACd,OAAO,YAAcH,EACrB,QAEA,YAAYY,EAA0B,CACpC,MAAMA,CAAM,EAGZ,KAAK,QAAUC,EAAA,GACbf,EACA,KAAK,OACP,EAGA,KAAK,sBAAsB,EAAI,CAAA,CAIjC,IAAI,MAAO,CACF,OAAAF,CAAA,CAUT,MAAQ,IAAM,CACN,KAAA,CAAE,QAAAK,GAAY,KAGhBA,GAAWa,EAAAA,GAASb,EAASc,EAAS,SAAA,IACxCL,EAAA,EAAcT,EAASI,CAAe,EAEjCA,EAAgB,mBACnBW,EAAA,GAAYf,EAASc,WAAS,EAE1BD,EAAA,GAASb,EAASgB,EAAAA,SAAS,EAC7BC,EAAAA,GAAqBjB,EAAS,IAAMO,EAAmB,IAAI,CAAC,IACpC,IAAI,GAGpC,EAMA,sBAAyBW,GAAkB,CACnC,MAAAC,EAASD,EAAME,EAAAA,EAAcC,EAAA,EAC7B,CAAE,QAAAC,EAAS,MAAAC,CAAA,EAAU,KAEvBD,GAASH,EAAOG,EAASE,EAAAA,GAAiBD,CAAK,CACrD,EAGA,SAAU,CACR,KAAK,sBAAsB,EAC3B,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file diff --git a/dist/components/alert.d.ts b/dist/components/alert.d.ts index 4081c201..14b86132 100644 --- a/dist/components/alert.d.ts +++ b/dist/components/alert.d.ts @@ -1,10 +1,10 @@ /** Creates a new Alert instance. */ declare class Alert extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Alert; - static getInstance: (element: HTMLElement) => Alert | null; + static init: (element: Element) => Alert; + static getInstance: (element: Element) => Alert | null; dismiss: HTMLElement | null; - constructor(target: HTMLElement | string); + constructor(target: Element | string); /** Returns component name string. */ get name(): string; /** @@ -26,13 +26,13 @@ export default Alert; /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; diff --git a/dist/components/alert.mjs b/dist/components/alert.mjs index f80e276b..94340f40 100644 --- a/dist/components/alert.mjs +++ b/dist/components/alert.mjs @@ -1,30 +1,30 @@ -import { B as p, q as h, h as o, d as c, r as v, e as E, g as f, c as l, m as u } from "./base-component-ylZzLp-h.mjs"; -import { E as C, r as A } from "./event-listener-C1-Yf9Z5.mjs"; +import { B as g, R as f, Y as n, q as l, Z as v, r as h, t as E, v as c, m as u } from "./base-component-Jx2aafTJ.mjs"; +import { E as A, r as C } from "./event-listener-CUwvA4j6.mjs"; import { f as $ } from "./fadeClass-CLIYI_zn.mjs"; import { s as i } from "./showClass-C8hdJfjQ.mjs"; -import { d as I } from "./dataBsDismiss-DdNPQYa-.mjs"; -const e = "alert", m = "Alert", L = `.${e}`, S = `[${I}="${e}"]`, _ = (t) => f(t, m), b = (t) => new k(t), r = l( +import { d as L } from "./dataBsDismiss-DdNPQYa-.mjs"; +const e = "alert", m = "Alert", _ = `.${e}`, b = `[${L}="${e}"]`, B = (t) => E(t, m), I = (t) => new w(t), r = c( `close.bs.${e}` -), B = l( +), S = c( `closed.bs.${e}` ), a = (t) => { const { element: s } = t; - c(s, B), t._toggleEventListeners(), t.dispose(), s.remove(); + l(s, S), t._toggleEventListeners(), t.dispose(), s.remove(); }; -class k extends p { - static selector = L; - static init = b; - static getInstance = _; +class w extends g { + static selector = _; + static init = I; + static getInstance = B; dismiss; constructor(s) { - super(s), this.dismiss = h(S, this.element), this._toggleEventListeners(!0); + super(s), this.dismiss = f( + b, + this.element + ), this._toggleEventListeners(!0); } - /** Returns component name string. */ get name() { return m; } - // ALERT PUBLIC METHODS - // ==================== /** * Public method that hides the `.alert` element from the user, * disposes the instance once animation is complete, then @@ -32,7 +32,7 @@ class k extends p { */ close = () => { const { element: s } = this; - s && o(s, i) && (c(s, r), r.defaultPrevented || (v(s, i), o(s, $) ? E(s, () => a(this)) : a(this))); + s && n(s, i) && (l(s, r), r.defaultPrevented || (v(s, i), n(s, $) ? h(s, () => a(this)) : a(this))); }; /** * Toggle on / off the `click` event listener. @@ -40,15 +40,14 @@ class k extends p { * @param add when `true`, event listener is added */ _toggleEventListeners = (s) => { - const d = s ? C : A, { dismiss: n, close: g } = this; - n && d(n, u, g); + const d = s ? A : C, { dismiss: o, close: p } = this; + o && d(o, u, p); }; - /** Remove the component from target element. */ dispose() { this._toggleEventListeners(), super.dispose(); } } export { - k as default + w as default }; //# sourceMappingURL=alert.mjs.map diff --git a/dist/components/alert.mjs.map b/dist/components/alert.mjs.map index 3c91a4c8..d06c03df 100644 --- a/dist/components/alert.mjs.map +++ b/dist/components/alert.mjs.map @@ -1 +1 @@ -{"version":3,"file":"alert.mjs","sources":["../../src/strings/alertString.ts","../../src/strings/alertComponent.ts","../../src/components/alert.ts"],"sourcesContent":["/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["alertString","alertComponent","alertSelector","alertDismissSelector","dataBsDismiss","getAlertInstance","element","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","BaseComponent","target","querySelector","hasClass","showClass","removeClass","fadeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent"],"mappings":";;;;;AACA,MAAMA,IAAc,SCAdC,IAAiB,SCyBjBC,IAAgB,IAAIF,CAAW,IAC/BG,IAAuB,IAAIC,CAAa,KAAKJ,CAAW,MAMxDK,IAAmB,CAACC,MACxBC,EAAmBD,GAAS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3,"file":"alert.mjs","sources":["../../src/strings/alertString.ts","../../src/strings/alertComponent.ts","../../src/components/alert.ts"],"sourcesContent":["/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["alertString","alertComponent","alertSelector","alertDismissSelector","dataBsDismiss","getAlertInstance","element","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","BaseComponent","target","querySelector","hasClass","showClass","removeClass","fadeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent"],"mappings":";;;;;AACA,MAAMA,IAAc,SCAdC,IAAiB,SCyBjBC,IAAgB,IAAIF,CAAW,IAC/BG,IAAuB,IAAIC,CAAa,KAAKJ,CAAW,MAMxDK,IAAmB,CAACC,MACxBC,EAAmBD,GAASL,CAAc,GAKtCO,IAAoB,CAACF,MAAqB,IAAIG,EAAMH,CAAO,GAI3DI,IAAkBC;AAAAA,EACtB,YAAYX,CAAW;AACzB,GACMY,IAAmBD;AAAAA,EACvB,aAAaX,CAAW;AAC1B,GASMa,IAAqB,CAACC,MAAgB;AACpC,QAAA,EAAE,SAAAR,MAAYQ;AACpBC,EAAAA,EAAcT,GAASM,CAAgB,GAEvCE,EAAK,sBAAsB,GAC3BA,EAAK,QAAQ,GACbR,EAAQ,OAAO;AACjB;AAKA,MAAqBG,UAAcO,EAAc;AAAA,EAC/C,OAAO,WAAWd;AAAA,EAClB,OAAO,OAAOM;AAAA,EACd,OAAO,cAAcH;AAAA,EACrB;AAAA,EAEA,YAAYY,GAA0B;AACpC,UAAMA,CAAM,GAGZ,KAAK,UAAUC;AAAAA,MACbf;AAAA,MACA,KAAK;AAAA,IACP,GAGA,KAAK,sBAAsB,EAAI;AAAA,EAAA;AAAA,EAIjC,IAAI,OAAO;AACF,WAAAF;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAUT,QAAQ,MAAM;AACN,UAAA,EAAE,SAAAK,MAAY;AAGpB,IAAIA,KAAWa,EAASb,GAASc,CAAS,MACxCL,EAAcT,GAASI,CAAe,GAEjCA,EAAgB,qBACnBW,EAAYf,GAASc,CAAS,GAE1BD,EAASb,GAASgB,CAAS,IAC7BC,EAAqBjB,GAAS,MAAMO,EAAmB,IAAI,CAAC,MACpC,IAAI;AAAA,EAGpC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAMA,wBAAwB,CAACW,MAAkB;AACnC,UAAAC,IAASD,IAAME,IAAcC,GAC7B,EAAE,SAAAC,GAAS,OAAAC,EAAA,IAAU;AAE3B,IAAID,KAASH,EAAOG,GAASE,GAAiBD,CAAK;AAAA,EACrD;AAAA,EAGA,UAAU;AACR,SAAK,sBAAsB,GAC3B,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file diff --git a/dist/components/base-component-D3rSrWwH.js b/dist/components/base-component-D3rSrWwH.js deleted file mode 100644 index 78e5a614..00000000 --- a/dist/components/base-component-D3rSrWwH.js +++ /dev/null @@ -1,2 +0,0 @@ -"use strict";const _="aria-describedby",X="aria-expanded",F="aria-hidden",Y="aria-modal",G="aria-pressed",J="aria-selected",Q="focus",ee="focusin",te="focusout",se="keydown",ne="keyup",oe="click",re="mousedown",ae="hover",ie="mouseenter",le="mouseleave",ue="pointerdown",ce="pointermove",de="pointerup",ge="touchstart",pe="dragstart",Ee='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',me="ArrowDown",he="ArrowUp",fe="ArrowLeft",ve="ArrowRight",ye="Escape",we="transitionDuration",be="transitionDelay",N="transitionend",I="transitionProperty",Ae=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},Te=()=>{},De=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},Ne=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},S=(e,t)=>e.getAttribute(t),O=(e,t)=>e.hasAttribute(t),Ce=(e,t,s)=>e.setAttribute(t,s),Le=(e,t)=>e.removeAttribute(t),Se=(e,...t)=>{e.classList.add(...t)},Me=(e,...t)=>{e.classList.remove(...t)},Be=(e,t)=>e.classList.contains(t),y=e=>e!=null&&typeof e=="object"||!1,a=e=>y(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,u=e=>a(e)&&e.nodeType===1||!1,m=new Map,f={data:m,set:(e,t,s)=>{u(e)&&(m.has(t)||m.set(t,new Map),m.get(t).set(e,s))},getAllFor:e=>m.get(e)||null,get:(e,t)=>{if(!u(e)||!t)return null;const s=f.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=f.getAllFor(t);!s||!u(e)||(s.delete(e),s.size===0&&m.delete(t))}},Re=(e,t)=>f.get(e,t),A=e=>typeof e=="string"||!1,He=e=>y(e)&&e.constructor.name==="Window"||!1,P=e=>a(e)&&e.nodeType===9||!1,d=e=>He(e)?e.document:P(e)?e:a(e)?e.ownerDocument:globalThis.document,T=(e,...t)=>Object.assign(e,...t),V=e=>{if(!e)return;if(A(e))return d().createElement(e);const{tagName:t}=e,s=V(t);if(!s)return;const n={...e};return delete n.tagName,T(s,n)},U=(e,t)=>e.dispatchEvent(t),v=(e,t)=>{const s=getComputedStyle(e),n=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return s.getPropertyValue(n)},Fe=e=>{const t=v(e,I),s=v(e,be),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},W=e=>{const t=v(e,I),s=v(e,we),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},Ie=(e,t)=>{let s=0;const n=new Event(N),o=W(e),c=Fe(e);if(o){const i=l=>{l.target===e&&(t.apply(e,[l]),e.removeEventListener(N,i),s=1)};e.addEventListener(N,i),setTimeout(()=>{s||U(e,n)},o+c+17)}else t.apply(e,[n])},Oe=(e,t)=>e.focus(t),M=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,b=e=>Object.entries(e),x=e=>e.toLowerCase(),Pe=(e,t,s,n)=>{const o={...s},c={...e.dataset},i={...t},l={},g="title";return b(c).forEach(([r,p])=>{const w=typeof r=="string"&&r.includes(n)?r.replace(n,"").replace(/[A-Z]/g,Z=>x(Z)):r;l[w]=M(p)}),b(o).forEach(([r,p])=>{o[r]=M(p)}),b(t).forEach(([r,p])=>{r in o?i[r]=o[r]:r in l?i[r]=l[r]:i[r]=r===g?S(e,g):p}),i},B=e=>Object.keys(e),Ve=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return y(t)&&T(s,t),s},Ue={passive:!0},We=e=>e.offsetHeight,xe=(e,t)=>{b(t).forEach(([s,n])=>{if(n&&A(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,T(e.style,o)}})},C=e=>y(e)&&e.constructor.name==="Map"||!1,qe=e=>typeof e=="number"||!1,E=new Map,je={set:(e,t,s,n)=>{u(e)&&(n&&n.length?(E.has(e)||E.set(e,new Map),E.get(e).set(n,setTimeout(t,s))):E.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!u(e))return null;const s=E.get(e);return t&&s&&C(s)?s.get(t)||null:qe(s)?s:null},clear:(e,t)=>{if(!u(e))return;const s=E.get(e);t&&t.length&&C(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&&E.delete(e)):(clearTimeout(s),E.delete(e))}},q=(e,t)=>(a(t)?t:d()).querySelectorAll(e),L=new Map;function ze(e){const{shiftKey:t,code:s}=e,n=d(this),o=[...q(Ee,this)].filter(l=>!O(l,"disabled")&&!S(l,F));if(!o.length)return;const c=o[0],i=o[o.length-1];s==="Tab"&&(t&&n.activeElement===c?(i.focus(),e.preventDefault()):!t&&n.activeElement===i&&(c.focus(),e.preventDefault()))}const $e=e=>L.has(e)===!0,ke=e=>{const t=$e(e);(t?Ne:De)(e,"keydown",ze),t?L.delete(e):L.set(e,!0)},j=(e,t)=>{const{width:s,height:n,top:o,right:c,bottom:i,left:l}=e.getBoundingClientRect();let g=1,r=1;if(t&&u(e)){const{offsetWidth:p,offsetHeight:w}=e;g=p>0?Math.round(s)/p:1,r=w>0?Math.round(n)/w:1}return{width:s/g,height:n/r,top:o/r,right:c/g,bottom:i/r,left:l/g,x:l/g,y:o/r}},Ke=e=>d(e).body,D=e=>d(e).documentElement,z=e=>a(e)&&e.constructor.name==="ShadowRoot"||!1,Ze=e=>e.nodeName==="HTML"?e:u(e)&&e.assignedSlot||a(e)&&e.parentNode||z(e)&&e.host||D(e);let R=0,H=0;const h=new Map,$=(e,t)=>{let s=t?R:H;if(t){const n=$(e),o=h.get(n)||new Map;h.has(n)||h.set(n,o),C(o)&&!o.has(t)?(o.set(t,s),R+=1):s=o.get(t)}else{const n=e.id||e;h.has(n)?s=h.get(n):(h.set(n,s),H+=1)}return s},_e=e=>e?P(e)?e.defaultView:a(e)?e?.ownerDocument?.defaultView:e:window,Xe=e=>Array.isArray(e)||!1,Ye=e=>{if(!a(e))return!1;const{top:t,bottom:s}=j(e),{clientHeight:n}=D(e);return t<=n&&s>=0},Ge=e=>typeof e=="function"||!1,Je=e=>y(e)&&e.constructor.name==="NodeList"||!1,Qe=e=>D(e).dir==="rtl",et=e=>a(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,k=(e,t)=>e?e.closest(t)||k(e.getRootNode().host,t):null,K=(e,t)=>u(e)?e:(a(t)?t:d()).querySelector(e),tt=(e,t)=>(a(t)?t:d()).getElementsByTagName(e),st=(e,t)=>(t&&a(t)?t:d()).getElementsByClassName(e),nt=(e,t)=>e.matches(t),ot="5.1.0",rt=ot;class at{constructor(t,s){let n;try{if(u(t))n=t;else if(A(t)){if(n=K(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(c){throw Error(`${this.name} Error: ${c.message}`)}const o=f.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&B(this.defaults).length?Pe(n,this.defaults,s||{},"bs"):{},f.set(n,this.name,this)}get version(){return rt}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){f.remove(this.element,this.name),B(this).forEach(t=>{delete this[t]})}}exports.BaseComponent=at;exports.ObjectAssign=T;exports.Timer=je;exports.addClass=Se;exports.ariaDescribedBy=_;exports.ariaExpanded=X;exports.ariaHidden=F;exports.ariaModal=Y;exports.ariaPressed=G;exports.ariaSelected=J;exports.closest=k;exports.createCustomEvent=Ve;exports.createElement=V;exports.dispatchEvent=U;exports.dragstartEvent=pe;exports.emulateTransitionEnd=Ie;exports.focus=Oe;exports.focusEvent=Q;exports.focusinEvent=ee;exports.focusoutEvent=te;exports.getAttribute=S;exports.getBoundingClientRect=j;exports.getDocument=d;exports.getDocumentBody=Ke;exports.getDocumentElement=D;exports.getElementStyle=v;exports.getElementTransitionDuration=W;exports.getElementsByClassName=st;exports.getElementsByTagName=tt;exports.getInstance=Re;exports.getParentNode=Ze;exports.getUID=$;exports.getWindow=_e;exports.hasAttribute=O;exports.hasClass=Be;exports.isApple=Ae;exports.isArray=Xe;exports.isElementInScrollRange=Ye;exports.isFunction=Ge;exports.isHTMLElement=u;exports.isNode=a;exports.isNodeList=Je;exports.isRTL=Qe;exports.isShadowRoot=z;exports.isString=A;exports.isTableElement=et;exports.keyArrowDown=me;exports.keyArrowLeft=fe;exports.keyArrowRight=ve;exports.keyArrowUp=he;exports.keyEscape=ye;exports.keydownEvent=se;exports.keyupEvent=ne;exports.matches=nt;exports.mouseclickEvent=oe;exports.mousedownEvent=re;exports.mouseenterEvent=ie;exports.mousehoverEvent=ae;exports.mouseleaveEvent=le;exports.noop=Te;exports.passiveHandler=Ue;exports.pointerdownEvent=ue;exports.pointermoveEvent=ce;exports.pointerupEvent=de;exports.querySelector=K;exports.querySelectorAll=q;exports.reflow=We;exports.removeAttribute=Le;exports.removeClass=Me;exports.setAttribute=Ce;exports.setElementStyle=xe;exports.toLowerCase=x;exports.toggleFocusTrap=ke;exports.touchstartEvent=ge; -//# sourceMappingURL=base-component-D3rSrWwH.js.map diff --git a/dist/components/base-component-D3rSrWwH.js.map b/dist/components/base-component-D3rSrWwH.js.map deleted file mode 100644 index 60b075d8..00000000 --- a/dist/components/base-component-D3rSrWwH.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"base-component-D3rSrWwH.js","sources":["../../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../../src/version.ts","../../src/components/base-component.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n"],"names":["ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","Version","version","BaseComponent","prevInstance"],"mappings":"aAAK,MAAqEA,EAAkB,mBAAoBC,EAAe,gBAAiDC,EAAa,cAA6EC,EAAY,aAAcC,EAAc,eAAgBC,EAAe,gBAAqYC,EAAa,QAASC,GAAe,UAAWC,GAAgB,WAAsHC,GAAe,UAAuCC,GAAa,QAA6BC,GAAkB,QAA0CC,GAAiB,YAAuCC,GAAkB,QAASC,GAAkB,aAAcC,GAAkB,aAAwQC,GAAmB,cAAmDC,GAAmB,cAAeC,GAAiB,YAA+OC,GAAkB,aAmDxxDC,GAAiB,YAaaC,GAAoB,oFAuCtDC,GAAe,YAAaC,GAAa,UAAWC,GAAe,YAAaC,GAAgB,aAAsKC,GAAY,SAA6SC,GAAqB,qBAAsBC,GAAkB,kBAAmBC,EAAqB,gBAAiBC,EAAqB,qBA+B1tBC,GAAU,IAAM,CACjB,MAAMC,EAAc,qBACpB,OAAO,WAAW,eAAe,OAAO,KACrCC,GAAMD,EAAY,KAAKC,EAAE,KAAK,CAChC,GACDD,EAAY,KACV,WAAW,SACZ,GAAI,EACP,EAC2GE,GAAO,IAAM,CACxH,EAAGC,GAAK,CAACC,EAASC,EAAWC,EAAUC,IAAY,CACjD,MAAMC,EAAMD,GAAW,GACvBH,EAAQ,iBACNC,EACAC,EACAE,CACD,CACH,EAAGC,GAAM,CAACL,EAASC,EAAWC,EAAUC,IAAY,CAClD,MAAMC,EAAMD,GAAW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,CAAM,EAAIA,EAASjE,EAAW,GAAI,qBACzRgE,CACF,EAAsLkD,GAAyB,CAAClD,EAAUC,KAAYA,GAAU/E,EAAO+E,CAAM,EAAIA,EAASjE,EAAa,GAAE,uBACvRgE,CACF,EAAGmD,GAAU,CAACxH,EAAQqE,IAAarE,EAAO,QAAQqE,CAAQ,aCrdpDoD,GAAUC,GCahB,MAAqBC,EAAc,CAQjC,YAAY3H,EAA8BsD,EAAsB,CAC1D,IAAAjF,EAEA,GAAA,CACE,GAAAoB,EAAcO,CAAM,EACZ3B,EAAA2B,UACDC,EAASD,CAAM,GAGxB,GAFA3B,EAAUgJ,EAA2BrH,CAAM,EAEvC,CAAC3B,EAAS,MAAM,MAAM,IAAI2B,CAAM,4BAA4B,MAEhE,OAAM,MAAM,gDAAgD,QAEvDiC,EAAG,CACV,MAAM,MAAM,GAAG,KAAK,IAAI,WAAYA,EAAY,OAAO,EAAE,CAAA,CAG3D,MAAM2F,EAAejI,EAAK,IAAiBtB,EAAS,KAAK,IAAI,EAEzDuJ,GAGFA,EAAa,sBAAsB,EAGrC,KAAK,QAAUvJ,EACf,KAAK,QAAU,KAAK,UAAY8E,EAAW,KAAK,QAAQ,EAAE,OACtDb,GAAiBjE,EAAS,KAAK,SAAUiF,GAAU,CAAI,EAAA,IAAI,EAE3D,CAAC,EAEL3D,EAAK,IAAItB,EAAS,KAAK,KAAM,IAAI,CAAA,CAInC,IAAI,SAAU,CACL,OAAAoJ,EAAA,CAIT,IAAI,MAAO,CACF,MAAA,eAAA,CAIT,IAAI,UAAW,CACb,MAAO,CAAC,CAAA,CAKV,sBAAwB,IAAM,CAE9B,EAGA,SAAU,CACR9H,EAAK,OAAoB,KAAK,QAAS,KAAK,IAAI,EAChDwD,EAAW,IAAI,EAAE,QAASjC,GAAS,CACjC,OAAO,KAAKA,CAAI,CAAA,CACjB,CAAA,CAEL","x_google_ignoreList":[0]} \ No newline at end of file diff --git a/dist/components/base-component-DaZCwW-u.js b/dist/components/base-component-DaZCwW-u.js new file mode 100644 index 00000000..ca6b8e51 --- /dev/null +++ b/dist/components/base-component-DaZCwW-u.js @@ -0,0 +1,2 @@ +"use strict";const K="aria-describedby",I="aria-expanded",R="aria-hidden",X="aria-modal",J="aria-pressed",ee="aria-selected",te="focus",ne="focusin",oe="focusout",se="keydown",re="keyup",ie="click",ae="mousedown",le="hover",ue="mouseenter",ce="mouseleave",de="pointerdown",he="pointermove",fe="pointerup",me="touchstart",ge="dragstart",pe='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',ye="ArrowDown",we="ArrowUp",be="ArrowLeft",ve="ArrowRight",Ee="Escape",Ae="transitionDuration",Ne="transitionDelay",D="transitionend",j="transitionProperty",Te=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},Le=()=>{},xe=(e,t,n,o)=>{const s=o||!1;e.addEventListener(t,n,s)},De=(e,t,n,o)=>{const s=o||!1;e.removeEventListener(t,n,s)},C=(e,t)=>e.getAttribute(t),F=(e,t)=>e.hasAttribute(t),Me=(e,t,n)=>e.setAttribute(t,n),ke=(e,t)=>e.removeAttribute(t),Ce=(e,...t)=>{e.classList.add(...t)},Se=(e,...t)=>{e.classList.remove(...t)},ze=(e,t)=>e.classList.contains(t),v=e=>e!=null&&typeof e=="object"||!1,c=e=>v(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,u=e=>c(e)&&e.nodeType===1||!1,g=new Map,y={data:g,set:(e,t,n)=>{u(e)&&(g.has(t)||g.set(t,new Map),g.get(t).set(e,n))},getAllFor:e=>g.get(e)||null,get:(e,t)=>{if(!u(e)||!t)return null;const n=y.getAllFor(t);return e&&n&&n.get(e)||null},remove:(e,t)=>{const n=y.getAllFor(t);!n||!u(e)||(n.delete(e),n.size===0&&g.delete(t))}},Be=(e,t)=>y.get(e,t),N=e=>typeof e=="string"||!1,H=e=>v(e)&&e.constructor.name==="Window"||!1,q=e=>c(e)&&e.nodeType===9||!1,d=e=>q(e)?e:c(e)?e.ownerDocument:H(e)?e.document:globalThis.document,T=(e,...t)=>Object.assign(e,...t),$=e=>{if(!e)return;if(N(e))return d().createElement(e);const{tagName:t}=e,n=$(t);if(!n)return;const o={...e};return delete o.tagName,T(n,o)},O=(e,t)=>e.dispatchEvent(t),w=(e,t,n)=>{const o=getComputedStyle(e,n),s=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return o.getPropertyValue(s)},Pe=e=>{const t=w(e,j),n=w(e,Ne),o=n.includes("ms")?1:1e3,s=t&&t!=="none"?parseFloat(n)*o:0;return Number.isNaN(s)?0:s},V=e=>{const t=w(e,j),n=w(e,Ae),o=n.includes("ms")?1:1e3,s=t&&t!=="none"?parseFloat(n)*o:0;return Number.isNaN(s)?0:s},Re=(e,t)=>{let n=0;const o=new Event(D),s=V(e),i=Pe(e);if(s){const a=l=>{l.target===e&&(t.apply(e,[l]),e.removeEventListener(D,a),n=1)};e.addEventListener(D,a),setTimeout(()=>{n||O(e,o)},s+i+17)}else t.apply(e,[o])},je=(e,t)=>e.focus(t),S=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,A=e=>Object.entries(e),W=e=>e.toLowerCase(),Fe=(e,t,n,o)=>{if(!u(e))return t;const s={...n},i={...e.dataset},a={...t},l={},h="title";return A(i).forEach(([r,f])=>{const E=typeof r=="string"&&r.includes(o)?r.replace(o,"").replace(/[A-Z]/g,_=>W(_)):r;l[E]=S(f)}),A(s).forEach(([r,f])=>{s[r]=S(f)}),A(t).forEach(([r,f])=>{r in s?a[r]=s[r]:r in l?a[r]=l[r]:a[r]=r===h?C(e,h):f}),a},z=e=>Object.keys(e),He=(e,t)=>{const n=new CustomEvent(e,{cancelable:!0,bubbles:!0});return v(t)&&T(n,t),n},qe={passive:!0},$e=e=>e.offsetHeight,Oe=(e,t)=>{A(t).forEach(([n,o])=>{if(o&&N(n)&&n.includes("--"))e.style.setProperty(n,o);else{const s={};s[n]=o,T(e.style,s)}})},M=e=>v(e)&&e.constructor.name==="Map"||!1,Ve=e=>typeof e=="number"||!1,m=new Map,We={set:(e,t,n,o)=>{u(e)&&(o&&o.length?(m.has(e)||m.set(e,new Map),m.get(e).set(o,setTimeout(t,n))):m.set(e,setTimeout(t,n)))},get:(e,t)=>{if(!u(e))return null;const n=m.get(e);return t&&n&&M(n)?n.get(t)||null:Ve(n)?n:null},clear:(e,t)=>{if(!u(e))return;const n=m.get(e);t&&t.length&&M(n)?(clearTimeout(n.get(t)),n.delete(t),n.size===0&&m.delete(e)):(clearTimeout(n),m.delete(e))}},G=(e,t)=>(c(t)?t:d()).querySelectorAll(e),k=new Map;function Ge(e){const{shiftKey:t,code:n}=e,o=d(this),s=[...G(pe,this)].filter(l=>!F(l,"disabled")&&!C(l,R));if(!s.length)return;const i=s[0],a=s[s.length-1];n==="Tab"&&(t&&o.activeElement===i?(a.focus(),e.preventDefault()):!t&&o.activeElement===a&&(i.focus(),e.preventDefault()))}const Ze=e=>k.has(e)===!0,Qe=e=>{const t=Ze(e);(t?De:xe)(e,"keydown",Ge),t?k.delete(e):k.set(e,!0)},L=e=>u(e)&&"offsetWidth"in e||!1,b=(e,t)=>{const{width:n,height:o,top:s,right:i,bottom:a,left:l}=e.getBoundingClientRect();let h=1,r=1;if(t&&L(e)){const{offsetWidth:f,offsetHeight:E}=e;h=f>0?Math.round(n)/f:1,r=E>0?Math.round(o)/E:1}return{width:n/h,height:o/r,top:s/r,right:i/h,bottom:a/r,left:l/h,x:l/h,y:s/r}},Ue=e=>d(e).body,x=e=>d(e).documentElement,Ye=e=>{const t=H(e),n=t?e.scrollX:e.scrollLeft,o=t?e.scrollY:e.scrollTop;return{x:n,y:o}},Z=e=>c(e)&&e.constructor.name==="ShadowRoot"||!1,_e=e=>e.nodeName==="HTML"?e:u(e)&&e.assignedSlot||c(e)&&e.parentNode||Z(e)&&e.host||x(e),Ke=e=>e?q(e)?e.defaultView:c(e)?e?.ownerDocument?.defaultView:e:window,Ie=e=>c(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,Xe=(e,t)=>e.matches(t),Je=e=>{if(!L(e))return!1;const{width:t,height:n}=b(e),{offsetWidth:o,offsetHeight:s}=e;return Math.round(t)!==o||Math.round(n)!==s},et=(e,t,n)=>{const o=L(t),s=b(e,o&&Je(t)),i={x:0,y:0};if(o){const a=b(t,!0);i.x=a.x+t.clientLeft,i.y=a.y+t.clientTop}return{x:s.left+n.x-i.x,y:s.top+n.y-i.y,width:s.width,height:s.height}};let B=0,P=0;const p=new Map,Q=(e,t)=>{let n=t?B:P;if(t){const o=Q(e),s=p.get(o)||new Map;p.has(o)||p.set(o,s),M(s)&&!s.has(t)?(s.set(t,n),B+=1):n=s.get(t)}else{const o=e.id||e;p.has(o)?n=p.get(o):(p.set(o,n),P+=1)}return n},tt=e=>Array.isArray(e)||!1,nt=e=>{if(!c(e))return!1;const{top:t,bottom:n}=b(e),{clientHeight:o}=x(e);return t<=o&&n>=0},ot=e=>typeof e=="function"||!1,st=e=>v(e)&&e.constructor.name==="NodeList"||!1,rt=e=>x(e).dir==="rtl",U=(e,t)=>!e||!t?null:e.closest(t)||U(e.getRootNode().host,t)||null,Y=(e,t)=>u(e)?e:(u(t)?t:d()).querySelector(e),it=(e,t)=>(c(t)?t:d()).getElementsByTagName(e),at=(e,t)=>(t&&c(t)?t:d()).getElementsByClassName(e),lt="5.1.0",ut=lt;class ct{constructor(t,n){let o;try{if(u(t))o=t;else if(N(t)){if(o=Y(t),!o)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const s=y.get(o,this.name);s&&s._toggleEventListeners(),this.element=o,this.options=this.defaults&&z(this.defaults).length?Fe(o,this.defaults,n||{},"bs"):{},y.set(o,this.name,this)}get version(){return ut}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){y.remove(this.element,this.name),z(this).forEach(t=>{delete this[t]})}}exports.$=R;exports.A=_e;exports.Ae=Q;exports.Ao=Qe;exports.BaseComponent=ct;exports.Be=J;exports.Co=et;exports.De=K;exports.Do=nt;exports.Dt=de;exports.Ee=Xe;exports.Eo=$e;exports.Fe=ee;exports.Gn=ke;exports.Go=at;exports.N=T;exports.Ne=it;exports.Oe=I;exports.Pe=X;exports.Qn=Me;exports.Ro=Y;exports.Rt=me;exports.S=x;exports.Se=tt;exports.So=Ue;exports.Uo=rt;exports.Vo=st;exports.Yn=ze;exports.Zn=Se;exports.at=oe;exports.be=Ie;exports.bo=qe;exports.bt=ae;exports.cn=ve;exports.ct=ne;exports.d=d;exports.de=G;exports.dt=se;exports.g=w;exports.gn=Ee;exports.ho=Oe;exports.ht=le;exports.ie=V;exports.io=je;exports.j=C;exports.je=ge;exports.k=N;exports.ke=U;exports.ko=Ye;exports.l=c;exports.m=L;exports.me=Z;exports.mt=ie;exports.ne=F;exports.oe=$;exports.on=ye;exports.pt=re;exports.q=O;exports.qn=Ce;exports.rn=be;exports.ro=Re;exports.rt=te;exports.sn=we;exports.te=Le;exports.to=Be;exports.ue=W;exports.ve=Ke;exports.vo=He;exports.w=b;exports.wt=ce;exports.xt=he;exports.yo=We;exports.yt=ue;exports.zn=Te;exports.zo=ot;exports.zt=fe; +//# sourceMappingURL=base-component-DaZCwW-u.js.map diff --git a/dist/components/base-component-DaZCwW-u.js.map b/dist/components/base-component-DaZCwW-u.js.map new file mode 100644 index 00000000..a508a2e5 --- /dev/null +++ b/dist/components/base-component-DaZCwW-u.js.map @@ -0,0 +1 @@ +{"version":3,"file":"base-component-DaZCwW-u.js","sources":["../../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../../src/version.ts","../../src/components/base-component.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","h","O","to","k","G","K","N","oe","q","g","ae","ie","ro","r","i","io","P","T","ue","lo","f","c","p","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","Version","version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop"],"mappings":"aAAK,MAA6DA,EAAK,mBAAoBC,EAAK,gBAAuCC,EAAI,cAA0DC,EAAK,aAAcC,EAAK,eAAgBC,GAAK,gBAAwPC,GAAK,QAASC,GAAK,UAAWC,GAAK,WAA0EC,GAAK,UAA4BC,GAAK,QAAsBC,GAAK,QAA0BC,GAAK,YAA6BC,GAAK,QAASC,GAAK,aAAcC,GAAK,aAAmKC,GAAK,cAAoCC,GAAK,cAAeC,GAAK,YAAsJC,GAAK,aAmD1mCC,GAAK,YAUuBC,GAAK,oFAoBlCC,GAAK,YAAaC,GAAK,UAAWC,GAAK,YAAaC,GAAK,aAAkHC,GAAK,SAAyMC,GAAK,qBAAsBC,GAAK,kBAAmBC,EAAI,gB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,EAA0BC,EAAsB,CACtD,IAAAC,EAEA,GAAA,CACE,GAAAC,EAAUH,CAAM,EACRE,EAAAF,UACDI,EAASJ,CAAM,GAGxB,GAFAE,EAAUG,EAAcL,CAAM,EAE1B,CAACE,EAAS,MAAM,MAAM,IAAIF,CAAM,4BAA4B,MAEhE,OAAM,MAAM,gDAAgD,QAEvD/E,EAAG,CACV,MAAM,MAAM,GAAG,KAAK,IAAI,WAAYA,EAAY,OAAO,EAAE,CAAA,CAG3D,MAAMqF,EAAeC,EAAK,IAAiBL,EAAS,KAAK,IAAI,EAEzDI,GAGFA,EAAa,sBAAsB,EAGrC,KAAK,QAAUJ,EACf,KAAK,QAAU,KAAK,UAAYM,EAAW,KAAK,QAAQ,EAAE,OACtDC,GAAiBP,EAAS,KAAK,SAAUD,GAAU,CAAI,EAAA,IAAI,EAE3D,CAAC,EAELM,EAAK,IAAIL,EAAS,KAAK,KAAM,IAAI,CAAA,CAInC,IAAI,SAAU,CACL,OAAAL,EAAA,CAIT,IAAI,MAAO,CACF,MAAA,eAAA,CAIT,IAAI,UAAW,CACb,MAAO,CAAC,CAAA,CAKV,sBAAwB,IAAM,CAE9B,EAGA,SAAU,CACRU,EAAK,OAAoB,KAAK,QAAS,KAAK,IAAI,EAChDC,EAAW,IAAI,EAAE,QAASE,GAAS,CACjC,OAAO,KAAKA,CAAI,CAAA,CACjB,CAAA,CAEL","x_google_ignoreList":[0]} \ No newline at end of file diff --git a/dist/components/base-component-Jx2aafTJ.mjs b/dist/components/base-component-Jx2aafTJ.mjs new file mode 100644 index 00000000..9e474571 --- /dev/null +++ b/dist/components/base-component-Jx2aafTJ.mjs @@ -0,0 +1,352 @@ +const ue = "aria-describedby", ce = "aria-expanded", W = "aria-hidden", de = "aria-modal", he = "aria-pressed", fe = "aria-selected", ge = "focus", me = "focusin", pe = "focusout", ye = "keydown", we = "keyup", be = "click", ve = "mousedown", Ee = "hover", Ae = "mouseenter", Te = "mouseleave", Ne = "pointerdown", Le = "pointermove", xe = "pointerup", Me = "touchstart", De = "dragstart", O = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]', ke = "ArrowDown", Ce = "ArrowUp", He = "ArrowLeft", Pe = "ArrowRight", Be = "Escape", V = "transitionDuration", $ = "transitionDelay", T = "transitionend", F = "transitionProperty", Fe = () => { + const e = /(iPhone|iPod|iPad)/; + return navigator?.userAgentData?.brands.some( + (t) => e.test(t.brand) + ) || e.test( + navigator?.userAgent + ) || !1; +}, Re = () => { +}, q = (e, t, s, n) => { + const a = n || !1; + e.addEventListener( + t, + s, + a + ); +}, G = (e, t, s, n) => { + const a = n || !1; + e.removeEventListener( + t, + s, + a + ); +}, R = (e, t) => e.getAttribute(t), Z = (e, t) => e.hasAttribute(t), Se = (e, t, s) => e.setAttribute(t, s), je = (e, t) => e.removeAttribute(t), ze = (e, ...t) => { + e.classList.add(...t); +}, We = (e, ...t) => { + e.classList.remove(...t); +}, Oe = (e, t) => e.classList.contains(t), w = (e) => e != null && typeof e == "object" || !1, c = (e) => w(e) && typeof e.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( + (t) => e.nodeType === t +) || !1, u = (e) => c(e) && e.nodeType === 1 || !1, m = /* @__PURE__ */ new Map(), y = { + data: m, + /** + * Sets web components data. + * + * @param element target element + * @param component the component's name or a unique key + * @param instance the component instance + */ + set: (e, t, s) => { + u(e) && (m.has(t) || m.set(t, /* @__PURE__ */ new Map()), m.get(t).set(e, s)); + }, + /** + * Returns all instances for specified component. + * + * @param component the component's name or a unique key + * @returns all the component instances + */ + getAllFor: (e) => m.get(e) || null, + /** + * Returns the instance associated with the target. + * + * @param element target element + * @param component the component's name or a unique key + * @returns the instance + */ + get: (e, t) => { + if (!u(e) || !t) return null; + const s = y.getAllFor(t); + return e && s && s.get(e) || null; + }, + /** + * Removes web components data. + * + * @param element target element + * @param component the component's name or a unique key + */ + remove: (e, t) => { + const s = y.getAllFor(t); + !s || !u(e) || (s.delete(e), s.size === 0 && m.delete(t)); + } +}, Ve = (e, t) => y.get(e, t), x = (e) => typeof e == "string" || !1, S = (e) => w(e) && e.constructor.name === "Window" || !1, j = (e) => c(e) && e.nodeType === 9 || !1, g = (e) => j(e) ? e : c(e) ? e.ownerDocument : S(e) ? e.document : globalThis.document, M = (e, ...t) => Object.assign(e, ...t), _ = (e) => { + if (!e) return; + if (x(e)) + return g().createElement(e); + const { tagName: t } = e, s = _(t); + if (!s) return; + const n = { ...e }; + return delete n.tagName, M(s, n); +}, K = (e, t) => e.dispatchEvent(t), E = (e, t, s) => { + const n = getComputedStyle(e, s), a = t.replace("webkit", "Webkit").replace(/([A-Z])/g, "-$1").toLowerCase(); + return n.getPropertyValue(a); +}, Q = (e) => { + const t = E(e, F), s = E(e, $), n = s.includes("ms") ? 1 : 1e3, a = t && t !== "none" ? parseFloat(s) * n : 0; + return Number.isNaN(a) ? 0 : a; +}, U = (e) => { + const t = E(e, F), s = E(e, V), n = s.includes("ms") ? 1 : 1e3, a = t && t !== "none" ? parseFloat(s) * n : 0; + return Number.isNaN(a) ? 0 : a; +}, $e = (e, t) => { + let s = 0; + const n = new Event(T), a = U(e), r = Q(e); + if (a) { + const i = (l) => { + l.target === e && (t.apply(e, [l]), e.removeEventListener(T, i), s = 1); + }; + e.addEventListener(T, i), setTimeout(() => { + s || K(e, n); + }, a + r + 17); + } else + t.apply(e, [n]); +}, qe = (e, t) => e.focus(t), C = (e) => ["true", !0].includes(e) ? !0 : ["false", !1].includes(e) ? !1 : ["null", "", null, void 0].includes(e) ? null : e !== "" && !Number.isNaN(+e) ? +e : e, v = (e) => Object.entries(e), Y = (e) => e.toLowerCase(), I = (e, t, s, n) => { + if (!u(e)) return t; + const a = { ...s }, r = { ...e.dataset }, i = { ...t }, l = {}, d = "title"; + return v(r).forEach(([o, h]) => { + const b = typeof o == "string" && o.includes(n) ? o.replace(n, "").replace( + /[A-Z]/g, + (z) => Y(z) + ) : o; + l[b] = C(h); + }), v(a).forEach(([o, h]) => { + a[o] = C(h); + }), v(t).forEach(([o, h]) => { + o in a ? i[o] = a[o] : o in l ? i[o] = l[o] : i[o] = o === d ? R(e, d) : h; + }), i; +}, H = (e) => Object.keys(e), Ge = (e, t) => { + const s = new CustomEvent(e, { + cancelable: !0, + bubbles: !0 + }); + return w(t) && M(s, t), s; +}, Ze = { passive: !0 }, _e = (e) => e.offsetHeight, Ke = (e, t) => { + v(t).forEach(([s, n]) => { + if (n && x(s) && s.includes("--")) + e.style.setProperty(s, n); + else { + const a = {}; + a[s] = n, M(e.style, a); + } + }); +}, N = (e) => w(e) && e.constructor.name === "Map" || !1, X = (e) => typeof e == "number" || !1, f = /* @__PURE__ */ new Map(), Qe = { + /** + * Sets a new timeout timer for an element, or element -> key association. + * + * @param element target element + * @param callback the callback + * @param delay the execution delay + * @param key a unique key + */ + set: (e, t, s, n) => { + u(e) && (n && n.length ? (f.has(e) || f.set(e, /* @__PURE__ */ new Map()), f.get(e).set(n, setTimeout(t, s))) : f.set(e, setTimeout(t, s))); + }, + /** + * Returns the timer associated with the target. + * + * @param element target element + * @param key a unique + * @returns the timer + */ + get: (e, t) => { + if (!u(e)) return null; + const s = f.get(e); + return t && s && N(s) ? s.get(t) || null : X(s) ? s : null; + }, + /** + * Clears the element's timer. + * + * @param element target element + * @param key a unique key + */ + clear: (e, t) => { + if (!u(e)) return; + const s = f.get(e); + t && t.length && N(s) ? (clearTimeout(s.get(t)), s.delete(t), s.size === 0 && f.delete(e)) : (clearTimeout(s), f.delete(e)); + } +}, J = (e, t) => (c(t) ? t : g()).querySelectorAll(e), L = /* @__PURE__ */ new Map(); +function ee(e) { + const { shiftKey: t, code: s } = e, n = g(this), a = [ + ...J(O, this) + ].filter( + (l) => !Z(l, "disabled") && !R(l, W) + ); + if (!a.length) return; + const r = a[0], i = a[a.length - 1]; + s === "Tab" && (t && n.activeElement === r ? (i.focus(), e.preventDefault()) : !t && n.activeElement === i && (r.focus(), e.preventDefault())); +} +const te = (e) => L.has(e) === !0, Ue = (e) => { + const t = te(e); + (t ? G : q)(e, "keydown", ee), t ? L.delete(e) : L.set(e, !0); +}, D = (e) => u(e) && "offsetWidth" in e || !1, A = (e, t) => { + const { width: s, height: n, top: a, right: r, bottom: i, left: l } = e.getBoundingClientRect(); + let d = 1, o = 1; + if (t && D(e)) { + const { offsetWidth: h, offsetHeight: b } = e; + d = h > 0 ? Math.round(s) / h : 1, o = b > 0 ? Math.round(n) / b : 1; + } + return { + width: s / d, + height: n / o, + top: a / o, + right: r / d, + bottom: i / o, + left: l / d, + x: l / d, + y: a / o + }; +}, Ye = (e) => g(e).body, k = (e) => g(e).documentElement, Ie = (e) => { + const t = S(e), s = t ? e.scrollX : e.scrollLeft, n = t ? e.scrollY : e.scrollTop; + return { x: s, y: n }; +}, se = (e) => c(e) && e.constructor.name === "ShadowRoot" || !1, Xe = (e) => e.nodeName === "HTML" ? e : u(e) && e.assignedSlot || c(e) && e.parentNode || se(e) && e.host || k(e), Je = (e) => e ? j(e) ? e.defaultView : c(e) ? e?.ownerDocument?.defaultView : e : window, et = (e) => c(e) && ["TABLE", "TD", "TH"].includes(e.nodeName) || !1, tt = (e, t) => e.matches(t), ne = (e) => { + if (!D(e)) return !1; + const { width: t, height: s } = A(e), { offsetWidth: n, offsetHeight: a } = e; + return Math.round(t) !== n || Math.round(s) !== a; +}, st = (e, t, s) => { + const n = D(t), a = A( + e, + n && ne(t) + ), r = { x: 0, y: 0 }; + if (n) { + const i = A(t, !0); + r.x = i.x + t.clientLeft, r.y = i.y + t.clientTop; + } + return { + x: a.left + s.x - r.x, + y: a.top + s.y - r.y, + width: a.width, + height: a.height + }; +}; +let P = 0, B = 0; +const p = /* @__PURE__ */ new Map(), ae = (e, t) => { + let s = t ? P : B; + if (t) { + const n = ae(e), a = p.get(n) || /* @__PURE__ */ new Map(); + p.has(n) || p.set(n, a), N(a) && !a.has(t) ? (a.set(t, s), P += 1) : s = a.get(t); + } else { + const n = e.id || e; + p.has(n) ? s = p.get(n) : (p.set(n, s), B += 1); + } + return s; +}, nt = (e) => Array.isArray(e) || !1, at = (e) => { + if (!c(e)) return !1; + const { top: t, bottom: s } = A(e), { clientHeight: n } = k(e); + return t <= n && s >= 0; +}, ot = (e) => typeof e == "function" || !1, rt = (e) => w(e) && e.constructor.name === "NodeList" || !1, it = (e) => k(e).dir === "rtl", oe = (e, t) => !e || !t ? null : e.closest(t) || oe(e.getRootNode().host, t) || null, re = (e, t) => u(e) ? e : (u(t) ? t : g()).querySelector(e), lt = (e, t) => (c(t) ? t : g()).getElementsByTagName( + e +), ut = (e, t) => (t && c(t) ? t : g()).getElementsByClassName( + e +), ie = "5.1.0", le = ie; +class ct { + /** + * @param target `Element` or selector string + * @param config component instance options + */ + constructor(t, s) { + let n; + try { + if (u(t)) + n = t; + else if (x(t)) { + if (n = re(t), !n) throw Error(`"${t}" is not a valid selector.`); + } else + throw Error("your target is not an instance of HTMLElement."); + } catch (r) { + throw Error(`${this.name} Error: ${r.message}`); + } + const a = y.get(n, this.name); + a && a._toggleEventListeners(), this.element = n, this.options = this.defaults && H(this.defaults).length ? I(n, this.defaults, s || {}, "bs") : {}, y.set(n, this.name, this); + } + get version() { + return le; + } + get name() { + return "BaseComponent"; + } + get defaults() { + return {}; + } + _toggleEventListeners = () => { + }; + dispose() { + y.remove(this.element, this.name), H(this).forEach((t) => { + delete this[t]; + }); + } +} +export { + W as $, + x as A, + ct as B, + Re as C, + at as D, + tt as E, + Ke as F, + ut as G, + Z as H, + qe as I, + E as J, + A as K, + ge as L, + we as M, + M as N, + ce as O, + ve as P, + Se as Q, + re as R, + k as S, + ke as T, + it as U, + Ce as V, + Be as W, + je as X, + Oe as Y, + We as Z, + Ye as _, + he as a, + de as a0, + Ue as a1, + Je as a2, + _ as a3, + lt as a4, + fe as a5, + me as a6, + pe as a7, + Ie as a8, + st as a9, + Y as aa, + ot as ab, + rt as ac, + nt as ad, + c as ae, + Xe as af, + se as ag, + et as ah, + ae as ai, + Ee as aj, + Fe as ak, + ue as al, + ze as b, + J as c, + g as d, + _e as e, + D as f, + Ae as g, + Ze as h, + U as i, + R as j, + Ne as k, + Me as l, + be as m, + De as n, + ye as o, + oe as p, + K as q, + $e as r, + Pe as s, + Ve as t, + He as u, + Ge as v, + Te as w, + Le as x, + Qe as y, + xe as z +}; +//# sourceMappingURL=base-component-Jx2aafTJ.mjs.map diff --git a/dist/components/base-component-Jx2aafTJ.mjs.map b/dist/components/base-component-Jx2aafTJ.mjs.map new file mode 100644 index 00000000..0006bd52 --- /dev/null +++ b/dist/components/base-component-Jx2aafTJ.mjs.map @@ -0,0 +1 @@ +{"version":3,"file":"base-component-Jx2aafTJ.mjs","sources":["../../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../../src/version.ts","../../src/components/base-component.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","n","o","s","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","h","O","to","k","G","K","d","N","oe","q","g","ae","ie","ro","a","i","io","P","T","ue","lo","f","c","p","E","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","Version","version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop"],"mappings":"AAAK,MAA6DA,KAAK,oBAAoBC,KAAK,iBAAuCC,IAAI,eAA0DC,KAAK,cAAcC,KAAK,gBAAgBC,KAAK,iBAAwPC,KAAK,SAASC,KAAK,WAAWC,KAAK,YAA0EC,KAAK,WAA4BC,KAAK,SAAsBC,KAAK,SAA0BC,KAAK,aAA6BC,KAAK,SAASC,KAAK,cAAcC,KAAK,cAAmKC,KAAK,eAAoCC,KAAK,eAAeC,KAAK,aAAsJC,KAAK,cAmD1mCC,KAAK,aAUuBC,IAAK,qFAoBlCC,KAAK,aAAaC,KAAK,WAAWC,KAAK,aAAaC,KAAK,cAAkHC,KAAK,UAAyMC,IAAK,sBAAsBC,IAAK,mBAAmBC,IAAI,iBAAiBC,IAAI,sBA+BjdC,KAAK,MAAM;AACZ,QAAMC,IAAI;AACV,SAAO,WAAW,eAAe,OAAO;AAAA,IACtC,CAACC,MAAMD,EAAE,KAAKC,EAAE,KAAK;AAAA,EACtB,KAAID,EAAE;AAAA,IACL,WAAW;AAAA,EACZ,KAAI;AACP,GAA2PE,KAAK,MAAM;AACtQ,GAAGC,IAAI,CAACH,GAAGC,GAAGG,GAAGC,MAAM;AACrB,QAAMC,IAAID,KAAK;AACf,EAAAL,EAAE;AAAA,IACAC;AAAA,IACAG;AAAA,IACAE;AAAA,EACD;AACH,GAAGC,IAAI,CAACP,GAAGC,GAAGG,GAAGC,MAAM;AACrB,QAAMC,IAAID,KAAK;AACf,EAAAL,EAAE;AAAA,IACAC;AAAA,IACAG;AAAA,IACAE;AAAA,EACD;AACH,GAesUE,IAAI,CAACR,GAAGC,MAAMD,EAAE,aAAaC,CAAC,GAA6CQ,IAAK,CAACT,GAAGC,MAAMD,EAAE,aAAaC,CAAC,GAA6CS,KAAK,CAACV,GAAGC,GAAGG,MAAMJ,EAAE,aAAa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AK,QAAQ,EAAE,SACtDC,EAAiBP,GAAS,KAAK,UAAUD,KAAU,CAAI,GAAA,IAAI,IAE3D,CAAC,GAELM,EAAK,IAAIL,GAAS,KAAK,MAAM,IAAI;AAAA,EAAA;AAAA,EAInC,IAAI,UAAU;AACL,WAAAL;AAAA,EAAA;AAAA,EAIT,IAAI,OAAO;AACF,WAAA;AAAA,EAAA;AAAA,EAIT,IAAI,WAAW;AACb,WAAO,CAAC;AAAA,EAAA;AAAA,EAKV,wBAAwB,MAAM;AAAA,EAE9B;AAAA,EAGA,UAAU;AACRU,IAAAA,EAAK,OAAoB,KAAK,SAAS,KAAK,IAAI,GAChDC,EAAW,IAAI,EAAE,QAAQ,CAACE,MAAS;AACjC,aAAO,KAAKA,CAAI;AAAA,IAAA,CACjB;AAAA,EAAA;AAEL;","x_google_ignoreList":[0]} \ No newline at end of file diff --git a/dist/components/base-component-ylZzLp-h.mjs b/dist/components/base-component-ylZzLp-h.mjs deleted file mode 100644 index 4360d55e..00000000 --- a/dist/components/base-component-ylZzLp-h.mjs +++ /dev/null @@ -1,366 +0,0 @@ -const it = "aria-describedby", lt = "aria-expanded", R = "aria-hidden", ct = "aria-modal", ut = "aria-pressed", dt = "aria-selected", pt = "focus", gt = "focusin", ht = "focusout", ft = "keydown", mt = "keyup", Et = "click", yt = "mousedown", wt = "hover", vt = "mouseenter", bt = "mouseleave", Tt = "pointerdown", At = "pointermove", Dt = "pointerup", Nt = "touchstart", Lt = "dragstart", V = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]', Mt = "ArrowDown", Ct = "ArrowUp", St = "ArrowLeft", Bt = "ArrowRight", Ot = "Escape", x = "transitionDuration", W = "transitionDelay", T = "transitionend", F = "transitionProperty", Ft = () => { - const t = /(iPhone|iPod|iPad)/; - return navigator?.userAgentData?.brands.some( - (e) => t.test(e.brand) - ) || /* istanbul ignore next @preserve */ - t.test( - navigator?.userAgent - ) || !1; -}, Ht = () => { -}, U = (t, e, s, a) => { - const n = a || !1; - t.addEventListener( - e, - s, - n - ); -}, j = (t, e, s, a) => { - const n = a || !1; - t.removeEventListener( - e, - s, - n - ); -}, H = (t, e) => t.getAttribute(e), q = (t, e) => t.hasAttribute(e), Pt = (t, e, s) => t.setAttribute(e, s), It = (t, e) => t.removeAttribute(e), Rt = (t, ...e) => { - t.classList.add(...e); -}, Vt = (t, ...e) => { - t.classList.remove(...e); -}, xt = (t, e) => t.classList.contains(e), y = (t) => t != null && typeof t == "object" || !1, l = (t) => y(t) && typeof t.nodeType == "number" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some( - (e) => t.nodeType === e -) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, f = /* @__PURE__ */ new Map(), E = { - data: f, - /** - * Sets web components data. - * - * @param element target element - * @param component the component's name or a unique key - * @param instance the component instance - */ - set: (t, e, s) => { - u(t) && (f.has(e) || f.set(e, /* @__PURE__ */ new Map()), f.get(e).set(t, s)); - }, - /** - * Returns all instances for specified component. - * - * @param component the component's name or a unique key - * @returns all the component instances - */ - getAllFor: (t) => f.get(t) || null, - /** - * Returns the instance associated with the target. - * - * @param element target element - * @param component the component's name or a unique key - * @returns the instance - */ - get: (t, e) => { - if (!u(t) || !e) return null; - const s = E.getAllFor(e); - return t && s && s.get(t) || null; - }, - /** - * Removes web components data. - * - * @param element target element - * @param component the component's name or a unique key - */ - remove: (t, e) => { - const s = E.getAllFor(e); - !s || !u(t) || (s.delete(t), s.size === 0 && f.delete(e)); - } -}, Wt = (t, e) => E.get(t, e), N = (t) => typeof t == "string" || !1, z = (t) => y(t) && t.constructor.name === "Window" || !1, P = (t) => l(t) && t.nodeType === 9 || !1, h = (t) => z(t) ? t.document : P(t) ? t : l(t) ? t.ownerDocument : globalThis.document, L = (t, ...e) => Object.assign(t, ...e), $ = (t) => { - if (!t) return; - if (N(t)) - return h().createElement(t); - const { tagName: e } = t, s = $(e); - if (!s) return; - const a = { ...t }; - return delete a.tagName, L(s, a); -}, K = (t, e) => t.dispatchEvent(e), b = (t, e) => { - const s = getComputedStyle(t), a = e.replace("webkit", "Webkit").replace(/([A-Z])/g, "-$1").toLowerCase(); - return s.getPropertyValue(a); -}, Z = (t) => { - const e = b(t, F), s = b(t, W), a = s.includes("ms") ? ( - /* istanbul ignore next */ - 1 - ) : 1e3, n = e && e !== "none" ? parseFloat(s) * a : ( - /* istanbul ignore next */ - 0 - ); - return Number.isNaN(n) ? ( - /* istanbul ignore next */ - 0 - ) : n; -}, _ = (t) => { - const e = b(t, F), s = b(t, x), a = s.includes("ms") ? ( - /* istanbul ignore next */ - 1 - ) : 1e3, n = e && e !== "none" ? parseFloat(s) * a : ( - /* istanbul ignore next */ - 0 - ); - return Number.isNaN(n) ? ( - /* istanbul ignore next */ - 0 - ) : n; -}, Ut = (t, e) => { - let s = 0; - const a = new Event(T), n = _(t), c = Z(t); - if (n) { - const o = (i) => { - i.target === t && (e.apply(t, [i]), t.removeEventListener(T, o), s = 1); - }; - t.addEventListener(T, o), setTimeout(() => { - s || K(t, a); - }, n + c + 17); - } else - e.apply(t, [a]); -}, jt = (t, e) => t.focus(e), C = (t) => ["true", !0].includes(t) ? !0 : ["false", !1].includes(t) ? !1 : ["null", "", null, void 0].includes(t) ? null : t !== "" && !Number.isNaN(+t) ? +t : t, v = (t) => Object.entries(t), X = (t) => t.toLowerCase(), Y = (t, e, s, a) => { - const n = { ...s }, c = { ...t.dataset }, o = { ...e }, i = {}, d = "title"; - return v(c).forEach(([r, p]) => { - const w = typeof r == "string" && r.includes(a) ? r.replace(a, "").replace( - /[A-Z]/g, - (I) => X(I) - ) : ( - /* istanbul ignore next @preserve */ - r - ); - i[w] = C(p); - }), v(n).forEach(([r, p]) => { - n[r] = C(p); - }), v(e).forEach(([r, p]) => { - r in n ? o[r] = n[r] : r in i ? o[r] = i[r] : o[r] = r === d ? H(t, d) : p; - }), o; -}, S = (t) => Object.keys(t), qt = (t, e) => { - const s = new CustomEvent(t, { - cancelable: !0, - bubbles: !0 - }); - return y(e) && L(s, e), s; -}, zt = { passive: !0 }, $t = (t) => t.offsetHeight, Kt = (t, e) => { - v(e).forEach(([s, a]) => { - if (a && N(s) && s.includes("--")) - t.style.setProperty(s, a); - else { - const n = {}; - n[s] = a, L(t.style, n); - } - }); -}, A = (t) => y(t) && t.constructor.name === "Map" || !1, G = (t) => typeof t == "number" || !1, g = /* @__PURE__ */ new Map(), Zt = { - /** - * Sets a new timeout timer for an element, or element -> key association. - * - * @param element target element - * @param callback the callback - * @param delay the execution delay - * @param key a unique key - */ - set: (t, e, s, a) => { - u(t) && (a && a.length ? (g.has(t) || g.set(t, /* @__PURE__ */ new Map()), g.get(t).set(a, setTimeout(e, s))) : g.set(t, setTimeout(e, s))); - }, - /** - * Returns the timer associated with the target. - * - * @param element target element - * @param key a unique - * @returns the timer - */ - get: (t, e) => { - if (!u(t)) return null; - const s = g.get(t); - return e && s && A(s) ? s.get(e) || /* istanbul ignore next @preserve */ - null : G(s) ? s : null; - }, - /** - * Clears the element's timer. - * - * @param element target element - * @param key a unique key - */ - clear: (t, e) => { - if (!u(t)) return; - const s = g.get(t); - e && e.length && A(s) ? (clearTimeout(s.get(e)), s.delete(e), s.size === 0 && g.delete(t)) : (clearTimeout(s), g.delete(t)); - } -}, J = (t, e) => (l(e) ? e : h()).querySelectorAll(t), D = /* @__PURE__ */ new Map(); -function Q(t) { - const { shiftKey: e, code: s } = t, a = h(this), n = [ - ...J(V, this) - ].filter( - (i) => !q(i, "disabled") && !H(i, R) - ); - if (!n.length) return; - const c = n[0], o = n[n.length - 1]; - s === "Tab" && (e && a.activeElement === c ? (o.focus(), t.preventDefault()) : !e && a.activeElement === o && (c.focus(), t.preventDefault())); -} -const k = (t) => D.has(t) === !0, _t = (t) => { - const e = k(t); - (e ? j : U)(t, "keydown", Q), e ? D.delete(t) : D.set(t, !0); -}, tt = (t, e) => { - const { width: s, height: a, top: n, right: c, bottom: o, left: i } = t.getBoundingClientRect(); - let d = 1, r = 1; - if (e && u(t)) { - const { offsetWidth: p, offsetHeight: w } = t; - d = p > 0 ? Math.round(s) / p : ( - /* istanbul ignore next @preserve */ - 1 - ), r = w > 0 ? Math.round(a) / w : ( - /* istanbul ignore next @preserve */ - 1 - ); - } - return { - width: s / d, - height: a / r, - top: n / r, - right: c / d, - bottom: o / r, - left: i / d, - x: i / d, - y: n / r - }; -}, Xt = (t) => h(t).body, M = (t) => h(t).documentElement, et = (t) => l(t) && t.constructor.name === "ShadowRoot" || !1, Yt = (t) => t.nodeName === "HTML" ? t : u(t) && t.assignedSlot || // step into the shadow DOM of the parent of a slotted node -l(t) && t.parentNode || // DOM Element detected -et(t) && t.host || // ShadowRoot detected -M(t); -let B = 0, O = 0; -const m = /* @__PURE__ */ new Map(), st = (t, e) => { - let s = e ? B : O; - if (e) { - const a = st(t), n = m.get(a) || /* @__PURE__ */ new Map(); - m.has(a) || m.set(a, n), A(n) && !n.has(e) ? (n.set(e, s), B += 1) : s = n.get(e); - } else { - const a = t.id || t; - m.has(a) ? s = m.get(a) : (m.set(a, s), O += 1); - } - return s; -}, Gt = (t) => t ? P(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, Jt = (t) => Array.isArray(t) || !1, Qt = (t) => { - if (!l(t)) return !1; - const { top: e, bottom: s } = tt(t), { clientHeight: a } = M(t); - return e <= a && s >= 0; -}, kt = (t) => typeof t == "function" || !1, te = (t) => y(t) && t.constructor.name === "NodeList" || !1, ee = (t) => M(t).dir === "rtl", se = (t) => l(t) && ["TABLE", "TD", "TH"].includes(t.nodeName) || !1, at = (t, e) => t ? t.closest(e) || // break out of `ShadowRoot` -at(t.getRootNode().host, e) : null, nt = (t, e) => u(t) ? t : (l(e) ? e : h()).querySelector(t), ae = (t, e) => (l(e) ? e : h()).getElementsByTagName( - t -), ne = (t, e) => (e && l(e) ? e : h()).getElementsByClassName( - t -), re = (t, e) => t.matches(e), rt = "5.1.0", ot = rt; -class oe { - /** - * @param target `HTMLElement` or selector string - * @param config component instance options - */ - constructor(e, s) { - let a; - try { - if (u(e)) - a = e; - else if (N(e)) { - if (a = nt(e), !a) throw Error(`"${e}" is not a valid selector.`); - } else - throw Error("your target is not an instance of HTMLElement."); - } catch (c) { - throw Error(`${this.name} Error: ${c.message}`); - } - const n = E.get(a, this.name); - n && n._toggleEventListeners(), this.element = a, this.options = this.defaults && S(this.defaults).length ? Y(a, this.defaults, s || {}, "bs") : {}, E.set(a, this.name, this); - } - // istanbul ignore next @preserve - get version() { - return ot; - } - // istanbul ignore next @preserve - get name() { - return "BaseComponent"; - } - // istanbul ignore next @preserve - get defaults() { - return {}; - } - /** just to have something to extend from */ - // istanbul ignore next @preserve coverage wise this isn't important - _toggleEventListeners = () => { - }; - /** Removes component from target element. */ - dispose() { - E.remove(this.element, this.name), S(this).forEach((e) => { - delete this[e]; - }); - } -} -export { - R as $, - Lt as A, - oe as B, - ft as C, - at as D, - At as E, - Dt as F, - Bt as G, - St as H, - N as I, - Ht as J, - Kt as K, - lt as L, - q as M, - jt as N, - L as O, - b as P, - M as Q, - tt as R, - pt as S, - Zt as T, - mt as U, - yt as V, - Mt as W, - Ct as X, - Ot as Y, - It as Z, - Xt as _, - ut as a, - ct as a0, - _t as a1, - Gt as a2, - $ as a3, - ae as a4, - dt as a5, - gt as a6, - ht as a7, - X as a8, - kt as a9, - te as aa, - Jt as ab, - l as ac, - Yt as ad, - et as ae, - se as af, - st as ag, - wt as ah, - Ft as ai, - it as aj, - H as b, - qt as c, - K as d, - Ut as e, - Rt as f, - Wt as g, - xt as h, - ee as i, - ne as j, - re as k, - h as l, - Et as m, - J as n, - Qt as o, - _ as p, - nt as q, - Vt as r, - Pt as s, - $t as t, - u, - vt as v, - bt as w, - zt as x, - Tt as y, - Nt as z -}; -//# sourceMappingURL=base-component-ylZzLp-h.mjs.map diff --git a/dist/components/base-component-ylZzLp-h.mjs.map b/dist/components/base-component-ylZzLp-h.mjs.map deleted file mode 100644 index 212d749b..00000000 --- a/dist/components/base-component-ylZzLp-h.mjs.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"base-component-ylZzLp-h.mjs","sources":["../../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../../src/version.ts","../../src/components/base-component.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n"],"names":["ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","Version","version","BaseComponent","prevInstance"],"mappings":"AAAK,MAAqEA,KAAkB,oBAAoBC,KAAe,iBAAiDC,IAAa,eAA6EC,KAAY,cAAcC,KAAc,gBAAgBC,KAAe,iBAAqYC,KAAa,SAASC,KAAe,WAAWC,KAAgB,YAAsHC,KAAe,WAAuCC,KAAa,SAA6BC,KAAkB,SAA0CC,KAAiB,aAAuCC,KAAkB,SAASC,KAAkB,cAAcC,KAAkB,cAAwQC,KAAmB,eAAmDC,KAAmB,eAAeC,KAAiB,aAA+OC,KAAkB,cAmDxxDC,KAAiB,aAaaC,IAAoB,qFAuCtDC,KAAe,aAAaC,KAAa,WAAWC,KAAe,aAAaC,KAAgB,cAAsKC,KAAY,UAA6SC,IAAqB,sBAAsBC,IAAkB,mBAAmBC,IAAqB,iBAAiBC,IAAqB,sBA+B1tBC,KAAU,M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I;AAAA,EAAA;AAAA;AAAA,EAInC,IAAI,UAAU;AACL,WAAAoJ;AAAA,EAAA;AAAA;AAAA,EAIT,IAAI,OAAO;AACF,WAAA;AAAA,EAAA;AAAA;AAAA,EAIT,IAAI,WAAW;AACb,WAAO,CAAC;AAAA,EAAA;AAAA;AAAA;AAAA,EAKV,wBAAwB,MAAM;AAAA,EAE9B;AAAA;AAAA,EAGA,UAAU;AACR,IAAA9H,EAAK,OAAoB,KAAK,SAAS,KAAK,IAAI,GAChDwD,EAAW,IAAI,EAAE,QAAQ,CAACjC,MAAS;AACjC,aAAO,KAAKA,CAAI;AAAA,IAAA,CACjB;AAAA,EAAA;AAEL;","x_google_ignoreList":[0]} \ No newline at end of file diff --git a/dist/components/button.cjs b/dist/components/button.cjs index ee558d7b..4657155a 100644 --- a/dist/components/button.cjs +++ b/dist/components/button.cjs @@ -1,2 +1,2 @@ -"use strict";const t=require("./base-component-D3rSrWwH.js"),a=require("./event-listener-W3RGkfJ6.js"),i=require("./activeClass-CxJYQAGN.js"),l=require("./dataBsToggle-Dj-Ng54N.js"),u="button",c="Button",g=`[${l.dataBsToggle}="${u}"]`,v=n=>t.getInstance(n,c),d=n=>new r(n);class r extends t.BaseComponent{static selector=g;static init=d;static getInstance=v;isActive=!1;constructor(s){super(s);const{element:e}=this;this.isActive=t.hasClass(e,i.activeClass),t.setAttribute(e,t.ariaPressed,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return c}toggle=s=>{s&&s.preventDefault();const{element:e,isActive:o}=this;!t.hasClass(e,"disabled")&&!t.getAttribute(e,"disabled")&&((o?t.removeClass:t.addClass)(e,i.activeClass),t.setAttribute(e,t.ariaPressed,o?"false":"true"),this.isActive=t.hasClass(e,i.activeClass))};_toggleEventListeners=s=>{(s?a.E:a.r)(this.element,t.mouseclickEvent,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=r; +"use strict";const t=require("./base-component-DaZCwW-u.js"),c=require("./event-listener-BQdA_KAC.js"),i=require("./activeClass-CxJYQAGN.js"),l=require("./dataBsToggle-Dj-Ng54N.js"),u="button",a="Button",g=`[${l.dataBsToggle}="${u}"]`,v=n=>t.to(n,a),b=n=>new r(n);class r extends t.BaseComponent{static selector=g;static init=b;static getInstance=v;constructor(s){super(s);const{element:e}=this;this.isActive=t.Yn(e,i.activeClass),t.Qn(e,t.Be,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return a}toggle=s=>{s&&s.preventDefault();const{element:e,isActive:o}=this;!t.Yn(e,"disabled")&&!t.j(e,"disabled")&&((o?t.Zn:t.qn)(e,i.activeClass),t.Qn(e,t.Be,o?"false":"true"),this.isActive=t.Yn(e,i.activeClass))};_toggleEventListeners=s=>{(s?c.E:c.r)(this.element,t.mt,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=r; //# sourceMappingURL=button.cjs.map diff --git a/dist/components/button.cjs.map b/dist/components/button.cjs.map index 76e81287..84c3d461 100644 --- a/dist/components/button.cjs.map +++ b/dist/components/button.cjs.map @@ -1 +1 @@ -{"version":3,"file":"button.cjs","sources":["../../src/strings/buttonString.ts","../../src/strings/buttonComponent.ts","../../src/components/button.ts"],"sourcesContent":["/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: HTMLElement) =>\n getInstance'}),c=e=>n.getInstance(e,t.popoverComponent),l=e=>new p(e);class p extends t.Tooltip{static selector=r;static init=l;static getInstance=c;static styleTip=t.styleTip;constructor(s,o){super(s,o)}get name(){return t.popoverComponent}get defaults(){return a}show=()=>{super.show();const{options:s,btn:o}=this;s.dismissible&&o&&setTimeout(()=>n.focus(o),17)}}module.exports=p; +"use strict";const n=require("./base-component-DaZCwW-u.js"),i=require("./dataBsToggle-Dj-Ng54N.js"),t=require("./tooltip-DKh6RNNg.js"),r=`[${i.dataBsToggle}="${t.popoverString}"],[data-tip="${t.popoverString}"]`,a=n.N({},t.tooltipDefaults,{template:t.getTipTemplate(t.popoverString),content:"",dismissible:!1,btnClose:''}),l=e=>n.to(e,t.popoverComponent),c=e=>new p(e);class p extends t.Tooltip{static selector=r;static init=c;static getInstance=l;static styleTip=t.styleTip;constructor(s,o){super(s,o)}get name(){return t.popoverComponent}get defaults(){return a}show=()=>{super.show();const{options:s,btn:o}=this;s.dismissible&&o&&setTimeout(()=>n.io(o),17)}}module.exports=p; //# sourceMappingURL=popover.cjs.map diff --git a/dist/components/popover.cjs.map b/dist/components/popover.cjs.map index 9c116f0e..73342db9 100644 --- a/dist/components/popover.cjs.map +++ b/dist/components/popover.cjs.map @@ -1 +1 @@ -{"version":3,"file":"popover.cjs","sources":["../../src/components/popover.ts"],"sourcesContent":["/* Native JavaScript for Bootstrap 5 | Popover\n---------------------------------------------- */\nimport { focus, getInstance, ObjectAssign } from \"@thednp/shorty\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\n\nimport getTipTemplate from \"../util/getTipTemplate\";\nimport styleTip from \"../util/styleTip\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport Tooltip from \"./tooltip\";\n\nimport type { PopoverOptions /* , PopoverEvent */ } from \"../interface/popover\";\n\n// POPOVER PRIVATE GC\n// ==================\nconst popoverSelector =\n `[${dataBsToggle}=\"${popoverString}\"],[data-tip=\"${popoverString}\"]`;\n\nconst popoverDefaults: PopoverOptions = ObjectAssign({}, tooltipDefaults, {\n template: getTipTemplate(popoverString),\n content: \"\",\n dismissible: false,\n btnClose: '',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n"],"names":["popoverSelector","dataBsToggle","popoverString","popoverDefaults","ObjectAssign","tooltipDefaults","getTipTemplate","getPopoverInstance","element","getInstance","popoverComponent","popoverInitCallback","Popover","Tooltip","styleTip","target","config","options","btn","focus"],"mappings":"wIAiBMA,EACJ,IAAIC,cAAY,KAAKC,EAAAA,aAAa,iBAAiBA,EAAa,aAAA,KAE5DC,EAAkCC,EAAAA,aAAa,CAAC,EAAGC,kBAAiB,CACxE,SAAUC,iBAAeJ,eAAa,EACtC,QAAS,GACT,YAAa,GACb,SAAU,wDACZ,CAAC,EAMKK,EAAsBC,GAC1BC,cAAqBD,EAASE,EAAAA,gBAAgB,EAK1CC,EAAuBH,GAAyB,IAAII,EAAQJ,CAAO,EAKzE,MAAqBI,UAAgBC,EAAAA,OAAQ,CAC3C,OAAO,SAAWb,EAClB,OAAO,KAAOW,EACd,OAAO,YAAcJ,EACrB,OAAO,SAAWO,EAAA,SAOlB,YAAYC,EAA8BC,EAAkC,CAC1E,MAAMD,EAAQC,CAAM,CAAA,CAKtB,IAAI,MAAO,CACF,OAAAN,EAAA,gBAAA,CAKT,IAAI,UAAW,CACN,OAAAP,CAAA,CAIT,KAAO,IAAM,CACX,MAAM,KAAK,EAEL,KAAA,CAAE,QAAAc,EAAS,IAAAC,CAAA,EAAQ,KAErBD,EAAQ,aAAeC,GAAK,WAAW,IAAMC,QAAMD,CAAG,EAAG,EAAE,CACjE,CACF"} \ No newline at end of file +{"version":3,"file":"popover.cjs","sources":["../../src/components/popover.ts"],"sourcesContent":["/* Native JavaScript for Bootstrap 5 | Popover\n---------------------------------------------- */\nimport { focus, getInstance, ObjectAssign } from \"@thednp/shorty\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\n\nimport getTipTemplate from \"../util/getTipTemplate\";\nimport styleTip from \"../util/styleTip\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport Tooltip from \"./tooltip\";\n\nimport type { PopoverOptions /* , PopoverEvent */ } from \"../interface/popover\";\n\n// POPOVER PRIVATE GC\n// ==================\nconst popoverSelector =\n `[${dataBsToggle}=\"${popoverString}\"],[data-tip=\"${popoverString}\"]`;\n\nconst popoverDefaults: PopoverOptions = ObjectAssign({}, tooltipDefaults, {\n template: getTipTemplate(popoverString),\n content: \"\",\n dismissible: false,\n btnClose: '',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n"],"names":["popoverSelector","dataBsToggle","popoverString","popoverDefaults","ObjectAssign","tooltipDefaults","getTipTemplate","getPopoverInstance","element","getInstance","popoverComponent","popoverInitCallback","Popover","Tooltip","styleTip","target","config","options","btn","focus"],"mappings":"wIAiBMA,EACJ,IAAIC,cAAY,KAAKC,EAAAA,aAAa,iBAAiBA,EAAa,aAAA,KAE5DC,EAAkCC,EAAAA,EAAa,CAAC,EAAGC,kBAAiB,CACxE,SAAUC,iBAAeJ,eAAa,EACtC,QAAS,GACT,YAAa,GACb,SAAU,wDACZ,CAAC,EAMKK,EAAsBC,GAC1BC,KAAqBD,EAASE,EAAAA,gBAAgB,EAK1CC,EAAuBH,GAAqB,IAAII,EAAQJ,CAAO,EAKrE,MAAqBI,UAAgBC,EAAAA,OAAQ,CAC3C,OAAO,SAAWb,EAClB,OAAO,KAAOW,EACd,OAAO,YAAcJ,EACrB,OAAO,SAAWO,EAAA,SAOlB,YAAYC,EAA0BC,EAAkC,CACtE,MAAMD,EAAQC,CAAM,CAAA,CAKtB,IAAI,MAAO,CACF,OAAAN,EAAA,gBAAA,CAKT,IAAI,UAAW,CACN,OAAAP,CAAA,CAIT,KAAO,IAAM,CACX,MAAM,KAAK,EAEL,KAAA,CAAE,QAAAc,EAAS,IAAAC,CAAA,EAAQ,KAErBD,EAAQ,aAAeC,GAAK,WAAW,IAAMC,KAAMD,CAAG,EAAG,EAAE,CACjE,CACF"} \ No newline at end of file diff --git a/dist/components/popover.d.ts b/dist/components/popover.d.ts index bdfc97df..852476da 100644 --- a/dist/components/popover.d.ts +++ b/dist/components/popover.d.ts @@ -1,14 +1,15 @@ import { default as default_2 } from '@thednp/position-observer'; +import { TouchEvent as TouchEvent_2 } from '@thednp/shorty'; /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -25,15 +26,15 @@ declare interface BaseOptions { /** Returns a new `Popover` instance. */ declare class Popover extends Tooltip { static selector: string; - static init: (element: HTMLElement) => Popover; - static getInstance: (element: HTMLElement) => Popover | null; - static styleTip: (self: T) => void; + static init: (element: Element) => Popover; + static getInstance: (element: Element) => Popover | null; + static styleTip: (self: Tooltip) => void; options: PopoverOptions; /** * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -56,15 +57,16 @@ declare interface PopoverOptions extends TooltipOptions { /** Creates a new `Tooltip` instance. */ declare class Tooltip extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Tooltip; - static getInstance: (element: HTMLElement) => Tooltip | null; - static styleTip: (self: T) => void; + static init: (element: Element) => Tooltip; + static getInstance: (element: Element) => Tooltip | null; + static styleTip: (self: Tooltip) => void; + element: Element & HTMLOrSVGElement; options: TooltipOptions; btn?: HTMLElement; - tooltip?: HTMLElement; - container: ParentNode; - arrow?: HTMLElement; - offsetParent?: HTMLElement; + tooltip: HTMLElement; + container: HTMLElement; + offsetParent: Element | Window; + arrow: HTMLElement; enabled: boolean; id: string; _observer: default_2; @@ -72,7 +74,7 @@ declare class Tooltip extends BaseComponent { * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -105,7 +107,7 @@ declare class Tooltip extends BaseComponent { * @this {Tooltip} * @param {TouchEvent} e the `Event` object */ - handleTouch: ({ target }: TouchEvent) => void; + handleTouch: ({ target }: TouchEvent_2) => void; /** * Toggles on/off the `Tooltip` event listeners. * diff --git a/dist/components/popover.mjs b/dist/components/popover.mjs index 100cecc1..76410aa5 100644 --- a/dist/components/popover.mjs +++ b/dist/components/popover.mjs @@ -1,23 +1,23 @@ -import { O as n, N as i, g as p } from "./base-component-ylZzLp-h.mjs"; +import { N as i, I as p, t as n } from "./base-component-Jx2aafTJ.mjs"; import { d as r } from "./dataBsToggle-B84TS15h.mjs"; -import { T as l, s as c, p as a, a as o, g as m, t as u } from "./tooltip-B5F6ZNW7.mjs"; -const g = `[${r}="${o}"],[data-tip="${o}"]`, b = n({}, u, { - template: m(o), +import { T as l, s as c, p as a, a as e, g as m, t as u } from "./tooltip-Cxy40RjE.mjs"; +const b = `[${r}="${e}"],[data-tip="${e}"]`, f = i({}, u, { + template: m(e), content: "", dismissible: !1, btnClose: '' -}), f = (t) => p(t, a), d = (t) => new T(t); +}), g = (t) => n(t, a), d = (t) => new T(t); class T extends l { - static selector = g; + static selector = b; static init = d; - static getInstance = f; + static getInstance = g; static styleTip = c; /** * @param target the target element * @param config the instance options */ - constructor(e, s) { - super(e, s); + constructor(o, s) { + super(o, s); } /** * Returns component name string. @@ -29,13 +29,12 @@ class T extends l { * Returns component default options. */ get defaults() { - return b; + return f; } - /* extend original `show()` */ show = () => { super.show(); - const { options: e, btn: s } = this; - e.dismissible && s && setTimeout(() => i(s), 17); + const { options: o, btn: s } = this; + o.dismissible && s && setTimeout(() => p(s), 17); }; } export { diff --git a/dist/components/popover.mjs.map b/dist/components/popover.mjs.map index d61e9b72..ed0a5e69 100644 --- a/dist/components/popover.mjs.map +++ b/dist/components/popover.mjs.map @@ -1 +1 @@ -{"version":3,"file":"popover.mjs","sources":["../../src/components/popover.ts"],"sourcesContent":["/* Native JavaScript for Bootstrap 5 | Popover\n---------------------------------------------- */\nimport { focus, getInstance, ObjectAssign } from \"@thednp/shorty\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\n\nimport getTipTemplate from \"../util/getTipTemplate\";\nimport styleTip from \"../util/styleTip\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport Tooltip from \"./tooltip\";\n\nimport type { PopoverOptions /* , PopoverEvent */ } from \"../interface/popover\";\n\n// POPOVER PRIVATE GC\n// ==================\nconst popoverSelector =\n `[${dataBsToggle}=\"${popoverString}\"],[data-tip=\"${popoverString}\"]`;\n\nconst popoverDefaults: PopoverOptions = ObjectAssign({}, tooltipDefaults, {\n template: getTipTemplate(popoverString),\n content: \"\",\n dismissible: false,\n btnClose: '',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n"],"names":["popoverSelector","dataBsToggle","popoverString","popoverDefaults","ObjectAssign","tooltipDefaults","getTipTemplate","getPopoverInstance","element","getInstance","popoverComponent","popoverInitCallback","Popover","Tooltip","styleTip","target","config","options","btn","focus"],"mappings":";;;AAiBA,MAAMA,IACJ,IAAIC,CAAY,KAAKC,CAAa,iBAAiBA,CAAa,MAE5DC,IAAkCC,EAAa,CAAC,GAAGC,GAAiB;AAAA,EACxE,UAAUC,EAAeJ,CAAa;AAAA,EACtC,SAAS;AAAA,EACT,aAAa;AAAA,EACb,UAAU;AACZ,CAAC,GAMKK,IAAqB,CAACC,MAC1BC,EAAqBD,GAASE,CAAgB,GAK1CC,IAAsB,CAACH,MAAyB,IAAII,EAAQJ,CAAO;AAKzE,MAAqBI,UAAgBC,EAAQ;AAAA,EAC3C,OAAO,WAAWb;AAAA,EAClB,OAAO,OAAOW;AAAA,EACd,OAAO,cAAcJ;AAAA,EACrB,OAAO,WAAWO;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlB,YAAYC,GAA8BC,GAAkC;AAC1E,UAAMD,GAAQC,CAAM;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA,EAKtB,IAAI,OAAO;AACF,WAAAN;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA,EAKT,IAAI,WAAW;AACN,WAAAP;AAAA,EAAA;AAAA;AAAA,EAIT,OAAO,MAAM;AACX,UAAM,KAAK;AAEL,UAAA,EAAE,SAAAc,GAAS,KAAAC,EAAA,IAAQ;AAErB,IAAAD,EAAQ,eAAeC,KAAK,WAAW,MAAMC,EAAMD,CAAG,GAAG,EAAE;AAAA,EACjE;AACF;"} \ No newline at end of file +{"version":3,"file":"popover.mjs","sources":["../../src/components/popover.ts"],"sourcesContent":["/* Native JavaScript for Bootstrap 5 | Popover\n---------------------------------------------- */\nimport { focus, getInstance, ObjectAssign } from \"@thednp/shorty\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\n\nimport getTipTemplate from \"../util/getTipTemplate\";\nimport styleTip from \"../util/styleTip\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport Tooltip from \"./tooltip\";\n\nimport type { PopoverOptions /* , PopoverEvent */ } from \"../interface/popover\";\n\n// POPOVER PRIVATE GC\n// ==================\nconst popoverSelector =\n `[${dataBsToggle}=\"${popoverString}\"],[data-tip=\"${popoverString}\"]`;\n\nconst popoverDefaults: PopoverOptions = ObjectAssign({}, tooltipDefaults, {\n template: getTipTemplate(popoverString),\n content: \"\",\n dismissible: false,\n btnClose: '',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n"],"names":["popoverSelector","dataBsToggle","popoverString","popoverDefaults","ObjectAssign","tooltipDefaults","getTipTemplate","getPopoverInstance","element","getInstance","popoverComponent","popoverInitCallback","Popover","Tooltip","styleTip","target","config","options","btn","focus"],"mappings":";;;AAiBA,MAAMA,IACJ,IAAIC,CAAY,KAAKC,CAAa,iBAAiBA,CAAa,MAE5DC,IAAkCC,EAAa,CAAC,GAAGC,GAAiB;AAAA,EACxE,UAAUC,EAAeJ,CAAa;AAAA,EACtC,SAAS;AAAA,EACT,aAAa;AAAA,EACb,UAAU;AACZ,CAAC,GAMKK,IAAqB,CAACC,MAC1BC,EAAqBD,GAASE,CAAgB,GAK1CC,IAAsB,CAACH,MAAqB,IAAII,EAAQJ,CAAO;AAKrE,MAAqBI,UAAgBC,EAAQ;AAAA,EAC3C,OAAO,WAAWb;AAAA,EAClB,OAAO,OAAOW;AAAA,EACd,OAAO,cAAcJ;AAAA,EACrB,OAAO,WAAWO;AAAA;AAAA;AAAA;AAAA;AAAA,EAOlB,YAAYC,GAA0BC,GAAkC;AACtE,UAAMD,GAAQC,CAAM;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA,EAKtB,IAAI,OAAO;AACF,WAAAN;AAAA,EAAA;AAAA;AAAA;AAAA;AAAA,EAKT,IAAI,WAAW;AACN,WAAAP;AAAA,EAAA;AAAA,EAIT,OAAO,MAAM;AACX,UAAM,KAAK;AAEL,UAAA,EAAE,SAAAc,GAAS,KAAAC,EAAA,IAAQ;AAErB,IAAAD,EAAQ,eAAeC,KAAK,WAAW,MAAMC,EAAMD,CAAG,GAAG,EAAE;AAAA,EACjE;AACF;"} \ No newline at end of file diff --git a/dist/components/popupContainer-CSoNJ-n6.js b/dist/components/popupContainer-CSoNJ-n6.js new file mode 100644 index 00000000..eb222cfe --- /dev/null +++ b/dist/components/popupContainer-CSoNJ-n6.js @@ -0,0 +1,2 @@ +"use strict";const p=require("./base-component-DaZCwW-u.js"),c="modal",d="offcanvas",e=p.oe({tagName:"div",className:"popup-container"}),f=(n,o)=>{const l=p.l(o)&&o.nodeName==="BODY",s=p.l(o)&&!l?o:e,a=l?o:p.So(n);p.l(n)&&(s===e&&a.append(e),s.append(n))},i=(n,o)=>{const l=p.l(o)&&o.nodeName==="BODY",s=p.l(o)&&!l?o:e;p.l(n)&&(n.remove(),s===e&&!e.children.length&&e.remove())},v=(n,o)=>{const l=p.l(o)&&o.nodeName!=="BODY"?o:e;return p.l(n)&&l.contains(n)};exports.appendPopup=f;exports.hasPopup=v;exports.modalString=c;exports.offcanvasString=d;exports.removePopup=i; +//# sourceMappingURL=popupContainer-CSoNJ-n6.js.map diff --git a/dist/components/popupContainer-CSoNJ-n6.js.map b/dist/components/popupContainer-CSoNJ-n6.js.map new file mode 100644 index 00000000..cd391de0 --- /dev/null +++ b/dist/components/popupContainer-CSoNJ-n6.js.map @@ -0,0 +1 @@ +{"version":3,"file":"popupContainer-CSoNJ-n6.js","sources":["../../src/strings/modalString.ts","../../src/strings/offcanvasString.ts","../../src/util/popupContainer.ts"],"sourcesContent":["/** @type {string} */\nconst modalString = \"modal\";\nexport default modalString;\n","/** @type {string} */\nconst offcanvasString = \"offcanvas\";\nexport default offcanvasString;\n","import { createElement, getDocumentBody, isNode } from \"@thednp/shorty\";\n\n// the default container for Modal, Offcanvas, Popover and Tooltip\nconst popupContainer = createElement({\n tagName: \"div\",\n className: \"popup-container\",\n}) as HTMLElement;\n\nconst appendPopup = (target: Element, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n const BODY = containerIsBody ? customContainer : getDocumentBody(target);\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n if (lookup === popupContainer) {\n BODY.append(popupContainer);\n }\n lookup.append(target);\n }\n};\n\nconst removePopup = (target: Element, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n target.remove();\n\n if (lookup === popupContainer && !popupContainer.children.length) {\n popupContainer.remove();\n }\n }\n};\n\nconst hasPopup = (target: Element, customContainer?: ParentNode) => {\n const lookup = isNode(customContainer) && customContainer.nodeName !== \"BODY\"\n ? customContainer\n : popupContainer;\n return isNode(target) && lookup.contains(target);\n};\n\nexport { appendPopup, hasPopup, popupContainer, removePopup };\n"],"names":["modalString","offcanvasString","popupContainer","createElement","appendPopup","target","customContainer","containerIsBody","isNode","lookup","BODY","getDocumentBody","removePopup","hasPopup"],"mappings":"6DACMA,EAAc,QCAdC,EAAkB,YCElBC,EAAiBC,EAAAA,GAAc,CACnC,QAAS,MACT,UAAW,iBACb,CAAC,EAEKC,EAAc,CAACC,EAAiBC,IAAiC,CACrE,MAAMC,EAAkBC,EAAAA,EAAOF,CAAe,GAC5CA,EAAgB,WAAa,OACzBG,EAASD,EAAAA,EAAOF,CAAe,GAAK,CAACC,EACvCD,EACAJ,EACEQ,EAAOH,EAAkBD,EAAkBK,EAAAA,GAAgBN,CAAM,EAGnEG,EAAAA,EAAOH,CAAM,IACXI,IAAWP,GACbQ,EAAK,OAAOR,CAAc,EAE5BO,EAAO,OAAOJ,CAAM,EAExB,EAEMO,EAAc,CAACP,EAAiBC,IAAiC,CACrE,MAAMC,EAAkBC,EAAAA,EAAOF,CAAe,GAC5CA,EAAgB,WAAa,OACzBG,EAASD,EAAAA,EAAOF,CAAe,GAAK,CAACC,EACvCD,EACAJ,EAGAM,EAAAA,EAAOH,CAAM,IACfA,EAAO,OAAO,EAEVI,IAAWP,GAAkB,CAACA,EAAe,SAAS,QACxDA,EAAe,OAAO,EAG5B,EAEMW,EAAW,CAACR,EAAiBC,IAAiC,CAClE,MAAMG,EAASD,EAAO,EAAAF,CAAe,GAAKA,EAAgB,WAAa,OACnEA,EACAJ,EACJ,OAAOM,EAAO,EAAAH,CAAM,GAAKI,EAAO,SAASJ,CAAM,CACjD"} \ No newline at end of file diff --git a/dist/components/popupContainer-CgZsH2ur.mjs b/dist/components/popupContainer-CgZsH2ur.mjs new file mode 100644 index 00000000..ba097d8e --- /dev/null +++ b/dist/components/popupContainer-CgZsH2ur.mjs @@ -0,0 +1,22 @@ +import { a3 as c, ae as s, _ as f } from "./base-component-Jx2aafTJ.mjs"; +const v = "modal", B = "offcanvas", a = c({ + tagName: "div", + className: "popup-container" +}), i = (p, o) => { + const n = s(o) && o.nodeName === "BODY", e = s(o) && !n ? o : a, d = n ? o : f(p); + s(p) && (e === a && d.append(a), e.append(p)); +}, N = (p, o) => { + const n = s(o) && o.nodeName === "BODY", e = s(o) && !n ? o : a; + s(p) && (p.remove(), e === a && !a.children.length && a.remove()); +}, h = (p, o) => { + const n = s(o) && o.nodeName !== "BODY" ? o : a; + return s(p) && n.contains(p); +}; +export { + i as a, + h, + v as m, + B as o, + N as r +}; +//# sourceMappingURL=popupContainer-CgZsH2ur.mjs.map diff --git a/dist/components/popupContainer-CgZsH2ur.mjs.map b/dist/components/popupContainer-CgZsH2ur.mjs.map new file mode 100644 index 00000000..1c12e46d --- /dev/null +++ b/dist/components/popupContainer-CgZsH2ur.mjs.map @@ -0,0 +1 @@ +{"version":3,"file":"popupContainer-CgZsH2ur.mjs","sources":["../../src/strings/modalString.ts","../../src/strings/offcanvasString.ts","../../src/util/popupContainer.ts"],"sourcesContent":["/** @type {string} */\nconst modalString = \"modal\";\nexport default modalString;\n","/** @type {string} */\nconst offcanvasString = \"offcanvas\";\nexport default offcanvasString;\n","import { createElement, getDocumentBody, isNode } from \"@thednp/shorty\";\n\n// the default container for Modal, Offcanvas, Popover and Tooltip\nconst popupContainer = createElement({\n tagName: \"div\",\n className: \"popup-container\",\n}) as HTMLElement;\n\nconst appendPopup = (target: Element, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n const BODY = containerIsBody ? customContainer : getDocumentBody(target);\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n if (lookup === popupContainer) {\n BODY.append(popupContainer);\n }\n lookup.append(target);\n }\n};\n\nconst removePopup = (target: Element, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n target.remove();\n\n if (lookup === popupContainer && !popupContainer.children.length) {\n popupContainer.remove();\n }\n }\n};\n\nconst hasPopup = (target: Element, customContainer?: ParentNode) => {\n const lookup = isNode(customContainer) && customContainer.nodeName !== \"BODY\"\n ? customContainer\n : popupContainer;\n return isNode(target) && lookup.contains(target);\n};\n\nexport { appendPopup, hasPopup, popupContainer, removePopup };\n"],"names":["modalString","offcanvasString","popupContainer","createElement","appendPopup","target","customContainer","containerIsBody","isNode","lookup","BODY","getDocumentBody","removePopup","hasPopup"],"mappings":";AACA,MAAMA,IAAc,SCAdC,IAAkB,aCElBC,IAAiBC,EAAc;AAAA,EACnC,SAAS;AAAA,EACT,WAAW;AACb,CAAC,GAEKC,IAAc,CAACC,GAAiBC,MAAiC;AACrE,QAAMC,IAAkBC,EAAOF,CAAe,KAC5CA,EAAgB,aAAa,QACzBG,IAASD,EAAOF,CAAe,KAAK,CAACC,IACvCD,IACAJ,GACEQ,IAAOH,IAAkBD,IAAkBK,EAAgBN,CAAM;AAGnE,EAAAG,EAAOH,CAAM,MACXI,MAAWP,KACbQ,EAAK,OAAOR,CAAc,GAE5BO,EAAO,OAAOJ,CAAM;AAExB,GAEMO,IAAc,CAACP,GAAiBC,MAAiC;AACrE,QAAMC,IAAkBC,EAAOF,CAAe,KAC5CA,EAAgB,aAAa,QACzBG,IAASD,EAAOF,CAAe,KAAK,CAACC,IACvCD,IACAJ;AAGA,EAAAM,EAAOH,CAAM,MACfA,EAAO,OAAO,GAEVI,MAAWP,KAAkB,CAACA,EAAe,SAAS,UACxDA,EAAe,OAAO;AAG5B,GAEMW,IAAW,CAACR,GAAiBC,MAAiC;AAClE,QAAMG,IAASD,EAAOF,CAAe,KAAKA,EAAgB,aAAa,SACnEA,IACAJ;AACJ,SAAOM,EAAOH,CAAM,KAAKI,EAAO,SAASJ,CAAM;AACjD;"} \ No newline at end of file diff --git a/dist/components/popupContainer-D8In9VFi.js b/dist/components/popupContainer-D8In9VFi.js deleted file mode 100644 index 2ebe8510..00000000 --- a/dist/components/popupContainer-D8In9VFi.js +++ /dev/null @@ -1,2 +0,0 @@ -"use strict";const e=require("./base-component-D3rSrWwH.js"),c="modal",i="offcanvas",n=e.createElement({tagName:"div",className:"popup-container"}),N=(p,o)=>{const s=e.isNode(o)&&o.nodeName==="BODY",d=e.isNode(o)&&!s?o:n,a=s?o:e.getDocumentBody(p);e.isNode(p)&&(d===n&&a.append(n),d.append(p))},f=(p,o)=>{const s=e.isNode(o)&&o.nodeName==="BODY",d=e.isNode(o)&&!s?o:n;e.isNode(p)&&(p.remove(),d===n&&!n.children.length&&n.remove())},l=(p,o)=>{const s=e.isNode(o)&&o.nodeName!=="BODY"?o:n;return e.isNode(p)&&s.contains(p)};exports.appendPopup=N;exports.hasPopup=l;exports.modalString=c;exports.offcanvasString=i;exports.removePopup=f; -//# sourceMappingURL=popupContainer-D8In9VFi.js.map diff --git a/dist/components/popupContainer-D8In9VFi.js.map b/dist/components/popupContainer-D8In9VFi.js.map deleted file mode 100644 index 72f177da..00000000 --- a/dist/components/popupContainer-D8In9VFi.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"popupContainer-D8In9VFi.js","sources":["../../src/strings/modalString.ts","../../src/strings/offcanvasString.ts","../../src/util/popupContainer.ts"],"sourcesContent":["/** @type {string} */\nconst modalString = \"modal\";\nexport default modalString;\n","/** @type {string} */\nconst offcanvasString = \"offcanvas\";\nexport default offcanvasString;\n","import { createElement, getDocumentBody, isNode } from \"@thednp/shorty\";\n\n// the default container for Modal, Offcanvas, Popover and Tooltip\nconst popupContainer = createElement({\n tagName: \"div\",\n className: \"popup-container\",\n}) as HTMLElement;\n\nconst appendPopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n const BODY = containerIsBody ? customContainer : getDocumentBody(target);\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n if (lookup === popupContainer) {\n BODY.append(popupContainer);\n }\n lookup.append(target);\n }\n};\n\nconst removePopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n target.remove();\n\n if (lookup === popupContainer && !popupContainer.children.length) {\n popupContainer.remove();\n }\n }\n};\n\nconst hasPopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const lookup = isNode(customContainer) && customContainer.nodeName !== \"BODY\"\n ? customContainer\n : popupContainer;\n return isNode(target) && lookup.contains(target);\n};\n\nexport { appendPopup, hasPopup, popupContainer, removePopup };\n"],"names":["modalString","offcanvasString","popupContainer","createElement","appendPopup","target","customContainer","containerIsBody","isNode","lookup","BODY","getDocumentBody","removePopup","hasPopup"],"mappings":"6DACMA,EAAc,QCAdC,EAAkB,YCElBC,EAAiBC,EAAAA,cAAc,CACnC,QAAS,MACT,UAAW,iBACb,CAAC,EAEKC,EAAc,CAACC,EAAqBC,IAAiC,CACzE,MAAMC,EAAkBC,EAAAA,OAAOF,CAAe,GAC5CA,EAAgB,WAAa,OACzBG,EAASD,EAAAA,OAAOF,CAAe,GAAK,CAACC,EACvCD,EACAJ,EACEQ,EAAOH,EAAkBD,EAAkBK,EAAAA,gBAAgBN,CAAM,EAGnEG,EAAAA,OAAOH,CAAM,IACXI,IAAWP,GACbQ,EAAK,OAAOR,CAAc,EAE5BO,EAAO,OAAOJ,CAAM,EAExB,EAEMO,EAAc,CAACP,EAAqBC,IAAiC,CACzE,MAAMC,EAAkBC,EAAAA,OAAOF,CAAe,GAC5CA,EAAgB,WAAa,OACzBG,EAASD,EAAAA,OAAOF,CAAe,GAAK,CAACC,EACvCD,EACAJ,EAGAM,EAAAA,OAAOH,CAAM,IACfA,EAAO,OAAO,EAEVI,IAAWP,GAAkB,CAACA,EAAe,SAAS,QACxDA,EAAe,OAAO,EAG5B,EAEMW,EAAW,CAACR,EAAqBC,IAAiC,CACtE,MAAMG,EAASD,EAAO,OAAAF,CAAe,GAAKA,EAAgB,WAAa,OACnEA,EACAJ,EACJ,OAAOM,EAAO,OAAAH,CAAM,GAAKI,EAAO,SAASJ,CAAM,CACjD"} \ No newline at end of file diff --git a/dist/components/popupContainer-ymf2oGcv.mjs b/dist/components/popupContainer-ymf2oGcv.mjs deleted file mode 100644 index 27c6b741..00000000 --- a/dist/components/popupContainer-ymf2oGcv.mjs +++ /dev/null @@ -1,22 +0,0 @@ -import { a3 as d, ac as s, _ as f } from "./base-component-ylZzLp-h.mjs"; -const B = "modal", i = "offcanvas", a = d({ - tagName: "div", - className: "popup-container" -}), m = (p, o) => { - const e = s(o) && o.nodeName === "BODY", n = s(o) && !e ? o : a, c = e ? o : f(p); - s(p) && (n === a && c.append(a), n.append(p)); -}, v = (p, o) => { - const e = s(o) && o.nodeName === "BODY", n = s(o) && !e ? o : a; - s(p) && (p.remove(), n === a && !a.children.length && a.remove()); -}, N = (p, o) => { - const e = s(o) && o.nodeName !== "BODY" ? o : a; - return s(p) && e.contains(p); -}; -export { - m as a, - N as h, - B as m, - i as o, - v as r -}; -//# sourceMappingURL=popupContainer-ymf2oGcv.mjs.map diff --git a/dist/components/popupContainer-ymf2oGcv.mjs.map b/dist/components/popupContainer-ymf2oGcv.mjs.map deleted file mode 100644 index a78157e7..00000000 --- a/dist/components/popupContainer-ymf2oGcv.mjs.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"popupContainer-ymf2oGcv.mjs","sources":["../../src/strings/modalString.ts","../../src/strings/offcanvasString.ts","../../src/util/popupContainer.ts"],"sourcesContent":["/** @type {string} */\nconst modalString = \"modal\";\nexport default modalString;\n","/** @type {string} */\nconst offcanvasString = \"offcanvas\";\nexport default offcanvasString;\n","import { createElement, getDocumentBody, isNode } from \"@thednp/shorty\";\n\n// the default container for Modal, Offcanvas, Popover and Tooltip\nconst popupContainer = createElement({\n tagName: \"div\",\n className: \"popup-container\",\n}) as HTMLElement;\n\nconst appendPopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n const BODY = containerIsBody ? customContainer : getDocumentBody(target);\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n if (lookup === popupContainer) {\n BODY.append(popupContainer);\n }\n lookup.append(target);\n }\n};\n\nconst removePopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const containerIsBody = isNode(customContainer) &&\n customContainer.nodeName === \"BODY\";\n const lookup = isNode(customContainer) && !containerIsBody\n ? customContainer\n : popupContainer;\n\n // istanbul ignore else @preserve\n if (isNode(target)) {\n target.remove();\n\n if (lookup === popupContainer && !popupContainer.children.length) {\n popupContainer.remove();\n }\n }\n};\n\nconst hasPopup = (target: HTMLElement, customContainer?: ParentNode) => {\n const lookup = isNode(customContainer) && customContainer.nodeName !== \"BODY\"\n ? customContainer\n : popupContainer;\n return isNode(target) && lookup.contains(target);\n};\n\nexport { appendPopup, hasPopup, popupContainer, removePopup };\n"],"names":["modalString","offcanvasString","popupContainer","createElement","appendPopup","target","customContainer","containerIsBody","isNode","lookup","BODY","getDocumentBody","removePopup","hasPopup"],"mappings":";AACA,MAAMA,IAAc,SCAdC,IAAkB,aCElBC,IAAiBC,EAAc;AAAA,EACnC,SAAS;AAAA,EACT,WAAW;AACb,CAAC,GAEKC,IAAc,CAACC,GAAqBC,MAAiC;AACzE,QAAMC,IAAkBC,EAAOF,CAAe,KAC5CA,EAAgB,aAAa,QACzBG,IAASD,EAAOF,CAAe,KAAK,CAACC,IACvCD,IACAJ,GACEQ,IAAOH,IAAkBD,IAAkBK,EAAgBN,CAAM;AAGnE,EAAAG,EAAOH,CAAM,MACXI,MAAWP,KACbQ,EAAK,OAAOR,CAAc,GAE5BO,EAAO,OAAOJ,CAAM;AAExB,GAEMO,IAAc,CAACP,GAAqBC,MAAiC;AACzE,QAAMC,IAAkBC,EAAOF,CAAe,KAC5CA,EAAgB,aAAa,QACzBG,IAASD,EAAOF,CAAe,KAAK,CAACC,IACvCD,IACAJ;AAGA,EAAAM,EAAOH,CAAM,MACfA,EAAO,OAAO,GAEVI,MAAWP,KAAkB,CAACA,EAAe,SAAS,UACxDA,EAAe,OAAO;AAG5B,GAEMW,IAAW,CAACR,GAAqBC,MAAiC;AACtE,QAAMG,IAASD,EAAOF,CAAe,KAAKA,EAAgB,aAAa,SACnEA,IACAJ;AACJ,SAAOM,EAAOH,CAAM,KAAKI,EAAO,SAASJ,CAAM;AACjD;"} \ No newline at end of file diff --git a/dist/components/scrollspy.cjs b/dist/components/scrollspy.cjs index b792fa57..ae7f1977 100644 --- a/dist/components/scrollspy.cjs +++ b/dist/components/scrollspy.cjs @@ -1,2 +1,2 @@ -"use strict";const s=require("./base-component-D3rSrWwH.js"),I=require("./index-BRPRSfaI.js"),u=require("./activeClass-CxJYQAGN.js"),b="scrollspy",S="ScrollSpy",x='[data-bs-spy="scroll"]',A={offset:10,target:null},B=t=>s.getInstance(t,S),L=t=>new E(t),v=s.createCustomEvent(`activate.bs.${b}`),q=t=>{const{target:e,scrollTarget:o,options:c,itemsLength:l,scrollHeight:r,element:i}=t,{offset:n}=c,a=o!==i,h=e&&s.getElementsByTagName("A",e),T=s.getDocument(i),m=o.scrollHeight;if(t.scrollTop=o.scrollTop,h&&(m!==r||l!==h.length)){let g,p,f;t.items=[],t.targets=[],t.offsets=[],t.scrollHeight=m,t.maxScroll=t.scrollHeight-D(t),Array.from(h).forEach(d=>{g=s.getAttribute(d,"href"),p=g&&g.charAt(0)==="#"&&g.slice(-1)!=="#"&&s.querySelector(g,T),p&&(t.items.push(d),t.targets.push(p),f=s.getBoundingClientRect(p),t.offsets.push((a?f.top+t.scrollTop:p.offsetTop)-n))}),t.itemsLength=t.items.length}},C=({targets:t,scrollTarget:e,element:o,_observer:c},l)=>{l?e===o?t.forEach(r=>c.observe(r)):c.observe(o):c.disconnect()},w=t=>t.scrollHeight,D=({element:t,scrollTarget:e})=>e!==t?e.clientHeight:s.getBoundingClientRect(t).height,H=t=>{[...s.getElementsByTagName("A",t)].forEach(e=>{s.hasClass(e,u.activeClass)&&s.removeClass(e,u.activeClass)})},y=(t,e)=>{const{target:o,element:c}=t;s.isHTMLElement(o)&&H(o),t.activeItem=e,s.addClass(e,u.activeClass);const l=[];let r=e;for(;r!==s.getDocumentBody(c);)r=r.parentElement,(s.hasClass(r,"nav")||s.hasClass(r,"dropdown-menu"))&&l.push(r);l.forEach(i=>{const n=i.previousElementSibling;n&&!s.hasClass(n,u.activeClass)&&s.addClass(n,u.activeClass)}),v.relatedTarget=e,s.dispatchEvent(c,v)};class E extends s.BaseComponent{static selector=x;static init=L;static getInstance=B;constructor(e,o){super(e,o);const{element:c,options:l}=this;this.target=s.querySelector(l.target,s.getDocument(c)),this.target&&(this.scrollTarget=c.clientHeightthis.refresh(),{root:this.scrollTarget}),C(this,!0))}get name(){return S}get defaults(){return A}refresh=()=>{const{target:e}=this;if(s.isHTMLElement(e)&&e.offsetHeight>0){q(this);const{scrollTop:o,maxScroll:c,itemsLength:l,items:r,activeItem:i}=this;if(o>=c){const a=r[l-1];i!==a&&y(this,a);return}const{offsets:n}=this;if(i&&o0){this.activeItem=null,e&&H(e);return}r.forEach((a,h)=>{i!==a&&o>=n[h]&&(typeof n[h+1]>"u"||os.to(t,C),Y=t=>new I(t),S=s.vo(`activate.bs.${w}`),R=t=>{const{target:e,scrollTarget:o,options:r,itemsLength:i,scrollHeight:n,element:l,_observer:c}=t,{offset:a}=r,g=o!==l,f=e&&s.Ne("A",e),b=s.d(l),m=o.scrollHeight;if(t.scrollTop=o.scrollTop,f&&(m!==n||i!==f.length)){let v,u,h,d;t.items=[],t.targets=[],t.offsets=[],t.scrollHeight=m,t.maxScroll=t.scrollHeight-B(t),Array.from(f).forEach(y=>{v=s.j(y,"href"),u=v?.slice(1),h=u?.length?b.getElementById(u):null,h&&(t.items.push(y),t.targets.push(h),d=c?.getEntry(h)?.boundingClientRect||s.w(h),t.offsets.push((g?d.top+t.scrollTop:h.offsetTop)-a))}),t.itemsLength=t.items.length}},H=({targets:t,scrollTarget:e,element:o,_observer:r},i)=>{i?e===o?t?.forEach(n=>r.observe(n)):r.observe(o):r.disconnect()},k=t=>t.scrollHeight,B=({element:t,scrollTarget:e})=>e!==t?e.clientHeight:s.w(t).height,E=t=>{Array.from(s.Ne("A",t)).forEach(e=>{s.Yn(e,p.activeClass)&&s.Zn(e,p.activeClass)})},T=(t,e)=>{const{target:o,element:r}=t;s.m(o)&&E(o),t.activeItem=e,s.qn(e,p.activeClass);const i=[];let n=e;for(;n!==s.So(r);)n=n.parentElement,(s.Yn(n,"nav")||s.Yn(n,"dropdown-menu"))&&i.push(n);i.forEach(l=>{const c=l.previousElementSibling;c&&!s.Yn(c,p.activeClass)&&s.qn(c,p.activeClass)}),S.relatedTarget=e,s.q(r,S)};class I extends s.BaseComponent{static selector=A;static init=Y;static getInstance=L;constructor(e,o){super(e,o);const{element:r,options:i}=this,n=s.Ro(i.target,s.d(r));n&&(this.target=n,this.scrollTarget=r.clientHeight{requestAnimationFrame(()=>{l.some(c=>c.isVisible)&&this.refresh()})},{root:this.scrollTarget}),H(this,!0))}get name(){return C}get defaults(){return x}refresh=()=>{const{target:e}=this;if(!s.m(e)||e.offsetHeight===0)return;R(this);const{scrollTop:o,maxScroll:r,itemsLength:i,items:n,activeItem:l}=this;if(o>=r){const a=n[i-1];l!==a&&T(this,a);return}const{offsets:c}=this;if(l&&o0){this.activeItem=null,e&&E(e);return}n.forEach((a,g)=>{l!==a&&o>=c[g]&&(typeof c[g+1]>"u"||o\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n"],"names":["scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","element","getInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","createCustomEvent","updateSpyTargets","self","target","scrollTarget","options","itemsLength","scrollHeight","offset","isRoot","links","getElementsByTagName","doc","getDocument","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","getAttribute","querySelector","getBoundingClientRect","toggleObservers","targets","_observer","add","getScrollHeight","clear","item","hasClass","activeClass","removeClass","activate","isHTMLElement","addClass","parents","parentItem","getDocumentBody","menuItem","parentLink","dispatchEvent","BaseComponent","config","getDocumentElement","PositionObserver","scrollTop","maxScroll","items","activeItem","newActiveItem","offsets","i","clone"],"mappings":"qIACMA,EAAkB,YCAlBC,EAAqB,YC6BrBC,EAAoB,yBAEpBC,EAAsC,CAC1C,OAAQ,GACR,OAAQ,IACV,EAUMC,EAAwBC,GAC5BC,cAAuBD,EAASJ,CAAkB,EAK9CM,EAAyBF,GAAyB,IAAIG,EAAUH,CAAO,EAIvEI,EAAoBC,EAAAA,kBAGxB,eAAeV,CAAe,EAAE,EAS5BW,EAAoBC,GAAoB,CAC5C,KAAM,CAAE,OAAAC,EAAQ,aAAAC,EAAc,QAAAC,EAAS,YAAAC,EAAa,aAAAC,EAAc,QAAAZ,GAChEO,EACI,CAAE,OAAAM,GAAWH,EACbI,EAASL,IAAiBT,EAE1Be,EAAQP,GAAUQ,uBAAqB,IAAKR,CAAM,EAClDS,EAAMC,cAAYlB,CAAO,EACzBmB,EAAeV,EAAa,aAMlC,GAJAF,EAAK,UAAYE,EAAa,UAK5BM,IAAUI,IAAiBP,GAAgBD,IAAgBI,EAAM,QACjE,CACI,IAAAK,EACAC,EACAC,EAGJf,EAAK,MAAQ,CAAC,EACdA,EAAK,QAAU,CAAC,EAChBA,EAAK,QAAU,CAAC,EAChBA,EAAK,aAAeY,EACpBZ,EAAK,UAAYA,EAAK,aAAegB,EAAgBhB,CAAI,EAEzD,MAAM,KAAKQ,CAAK,EAAE,QAASS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vC2C,IAAeC,GACjBjB,EAAS,KAAMiB,CAAa,EAE9B,MAAA,CAGI,KAAA,CAAE,QAAAC,GAAY,KAGhB,GAAAF,GAAcH,EAAYK,EAAQ,CAAC,GAAKA,EAAQ,CAAC,EAAI,EAAG,CAC1D,KAAK,WAAa,KAEdhD,KAAcA,CAAM,EACxB,MAAA,CAGI6C,EAAA,QAAQ,CAACnB,EAAMuB,IAAM,CAEvBH,IAAepB,GACfiB,GAAaK,EAAQC,CAAC,IACrB,OAAOD,EAAQC,EAAI,CAAC,EAAM,KAAeN,EAAYK,EAAQC,EAAI,CAAC,IAEnEnB,EAAS,KAAMJ,CAAI,CACrB,CACD,CAAA,CAEL,EAGA,SAAU,CACF,MAAAwB,EAAQ,CAAE,GAAG,IAAK,EACxB9B,EAAgB8B,CAAK,EACrB,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file +{"version":3,"file":"scrollspy.cjs","sources":["../../src/strings/scrollspyString.ts","../../src/strings/scrollspyComponent.ts","../../src/components/scrollspy.ts"],"sourcesContent":["/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n"],"names":["scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","element","getInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","createCustomEvent","updateSpyTargets","self","target","scrollTarget","options","itemsLength","scrollHeight","_observer","offset","isRoot","links","getElementsByTagName","doc","getDocument","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","getAttribute","getBoundingClientRect","toggleObservers","targets","add","getScrollHeight","clear","item","hasClass","activeClass","removeClass","activate","isHTMLElement","addClass","parents","parentItem","getDocumentBody","menuItem","parentLink","dispatchEvent","BaseComponent","config","spyTarget","querySelector","getDocumentElement","PositionObserver","entries","entry","scrollTop","maxScroll","items","activeItem","newActiveItem","offsets","i","clone"],"mappings":"qIACMA,EAAkB,YCAlBC,EAAqB,YC6BrBC,EAAoB,yBAEpBC,EAA+C,CACnD,OAAQ,GACR,OAAQ,MACV,EAUMC,EAAwBC,GAC5BC,KAAuBD,EAASJ,CAAkB,EAK9CM,EAAyBF,GAAqB,IAAIG,EAAUH,CAAO,EAInEI,EAAoBC,EAAAA,GAGxB,eAAeV,CAAe,EAAE,EAS5BW,EAAoBC,GAAoB,CACtC,KAAA,CACJ,OAAAC,EACA,aAAAC,EACA,QAAAC,EACA,YAAAC,EACA,a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KAAK,QAAQ,EAGb,KAAK,UAAY,IAAIoB,EAAiB,EAACC,GAAY,CACjD,sBAAsB,IAAM,CAEtBA,EAAQ,KAAMC,GAAUA,EAAM,SAAS,GACzC,KAAK,QAAQ,CACf,CACD,CAAA,EACA,CACD,KAAM,KAAK,YAAA,CACZ,EAGDzB,EAAgB,KAAM,EAAI,EAAA,CAO5B,IAAI,MAAO,CACF,OAAAjC,CAAA,CAKT,IAAI,UAAW,CACN,OAAAE,CAAA,CAOT,QAAU,IAAM,CACR,KAAA,CAAE,OAAAU,GAAW,KAGnB,GAAI,CAAC+B,EAAc,EAAA/B,CAAM,GAAKA,EAAO,eAAiB,EAAG,OAEzDF,EAAiB,IAAI,EAErB,KAAM,CAAE,UAAAiD,EAAW,UAAAC,EAAW,YAAA7C,EAAa,MAAA8C,EAAO,WAAAC,GAAe,KAEjE,GAAIH,GAAaC,EAAW,CACpB,MAAAG,EAAgBF,EAAM9C,EAAc,CAAC,EAGvC+C,IAAeC,GAAwBrB,EAAA,KAAMqB,CAAa,EAC9D,MAAA,CAGI,KAAA,CAAE,QAAAC,GAAY,KAGhB,GAAAF,GAAcH,EAAYK,EAAQ,CAAC,GAAKA,EAAQ,CAAC,EAAI,EAAG,CAC1D,KAAK,WAAa,KAEdpD,KAAcA,CAAM,EACxB,MAAA,CAGIiD,EAAA,QAAQ,CAACvB,EAAM2B,IAAM,CAEvBH,IAAexB,GACfqB,GAAaK,EAAQC,CAAC,IACrB,OAAOD,EAAQC,EAAI,CAAC,EAAM,KAAeN,EAAYK,EAAQC,EAAI,CAAC,IAEnEvB,EAAS,KAAMJ,CAAI,CACrB,CACD,CACH,EAGA,SAAU,CACF,MAAA4B,EAAQ,CAAE,GAAG,IAAK,EACxBjC,EAAgBiC,CAAK,EACrB,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file diff --git a/dist/components/scrollspy.d.ts b/dist/components/scrollspy.d.ts index 6be97b7a..048af6f4 100644 --- a/dist/components/scrollspy.d.ts +++ b/dist/components/scrollspy.d.ts @@ -2,13 +2,13 @@ import { default as default_2 } from '@thednp/position-observer'; /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -25,8 +25,9 @@ declare interface BaseOptions { /** Returns a new `ScrollSpy` instance. */ declare class ScrollSpy extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => ScrollSpy; - static getInstance: (element: HTMLElement) => ScrollSpy | null; + static init: (element: Element) => ScrollSpy; + static getInstance: (element: Element) => ScrollSpy | null; + element: HTMLElement; options: ScrollSpyOptions; target: HTMLElement | null; scrollTarget: HTMLElement; @@ -43,7 +44,7 @@ declare class ScrollSpy extends BaseComponent { * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -51,7 +52,7 @@ declare class ScrollSpy extends BaseComponent { /** * Returns component default options. */ - get defaults(): ScrollSpyOptions; + get defaults(): Partial; /** Updates all items. */ refresh: () => void; /** Removes `ScrollSpy` from the target element. */ @@ -61,7 +62,7 @@ export default ScrollSpy; declare interface ScrollSpyOptions extends BaseOptions { offset: number; - target: HTMLElement | string | null; + target: HTMLElement | string; } export { } diff --git a/dist/components/scrollspy.mjs b/dist/components/scrollspy.mjs index 83a4789c..4dd4c29d 100644 --- a/dist/components/scrollspy.mjs +++ b/dist/components/scrollspy.mjs @@ -1,99 +1,106 @@ -import { B, q as E, l as T, Q as L, u as I, g as D, c as R, a4 as C, b as k, R as b, h as f, r as q, f as y, _ as O, d as G } from "./base-component-ylZzLp-h.mjs"; -import { x as M } from "./index-gZuXW-3_.mjs"; -import { a as p } from "./activeClass-iqaD75Su.mjs"; -const N = "scrollspy", A = "ScrollSpy", Q = '[data-bs-spy="scroll"]', $ = { +import { B as R, R as q, d as I, S as B, f as b, t as k, v as O, a4 as w, j as Y, K as A, Y as p, Z, b as v, _ as j, q as D } from "./base-component-Jx2aafTJ.mjs"; +import { E as F } from "./index-DinhT6Jq.mjs"; +import { a as g } from "./activeClass-iqaD75Su.mjs"; +const G = "scrollspy", C = "ScrollSpy", K = '[data-bs-spy="scroll"]', N = { offset: 10, - target: null -}, j = (t) => D(t, A), z = (t) => new P(t), S = R(`activate.bs.${N}`), F = (t) => { - const { target: e, scrollTarget: s, options: o, itemsLength: n, scrollHeight: r, element: a } = t, { offset: c } = o, i = s !== a, l = e && C("A", e), x = T(a), m = s.scrollHeight; - if (t.scrollTop = s.scrollTop, l && (m !== r || n !== l.length)) { - let h, g, u; - t.items = [], t.targets = [], t.offsets = [], t.scrollHeight = m, t.maxScroll = t.scrollHeight - K(t), Array.from(l).forEach((d) => { - h = k(d, "href"), g = h && h.charAt(0) === "#" && h.slice(-1) !== "#" && E(h, x), g && (t.items.push(d), t.targets.push(g), u = b(g), t.offsets.push( - (i ? u.top + t.scrollTop : g.offsetTop) - c + target: void 0 +}, V = (t) => k(t, C), _ = (t) => new M(t), H = O(`activate.bs.${G}`), $ = (t) => { + const { + target: e, + scrollTarget: s, + options: o, + itemsLength: c, + scrollHeight: r, + element: i, + _observer: n + } = t, { offset: l } = o, h = s !== i, f = e && w("A", e), L = I(i), u = s.scrollHeight; + if (t.scrollTop = s.scrollTop, f && (u !== r || c !== f.length)) { + let d, m, a, y; + t.items = [], t.targets = [], t.offsets = [], t.scrollHeight = u, t.maxScroll = t.scrollHeight - J(t), Array.from(f).forEach((S) => { + d = Y(S, "href"), m = d?.slice(1), a = m?.length ? L.getElementById(m) : null, a && (t.items.push(S), t.targets.push(a), y = n?.getEntry(a)?.boundingClientRect || A(a), t.offsets.push( + (h ? y.top + t.scrollTop : a.offsetTop) - l )); }), t.itemsLength = t.items.length; } -}, v = ({ targets: t, scrollTarget: e, element: s, _observer: o }, n) => { - n ? e === s ? t.forEach((r) => o.observe(r)) : o.observe(s) : o.disconnect(); -}, J = (t) => t.scrollHeight, K = ({ element: t, scrollTarget: e }) => e !== t ? e.clientHeight : b(t).height, w = (t) => { - [...C("A", t)].forEach((e) => { - f(e, p) && q(e, p); - }); -}, H = (t, e) => { +}, T = ({ targets: t, scrollTarget: e, element: s, _observer: o }, c) => { + c ? e === s ? t?.forEach((r) => o.observe(r)) : o.observe(s) : o.disconnect(); +}, z = (t) => t.scrollHeight, J = ({ element: t, scrollTarget: e }) => e !== t ? e.clientHeight : A(t).height, x = (t) => { + Array.from(w("A", t)).forEach( + (e) => { + p(e, g) && Z(e, g); + } + ); +}, E = (t, e) => { const { target: s, element: o } = t; - I(s) && w(s), t.activeItem = e, y(e, p); - const n = []; + b(s) && x(s), t.activeItem = e, v(e, g); + const c = []; let r = e; - for (; r !== O(o); ) - r = r.parentElement, (f(r, "nav") || f(r, "dropdown-menu")) && n.push(r); - n.forEach((a) => { - const c = a.previousElementSibling; - c && !f(c, p) && y(c, p); - }), S.relatedTarget = e, G(o, S); + for (; r !== j(o); ) + r = r.parentElement, (p(r, "nav") || p(r, "dropdown-menu")) && c.push(r); + c.forEach((i) => { + const n = i.previousElementSibling; + n && !p(n, g) && v(n, g); + }), H.relatedTarget = e, D(o, H); }; -class P extends B { - static selector = Q; - static init = z; - static getInstance = j; +class M extends R { + static selector = K; + static init = _; + static getInstance = V; /** * @param target the target element * @param config the instance options */ constructor(e, s) { super(e, s); - const { element: o, options: n } = this; - this.target = E( - n.target, - T(o) - ), this.target && (this.scrollTarget = o.clientHeight < o.scrollHeight ? o : L(o), this.scrollHeight = J(this.scrollTarget), this.refresh(), this._observer = new M(() => this.refresh(), { + const { element: o, options: c } = this, r = q( + c.target, + I(o) + ); + r && (this.target = r, this.scrollTarget = o.clientHeight < o.scrollHeight ? o : B(o), this.scrollHeight = z(this.scrollTarget), this.refresh(), this._observer = new F((i) => { + requestAnimationFrame(() => { + i.some((n) => n.isVisible) && this.refresh(); + }); + }, { root: this.scrollTarget - }), v(this, !0)); + }), T(this, !0)); } - /* eslint-disable */ /** * Returns component name string. */ get name() { - return A; + return C; } /** * Returns component default options. */ get defaults() { - return $; + return N; } - /* eslint-enable */ - // SCROLLSPY PUBLIC METHODS - // ======================== - /** Updates all items. */ refresh = () => { const { target: e } = this; - if (I(e) && e.offsetHeight > 0) { - F(this); - const { scrollTop: s, maxScroll: o, itemsLength: n, items: r, activeItem: a } = this; - if (s >= o) { - const i = r[n - 1]; - a !== i && H(this, i); - return; - } - const { offsets: c } = this; - if (a && s < c[0] && c[0] > 0) { - this.activeItem = null, e && w(e); - return; - } - r.forEach((i, l) => { - a !== i && s >= c[l] && (typeof c[l + 1] > "u" || s < c[l + 1]) && H(this, i); - }); + if (!b(e) || e.offsetHeight === 0) return; + $(this); + const { scrollTop: s, maxScroll: o, itemsLength: c, items: r, activeItem: i } = this; + if (s >= o) { + const l = r[c - 1]; + i !== l && E(this, l); + return; + } + const { offsets: n } = this; + if (i && s < n[0] && n[0] > 0) { + this.activeItem = null, e && x(e); + return; } + r.forEach((l, h) => { + i !== l && s >= n[h] && (typeof n[h + 1] > "u" || s < n[h + 1]) && E(this, l); + }); }; - /** Removes `ScrollSpy` from the target element. */ dispose() { const e = { ...this }; - v(e), super.dispose(); + T(e), super.dispose(); } } export { - P as default + M as default }; //# sourceMappingURL=scrollspy.mjs.map diff --git a/dist/components/scrollspy.mjs.map b/dist/components/scrollspy.mjs.map index 3987c188..9b43d243 100644 --- a/dist/components/scrollspy.mjs.map +++ b/dist/components/scrollspy.mjs.map @@ -1 +1 @@ -{"version":3,"file":"scrollspy.mjs","sources":["../../src/strings/scrollspyString.ts","../../src/strings/scrollspyComponent.ts","../../src/components/scrollspy.ts"],"sourcesContent":["/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: ScrollSpyOptions = {\n offset: 10,\n target: null,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: HTMLElement) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n"],"names":["scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","element","getInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","createCustomEvent","updateSpyTargets","self","target","scrollTarget","options","itemsLength","scrollHeight","offset","isRoot","links","getElementsByTagName","doc","getDocument","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","getAttribute","querySelector","getBoundingClientRect","toggleObservers","targets","_observer","add","getScrollHeight","clear","item","hasClass","activeClass","removeClass","activate","isHTMLElement","addClass","parents","parentItem","getDocumentBody","menuItem","parentLink","dispatchEvent","BaseComponent","config","getDocumentElement","PositionObserver","scrollTop","maxScroll","items","activeItem","newActiveItem","offsets","i","clone"],"mappings":";;;AACA,MAAMA,IAAkB,aCAlBC,IAAqB,aC6BrBC,IAAoB,0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,MAAM;AACzB,QACEH,MAAepB,KACfiB,KAAaK,EAAQC,CAAC,MACrB,OAAOD,EAAQC,IAAI,CAAC,IAAM,OAAeN,IAAYK,EAAQC,IAAI,CAAC,MAEnEnB,EAAS,MAAMJ,CAAI;AAAA,MACrB,CACD;AAAA,IAAA;AAAA,EAEL;AAAA;AAAA,EAGA,UAAU;AACF,UAAAwB,IAAQ,EAAE,GAAG,KAAK;AACxB,IAAA9B,EAAgB8B,CAAK,GACrB,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file +{"version":3,"file":"scrollspy.mjs","sources":["../../src/strings/scrollspyString.ts","../../src/strings/scrollspyComponent.ts","../../src/components/scrollspy.ts"],"sourcesContent":["/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n"],"names":["scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","element","getInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","createCustomEvent","updateSpyTargets","self","target","scrollTarget","options","itemsLength","scrollHeight","_observer","offset","isRoot","links","getElementsByTagName","doc","getDocument","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","getAttribute","getBoundingClientRect","toggleObservers","targets","add","getScrollHeight","clear","item","hasClass","activeClass","removeClass","activate","isHTMLElement","addClass","parents","parentItem","getDocumentBody","menuItem","parentLink","dispatchEvent","BaseComponent","config","spyTarget","querySelector","getDocumentElement","PositionObserver","entries","entry","scrollTop","maxScroll","items","activeItem","newActiveItem","offsets","i","clone"],"mappings":";;;AACA,MAAMA,IAAkB,aCAlBC,IAAqB,aC6BrBC,IAAoB,0BAEpBC,IAA+C;AAAA,EACnD,QAAQ;AAAA,EACR,QAAQ;AACV,GAUMC,IAAuB,CAACC,MAC5BC,EAAuBD,GAASJ,CAAkB,GAK9CM,IAAwB,CAACF,MAAqB,IAAIG,EAAUH,CAAO,GAInEI,IAAoBC,EAGxB,eAAeV,CAAe,EAAE,GAS5BW,IAAmB,CAACC,MAAoB;AACtC,QAAA;AAAA,IACJ,QAAAC;AAAA,IACA,cAAAC;AAAA,IACA,SAAAC;AAAA,IACA,aAAAC;AAAA,IACA,cAAAC;AAAA,IACA,SAAAZ;AAAA,IACA,WAAAa;AAAA,EAAA,IACEN,GACE,EAAE,QAAAO,MAAWJ,GACbK,IAASN,MAAiBT,GAE1BgB,IAAQR,KAAUS,EAAwC,KAAKT,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rB,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file diff --git a/dist/components/tab.cjs b/dist/components/tab.cjs index 18811440..94910d2b 100644 --- a/dist/components/tab.cjs +++ b/dist/components/tab.cjs @@ -1,2 +1,2 @@ -"use strict";const e=require("./base-component-D3rSrWwH.js"),p=require("./event-listener-W3RGkfJ6.js"),b=require("./collapsingClass-CLblascz.js"),c=require("./activeClass-CxJYQAGN.js"),C=require("./fadeClass-Co6nOzNJ.js"),u=require("./showClass-D_Ms1FgG.js"),m=require("./dropdownClasses-CnEyz_iw.js"),I=require("./dataBsToggle-Dj-Ng54N.js"),T=require("./getTargetElement-DOtJ4BXO.js"),g="tab",y="Tab",w=`[${I.dataBsToggle}="${g}"]`,A=a=>e.getInstance(a,y),P=a=>new B(a),v=e.createCustomEvent(`show.bs.${g}`),H=e.createCustomEvent(`shown.bs.${g}`),f=e.createCustomEvent(`hide.bs.${g}`),L=e.createCustomEvent(`hidden.bs.${g}`),h=new Map,M=a=>{const{tabContent:s,nav:t}=a;s&&e.hasClass(s,b.collapsingClass)&&(s.style.height="",e.removeClass(s,b.collapsingClass)),t&&e.Timer.clear(t)},q=a=>{const{element:s,tabContent:t,content:n,nav:i}=a,{tab:l}=e.isHTMLElement(i)&&h.get(i)||{tab:null};if(t&&n&&e.hasClass(n,C.fadeClass)){const{currentHeight:o,nextHeight:r}=h.get(s)||{currentHeight:0,nextHeight:0};o!==r?setTimeout(()=>{t.style.height=`${r}px`,e.reflow(t),e.emulateTransitionEnd(t,()=>M(a))},50):M(a)}else i&&e.Timer.clear(i);H.relatedTarget=l,e.dispatchEvent(s,H)},x=a=>{const{element:s,content:t,tabContent:n,nav:i}=a,{tab:l,content:o}=i&&h.get(i)||{tab:null,content:null};let r=0;if(n&&t&&e.hasClass(t,C.fadeClass)&&([o,t].forEach(d=>{e.isHTMLElement(d)&&e.addClass(d,"overflow-hidden")}),r=e.isHTMLElement(o)?o.scrollHeight:0),v.relatedTarget=l,L.relatedTarget=s,e.dispatchEvent(s,v),!v.defaultPrevented){if(t&&e.addClass(t,c.activeClass),o&&e.removeClass(o,c.activeClass),n&&t&&e.hasClass(t,C.fadeClass)){const d=t.scrollHeight;h.set(s,{currentHeight:r,nextHeight:d,tab:null,content:null}),e.addClass(n,b.collapsingClass),n.style.height=`${r}px`,e.reflow(n),[o,t].forEach(E=>{E&&e.removeClass(E,"overflow-hidden")})}t&&t&&e.hasClass(t,C.fadeClass)?setTimeout(()=>{e.addClass(t,u.showClass),e.emulateTransitionEnd(t,()=>{q(a)})},1):(t&&e.addClass(t,u.showClass),q(a)),l&&e.dispatchEvent(l,L)}},$=a=>{const{nav:s}=a;if(!e.isHTMLElement(s))return{tab:null,content:null};const t=e.getElementsByClassName(c.activeClass,s);let n=null;t.length===1&&!m.dropdownMenuClasses.some(l=>e.hasClass(t[0].parentElement,l))?[n]=t:t.length>1&&(n=t[t.length-1]);const i=e.isHTMLElement(n)?T.getTargetElement(n):null;return{tab:n,content:i}},S=a=>{if(!e.isHTMLElement(a))return null;const s=e.closest(a,`.${m.dropdownMenuClasses.join(",.")}`);return s?e.querySelector(`.${m.dropdownMenuClasses[0]}-toggle`,s):null},k=a=>{const s=A(a.target);s&&(a.preventDefault(),s.show())};class B extends e.BaseComponent{static selector=w;static init=P;static getInstance=A;constructor(s){super(s);const{element:t}=this,n=T.getTargetElement(t);if(n){const i=e.closest(t,".nav"),l=e.closest(n,".tab-content");this.nav=i,this.content=n,this.tabContent=l,this.dropdown=S(t);const{tab:o}=$(this);if(i&&!o){const r=e.querySelector(w,i),d=r&&T.getTargetElement(r);d&&(e.addClass(r,c.activeClass),e.addClass(d,u.showClass),e.addClass(d,c.activeClass),e.setAttribute(t,e.ariaSelected,"true"))}this._toggleEventListeners(!0)}}get name(){return y}show(){const{element:s,content:t,nav:n,dropdown:i}=this;if(!(n&&e.Timer.get(n))&&!e.hasClass(s,c.activeClass)){const{tab:l,content:o}=$(this);if(n&&h.set(n,{tab:l,content:o,currentHeight:0,nextHeight:0}),f.relatedTarget=s,e.isHTMLElement(l)&&(e.dispatchEvent(l,f),!f.defaultPrevented)){e.addClass(s,c.activeClass),e.setAttribute(s,e.ariaSelected,"true");const r=e.isHTMLElement(l)&&S(l);if(r&&e.hasClass(r,c.activeClass)&&e.removeClass(r,c.activeClass),n){const d=()=>{l&&(e.removeClass(l,c.activeClass),e.setAttribute(l,e.ariaSelected,"false")),i&&!e.hasClass(i,c.activeClass)&&e.addClass(i,c.activeClass)};o&&(e.hasClass(o,C.fadeClass)||t&&e.hasClass(t,C.fadeClass))?e.Timer.set(n,d,1):d()}o&&(e.removeClass(o,u.showClass),e.hasClass(o,C.fadeClass)?e.emulateTransitionEnd(o,()=>x(this)):x(this))}}}_toggleEventListeners=s=>{(s?p.E:p.r)(this.element,e.mouseclickEvent,k)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=B; +"use strict";const t=require("./base-component-DaZCwW-u.js"),m=require("./event-listener-BQdA_KAC.js"),v=require("./collapsingClass-CLblascz.js"),c=require("./activeClass-CxJYQAGN.js"),h=require("./fadeClass-Co6nOzNJ.js"),u=require("./showClass-D_Ms1FgG.js"),T=require("./dropdownClasses-CnEyz_iw.js"),P=require("./dataBsToggle-Dj-Ng54N.js"),p=require("./getTargetElement-CXAsWuzD.js"),f="tab",k="Tab",q=`[${P.dataBsToggle}="${f}"]`,L=o=>t.to(o,k),B=o=>new M(o),C=t.vo(`show.bs.${f}`),E=t.vo(`shown.bs.${f}`),b=t.vo(`hide.bs.${f}`),H=t.vo(`hidden.bs.${f}`),d=new Map,Y=o=>{const{tabContent:n,nav:e}=o;n&&t.Yn(n,v.collapsingClass)&&(n.style.height="",t.Zn(n,v.collapsingClass)),e&&t.yo.clear(e)},x=o=>{const{element:n,tabContent:e,content:s,nav:l}=o,{tab:a}=t.m(l)&&d.get(l)||{tab:null};if(e&&s&&t.Yn(s,h.fadeClass)){const{currentHeight:i,nextHeight:r}=d.get(n)||{currentHeight:0,nextHeight:0};i!==r?setTimeout(()=>{e.style.height=`${r}px`,t.Eo(e),t.ro(e,()=>Y(o))},50):Y(o)}else l&&t.yo.clear(l);E.relatedTarget=a,t.q(n,E)},$=o=>{const{element:n,content:e,tabContent:s,nav:l}=o,{tab:a,content:i}=l&&d.get(l)||{tab:null,content:null};let r=0;if(s&&e&&t.Yn(e,h.fadeClass)&&([i,e].forEach(g=>{g&&t.qn(g,"overflow-hidden")}),r=i?i.scrollHeight:0),C.relatedTarget=a,H.relatedTarget=n,t.q(n,C),!C.defaultPrevented){if(e&&t.qn(e,c.activeClass),i&&t.Zn(i,c.activeClass),s&&e&&t.Yn(e,h.fadeClass)){const g=e.scrollHeight;d.set(n,{currentHeight:r,nextHeight:g,tab:null,content:null}),t.qn(s,v.collapsingClass),s.style.height=`${r}px`,t.Eo(s),[i,e].forEach(w=>{w&&t.Zn(w,"overflow-hidden")})}e&&e&&t.Yn(e,h.fadeClass)?setTimeout(()=>{t.qn(e,u.showClass),t.ro(e,()=>{x(o)})},1):(e&&t.qn(e,u.showClass),x(o)),a&&t.q(a,H)}},y=o=>{const{nav:n}=o;if(!t.m(n))return{tab:null,content:null};const e=t.Go(c.activeClass,n);let s=null;e.length===1&&!T.dropdownMenuClasses.some(a=>t.Yn(e[0].parentElement,a))?[s]=e:e.length>1&&(s=e[e.length-1]);const l=t.m(s)?p.getTargetElement(s):null;return{tab:s,content:l}},Z=o=>{if(!t.m(o))return null;const n=t.ke(o,`.${T.dropdownMenuClasses.join(",.")}`);return n?t.Ro(`.${T.dropdownMenuClasses[0]}-toggle`,n):null},D=o=>{const n=L(o.target);o.preventDefault(),n&&n.show()};class M extends t.BaseComponent{static selector=q;static init=B;static getInstance=L;constructor(n){super(n);const{element:e}=this,s=p.getTargetElement(e);if(!s)return;const l=t.ke(e,".nav"),a=t.ke(s,".tab-content");this.nav=l,this.content=s,this.tabContent=a,this.dropdown=Z(e);const{tab:i}=y(this);if(l&&!i){const r=t.Ro(q,l),g=r&&p.getTargetElement(r);g&&(t.qn(r,c.activeClass),t.qn(g,u.showClass),t.qn(g,c.activeClass),t.Qn(e,t.Fe,"true"))}this._toggleEventListeners(!0)}get name(){return k}show(){const{element:n,content:e,nav:s,dropdown:l}=this;if(s&&t.yo.get(s)||t.Yn(n,c.activeClass))return;const{tab:a,content:i}=y(this);if(s&&a&&d.set(s,{tab:a,content:i,currentHeight:0,nextHeight:0}),b.relatedTarget=n,!t.m(a)||(t.q(a,b),b.defaultPrevented))return;t.qn(n,c.activeClass),t.Qn(n,t.Fe,"true");const r=t.m(a)&&Z(a);if(r&&t.Yn(r,c.activeClass)&&t.Zn(r,c.activeClass),s){const g=()=>{a&&(t.Zn(a,c.activeClass),t.Qn(a,t.Fe,"false")),l&&!t.Yn(l,c.activeClass)&&t.qn(l,c.activeClass)};i&&(t.Yn(i,h.fadeClass)||e&&t.Yn(e,h.fadeClass))?t.yo.set(s,g,1):g()}i&&(t.Zn(i,u.showClass),t.Yn(i,h.fadeClass)?t.ro(i,()=>$(this)):$(this))}_toggleEventListeners=n=>{(n?m.E:m.r)(this.element,t.mt,D)};dispose(){this._toggleEventListeners(),super.dispose()}}module.exports=M; //# sourceMappingURL=tab.cjs.map diff --git a/dist/components/tab.cjs.map b/dist/components/tab.cjs.map index eb408d0a..90c79ade 100644 --- a/dist/components/tab.cjs.map +++ b/dist/components/tab.cjs.map @@ -1 +1 @@ -{"version":3,"file":"tab.cjs","sources":["../../src/strings/tabString.ts","../../src/strings/tabComponent.ts","../../src/components/tab.ts"],"sourcesContent":["/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["tabString","tabComponent","tabSelector","dataBsToggle","getTabInstance","element","getInstance","tabInitCallback","Tab","showTabEvent","createCustomEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","self","tabContent","nav","hasClass","collapsingClass","removeClass","Timer","triggerTabShow","nextContent","tab","isHTMLElement","fadeClass","currentHeight","nextHeight","reflow","emulateTransitionEnd","dispatchEvent","triggerTabHide","content","c","addClass","activeClass","showClass","getActiveTab","activeTabs","getElementsByClassName","dropdownClasses","getTargetElement","getParentDropdown","dropdown","closest","querySelector","tabClickHandler","e","BaseComponent","target","container","firstTab","firstTabContent","setAttribute","ariaSelected","activeDropdown","toggleTab","add","addListener","removeListener","mouseclickEvent"],"mappings":"kYACMA,EAAY,MCAZC,EAAe,MCqCfC,EAAc,IAAIC,EAAAA,YAAY,KAAKH,CAAS,KAM5CI,EAAkBC,GACtBC,cAAiBD,EAASJ,CAAY,EAGlCM,EAAmBF,GAAyB,IAAIG,EAAIH,CAAO,EAQ3DI,EAAeC,EAAA,kBACnB,WAAWV,CAAS,EACtB,EACMW,EAAgBD,EAAA,kBACpB,YAAYV,CAAS,EACvB,EACMY,EAAeF,EAAA,kBACnB,WAAWV,CAAS,EACtB,EACMa,EAAiBH,EAAA,kBACrB,aAAaV,CAAS,EACxB,EAaMc,MAA+C,IAS/CC,EAAiBC,GAAc,CAC7B,KAAA,CAAE,WAAAC,EAAY,IAAAC,CAAA,EAAQF,EAGxBC,GAAcE,EAAAA,SAASF,EAAYG,EAAe,eAAA,IACpDH,EAAW,MAAM,OAAS,GAC1BI,EAAA,YAAYJ,EAAYG,iBAAe,GAIrCF,GAAWI,EAAAA,MAAA,MAAMJ,CAAG,CAC1B,EAOMK,EAAkBP,GAAc,CACpC,KAAM,CAAE,QAAAX,EAAS,WAAAY,EAAY,QAASO,EAAa,IAAAN,GAAQF,EACrD,CAAE,IAAAS,GAASC,EAAA,cAAcR,CAAG,GAAKJ,EAAW,IAAII,CAAG,GAEvD,CAAE,IAAK,IAAK,EAGd,GAAID,GAAcO,GAAeL,EAAS,SAAAK,EAAaG,EAAS,SAAA,EAAG,CACjE,KAAM,CAAE,cAAAC,EAAe,WAAAC,CAAA,EAAef,EAAW,IAAIT,CAAO,GAE1D,CAAE,cAAe,EAAG,WAAY,CAAE,EAEhCuB,IAAkBC,EAEpB,WAAW,IAAM,CAC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AY,EAAG,EAIvEtB,EAAa,cAAgBP,EAGzBqB,EAAAA,cAAcD,CAAG,IACnBO,EAAA,cAAcP,EAAoBb,CAAY,EAE1C,CAACA,EAAa,kBAAkB,CAClCwB,EAAA,SAAS/B,EAASgC,aAAW,EAChBkB,eAAAlD,EAASmD,eAAc,MAAM,EAE1C,MAAMC,EAAiB/B,EAAA,cAAcD,CAAG,GAAKmB,EAAkBnB,CAAG,EAMlE,GALIgC,GAAkBtC,EAAAA,SAASsC,EAAgBpB,EAAW,WAAA,GACxDhB,EAAA,YAAYoC,EAAgBpB,aAAW,EAIrCnB,EAAK,CACP,MAAMwC,EAAY,IAAM,CAElBjC,IACFJ,EAAA,YAAYI,EAAKY,aAAW,EACfkB,eAAA9B,EAAK+B,eAAc,OAAO,GAErCX,GAAY,CAAC1B,EAAAA,SAAS0B,EAAUR,EAAW,WAAA,GAC7CD,EAAA,SAASS,EAAUR,aAAW,CAElC,EAGEH,IACCf,WAASe,EAASP,EAAS,SAAA,GACzBH,GAAeL,WAASK,EAAaG,EAAS,SAAA,GAE3CL,EAAAA,MAAA,IAAIJ,EAAKwC,EAAW,CAAC,EACZA,EAAA,CAAA,CAIfxB,IACFb,EAAA,YAAYa,EAASI,WAAS,EAC1BnB,EAAA,SAASe,EAASP,EAAAA,SAAS,EAC7BI,EAAAA,qBAAqBG,EAAS,IAAMD,EAAe,IAAI,CAAC,EAExDA,EAAe,IAAI,EAEvB,CAEJ,CACF,CAQF,sBAAyB0B,GAAkB,EAC1BA,EAAMC,EAAAA,EAAcC,EAAA,GAC5B,KAAK,QAASC,EAAAA,gBAAiBd,CAAe,CACvD,EAGA,SAAU,CACR,KAAK,sBAAsB,EAC3B,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file +{"version":3,"file":"tab.cjs","sources":["../../src/strings/tabString.ts","../../src/strings/tabComponent.ts","../../src/components/tab.ts"],"sourcesContent":["/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["tabString","tabComponent","tabSelector","dataBsToggle","getTabInstance","element","getInstance","tabInitCallback","Tab","showTabEvent","createCustomEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","self","tabContent","nav","hasClass","collapsingClass","removeClass","Timer","triggerTabShow","nextContent","tab","isHTMLElement","fadeClass","currentHeight","nextHeight","reflow","emulateTransitionEnd","dispatchEvent","triggerTabHide","content","c","addClass","activeClass","showClass","getActiveTab","activeTabs","getElementsByClassName","dropdownClasses","getTargetElement","getParentDropdown","dropdown","closest","querySelector","tabClickHandler","e","BaseComponent","target","container","firstTab","firstTabContent","setAttribute","ariaSelected","activeDropdown","toggleTab","add","addListener","removeListener","mouseclickEvent"],"mappings":"kYACMA,EAAY,MCAZC,EAAe,MCsCfC,EAAc,IAAIC,EAAAA,YAAY,KAAKH,CAAS,KAM5CI,EAAkBC,GACtBC,KAAiBD,EAASJ,CAAY,EAGlCM,EAAmBF,GAAqB,IAAIG,EAAIH,CAAO,EAQvDI,EAAeC,EAAA,GACnB,WAAWV,CAAS,EACtB,EACMW,EAAgBD,EAAA,GACpB,YAAYV,CAAS,EACvB,EACMY,EAAeF,EAAA,GACnB,WAAWV,CAAS,EACtB,EACMa,EAAiBH,EAAA,GACrB,aAAaV,CAAS,EACxB,EAaMc,UASAC,EAAiBC,GAAc,CAC7B,KAAA,CAAE,WAAAC,EAAY,IAAAC,CAAA,EAAQF,EAGxBC,GAAcE,EAAAA,GAASF,EAAYG,EAAe,eAAA,IACpDH,EAAW,MAAM,OAAS,GAC1BI,EAAA,GAAYJ,EAAYG,iBAAe,GAIrCF,GAAWI,EAAAA,GAAA,MAAMJ,CAAG,CAC1B,EAOMK,EAAkBP,GAAc,CACpC,KAAM,CAAE,QAAAX,EAAS,WAAAY,EAAY,QAASO,EAAa,IAAAN,GAAQF,EACrD,CAAE,IAAAS,GAASC,EAAA,EAAcR,CAAG,GAAKJ,EAAW,IAAII,CAAG,GAEvD,CAAE,IAAK,IAAK,EAGd,GAA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bf1..b01222e6 100644 --- a/dist/components/tab.d.ts +++ b/dist/components/tab.d.ts @@ -1,12 +1,12 @@ /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -23,15 +23,16 @@ declare interface BaseOptions { /** Creates a new `Tab` instance. */ declare class Tab extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Tab; - static getInstance: (element: HTMLElement) => Tab | null; + static init: (element: Element) => Tab; + static getInstance: (element: Element) => Tab | null; + element: HTMLElement; nav: HTMLElement | null; content: HTMLElement | null; tabContent: HTMLElement | null; nextContent: HTMLElement | null; dropdown: HTMLElement | null; /** @param target the target element */ - constructor(target: HTMLElement | string); + constructor(target: Element | string); /** * Returns component name string. */ diff --git a/dist/components/tab.mjs b/dist/components/tab.mjs index 6c4d35a8..06a189d7 100644 --- a/dist/components/tab.mjs +++ b/dist/components/tab.mjs @@ -1,121 +1,117 @@ -import { B as J, D as $, q as N, f, s as w, T as p, h as l, u as h, d as v, r as b, e as D, g as K, c as C, t as z, j as O, a5 as E, m as Q } from "./base-component-ylZzLp-h.mjs"; -import { E as R, r as U } from "./event-listener-C1-Yf9Z5.mjs"; +import { B as A, p as $, R, b as g, Q as C, y as p, Y as l, f as d, q as v, Z as b, r as B, t as F, v as w, e as Y, G as z, a5 as E, m as J } from "./base-component-Jx2aafTJ.mjs"; +import { E as K, r as N } from "./event-listener-CUwvA4j6.mjs"; import { c as y } from "./collapsingClass-BxKtDBMH.mjs"; import { a as c } from "./activeClass-iqaD75Su.mjs"; -import { f as d } from "./fadeClass-CLIYI_zn.mjs"; +import { f as h } from "./fadeClass-CLIYI_zn.mjs"; import { s as T } from "./showClass-C8hdJfjQ.mjs"; -import { d as S } from "./dropdownClasses-CdCdZ-PX.mjs"; -import { d as V } from "./dataBsToggle-B84TS15h.mjs"; -import { g as B } from "./getTargetElement-BFOUI7hP.mjs"; -const u = "tab", F = "Tab", L = `[${V}="${u}"]`, G = (s) => K(s, F), W = (s) => new Y(s), H = C( - `show.bs.${u}` -), P = C( - `shown.bs.${u}` -), x = C( - `hide.bs.${u}` -), k = C( - `hidden.bs.${u}` -), m = /* @__PURE__ */ new Map(), M = (s) => { +import { d as P } from "./dropdownClasses-CdCdZ-PX.mjs"; +import { d as O } from "./dataBsToggle-B84TS15h.mjs"; +import { g as k } from "./getTargetElement-Bv0W3Fir.mjs"; +const m = "tab", Z = "Tab", I = `[${O}="${m}"]`, j = (s) => F(s, Z), U = (s) => new W(s), H = w( + `show.bs.${m}` +), L = w( + `shown.bs.${m}` +), x = w( + `hide.bs.${m}` +), S = w( + `hidden.bs.${m}` +), u = /* @__PURE__ */ new Map(), _ = (s) => { const { tabContent: e, nav: t } = s; e && l(e, y) && (e.style.height = "", b(e, y)), t && p.clear(t); -}, _ = (s) => { - const { element: e, tabContent: t, content: n, nav: i } = s, { tab: o } = h(i) && m.get(i) || // istanbul ignore next @preserve - { tab: null }; - if (t && n && l(n, d)) { - const { currentHeight: a, nextHeight: r } = m.get(e) || // istanbul ignore next @preserve - { currentHeight: 0, nextHeight: 0 }; +}, q = (s) => { + const { element: e, tabContent: t, content: n, nav: i } = s, { tab: o } = d(i) && u.get(i) || { tab: null }; + if (t && n && l(n, h)) { + const { currentHeight: a, nextHeight: r } = u.get(e) || { currentHeight: 0, nextHeight: 0 }; a !== r ? setTimeout(() => { - t.style.height = `${r}px`, z(t), D(t, () => M(s)); - }, 50) : M(s); + t.style.height = `${r}px`, Y(t), B(t, () => _(s)); + }, 50) : _(s); } else i && p.clear(i); - P.relatedTarget = o, v(e, P); -}, j = (s) => { - const { element: e, content: t, tabContent: n, nav: i } = s, { tab: o, content: a } = i && m.get(i) || // istanbul ignore next @preserve - { tab: null, content: null }; + L.relatedTarget = o, v(e, L); +}, G = (s) => { + const { element: e, content: t, tabContent: n, nav: i } = s, { tab: o, content: a } = i && u.get(i) || { tab: null, content: null }; let r = 0; - if (n && t && l(t, d) && ([a, t].forEach((g) => { - h(g) && f(g, "overflow-hidden"); - }), r = h(a) ? a.scrollHeight : 0), H.relatedTarget = o, k.relatedTarget = e, v(e, H), !H.defaultPrevented) { - if (t && f(t, c), a && b(a, c), n && t && l(t, d)) { - const g = t.scrollHeight; - m.set(e, { + if (n && t && l(t, h) && ([a, t].forEach((f) => { + f && g(f, "overflow-hidden"); + }), r = a ? a.scrollHeight : 0), H.relatedTarget = o, S.relatedTarget = e, v(e, H), !H.defaultPrevented) { + if (t && g(t, c), a && b(a, c), n && t && l(t, h)) { + const f = t.scrollHeight; + u.set(e, { currentHeight: r, - nextHeight: g, + nextHeight: f, tab: null, content: null - }), f(n, y), n.style.height = `${r}px`, z(n), [a, t].forEach((I) => { - I && b(I, "overflow-hidden"); + }), g(n, y), n.style.height = `${r}px`, Y(n), [a, t].forEach((D) => { + D && b(D, "overflow-hidden"); }); } - t && t && l(t, d) ? setTimeout(() => { - f(t, T), D(t, () => { - _(s); + t && t && l(t, h) ? setTimeout(() => { + g(t, T), B(t, () => { + q(s); }); - }, 1) : (t && f(t, T), _(s)), o && v(o, k); + }, 1) : (t && g(t, T), q(s)), o && v(o, S); } -}, q = (s) => { +}, M = (s) => { const { nav: e } = s; - if (!h(e)) + if (!d(e)) return { tab: null, content: null }; - const t = O(c, e); + const t = z( + c, + e + ); let n = null; - t.length === 1 && !S.some( + t.length === 1 && !P.some( (o) => l(t[0].parentElement, o) ) ? [n] = t : t.length > 1 && (n = t[t.length - 1]); - const i = h(n) ? B(n) : null; + const i = d(n) ? k(n) : null; return { tab: n, content: i }; -}, A = (s) => { - if (!h(s)) return null; - const e = $(s, `.${S.join(",.")}`); - return e ? N(`.${S[0]}-toggle`, e) : null; -}, X = (s) => { - const e = G(s.target); - e && (s.preventDefault(), e.show()); +}, Q = (s) => { + if (!d(s)) return null; + const e = $(s, `.${P.join(",.")}`); + return e ? R(`.${P[0]}-toggle`, e) : null; +}, V = (s) => { + const e = j(s.target); + s.preventDefault(), e && e.show(); }; -class Y extends J { - static selector = L; - static init = W; - static getInstance = G; - /** @param target the target element */ +class W extends A { + static selector = I; + static init = U; + static getInstance = j; constructor(e) { super(e); - const { element: t } = this, n = B(t); - if (n) { - const i = $(t, ".nav"), o = $(n, ".tab-content"); - this.nav = i, this.content = n, this.tabContent = o, this.dropdown = A(t); - const { tab: a } = q(this); - if (i && !a) { - const r = N(L, i), g = r && B(r); - g && (f(r, c), f(g, T), f(g, c), w(t, E, "true")); - } - this._toggleEventListeners(!0); + const { element: t } = this, n = k(t); + if (!n) return; + const i = $(t, ".nav"), o = $( + n, + ".tab-content" + ); + this.nav = i, this.content = n, this.tabContent = o, this.dropdown = Q(t); + const { tab: a } = M(this); + if (i && !a) { + const r = R(I, i), f = r && k(r); + f && (g(r, c), g(f, T), g(f, c), C(t, E, "true")); } + this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return F; + return Z; } - // TAB PUBLIC METHODS - // ================== - /** Shows the tab to the user. */ show() { const { element: e, content: t, nav: n, dropdown: i } = this; - if (!(n && p.get(n)) && !l(e, c)) { - const { tab: o, content: a } = q(this); - if (n && m.set(n, { tab: o, content: a, currentHeight: 0, nextHeight: 0 }), x.relatedTarget = e, h(o) && (v(o, x), !x.defaultPrevented)) { - f(e, c), w(e, E, "true"); - const r = h(o) && A(o); - if (r && l(r, c) && b(r, c), n) { - const g = () => { - o && (b(o, c), w(o, E, "false")), i && !l(i, c) && f(i, c); - }; - a && (l(a, d) || t && l(t, d)) ? p.set(n, g, 1) : g(); - } - a && (b(a, T), l(a, d) ? D(a, () => j(this)) : j(this)); - } + if (n && p.get(n) || l(e, c)) return; + const { tab: o, content: a } = M(this); + if (n && o && u.set(n, { tab: o, content: a, currentHeight: 0, nextHeight: 0 }), x.relatedTarget = e, !d(o) || (v(o, x), x.defaultPrevented)) return; + g(e, c), C(e, E, "true"); + const r = d(o) && Q(o); + if (r && l(r, c) && b(r, c), n) { + const f = () => { + o && (b(o, c), C(o, E, "false")), i && !l(i, c) && g(i, c); + }; + a && (l(a, h) || t && l(t, h)) ? p.set(n, f, 1) : f(); } + a && (b(a, T), l(a, h) ? B(a, () => G(this)) : G(this)); } /** * Toggles on/off the `click` event listener. @@ -123,14 +119,13 @@ class Y extends J { * @param add when `true`, event listener is added */ _toggleEventListeners = (e) => { - (e ? R : U)(this.element, Q, X); + (e ? K : N)(this.element, J, V); }; - /** Removes the `Tab` component from the target element. */ dispose() { this._toggleEventListeners(), super.dispose(); } } export { - Y as default + W as default }; //# sourceMappingURL=tab.mjs.map diff --git a/dist/components/tab.mjs.map b/dist/components/tab.mjs.map index e7f0625b..ebbf51ac 100644 --- a/dist/components/tab.mjs.map +++ b/dist/components/tab.mjs.map @@ -1 +1 @@ -{"version":3,"file":"tab.mjs","sources":["../../src/strings/tabString.ts","../../src/strings/tabComponent.ts","../../src/components/tab.ts"],"sourcesContent":["/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["tabString","tabComponent","tabSelector","dataBsToggle","getTabInstance","element","getInstance","tabInitCallback","Tab","showTabEvent","createCustomEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","self","tabContent","nav","hasClass","collapsingClass","removeClass","Timer","triggerTabShow","nextContent","tab","isHTMLElement","fadeClass","currentHeight","nextHeight","reflow","emulateTransitionEnd","dispatchEvent","triggerTabHide","content","c","addClass","activeClass","showClass","getActiveTab","activeTabs","getElementsByClassName","dropdownClasses","getTargetElement","getParentDropdown","dropdown","closest","querySelector","tabClickHandler","e","BaseComponent","target","container","firstTab","firstTabContent","setAttribute","ariaSelected","activeDropdown","toggleTab","add","addListener","removeListener","mouseclickEvent"],"mappings":";;;;;;;;;AACA,MAAMA,IAAY,OCAZC,IAAe,OCqCfC,IAAc,IAAIC,CAAY,KA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,GAAgBpB,CAAW,KACxDhB,EAAYoC,GAAgBpB,CAAW,GAIrCnB,GAAK;AACP,gBAAMwC,IAAY,MAAM;AAEtB,YAAIjC,MACFJ,EAAYI,GAAKY,CAAW,GACfkB,EAAA9B,GAAK+B,GAAc,OAAO,IAErCX,KAAY,CAAC1B,EAAS0B,GAAUR,CAAW,KAC7CD,EAASS,GAAUR,CAAW;AAAA,UAElC;AAGE,UAAAH,MACCf,EAASe,GAASP,CAAS,KACzBH,KAAeL,EAASK,GAAaG,CAAS,KAE3CL,EAAA,IAAIJ,GAAKwC,GAAW,CAAC,IACZA,EAAA;AAAA,QAAA;AAInB,QAAIxB,MACFb,EAAYa,GAASI,CAAS,GAC1BnB,EAASe,GAASP,CAAS,IAC7BI,EAAqBG,GAAS,MAAMD,EAAe,IAAI,CAAC,IAExDA,EAAe,IAAI;AAAA,MAEvB;AAAA,IAEJ;AAAA,EACF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQF,wBAAwB,CAAC0B,MAAkB;AAElC,KADQA,IAAMC,IAAcC,GAC5B,KAAK,SAASC,GAAiBd,CAAe;AAAA,EACvD;AAAA;AAAA,EAGA,UAAU;AACR,SAAK,sBAAsB,GAC3B,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file +{"version":3,"file":"tab.mjs","sources":["../../src/strings/tabString.ts","../../src/strings/tabComponent.ts","../../src/components/tab.ts"],"sourcesContent":["/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n"],"names":["tabString","tabComponent","tabSelector","dataBsToggle","getTabInstance","element","getInstance","tabInitCallback","Tab","showTabEvent","createCustomEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","self","tabContent","nav","hasClass","collapsingClass","removeClass","Timer","triggerTabShow","nextContent","tab","isHTMLElement","fadeClass","currentHeight","nextHeight","reflow","emulateTransitionEnd","dispatchEvent","triggerTabHide","content","c","addClass","activeClass","showClass","getActiveTab","activeTabs","getElementsByClassName","dropdownClasses","getTargetElement","getParentDropdown","dropdown","closest","querySelector","tabClickHandler","e","BaseComponent","target","container","firstTab","firstTabContent","setAttribute","ariaSelected","activeDropdown","toggleTab","add","addListener","removeListener","mouseclickEvent"],"mappings":";;;;;;;;;AACA,MAAMA,IAAY,OCAZC,IAAe,OCsCfC,IAAc,IAAIC,CAAY,KAAKH,CAAS,MAM5CI,IAAiB,CAACC,MACtBC,EAAiBD,GAASJ,CAAY,GAGlCM,IAAkB,CAACF,MAAqB,IAAIG,EAAIH,CAAO,GAQvDI,IAAeC;AAAAA,EACnB,WAAWV,CAAS;AACtB,GACMW,IAAgBD;AAAAA,EACpB,YAAYV,CAAS;AACvB,GACMY,IAAeF;AAAAA,EACnB,WAAWV,CAAS;AACtB,GACMa,IAAiBH;AAAAA,EACrB,aAAaV,CAAS;AACxB,GAaMc,+BASAC,IAAgB,CAACC,MAAc;AAC7B,QAAA,EAAE,YAAAC,GAAY,KAAAC,EAAA,IAAQF;AAG5B,EAAIC,KAAcE,EAASF,GAAYG,CAAe,MACpDH,EAAW,MAAM,SAAS,IAC1BI,EAAYJ,GAAYG,CAAe,IAIrCF,KAAWI,EAAA,MAAMJ,CAAG;AAC1B,GAOMK,IAAiB,CAACP,MAAc;AACpC,QAAM,EAAE,SAAAX,GAAS,YAAAY,GAAY,SAASO,GAAa,KAAAN,MAAQF,GACrD,EAAE,KAAAS,MAASC,EAAcR,CAAG,KAAKJ,EAAW,IAAII,CAAG,KAEvD,EAAE,KAAK,KAAK;AAGd,MAAID,KAAcO,KAAeL,EAASK,GAAaG,CAAS,GAAG;AACjE,UAAM,EAAE,eAAAC,GAAe,YAAAC,EAAA,IAAef,EAAW,IAAIT,CAAO,KAE1D,EAAE,eAAe,GAAG,YAAY,EAAE;AAEpC,IAAIuB,MAAkBC,IAEpB,WAAW,MAAM;AACJ,MAAAZ,EAAA,MAAM,SAAS,GAAGY,CAAU,MACvCC,EAAOb,CAAU,GACjBc,EAAqBd,GAAY,MA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CwB,IAAAA,EAAS/B,GAASgC,CAAW,GAChBkB,EAAAlD,GAASmD,GAAc,MAAM;AAE1C,UAAMC,IAAiB/B,EAAcD,CAAG,KAAKmB,EAAkBnB,CAAG;AAMlE,QALIgC,KAAkBtC,EAASsC,GAAgBpB,CAAW,KACxDhB,EAAYoC,GAAgBpB,CAAW,GAIrCnB,GAAK;AACP,YAAMwC,IAAY,MAAM;AAEtB,QAAIjC,MACFJ,EAAYI,GAAKY,CAAW,GACfkB,EAAA9B,GAAK+B,GAAc,OAAO,IAErCX,KAAY,CAAC1B,EAAS0B,GAAUR,CAAW,KAC7CD,EAASS,GAAUR,CAAW;AAAA,MAElC;AAGE,MAAAH,MACCf,EAASe,GAASP,CAAS,KACzBH,KAAeL,EAASK,GAAaG,CAAS,KAE3CL,EAAA,IAAIJ,GAAKwC,GAAW,CAAC,IACZA,EAAA;AAAA,IAAA;AAInB,IAAIxB,MACFb,EAAYa,GAASI,CAAS,GAC1BnB,EAASe,GAASP,CAAS,IAC7BI,EAAqBG,GAAS,MAAMD,EAAe,IAAI,CAAC,IAExDA,EAAe,IAAI;AAAA,EAEvB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAQF,wBAAwB,CAAC0B,MAAkB;AAElC,KADQA,IAAMC,IAAcC,GAC5B,KAAK,SAASC,GAAiBd,CAAe;AAAA,EACvD;AAAA,EAGA,UAAU;AACR,SAAK,sBAAsB,GAC3B,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file diff --git a/dist/components/toast.cjs b/dist/components/toast.cjs index af960ea8..d5f08902 100644 --- a/dist/components/toast.cjs +++ b/dist/components/toast.cjs @@ -1,2 +1,2 @@ -"use strict";const e=require("./base-component-D3rSrWwH.js"),u=require("./event-listener-W3RGkfJ6.js"),l=require("./fadeClass-Co6nOzNJ.js"),d=require("./showClass-D_Ms1FgG.js"),b=require("./dataBsDismiss-CMHF7If_.js"),y=require("./dataBsToggle-Dj-Ng54N.js"),E=require("./getTargetElement-DOtJ4BXO.js"),i="toast",T="Toast",D=`.${i}`,B=`[${b.dataBsDismiss}="${i}"]`,p=`[${y.dataBsToggle}="${i}"]`,r="showing",w="hide",k={animation:!0,autohide:!0,delay:5e3},h=o=>e.getInstance(o,T),I=o=>new S(o),g=e.createCustomEvent(`show.bs.${i}`),L=e.createCustomEvent(`shown.bs.${i}`),C=e.createCustomEvent(`hide.bs.${i}`),_=e.createCustomEvent(`hidden.bs.${i}`),v=o=>{const{element:t,options:s}=o;e.removeClass(t,r),e.Timer.clear(t,r),e.dispatchEvent(t,L),s.autohide&&e.Timer.set(t,()=>o.hide(),s.delay,i)},f=o=>{const{element:t}=o;e.removeClass(t,r),e.removeClass(t,d.showClass),e.addClass(t,w),e.Timer.clear(t,i),e.dispatchEvent(t,_)},x=o=>{const{element:t,options:s}=o;e.addClass(t,r),s.animation?(e.reflow(t),e.emulateTransitionEnd(t,()=>f(o))):f(o)},A=o=>{const{element:t,options:s}=o;e.Timer.set(t,()=>{e.removeClass(t,w),e.reflow(t),e.addClass(t,d.showClass),e.addClass(t,r),s.animation?e.emulateTransitionEnd(t,()=>v(o)):v(o)},17,r)},H=o=>{const{target:t}=o,s=t&&e.closest(t,p),n=s&&E.getTargetElement(s),a=n&&h(n);a&&(s&&s.tagName==="A"&&o.preventDefault(),a.relatedTarget=s,a.show())},P=o=>{const t=o.target,s=h(t),{type:n,relatedTarget:a}=o;s&&t!==a&&!t.contains(a)&&([e.mouseenterEvent,e.focusinEvent].includes(n)?e.Timer.clear(t,i):e.Timer.set(t,()=>s.hide(),s.options.delay,i))};class S extends e.BaseComponent{static selector=D;static init=I;static getInstance=h;constructor(t,s){super(t,s);const{element:n,options:a}=this;a.animation&&!e.hasClass(n,l.fadeClass)?e.addClass(n,l.fadeClass):!a.animation&&e.hasClass(n,l.fadeClass)&&e.removeClass(n,l.fadeClass),this.dismiss=e.querySelector(B,n),this.triggers=[...e.querySelectorAll(p,e.getDocument(n))].filter(c=>E.getTargetElement(c)===n),this._toggleEventListeners(!0)}get name(){return T}get defaults(){return k}get isShown(){return e.hasClass(this.element,d.showClass)}show=()=>{const{element:t,isShown:s}=this;t&&!s&&(e.dispatchEvent(t,g),g.defaultPrevented||A(this))};hide=()=>{const{element:t,isShown:s}=this;t&&s&&(e.dispatchEvent(t,C),C.defaultPrevented||x(this))};_toggleEventListeners=t=>{const s=t?u.E:u.r,{element:n,triggers:a,dismiss:c,options:q,hide:$}=this;c&&s(c,e.mouseclickEvent,$),q.autohide&&[e.focusinEvent,e.focusoutEvent,e.mouseenterEvent,e.mouseleaveEvent].forEach(m=>s(n,m,P)),a.length&&a.forEach(m=>s(m,e.mouseclickEvent,H))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),e.Timer.clear(t,i),s&&e.removeClass(t,d.showClass),super.dispose()}}module.exports=S; +"use strict";const t=require("./base-component-DaZCwW-u.js"),m=require("./event-listener-BQdA_KAC.js"),l=require("./fadeClass-Co6nOzNJ.js"),h=require("./showClass-D_Ms1FgG.js"),S=require("./dataBsDismiss-CMHF7If_.js"),b=require("./dataBsToggle-Dj-Ng54N.js"),C=require("./getTargetElement-CXAsWuzD.js"),a="toast",p="Toast",Z=`.${a}`,B=`[${S.dataBsDismiss}="${a}"]`,q=`[${b.dataBsToggle}="${a}"]`,r="showing",v="hide",D={animation:!0,autohide:!0,delay:5e3},g=o=>t.to(o,p),L=o=>new E(o),u=t.vo(`show.bs.${a}`),k=t.vo(`shown.bs.${a}`),f=t.vo(`hide.bs.${a}`),I=t.vo(`hidden.bs.${a}`),w=o=>{const{element:e,options:s}=o;t.Zn(e,r),t.yo.clear(e,r),t.q(e,k),s.autohide&&t.yo.set(e,()=>o.hide(),s.delay,a)},T=o=>{const{element:e}=o;t.Zn(e,r),t.Zn(e,h.showClass),t.qn(e,v),t.yo.clear(e,a),t.q(e,I)},Y=o=>{const{element:e,options:s}=o;t.qn(e,r),s.animation?(t.Eo(e),t.ro(e,()=>T(o))):T(o)},_=o=>{const{element:e,options:s}=o;t.yo.set(e,()=>{t.Zn(e,v),t.Eo(e),t.qn(e,h.showClass),t.qn(e,r),s.animation?t.ro(e,()=>w(o)):w(o)},17,r)},x=o=>{const{target:e}=o,s=e&&t.ke(e,q),n=s&&C.getTargetElement(s),i=n&&g(n);i&&(s&&s.tagName==="A"&&o.preventDefault(),i.relatedTarget=s,i.show())},H=o=>{const e=o.target,s=g(e),{type:n,relatedTarget:i}=o;!s||e===i||e.contains(i)||([t.yt,t.ct].includes(n)?t.yo.clear(e,a):t.yo.set(e,()=>s.hide(),s.options.delay,a))};class E extends t.BaseComponent{static selector=Z;static init=L;static getInstance=g;constructor(e,s){super(e,s);const{element:n,options:i}=this;i.animation&&!t.Yn(n,l.fadeClass)?t.qn(n,l.fadeClass):!i.animation&&t.Yn(n,l.fadeClass)&&t.Zn(n,l.fadeClass),this.dismiss=t.Ro(B,n),this.triggers=[...t.de(q,t.d(n))].filter(c=>C.getTargetElement(c)===n),this._toggleEventListeners(!0)}get name(){return p}get defaults(){return D}get isShown(){return t.Yn(this.element,h.showClass)}show=()=>{const{element:e,isShown:s}=this;!e||s||(t.q(e,u),u.defaultPrevented||_(this))};hide=()=>{const{element:e,isShown:s}=this;!e||!s||(t.q(e,f),f.defaultPrevented||Y(this))};_toggleEventListeners=e=>{const s=e?m.E:m.r,{element:n,triggers:i,dismiss:c,options:y,hide:$}=this;c&&s(c,t.mt,$),y.autohide&&[t.ct,t.at,t.yt,t.wt].forEach(d=>s(n,d,H)),i.length&&i.forEach(d=>s(d,t.mt,x))};dispose(){const{element:e,isShown:s}=this;this._toggleEventListeners(),t.yo.clear(e,a),s&&t.Zn(e,h.showClass),super.dispose()}}module.exports=E; //# sourceMappingURL=toast.cjs.map diff --git a/dist/components/toast.cjs.map b/dist/components/toast.cjs.map index 80994da5..522de57c 100644 --- a/dist/components/toast.cjs.map +++ b/dist/components/toast.cjs.map @@ -1 +1 @@ -{"version":3,"file":"toast.cjs","sources":["../../src/strings/toastString.ts","../../src/strings/toastComponent.ts","../../src/components/toast.ts"],"sourcesContent":["/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n"],"names":["toastString","toastComponent","toastSelector","toastDismissSelector","dataBsDismiss","toastToggleSelector","dataBsToggle","showingClass","hideClass","toastDefaults","getToastInstance","element","getInstance","toastInitCallback","Toast","showToastEvent","createCustomEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","self","options","removeClass","Timer","dispatchEvent","hideToastComplete","showClass","addClass","hideToast","reflow","emulateTransitionEnd","showToast","toastClickHandler","e","target","trigger","closest","getTargetElement","interactiveToastHandler","type","relatedTarget","mouseenterEvent","focusinEvent","BaseComponent","config","hasClass","fadeClass","querySelector","querySelectorAll","getDocument","btn","isShown","add","action","addListener","removeListener","triggers","dismiss","hide","mouseclickEvent","focusoutEvent","mouseleaveEvent"],"mappings":"8SACMA,EAAc,QCAdC,EAAiB,Q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AAS,QACFA,EAAA,QAASN,GAChBG,EAAOH,EAAKS,kBAAiB3B,CAAiB,CAChD,CAEJ,EAGA,SAAU,CACF,KAAA,CAAE,QAAAtB,EAAS,QAAAyC,CAAA,EAAY,KAC7B,KAAK,sBAAsB,EACrB5B,QAAA,MAAMb,EAASX,CAAW,EAE5BoD,GACF7B,EAAA,YAAYZ,EAASgB,WAAS,EAEhC,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file +{"version":3,"file":"toast.cjs","sources":["../../src/strings/toastString.ts","../../src/strings/toastComponent.ts","../../src/components/toast.ts"],"sourcesContent":["/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n"],"names":["toastString","toastComponent","toastSelector","toastDismissSelector","dataBsDismiss","toastToggleSelector","dataBsToggle","showingClass","hideClass","toastDefaults","getToastInstance","element","getInstance","toastInitCallback","Toast","showToastEvent","createCustomEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","self","options","removeClass","Timer","dispatchEvent","hideToastComplete","showClass","addClass","hideToast","reflow","emulateTransitionEnd","showToast","toastClickHandler","e","target","trigger","closest","getTargetElement","interactiveToastHandler","type","relatedTarget","mouseenterEvent","focusinEvent","BaseComponent","config","hasClass","fadeClass","querySelector","querySelectorAll","getDocument","btn","isShown","add","action","addListener","removeListener","triggers","dismiss","hide","mouseclickEvent","focusoutEvent","mouseleaveEvent"],"mappings":"8SACMA,EAAc,QCAdC,EAAiB,QCqCjBC,EAAgB,IAAIF,CAAW,GAC/BG,EAAuB,IAAIC,EAAAA,aAAa,KAAKJ,CAAW,KACxDK,EAAsB,IAAIC,EAAAA,YAAY,KAAKN,CAAW,KACtDO,EAAe,UAEfC,EAAY,OAEZC,EAAgB,CACpB,UAAW,GACX,SAAU,GACV,MAAO,GACT,EAMMC,EAAoBC,GACxBC,KAAmBD,EAASV,CAAc,EAKtCY,EAAqBF,GAAqB,IAAIG,EAAMH,CAAO,EAI3DI,EAAiBC,EAAA,GACrB,WAAWhB,CAAW,EACxB,EACMiB,EAAkBD,EAAA,GACtB,YAAYhB,CAAW,EACzB,EACMkB,EAAiBF,EAAA,GACrB,WAAWhB,CAAW,EACxB,EACMmB,EAAmBH,EAAA,GACvB,aAAahB,CAAW,EAC1B,EASMoB,EAAqBC,GAAgB,CACnC,KAAA,CAAE,QAAAV,EAAS,QAAAW,CAAA,EAAYD,EAC7BE,EAAA,GAAYZ,EAASJ,CAAY,EAC3BiB,KAAA,MAAMb,EAASJ,CAAY,EAEjCkB,EAAA,EAAcd,EAASM,CAAe,EAElCK,EAAQ,UACJE,KAAA,IAAIb,EAAS,IAAMU,EAAK,OAAQC,EAAQ,MAAOtB,CAAW,CAEpE,EAOM0B,EAAqBL,GAAgB,CACnC,KAAA,CAAE,QAAAV,GAAYU,EACpBE,EAAA,GAAYZ,EAASJ,CAAY,EACjCgB,EAAA,GAAYZ,EAASgB,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AU,IAAI,EACtD,EAOA,sBAAyBwB,GAAkB,CACnC,MAAAC,EAASD,EAAME,EAAAA,EAAcC,EAAA,EAC7B,CAAE,QAAA7C,EAAS,SAAA8C,EAAU,QAAAC,EAAS,QAAApC,EAAS,KAAAqC,GAAS,KAGlDD,GACKJ,EAAAI,EAASE,KAAiBD,CAAI,EAInCrC,EAAQ,UACV,CAACqB,EAAc,GAAAkB,EAAA,GAAenB,KAAiBoB,EAAAA,EAAe,EAAE,QAC7D5B,GAAMoB,EAAO3C,EAASuB,EAAGK,CAAuB,CACnD,EAGEkB,EAAS,QACFA,EAAA,QAASN,GAChBG,EAAOH,EAAKS,KAAiB3B,CAAiB,CAChD,CAEJ,EAGA,SAAU,CACF,KAAA,CAAE,QAAAtB,EAAS,QAAAyC,CAAA,EAAY,KAC7B,KAAK,sBAAsB,EACrB5B,KAAA,MAAMb,EAASX,CAAW,EAE5BoD,GAAqB7B,EAAAA,GAAAZ,EAASgB,WAAS,EAE3C,MAAM,QAAQ,CAAA,CAElB"} \ No newline at end of file diff --git a/dist/components/toast.d.ts b/dist/components/toast.d.ts index d7e8707f..47c91fff 100644 --- a/dist/components/toast.d.ts +++ b/dist/components/toast.d.ts @@ -1,12 +1,12 @@ /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -23,8 +23,9 @@ declare interface BaseOptions { /** Creates a new `Toast` instance. */ declare class Toast extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Toast; - static getInstance: (element: HTMLElement) => Toast | null; + static init: (element: Element) => Toast; + static getInstance: (element: Element) => Toast | null; + element: HTMLElement; options: ToastOptions; dismiss: HTMLElement | null; triggers: HTMLElement[]; @@ -33,7 +34,7 @@ declare class Toast extends BaseComponent { * @param target the target `.toast` element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ diff --git a/dist/components/toast.mjs b/dist/components/toast.mjs index 91eb51cb..314e33ab 100644 --- a/dist/components/toast.mjs +++ b/dist/components/toast.mjs @@ -1,52 +1,52 @@ -import { B as x, h as p, f as l, r, q as A, n as H, l as P, d, a6 as $, a7 as N, v as y, w as j, T as i, g as z, c as g, t as D, e as b, m as T, D as F } from "./base-component-ylZzLp-h.mjs"; -import { E as G, r as J } from "./event-listener-C1-Yf9Z5.mjs"; -import { f as h } from "./fadeClass-CLIYI_zn.mjs"; -import { s as f } from "./showClass-C8hdJfjQ.mjs"; -import { d as K } from "./dataBsDismiss-DdNPQYa-.mjs"; -import { d as M } from "./dataBsToggle-B84TS15h.mjs"; -import { g as B } from "./getTargetElement-BFOUI7hP.mjs"; -const a = "toast", I = "Toast", O = `.${a}`, Q = `[${K}="${a}"]`, k = `[${M}="${a}"]`, c = "showing", q = "hide", R = { +import { B as x, Y as u, b as l, Z as r, R as H, c as P, d as R, q as d, a6 as S, a7 as Y, g as y, w as Z, y as i, t as A, v as f, e as b, r as B, m as T, p as N } from "./base-component-Jx2aafTJ.mjs"; +import { E as j, r as z } from "./event-listener-CUwvA4j6.mjs"; +import { f as m } from "./fadeClass-CLIYI_zn.mjs"; +import { s as g } from "./showClass-C8hdJfjQ.mjs"; +import { d as F } from "./dataBsDismiss-DdNPQYa-.mjs"; +import { d as G } from "./dataBsToggle-B84TS15h.mjs"; +import { g as D } from "./getTargetElement-Bv0W3Fir.mjs"; +const a = "toast", k = "Toast", J = `.${a}`, K = `[${F}="${a}"]`, I = `[${G}="${a}"]`, c = "showing", L = "hide", M = { animation: !0, autohide: !0, delay: 5e3 -}, v = (e) => z(e, I), U = (e) => new st(e), E = g( +}, w = (e) => A(e, k), O = (e) => new st(e), v = f( `show.bs.${a}` -), V = g( +), Q = f( `shown.bs.${a}` -), w = g( +), E = f( `hide.bs.${a}` -), W = g( +), U = f( `hidden.bs.${a}` ), C = (e) => { const { element: t, options: s } = e; - r(t, c), i.clear(t, c), d(t, V), s.autohide && i.set(t, () => e.hide(), s.delay, a); -}, S = (e) => { + r(t, c), i.clear(t, c), d(t, Q), s.autohide && i.set(t, () => e.hide(), s.delay, a); +}, $ = (e) => { const { element: t } = e; - r(t, c), r(t, f), l(t, q), i.clear(t, a), d(t, W); -}, X = (e) => { + r(t, c), r(t, g), l(t, L), i.clear(t, a), d(t, U); +}, V = (e) => { const { element: t, options: s } = e; - l(t, c), s.animation ? (D(t), b(t, () => S(e))) : S(e); -}, Y = (e) => { + l(t, c), s.animation ? (b(t), B(t, () => $(e))) : $(e); +}, W = (e) => { const { element: t, options: s } = e; i.set( t, () => { - r(t, q), D(t), l(t, f), l(t, c), s.animation ? b(t, () => C(e)) : C(e); + r(t, L), b(t), l(t, g), l(t, c), s.animation ? B(t, () => C(e)) : C(e); }, 17, c ); -}, Z = (e) => { - const { target: t } = e, s = t && F(t, k), o = s && B(s), n = o && v(o); +}, X = (e) => { + const { target: t } = e, s = t && N(t, I), o = s && D(s), n = o && w(o); n && (s && s.tagName === "A" && e.preventDefault(), n.relatedTarget = s, n.show()); }, tt = (e) => { - const t = e.target, s = v(t), { type: o, relatedTarget: n } = e; - s && t !== n && !t.contains(n) && ([y, $].includes(o) ? i.clear(t, a) : i.set(t, () => s.hide(), s.options.delay, a)); + const t = e.target, s = w(t), { type: o, relatedTarget: n } = e; + !s || t === n || t.contains(n) || ([y, S].includes(o) ? i.clear(t, a) : i.set(t, () => s.hide(), s.options.delay, a)); }; class st extends x { - static selector = O; - static init = U; - static getInstance = v; + static selector = J; + static init = O; + static getInstance = w; /** * @param target the target `.toast` element * @param config the instance options @@ -54,41 +54,40 @@ class st extends x { constructor(t, s) { super(t, s); const { element: o, options: n } = this; - n.animation && !p(o, h) ? l(o, h) : !n.animation && p(o, h) && r(o, h), this.dismiss = A(Q, o), this.triggers = [ - ...H(k, P(o)) + n.animation && !u(o, m) ? l(o, m) : !n.animation && u(o, m) && r(o, m), this.dismiss = H(K, o), this.triggers = [ + ...P( + I, + R(o) + ) ].filter( - (m) => B(m) === o + (h) => D(h) === o ), this._toggleEventListeners(!0); } /** * Returns component name string. */ get name() { - return I; + return k; } /** * Returns component default options. */ get defaults() { - return R; + return M; } /** * Returns *true* when toast is visible. */ get isShown() { - return p(this.element, f); + return u(this.element, g); } - // TOAST PUBLIC METHODS - // ==================== - /** Shows the toast. */ show = () => { const { element: t, isShown: s } = this; - t && !s && (d(t, E), E.defaultPrevented || Y(this)); + !t || s || (d(t, v), v.defaultPrevented || W(this)); }; - /** Hides the toast. */ hide = () => { const { element: t, isShown: s } = this; - t && s && (d(t, w), w.defaultPrevented || X(this)); + !t || !s || (d(t, E), E.defaultPrevented || V(this)); }; /** * Toggles on/off the `click` event listener. @@ -96,17 +95,16 @@ class st extends x { * @param add when `true`, it will add the listener */ _toggleEventListeners = (t) => { - const s = t ? G : J, { element: o, triggers: n, dismiss: m, options: L, hide: _ } = this; - m && s(m, T, _), L.autohide && [$, N, y, j].forEach( - (u) => s(o, u, tt) + const s = t ? j : z, { element: o, triggers: n, dismiss: h, options: _, hide: q } = this; + h && s(h, T, q), _.autohide && [S, Y, y, Z].forEach( + (p) => s(o, p, tt) ), n.length && n.forEach( - (u) => s(u, T, Z) + (p) => s(p, T, X) ); }; - /** Removes the `Toast` component from the target element. */ dispose() { const { element: t, isShown: s } = this; - this._toggleEventListeners(), i.clear(t, a), s && r(t, f), super.dispose(); + this._toggleEventListeners(), i.clear(t, a), s && r(t, g), super.dispose(); } } export { diff --git a/dist/components/toast.mjs.map b/dist/components/toast.mjs.map index 62ff2e39..48c9cc97 100644 --- a/dist/components/toast.mjs.map +++ b/dist/components/toast.mjs.map @@ -1 +1 @@ -{"version":3,"file":"toast.mjs","sources":["../../src/strings/toastString.ts","../../src/strings/toastComponent.ts","../../src/components/toast.ts"],"sourcesContent":["/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n"],"names":["toastString","toastComponent","toastSelector","toastDismissSelector","dataBsDismiss","toastToggleSelector","dataBsToggle","showingClass","hideClass","toastDefaults","getToastInstance","element","getInstance","toastInitCallback","Toast","showToastEvent","createCustomEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","self","options","removeClass","Timer","dispatchEvent","hideToastComplete","showClass","addClass","hideToast","reflow","emulateTransitionEnd","showToast","toastClickHandler","target","trigger","closest","getTargetElement","interactiveToastHandler","type","relatedTarget","mouseenterEvent","focusinEvent","BaseComponent","config","hasClass","fadeClass","querySelector","querySelectorAll","getDocument","btn","isShown","add","action","addListener","removeListener","triggers","dismiss","hide","mouseclickEvent","focusoutEvent","mouseleaveEvent","e"],"mappings":";;;;;;;AACA,MAAMA,IAAc,SCAdC,IAAiB,SCoCjBC,IAAgB,IAAIF,CAAW,IAC/BG,IAAuB,IA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InCpC,EAAQ,YACV,CAACoB,GAAckB,GAAenB,GAAiBoB,CAAe,EAAE;AAAA,MAC9D,CAACC,MAAMT,EAAO1C,GAASmD,GAAGxB,EAAuB;AAAA,IACnD,GAGEkB,EAAS,UACFA,EAAA;AAAA,MAAQ,CAACN,MAChBG,EAAOH,GAAKS,GAAiB1B,CAAiB;AAAA,IAChD;AAAA,EAEJ;AAAA;AAAA,EAGA,UAAU;AACF,UAAA,EAAE,SAAAtB,GAAS,SAAAwC,EAAA,IAAY;AAC7B,SAAK,sBAAsB,GACrB3B,EAAA,MAAMb,GAASX,CAAW,GAE5BmD,KACF5B,EAAYZ,GAASgB,CAAS,GAEhC,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file +{"version":3,"file":"toast.mjs","sources":["../../src/strings/toastString.ts","../../src/strings/toastComponent.ts","../../src/components/toast.ts"],"sourcesContent":["/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n"],"names":["toastString","toastComponent","toastSelector","toastDismissSelector","dataBsDismiss","toastToggleSelector","dataBsToggle","showingClass","hideClass","toastDefaults","getToastInstance","element","getInstance","toastInitCallback","Toast","showToastEvent","createCustomEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","self","options","removeClass","Timer","dispatchEvent","hideToastComplete","showClass","addClass","hideToast","reflow","emulateTransitionEnd","showToast","toastClickHandler","target","trigger","closest","getTargetElement","interactiveToastHandler","type","relatedTarget","mouseenterEvent","focusinEvent","BaseComponent","config","hasClass","fadeClass","querySelector","querySelectorAll","getDocument","btn","isShown","add","action","addListener","removeListener","triggers","dismiss","hide","mouseclickEvent","focusoutEvent","mouseleaveEvent","e"],"mappings":";;;;;;;AACA,MAAMA,IAAc,SCAdC,IAAiB,SCqCjBC,IAAgB,IAAIF,CAAW,IAC/BG,IAAuB,IAAIC,CAAa,KAAKJ,CAAW,MACxDK,IAAsB,IAAIC,CAAY,KAAKN,CAAW,MACtDO,IAAe,WAEfC,IAAY,QAEZC,IAAgB;AAAA,EACpB,WAAW;AAAA,EACX,UAAU;AAAA,EACV,OAAO;AACT,GAMMC,IAAmB,CAACC,MACxBC,EAAmBD,GAASV,CAAc,GAKtCY,IAAoB,CAACF,MAAqB,IAAIG,GAAMH,CAAO,GAI3DI,IAAiBC;AAAAA,EACrB,WAAWhB,CAAW;AACxB,GACMiB,IAAkBD;AAAAA,EACtB,YAAYhB,CAAW;AACzB,GACMkB,IAAiBF;AAAAA,EACrB,WAAWhB,CAAW;AACxB,GACMmB,IAAmBH;AAAAA,EACvB,aAAahB,CAAW;AAC1B,GASMoB,IAAoB,CAACC,MAAgB;AACnC,QAAA,EAAE,SAAAV,GAAS,SAAAW,EAAA,IAAYD;AAC7BE,EAAAA,EAAYZ,GAASJ,CAAY,GAC3BiB,EAAA,MAAMb,GAASJ,CAAY,GAEjCkB,EAAcd,GAASM,CAAe,GA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AA,EAAA;AAAA,EAMzC,OAAO,MAAM;AACL,UAAA,EAAE,SAAAhB,GAAS,SAAAwC,EAAA,IAAY;AAGzB,IAAA,CAACxC,KAAWwC,MAEhB1B,EAAcd,GAASI,CAAc,GAChCA,EAAe,oBAAkBiB,EAAU,IAAI;AAAA,EACtD;AAAA,EAGA,OAAO,MAAM;AACL,UAAA,EAAE,SAAArB,GAAS,SAAAwC,EAAA,IAAY;AAGzB,IAAA,CAACxC,KAAW,CAACwC,MAEjB1B,EAAcd,GAASO,CAAc,GAChCA,EAAe,oBAAkBW,EAAU,IAAI;AAAA,EACtD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EAOA,wBAAwB,CAACuB,MAAkB;AACnC,UAAAC,IAASD,IAAME,IAAcC,GAC7B,EAAE,SAAA5C,GAAS,UAAA6C,GAAU,SAAAC,GAAS,SAAAnC,GAAS,MAAAoC,MAAS;AAGtD,IAAID,KACKJ,EAAAI,GAASE,GAAiBD,CAAI,GAInCpC,EAAQ,YACV,CAACoB,GAAckB,GAAenB,GAAiBoB,CAAe,EAAE;AAAA,MAC9D,CAACC,MAAMT,EAAO1C,GAASmD,GAAGxB,EAAuB;AAAA,IACnD,GAGEkB,EAAS,UACFA,EAAA;AAAA,MAAQ,CAACN,MAChBG,EAAOH,GAAKS,GAAiB1B,CAAiB;AAAA,IAChD;AAAA,EAEJ;AAAA,EAGA,UAAU;AACF,UAAA,EAAE,SAAAtB,GAAS,SAAAwC,EAAA,IAAY;AAC7B,SAAK,sBAAsB,GACrB3B,EAAA,MAAMb,GAASX,CAAW,GAE5BmD,KAAqB5B,EAAAZ,GAASgB,CAAS,GAE3C,MAAM,QAAQ;AAAA,EAAA;AAElB;"} \ No newline at end of file diff --git a/dist/components/tooltip--Tnf23hE.js b/dist/components/tooltip--Tnf23hE.js deleted file mode 100644 index dea528db..00000000 --- a/dist/components/tooltip--Tnf23hE.js +++ /dev/null @@ -1,2 +0,0 @@ -"use strict";const t=require("./base-component-D3rSrWwH.js"),q=require("./event-listener-W3RGkfJ6.js"),vt=require("./index-BRPRSfaI.js"),bt=require("./dataBsToggle-Dj-Ng54N.js"),Z=require("./showClass-D_Ms1FgG.js"),N=require("./popupContainer-D8In9VFi.js"),st=require("./fadeClass-Co6nOzNJ.js"),z="popover",ot="Popover",C="tooltip",rt=i=>{const e=i===C,s=e?`${i}-inner`:`${i}-body`,o=e?"":`

`,n=`
`,l=`
`;return`
${o+n+l}
`},ct={top:"top",bottom:"bottom",left:"start",right:"end"},tt=i=>{const e=/\b(top|bottom|start|end)+/,{element:s,tooltip:o,container:n,options:l,arrow:c}=i;if(o){const m={...ct},p=t.isRTL(s);t.setElementStyle(o,{top:"",left:"",right:"",bottom:""});const f=i.name===ot,{offsetWidth:r,offsetHeight:g}=o,{clientWidth:P,clientHeight:b,offsetWidth:B}=t.getDocumentElement(s);let{placement:a}=l;const{clientWidth:E,offsetWidth:T}=n,H=t.getElementStyle(n,"position")==="fixed",d=Math.abs(H?E-T:P-B),L=p&&H?d:0,w=P-(p?0:d)-1,{width:u,height:v,left:h,right:ft,top:D}=t.getBoundingClientRect(s,!0),{x:U,y:R}={x:h,y:D};t.setElementStyle(c,{top:"",left:"",right:"",bottom:""});let x=0,O="",y=0,K="",W="",Y="",Q="";const A=c.offsetWidth||0,$=c.offsetHeight||0,V=A/2;let _=D-g-$<0,k=D+g+v+$>=b,I=h-r-A=w;const G=["left","right"],X=["top","bottom"];_=G.includes(a)?D+v/2-g/2-$<0:_,k=G.includes(a)?D+g/2+v/2+$>=b:k,I=X.includes(a)?h+u/2-r/2=w:F,a=G.includes(a)&&I&&F?"top":a,a=a==="top"&&_?"bottom":a,a=a==="bottom"&&k?"top":a,a=a==="left"&&I?"right":a,a=a==="right"&&F?"left":a,o.className.includes(a)||(o.className=o.className.replace(e,m[a])),G.includes(a)?(a==="left"?y=U-r-(f?A:0):y=U+u+(f?A:0),_&&k?(x=0,O=0,W=D+v/2-$/2):_?(x=R,O="",W=v/2-A):k?(x=R-g+v,O="",W=g-v/2-A):(x=R-g/2+v/2,W=g/2-$/2)):X.includes(a)&&(a==="top"?x=R-g-(f?$:0):x=R+v+(f?$:0),I?(y=0,Y=U+u/2-V):F?(y="auto",K=0,Q=u/2+w-ft-V):(y=U-r/2+u/2,Y=r/2-V)),t.setElementStyle(o,{top:`${x}px`,bottom:O===""?"":`${O}px`,left:y==="auto"?y:`${y}px`,right:K!==""?`${K}px`:""}),t.isHTMLElement(c)&&(W!==""&&(c.style.top=`${W}px`),Y!==""?c.style.left=`${Y}px`:Q!==""&&(c.style.right=`${Q}px`));const gt=t.createCustomEvent(`updated.bs.${t.toLowerCase(i.name)}`);t.dispatchEvent(s,gt)}},et={template:rt(C),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},dt="data-original-title",M="Tooltip",S=(i,e,s)=>{if(t.isString(e)&&e.length){let o=e.trim();t.isFunction(s)&&(o=s(o));const l=new DOMParser().parseFromString(o,"text/html");i.append(...l.body.childNodes)}else t.isHTMLElement(e)?i.append(e):(t.isNodeList(e)||t.isArray(e)&&e.every(t.isNode))&&i.append(...e)},Et=i=>{const e=i.name===M,{id:s,element:o,options:n}=i,{title:l,placement:c,template:m,animation:p,customClass:f,sanitizeFn:r,dismissible:g,content:P,btnClose:b}=n,B=e?C:z,a={...ct};let E=[],T=[];t.isRTL(o)&&(a.left="end",a.right="start");const J=`bs-${B}-${a[c]}`;let H;if(t.isHTMLElement(m))H=m;else{const L=t.createElement("div");S(L,m,r),H=L.firstChild}i.tooltip=t.isHTMLElement(H)?H.cloneNode(!0):void 0;const{tooltip:d}=i;if(d){t.setAttribute(d,"id",s),t.setAttribute(d,"role",C);const L=e?`${C}-inner`:`${z}-body`,w=e?null:t.querySelector(`.${z}-header`,d),u=t.querySelector(`.${L}`,d);i.arrow=t.querySelector(`.${B}-arrow`,d);const{arrow:v}=i;if(t.isHTMLElement(l))E=[l.cloneNode(!0)];else{const h=t.createElement("div");S(h,l,r),E=[...h.childNodes]}if(t.isHTMLElement(P))T=[P.cloneNode(!0)];else{const h=t.createElement("div");S(h,P,r),T=[...h.childNodes]}if(g)if(l)if(t.isHTMLElement(b))E=[...E,b.cloneNode(!0)];else{const h=t.createElement("div");S(h,b,r),E=[...E,h.firstChild]}else if(w&&w.remove(),t.isHTMLElement(b))T=[...T,b.cloneNode(!0)];else{const h=t.createElement("div");S(h,b,r),T=[...T,h.firstChild]}e?l&&u&&S(u,l,r):(l&&w&&S(w,E,r),P&&u&&S(u,T,r),i.btn=t.querySelector(".btn-close",d)||void 0),t.addClass(d,"position-fixed"),t.addClass(v,"position-absolute"),t.hasClass(d,B)||t.addClass(d,B),p&&!t.hasClass(d,st.fadeClass)&&t.addClass(d,st.fadeClass),f&&!t.hasClass(d,f)&&t.addClass(d,f),t.hasClass(d,J)||t.addClass(d,J)}},Tt=i=>{const e=["HTML","BODY"],s=[];let{parentNode:o}=i;for(;o&&!e.includes(o.nodeName);)o=t.getParentNode(o),t.isShadowRoot(o)||t.isTableElement(o)||s.push(o);return s.find((n,l)=>t.getElementStyle(n,"position")!=="relative"&&s.slice(l+1).every(c=>t.getElementStyle(c,"position")==="static")?n:null)||t.getDocument(i).body},Ct=`[${bt.dataBsToggle}="${C}"],[data-tip="${C}"]`,ht="title";let it=i=>t.getInstance(i,M);const wt=i=>new ut(i),yt=i=>{const{element:e,tooltip:s,container:o,offsetParent:n}=i;t.removeAttribute(e,t.ariaDescribedBy),N.removePopup(s,o===n?o:n)},j=i=>{const{tooltip:e,container:s,offsetParent:o}=i;return e&&N.hasPopup(e,s===o?s:o)},$t=(i,e)=>{const{element:s}=i;i._toggleEventListeners(),t.hasAttribute(s,dt)&&i.name===M&&mt(i),e&&e()},pt=(i,e)=>{const s=e?q.E:q.r,{element:o}=i;s(t.getDocument(o),t.touchstartEvent,i.handleTouch,t.passiveHandler)},nt=i=>{const{element:e}=i,s=t.createCustomEvent(`shown.bs.${t.toLowerCase(i.name)}`);pt(i,!0),t.dispatchEvent(e,s),t.Timer.clear(e,"in")},lt=i=>{const{element:e}=i,s=t.createCustomEvent(`hidden.bs.${t.toLowerCase(i.name)}`);pt(i),yt(i),t.dispatchEvent(e,s),t.Timer.clear(e,"out")},at=(i,e)=>{const s=e?q.E:q.r,{element:o}=i,n=t.closest(o,`.${N.modalString}`),l=t.closest(o,`.${N.offcanvasString}`);e?i._observer.observe(i.element):i._observer.disconnect(),n&&s(n,`hide.bs.${N.modalString}`,i.handleHide),l&&s(l,`hide.bs.${N.offcanvasString}`,i.handleHide)},mt=(i,e)=>{const s=[dt,ht],{element:o}=i;t.setAttribute(o,s[e?0:1],e||t.getAttribute(o,s[0])||""),t.removeAttribute(o,s[e?1:0])};class ut extends t.BaseComponent{static selector=Ct;static init=wt;static getInstance=it;static styleTip=tt;constructor(e,s){super(e,s);const{element:o}=this,n=this.name===M,l=n?C:z,c=n?M:ot;it=p=>t.getInstance(p,c),this.enabled=!0,this.id=`${l}-${t.getUID(o,l)}`;const{options:m}=this;!m.title&&n||!n&&!m.content||(t.ObjectAssign(et,{titleAttr:""}),t.hasAttribute(o,ht)&&n&&typeof m.title=="string"&&mt(this,m.title),this.container=Tt(o),this.offsetParent=["sticky","fixed"].some(p=>t.getElementStyle(this.container,"position")===p)?this.container:t.getDocument(this.element).body,Et(this),this._observer=new vt.x(()=>this.update()),this._toggleEventListeners(!0))}get name(){return M}get defaults(){return et}handleFocus=()=>t.focus(this.element);handleShow=()=>this.show();show(){const{options:e,tooltip:s,element:o,container:n,offsetParent:l,id:c}=this,{animation:m}=e,p=t.Timer.get(o,"out"),f=n===l?n:l;t.Timer.clear(o,"out"),s&&!p&&!j(this)&&t.Timer.set(o,()=>{const r=t.createCustomEvent(`show.bs.${t.toLowerCase(this.name)}`);t.dispatchEvent(o,r),r.defaultPrevented||(N.appendPopup(s,f),t.setAttribute(o,t.ariaDescribedBy,`#${c}`),this.update(),at(this,!0),t.hasClass(s,Z.showClass)||t.addClass(s,Z.showClass),m?t.emulateTransitionEnd(s,()=>nt(this)):nt(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:e,tooltip:s,element:o}=this,{animation:n,delay:l}=e;t.Timer.clear(o,"in"),s&&j(this)&&t.Timer.set(o,()=>{const c=t.createCustomEvent(`hide.bs.${t.toLowerCase(this.name)}`);t.dispatchEvent(o,c),c.defaultPrevented||(this.update(),t.removeClass(s,Z.showClass),at(this),n?t.emulateTransitionEnd(s,()=>lt(this)):lt(this))},l+17,"out")}update=()=>{tt(this)};toggle=()=>{const{tooltip:e}=this;e&&!j(this)?this.show():this.hide()};enable(){const{enabled:e}=this;e||(this._toggleEventListeners(!0),this.enabled=!e)}disable(){const{tooltip:e,enabled:s}=this;s&&(e&&j(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:e})=>{const{tooltip:s,element:o}=this;s&&s.contains(e)||e===o||e&&o.contains(e)||this.hide()};_toggleEventListeners=e=>{const s=e?q.E:q.r,{element:o,options:n,btn:l}=this,{trigger:c}=n,p=!!(this.name!==M&&n.dismissible);c.includes("manual")||(this.enabled=!!e,c.split(" ").forEach(r=>{r===t.mousehoverEvent?(s(o,t.mousedownEvent,this.handleShow),s(o,t.mouseenterEvent,this.handleShow),p||(s(o,t.mouseleaveEvent,this.handleHide),s(t.getDocument(o),t.touchstartEvent,this.handleTouch,t.passiveHandler))):r===t.mouseclickEvent?s(o,r,p?this.handleShow:this.toggle):r===t.focusEvent&&(s(o,t.focusinEvent,this.handleShow),p||s(o,t.focusoutEvent,this.handleHide),t.isApple()&&s(o,t.mouseclickEvent,this.handleFocus)),p&&l&&s(l,t.mouseclickEvent,this.handleHide)}))};dispose(){const{tooltip:e,options:s}=this,o={...this,name:this.name},n=()=>setTimeout(()=>$t(o,()=>super.dispose()),17);s.animation&&j(o)?(this.options.delay=0,this.hide(),t.emulateTransitionEnd(e,n)):n()}}exports.Tooltip=ut;exports.getTipTemplate=rt;exports.popoverComponent=ot;exports.popoverString=z;exports.styleTip=tt;exports.tooltipDefaults=et; -//# sourceMappingURL=tooltip--Tnf23hE.js.map diff --git a/dist/components/tooltip--Tnf23hE.js.map b/dist/components/tooltip--Tnf23hE.js.map deleted file mode 100644 index 42fefba5..00000000 --- a/dist/components/tooltip--Tnf23hE.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"tooltip--Tnf23hE.js","sources":["../../src/strings/popoverString.ts","../../src/strings/popoverComponent.ts","../../src/strings/tooltipString.ts","../../src/util/getTipTemplate.ts","../../src/util/tipClassPositions.ts","../../src/util/styleTip.ts","../../src/util/tooltipDefaults.ts","../../src/strings/dataOriginalTitle.ts","../../src/strings/tooltipComponent.ts","../../src/util/setHtml.ts","../../src/util/createTip.ts","../../src/util/getElementContainer.ts","../../src/components/tooltip.ts"],"sourcesContent":["/** @type {string} */\nconst popoverString = \"popover\";\nexport default popoverString;\n","/** @type {string} */\nconst popoverComponent = \"Popover\";\nexport default popoverComponent;\n","/** @type {string} */\nconst tooltipString = \"tooltip\";\nexport default tooltipString;\n","import tooltipString from \"../strings/tooltipString\";\n\n/**\n * Returns a template for Popover / Tooltip.\n *\n * @param tipType the expected markup type\n * @returns the template markup\n */\nconst getTipTemplate = (tipType: string) => {\n const isTooltip = tipType === tooltipString;\n const bodyClass = isTooltip ? `${tipType}-inner` : `${tipType}-body`;\n const header = !isTooltip ? `

` : \"\";\n const arrow = `
`;\n const body = `
`;\n return `
${\n header + arrow + body\n }
`;\n};\n\nexport default getTipTemplate;\n","const tipClassPositions = {\n top: \"top\",\n bottom: \"bottom\",\n left: \"start\",\n right: \"end\",\n};\n\nexport default tipClassPositions;\n","import {\n createCustomEvent,\n dispatchEvent,\n getBoundingClientRect,\n getDocumentElement,\n getElementStyle,\n isHTMLElement,\n isRTL,\n setElementStyle,\n toLowerCase,\n} from \"@thednp/shorty\";\n\nimport popoverComponent from \"../strings/popoverComponent\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport Tooltip from \"../components/tooltip\";\nimport type { TooltipEvent } from \"../interface/tooltip\";\nimport type { PopoverEvent } from \"../interface/popover\";\n\n/**\n * Style popovers and tooltips.\n *\n * @param self the `Popover` / `Tooltip` instance\n */\nconst styleTip = (self: T) => {\n const tipClasses = /\\b(top|bottom|start|end)+/;\n const { element, tooltip, container, options, arrow } = self;\n\n // istanbul ignore else @preserve\n if (tooltip) {\n const tipPositions = { ...tipClassPositions };\n const RTL = isRTL(element);\n\n // reset tooltip style (top: 0, left: 0 works best)\n setElementStyle(tooltip, {\n // top: '0px', left: '0px', right: '', bottom: '',\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n const isPopover = self.name === popoverComponent;\n const { offsetWidth: tipWidth, offsetHeight: tipHeight } = tooltip;\n const { clientWidth: htmlcw, clientHeight: htmlch, offsetWidth: htmlow } =\n getDocumentElement(element);\n let { placement } = options;\n const { clientWidth: parentCWidth, offsetWidth: parentOWidth } =\n container as HTMLElement;\n const parentPosition = getElementStyle(\n container as HTMLElement,\n \"position\",\n );\n const fixedParent = parentPosition === \"fixed\";\n const scrollbarWidth = fixedParent\n ? Math.abs(parentCWidth - parentOWidth)\n : Math.abs(htmlcw - htmlow);\n const leftBoundry = RTL && fixedParent\n // istanbul ignore next @preserve\n ? scrollbarWidth\n : 0;\n const rightBoundry = htmlcw - (!RTL ? scrollbarWidth : 0) - 1;\n const {\n width: elemWidth,\n height: elemHeight,\n left: elemRectLeft,\n right: elemRectRight,\n top: elemRectTop,\n } = getBoundingClientRect(element, true);\n const { x, y } = {\n x: elemRectLeft,\n y: elemRectTop,\n };\n // reset arrow style\n setElementStyle(arrow as HTMLElement, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n let topPosition: number | string = 0;\n let bottomPosition: number | string = \"\";\n let leftPosition: number | string = 0;\n let rightPosition: number | string = \"\";\n let arrowTop: number | string = \"\";\n let arrowLeft: number | string = \"\";\n let arrowRight: number | string = \"\";\n\n const arrowWidth = (arrow as HTMLElement).offsetWidth || 0;\n const arrowHeight = (arrow as HTMLElement).offsetHeight || 0;\n const arrowAdjust = arrowWidth / 2;\n\n // check placement\n let topExceed = elemRectTop - tipHeight - arrowHeight < 0;\n let bottomExceed =\n elemRectTop + tipHeight + elemHeight + arrowHeight >= htmlch;\n let leftExceed = elemRectLeft - tipWidth - arrowWidth < leftBoundry;\n let rightExceed =\n elemRectLeft + tipWidth + elemWidth + arrowWidth >= rightBoundry;\n\n const horizontals = [\"left\", \"right\"];\n const verticals = [\"top\", \"bottom\"];\n\n topExceed = horizontals.includes(placement)\n ? elemRectTop + elemHeight / 2 - tipHeight / 2 - arrowHeight < 0\n : topExceed;\n bottomExceed = horizontals.includes(placement)\n ? elemRectTop + tipHeight / 2 + elemHeight / 2 + arrowHeight >= htmlch\n : bottomExceed;\n leftExceed = verticals.includes(placement)\n ? elemRectLeft + elemWidth / 2 - tipWidth / 2 < leftBoundry\n : leftExceed;\n rightExceed = verticals.includes(placement)\n ? elemRectLeft + tipWidth / 2 + elemWidth / 2 >= rightBoundry\n : rightExceed;\n\n // first remove side positions if both left and right limits are exceeded\n // we usually fall back to top|bottom\n placement = horizontals.includes(placement) && leftExceed && rightExceed\n ? \"top\"\n : placement;\n // recompute placement\n placement = placement === \"top\" && topExceed ? \"bottom\" : placement;\n placement = placement === \"bottom\" && bottomExceed ? \"top\" : placement;\n placement = placement === \"left\" && leftExceed ? \"right\" : placement;\n placement = placement === \"right\" && rightExceed\n ? \"left\"\n // istanbul ignore next @preserve\n : placement;\n\n // update tooltip/popover class\n if (!tooltip.className.includes(placement)) {\n tooltip.className = tooltip.className.replace(\n tipClasses,\n tipPositions[placement],\n );\n }\n\n // compute tooltip / popover coordinates\n // istanbul ignore else @preserve\n if (horizontals.includes(placement)) {\n // secondary|side positions\n if (placement === \"left\") {\n // LEFT\n leftPosition = x - tipWidth - (isPopover ? arrowWidth : 0);\n } else {\n // RIGHT\n leftPosition = x + elemWidth + (isPopover ? arrowWidth : 0);\n }\n\n // adjust top and arrow\n if (topExceed && bottomExceed) {\n topPosition = 0;\n bottomPosition = 0;\n arrowTop = elemRectTop + elemHeight / 2 - arrowHeight / 2;\n } else if (topExceed) {\n topPosition = y;\n bottomPosition = \"\";\n arrowTop = elemHeight / 2 - arrowWidth;\n } else if (bottomExceed) {\n topPosition = y - tipHeight + elemHeight;\n bottomPosition = \"\";\n arrowTop = tipHeight - elemHeight / 2 - arrowWidth;\n } else {\n topPosition = y - tipHeight / 2 + elemHeight / 2;\n arrowTop = tipHeight / 2 - arrowHeight / 2;\n }\n } else if (verticals.includes(placement)) {\n if (placement === \"top\") {\n topPosition = y - tipHeight - (isPopover ? arrowHeight : 0);\n } else {\n // BOTTOM\n topPosition = y + elemHeight + (isPopover ? arrowHeight : 0);\n }\n\n // adjust left | right and also the arrow\n if (leftExceed) {\n leftPosition = 0;\n arrowLeft = x + elemWidth / 2 - arrowAdjust;\n } else if (rightExceed) {\n leftPosition = \"auto\";\n rightPosition = 0;\n arrowRight = elemWidth / 2 + rightBoundry - elemRectRight - arrowAdjust;\n } else {\n leftPosition = x - tipWidth / 2 + elemWidth / 2;\n arrowLeft = tipWidth / 2 - arrowAdjust;\n }\n }\n\n // apply style to tooltip/popover\n setElementStyle(tooltip, {\n top: `${topPosition}px`,\n bottom: bottomPosition === \"\" ? \"\" : `${bottomPosition}px`,\n left: leftPosition === \"auto\" ? leftPosition : `${leftPosition}px`,\n right: rightPosition !== \"\" ? `${rightPosition}px` : \"\",\n });\n\n // update arrow placement\n // istanbul ignore else @preserve\n if (isHTMLElement(arrow)) {\n if (arrowTop !== \"\") {\n arrow.style.top = `${arrowTop}px`;\n }\n if (arrowLeft !== \"\") {\n arrow.style.left = `${arrowLeft}px`;\n } else if (arrowRight !== \"\") {\n arrow.style.right = `${arrowRight}px`;\n }\n }\n const updatedTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `updated.bs.${toLowerCase(self.name)}`,\n );\n dispatchEvent(element, updatedTooltipEvent);\n }\n};\n\nexport default styleTip;\n","import getTipTemplate from \"./getTipTemplate\";\nimport tooltipString from \"../strings/tooltipString\";\nimport { TooltipOptions } from \"../interface/tooltip\";\n\nconst tooltipDefaults: TooltipOptions = {\n template: getTipTemplate(tooltipString),\n title: \"\",\n customClass: \"\",\n trigger: \"hover focus\",\n placement: \"top\",\n sanitizeFn: undefined,\n animation: true,\n delay: 200,\n container: document.body,\n content: \"\",\n dismissible: false,\n btnClose: \"\",\n};\nexport default tooltipDefaults;\n","/**\n * Global namespace for `data-bs-title` attribute.\n */\nconst dataOriginalTitle = \"data-original-title\";\nexport default dataOriginalTitle;\n","/** @type {string} */\nconst tooltipComponent = \"Tooltip\";\nexport default tooltipComponent;\n","import {\n isArray,\n isFunction,\n isHTMLElement,\n isNode,\n isNodeList,\n isString,\n} from \"@thednp/shorty\";\n\n/**\n * Append an existing `Element` to Popover / Tooltip component or HTML\n * markup string to be parsed & sanitized to be used as popover / tooltip content.\n *\n * @param element target\n * @param content the `Element` to append / string\n * @param sanitizeFn a function to sanitize string content\n */\nconst setHtml = (\n element: HTMLElement,\n content: Node[] | Node | string,\n sanitizeFn?: (s: string) => string,\n) => {\n // istanbul ignore else @preserve\n if (isString(content) && content.length) {\n let dirty = content.trim(); // fixing #233\n if (isFunction(sanitizeFn)) dirty = sanitizeFn(dirty);\n\n const domParser = new DOMParser();\n const tempDocument = domParser.parseFromString(dirty, \"text/html\");\n element.append(...[...tempDocument.body.childNodes]);\n } else if (isHTMLElement(content)) {\n element.append(content);\n } else if (\n isNodeList(content) || (isArray(content) && content.every(isNode))\n ) {\n element.append(...[...content]);\n }\n};\nexport default setHtml;\n","import {\n addClass,\n createElement,\n hasClass,\n isHTMLElement,\n isRTL,\n querySelector,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport tooltipString from \"../strings/tooltipString\";\nimport popoverString from \"../strings/popoverString\";\nimport fadeClass from \"../strings/fadeClass\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport setHtml from \"./setHtml\";\nimport Tooltip from \"../components/tooltip\";\nimport Popover from \"../components/popover\";\n\n/**\n * Creates a new tooltip / popover.\n *\n * @param self the `Tooltip` / `Popover` instance\n */\nconst createTip = (self: Tooltip | Popover) => {\n const isTooltip = self.name === tooltipComponent;\n\n const { id, element, options } = self;\n const {\n title,\n placement,\n template,\n animation,\n customClass,\n sanitizeFn,\n dismissible,\n content,\n btnClose,\n } = options;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipPositions = { ...tipClassPositions };\n let titleParts: Node[] = [];\n let contentParts: Node[] = [];\n\n if (isRTL(element)) {\n tipPositions.left = \"end\";\n tipPositions.right = \"start\";\n }\n\n // set initial popover class\n const placementClass = `bs-${tipString}-${tipPositions[placement]}`;\n\n // load template\n let tooltipTemplate: Node | string;\n if (isHTMLElement(template)) {\n tooltipTemplate = template;\n } else {\n const htmlMarkup = createElement(\"div\") as HTMLElement;\n setHtml(htmlMarkup, template, sanitizeFn);\n tooltipTemplate = htmlMarkup.firstChild as HTMLElement;\n }\n\n // set popover markup\n self.tooltip = isHTMLElement(tooltipTemplate)\n ? (tooltipTemplate.cloneNode(true) as HTMLElement)\n // istanbul ignore next @preserve\n : undefined;\n\n const { tooltip } = self;\n // istanbul ignore else @preserve\n if (tooltip) {\n // set id and role attributes\n setAttribute(tooltip, \"id\", id);\n setAttribute(tooltip, \"role\", tooltipString);\n\n const bodyClass = isTooltip\n ? `${tooltipString}-inner`\n : `${popoverString}-body`;\n const tooltipHeader = isTooltip\n ? null\n : querySelector(`.${popoverString}-header`, tooltip);\n const tooltipBody = querySelector(`.${bodyClass}`, tooltip);\n\n // set arrow and enable access for styleTip\n self.arrow = querySelector(`.${tipString}-arrow`, tooltip) as HTMLElement;\n const { arrow } = self;\n\n if (isHTMLElement(title)) titleParts = [title.cloneNode(true)];\n else {\n const tempTitle = createElement(\"div\") as HTMLElement;\n setHtml(tempTitle, title, sanitizeFn);\n titleParts = [...[...tempTitle.childNodes]];\n }\n\n if (isHTMLElement(content)) contentParts = [content.cloneNode(true)];\n else {\n const tempContent = createElement(\"div\") as HTMLElement;\n setHtml(tempContent, content, sanitizeFn);\n contentParts = [...[...tempContent.childNodes]];\n }\n\n // set dismissible button\n if (dismissible) {\n if (title) {\n if (isHTMLElement(btnClose)) {\n titleParts = [...titleParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n titleParts = [...titleParts, tempBtn.firstChild as Node];\n }\n } else {\n // istanbul ignore else @preserve\n if (tooltipHeader) tooltipHeader.remove();\n if (isHTMLElement(btnClose)) {\n contentParts = [...contentParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n contentParts = [...contentParts, tempBtn.firstChild as Node];\n }\n }\n }\n\n // fill the template with content from options / data attributes\n // also sanitize title && content\n // istanbul ignore else @preserve\n if (!isTooltip) {\n // istanbul ignore else @preserve\n if (title && tooltipHeader) {\n setHtml(tooltipHeader, titleParts, sanitizeFn);\n }\n // istanbul ignore else @preserve\n if (content && tooltipBody) {\n setHtml(tooltipBody, contentParts, sanitizeFn);\n }\n // set btn\n self.btn = querySelector(\".btn-close\", tooltip) || undefined;\n } else if (title && tooltipBody) setHtml(tooltipBody, title, sanitizeFn);\n\n // Bootstrap 5.2.x\n // addClass(tooltip, 'position-absolute');\n addClass(tooltip, \"position-fixed\");\n addClass(arrow, \"position-absolute\");\n\n // set popover animation and placement\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, tipString)) addClass(tooltip, tipString);\n // istanbul ignore else @preserve\n if (animation && !hasClass(tooltip, fadeClass)) {\n addClass(tooltip, fadeClass);\n }\n // istanbul ignore else @preserve\n if (customClass && !hasClass(tooltip, customClass)) {\n addClass(tooltip, customClass);\n }\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, placementClass)) addClass(tooltip, placementClass);\n }\n};\n\nexport default createTip;\n","import {\n getDocument,\n getElementStyle,\n getParentNode,\n isShadowRoot,\n isTableElement,\n} from \"@thednp/shorty\";\n\n/**\n * Returns an `HTMLElement` to be used as default value for *options.container*\n * for `Tooltip` / `Popover` components.\n *\n * @see https://github.com/floating-ui/floating-ui\n *\n * @param element the target\n * @returns the query result\n */\nconst getElementContainer = (element: HTMLElement): ParentNode => {\n const majorBlockTags = [\"HTML\", \"BODY\"];\n const containers: ParentNode[] = [];\n let { parentNode } = element as Node;\n\n while (parentNode && !majorBlockTags.includes(parentNode.nodeName)) {\n parentNode = getParentNode(parentNode) as ParentNode;\n // istanbul ignore else @preserve\n if (!(isShadowRoot(parentNode) || isTableElement(parentNode))) {\n containers.push(parentNode);\n }\n }\n\n return (\n containers.find((c, i) => {\n if (\n getElementStyle(c as HTMLElement, \"position\") !== \"relative\" &&\n containers.slice(i + 1).every((r) =>\n getElementStyle(r as HTMLElement, \"position\") === \"static\"\n )\n ) {\n return c;\n }\n return null;\n }) ||\n // istanbul ignore next: optional guard\n getDocument(element).body\n );\n};\n\nexport default getElementContainer;\n","/* Native JavaScript for Bootstrap 5 | Tooltip\n---------------------------------------------- */\nimport {\n addClass,\n ariaDescribedBy,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focus,\n focusEvent,\n focusinEvent,\n focusoutEvent,\n getAttribute,\n getDocument,\n getElementStyle,\n getInstance,\n getUID,\n hasAttribute,\n hasClass,\n isApple,\n mouseclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseleaveEvent,\n ObjectAssign,\n passiveHandler,\n removeAttribute,\n removeClass,\n setAttribute,\n Timer,\n toLowerCase,\n touchstartEvent,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport dataOriginalTitle from \"../strings/dataOriginalTitle\";\nimport showClass from \"../strings/showClass\";\nimport tooltipString from \"../strings/tooltipString\";\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\nimport modalString from \"../strings/modalString\";\nimport offcanvasString from \"../strings/offcanvasString\";\n\nimport styleTip from \"../util/styleTip\";\nimport createTip from \"../util/createTip\";\nimport { appendPopup, hasPopup, removePopup } from \"../util/popupContainer\";\nimport getElementContainer from \"../util/getElementContainer\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport BaseComponent from \"./base-component\";\nimport type { TooltipEvent, TooltipOptions } from \"../interface/tooltip\";\nimport type { PopoverEvent, PopoverOptions } from \"../interface/popover\";\n\n// TOOLTIP PRIVATE GC\n// ==================\nconst tooltipSelector =\n `[${dataBsToggle}=\"${tooltipString}\"],[data-tip=\"${tooltipString}\"]`;\nconst titleAttr = \"title\";\n\n/**\n * Static method which returns an existing `Tooltip` instance associated\n * to a target `Element`.\n */\nlet getTooltipInstance = (element: HTMLElement) =>\n getInstance(element, tooltipComponent);\n\n/**\n * A `Tooltip` initialization callback.\n */\nconst tooltipInitCallback = (element: HTMLElement) => new Tooltip(element);\n\n// TOOLTIP PRIVATE METHODS\n// =======================\n/**\n * Removes the tooltip from the DOM.\n *\n * @param self the `Tooltip` instance\n */\nconst removeTooltip = (self: Tooltip) => {\n const { element, tooltip, container, offsetParent } = self;\n removeAttribute(element, ariaDescribedBy);\n removePopup(\n tooltip as HTMLElement,\n container === offsetParent ? container : offsetParent,\n );\n};\n\n/**\n * Check if container contains the tooltip.\n *\n * @param self Tooltip\n */\nconst hasTip = (self: Tooltip): boolean | undefined => {\n const { tooltip, container, offsetParent } = self;\n\n return tooltip &&\n hasPopup(tooltip, container === offsetParent ? container : offsetParent);\n};\n\n/**\n * Executes after the instance has been disposed.\n *\n * @param self the `Tooltip` instance\n * @param callback the parent dispose callback\n */\nconst disposeTooltipComplete = (self: Tooltip, callback?: () => void) => {\n const { element } = self;\n self._toggleEventListeners();\n\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, dataOriginalTitle) && self.name === tooltipComponent\n ) {\n toggleTooltipTitle(self);\n }\n // istanbul ignore else @preserve\n if (callback) callback();\n};\n\n/**\n * Toggles on/off the special `Tooltip` event listeners.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipAction = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n\n action(\n getDocument(element),\n touchstartEvent,\n self.handleTouch,\n passiveHandler,\n );\n};\n\n/**\n * Executes after the tooltip was shown to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipShownAction = (self: Tooltip) => {\n const { element } = self;\n const shownTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `shown.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self, true);\n dispatchEvent(element, shownTooltipEvent);\n Timer.clear(element, \"in\");\n};\n\n/**\n * Executes after the tooltip was hidden to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipHiddenAction = (self: Tooltip) => {\n const { element } = self;\n const hiddenTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hidden.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self);\n removeTooltip(self);\n dispatchEvent(element, hiddenTooltipEvent);\n\n Timer.clear(element, \"out\");\n};\n\n/**\n * Toggles on/off the `Tooltip` event listeners that hide/update the tooltip.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipOpenHandlers = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n // const { offsetHeight, scrollHeight } = container as HTMLElement;\n const parentModal = closest(element, `.${modalString}`);\n const parentOffcanvas = closest(element, `.${offcanvasString}`);\n\n if (add) self._observer.observe(self.element);\n else self._observer.disconnect();\n\n // dismiss tooltips inside modal / offcanvas\n if (parentModal) {\n action(parentModal, `hide.bs.${modalString}`, self.handleHide);\n }\n if (parentOffcanvas) {\n action(parentOffcanvas, `hide.bs.${offcanvasString}`, self.handleHide);\n }\n};\n\n/**\n * Toggles the `title` and `data-original-title` attributes.\n *\n * @param self the `Tooltip` instance\n * @param content when `true`, event listeners are added\n */\nconst toggleTooltipTitle = (self: Tooltip, content?: string) => {\n // [0 - add, 1 - remove] | [0 - remove, 1 - add]\n const titleAtt = [dataOriginalTitle, titleAttr];\n const { element } = self;\n\n setAttribute(\n element,\n titleAtt[content ? 0 : 1],\n content ||\n getAttribute(element, titleAtt[0]) ||\n // istanbul ignore next @preserve\n \"\",\n );\n removeAttribute(element, titleAtt[content ? 1 : 0]);\n};\n\n// TOOLTIP DEFINITION\n// ==================\n/** Creates a new `Tooltip` instance. */\nexport default class Tooltip extends BaseComponent {\n static selector = tooltipSelector;\n static init = tooltipInitCallback;\n static getInstance = getTooltipInstance;\n static styleTip = styleTip;\n declare options: TooltipOptions;\n declare btn?: HTMLElement;\n declare tooltip?: HTMLElement;\n declare container: ParentNode;\n declare arrow?: HTMLElement;\n declare offsetParent?: HTMLElement;\n declare enabled: boolean;\n declare id: string;\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n\n const { element } = this;\n const isTooltip = this.name === tooltipComponent;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipComponent = isTooltip ? tooltipComponent : popoverComponent;\n\n // istanbul ignore next @preserve: this is to set Popover too\n getTooltipInstance = (elem: HTMLElement) =>\n getInstance(elem, tipComponent);\n\n // additional properties\n this.enabled = true;\n /** Set unique ID for `aria-describedby`. */\n this.id = `${tipString}-${getUID(element, tipString)}`;\n\n // instance options\n const { options } = this;\n\n // invalidate\n if (!((!options.title && isTooltip) || (!isTooltip && !options.content))) {\n // reset default options\n ObjectAssign(tooltipDefaults, { titleAttr: \"\" });\n\n // set title attributes and add event listeners\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, titleAttr) && isTooltip &&\n typeof options.title === \"string\"\n ) {\n toggleTooltipTitle(this, options.title);\n }\n\n // set containers\n this.container = getElementContainer(element);\n this.offsetParent = [\"sticky\", \"fixed\"].some(\n (position) =>\n getElementStyle(this.container as HTMLElement, \"position\") ===\n position,\n )\n ? (this.container as HTMLElement)\n : getDocument(this.element).body;\n\n // create tooltip here\n createTip(this);\n\n // create observer\n this._observer = new PositionObserver(() => this.update());\n\n // attach events\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tooltipComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return tooltipDefaults;\n }\n\n // TOOLTIP PUBLIC METHODS\n // ======================\n /** Handles the focus event on iOS. */\n // istanbul ignore next @preserve - impossible to test without Apple device\n handleFocus = () => focus(this.element);\n /** Shows the tooltip. */\n handleShow = () => this.show();\n show() {\n const { options, tooltip, element, container, offsetParent, id } = this;\n const { animation } = options;\n const outTimer = Timer.get(element, \"out\");\n const tipContainer = container === offsetParent ? container : offsetParent;\n\n Timer.clear(element, \"out\");\n\n if (tooltip && !outTimer && !hasTip(this)) {\n Timer.set(\n element,\n () => {\n const showTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `show.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, showTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!showTooltipEvent.defaultPrevented) {\n // append to container\n appendPopup(tooltip, tipContainer);\n\n setAttribute(element, ariaDescribedBy, `#${id}`);\n\n this.update();\n toggleTooltipOpenHandlers(this, true);\n\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, showClass)) addClass(tooltip, showClass);\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipShownAction(this));\n } else tooltipShownAction(this);\n }\n },\n 17,\n \"in\",\n );\n }\n }\n\n /** Hides the tooltip. */\n handleHide = () => this.hide();\n hide() {\n const { options, tooltip, element } = this;\n const { animation, delay } = options;\n\n Timer.clear(element, \"in\");\n\n // istanbul ignore else @preserve\n if (tooltip && hasTip(this)) {\n Timer.set(\n element,\n () => {\n const hideTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hide.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, hideTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!hideTooltipEvent.defaultPrevented) {\n this.update();\n removeClass(tooltip, showClass);\n toggleTooltipOpenHandlers(this);\n\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipHiddenAction(this));\n } else tooltipHiddenAction(this);\n }\n },\n delay + 17,\n \"out\",\n );\n }\n }\n\n /** Updates the tooltip position. */\n update = () => {\n styleTip(this);\n };\n\n /** Toggles the tooltip visibility. */\n toggle = () => {\n const { tooltip } = this;\n\n if (tooltip && !hasTip(this)) this.show();\n else this.hide();\n };\n\n /** Enables the tooltip. */\n enable() {\n const { enabled } = this;\n // istanbul ignore else @preserve\n if (!enabled) {\n this._toggleEventListeners(true);\n this.enabled = !enabled;\n }\n }\n\n /** Disables the tooltip. */\n disable() {\n const { tooltip, enabled } = this;\n // istanbul ignore else @preserve\n if (enabled) {\n if (tooltip && hasTip(this)) this.hide();\n this._toggleEventListeners();\n this.enabled = !enabled;\n }\n }\n\n /** Toggles the `disabled` property. */\n toggleEnabled() {\n if (!this.enabled) this.enable();\n else this.disable();\n }\n\n /**\n * Handles the `touchstart` event listener for `Tooltip`\n *\n * @this {Tooltip}\n * @param {TouchEvent} e the `Event` object\n */\n handleTouch = ({ target }: TouchEvent) => {\n const { tooltip, element } = this;\n\n // istanbul ignore if @preserve\n if (\n (tooltip && tooltip.contains(target as HTMLElement)) ||\n target === element ||\n (target && element.contains(target as HTMLElement))\n ) {\n // smile for ESLint\n } else {\n this.hide();\n }\n };\n\n /**\n * Toggles on/off the `Tooltip` event listeners.\n *\n * @param add when `true`, event listeners are added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n // btn is only for dismissible popover\n const { element, options, btn } = this;\n const { trigger } = options;\n const isPopover = this.name !== tooltipComponent;\n const dismissible = isPopover && (options as PopoverOptions).dismissible\n ? true\n : false;\n\n // istanbul ignore else @preserve\n if (!trigger.includes(\"manual\")) {\n this.enabled = !!add;\n\n const triggerOptions = trigger.split(\" \");\n\n triggerOptions.forEach((tr) => {\n // istanbul ignore else @preserve\n if (tr === mousehoverEvent) {\n action(element, mousedownEvent, this.handleShow);\n action(element, mouseenterEvent, this.handleShow);\n\n // istanbul ignore else @preserve\n if (!dismissible) {\n action(element, mouseleaveEvent, this.handleHide);\n action(\n getDocument(element),\n touchstartEvent,\n this.handleTouch,\n passiveHandler,\n );\n }\n } else if (tr === mouseclickEvent) {\n action(element, tr, !dismissible ? this.toggle : this.handleShow);\n } else if (tr === focusEvent) {\n action(element, focusinEvent, this.handleShow);\n // istanbul ignore else @preserve\n if (!dismissible) action(element, focusoutEvent, this.handleHide);\n // istanbul ignore else @preserve\n if (isApple()) {\n action(element, mouseclickEvent, this.handleFocus);\n }\n }\n // istanbul ignore else @preserve\n if (dismissible && btn) {\n action(btn, mouseclickEvent, this.handleHide);\n }\n });\n }\n };\n\n /** Removes the `Tooltip` from the target element. */\n dispose() {\n const { tooltip, options } = this;\n const clone = { ...this, name: this.name };\n const callback = () =>\n setTimeout(\n () => disposeTooltipComplete(clone, () => super.dispose()),\n 17,\n );\n\n if (options.animation && hasTip(clone)) {\n this.options.delay = 0; // reset delay\n this.hide();\n emulateTransitionEnd(tooltip as HTMLElement, callback);\n } else {\n callback();\n }\n }\n}\n"],"names":["popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","arrow","body","tipClassPositions","styleTip","self","tipClasses","element","tooltip","container","options","tipPositions","RTL","isRTL","setElementStyle","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","getDocumentElement","placement","parentCWidth","parentOWidth","fixedParent","getElementStyle","scrollbarWidth","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","getBoundingClientRect","x","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","topExceed","bottomExceed","leftExceed","rightExceed","horizontals","verticals","isHTMLElement","updatedTooltipEvent","createCustomEvent","toLowerCase","dispatchEvent","tooltipDefaults","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","isString","dirty","isFunction","tempDocument","isNodeList","isArray","isNode","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","createElement","setAttribute","tooltipHeader","querySelector","tooltipBody","tempTitle","tempContent","tempBtn","addClass","hasClass","fadeClass","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","c","i","r","getDocument","tooltipSelector","dataBsToggle","titleAttr","getTooltipInstance","getInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","removeAttribute","ariaDescribedBy","removePopup","hasTip","hasPopup","disposeTooltipComplete","callback","hasAttribute","toggleTooltipTitle","toggleTooltipAction","add","action","addListener","removeListener","touchstartEvent","passiveHandler","tooltipShownAction","shownTooltipEvent","Timer","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","closest","modalString","parentOffcanvas","offcanvasString","titleAtt","getAttribute","BaseComponent","target","config","tipComponent","elem","getUID","ObjectAssign","position","PositionObserver","focus","outTimer","tipContainer","showTooltipEvent","appendPopup","showClass","emulateTransitionEnd","delay","hideTooltipEvent","removeClass","enabled","btn","trigger","tr","mousehoverEvent","mousedownEvent","mouseenterEvent","mouseleaveEvent","mouseclickEvent","focusEvent","focusinEvent","focusoutEvent","isApple","clone"],"mappings":"uSACMA,EAAgB,UCAhBC,GAAmB,UCAnBC,EAAgB,UCOhBC,GAAkBC,GAAoB,CAC1C,MAAMC,EAAYD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AAK,UAAU,EACxC1C,EAAAzH,EAASoK,kBAAiB,KAAK,UAAU,EAG3C7F,IACIkD,EAAAzH,EAASqK,kBAAiB,KAAK,UAAU,EAChD5C,EACErB,EAAAA,YAAYpG,CAAO,EACnB4H,EAAA,gBACA,KAAK,YACLC,EAAAA,cACF,IAEOoC,IAAOK,kBAChB7C,EAAOzH,EAASiK,EAAK1F,EAA4B,KAAK,WAAnB,KAAK,MAAwB,EACvD0F,IAAOM,eACT9C,EAAAzH,EAASwK,eAAc,KAAK,UAAU,EAExCjG,GAAakD,EAAOzH,EAASyK,EAAA,cAAe,KAAK,UAAU,EAE5DC,aACKjD,EAAAzH,EAASsK,kBAAiB,KAAK,WAAW,GAIjD/F,GAAewF,GACVtC,EAAAsC,EAAKO,kBAAiB,KAAK,UAAU,CAC9C,CACD,EAEL,EAGA,SAAU,CACF,KAAA,CAAE,QAAArK,EAAS,QAAAE,CAAA,EAAY,KACvBwK,EAAQ,CAAE,GAAG,KAAM,KAAM,KAAK,IAAK,EACnCvD,EAAW,IACf,WACE,IAAMD,GAAuBwD,EAAO,IAAM,MAAM,SAAS,EACzD,EACF,EAEExK,EAAQ,WAAa8G,EAAO0D,CAAK,GACnC,KAAK,QAAQ,MAAQ,EACrB,KAAK,KAAK,EACVjB,EAAA,qBAAqBzJ,EAAwBmH,CAAQ,GAE5CA,EAAA,CACX,CAEJ"} \ No newline at end of file diff --git a/dist/components/tooltip-B5F6ZNW7.mjs b/dist/components/tooltip-B5F6ZNW7.mjs deleted file mode 100644 index cbcd2960..00000000 --- a/dist/components/tooltip-B5F6ZNW7.mjs +++ /dev/null @@ -1,327 +0,0 @@ -import { i as Pt, K as ct, Q as It, P as tt, R as kt, u as y, c as Q, a8 as U, d as V, I as Ft, a9 as jt, aa as zt, ab as qt, ac as Kt, a3 as z, s as et, q as J, f as L, h as K, ad as Qt, ae as Ut, af as Vt, l as st, B as Yt, g as yt, ag as Zt, O as Gt, M as xt, N as Jt, T as B, e as rt, r as Xt, ah as te, V as ee, v as se, w as oe, z as St, m as dt, S as ie, a6 as ne, a7 as ae, ai as le, D as ft, b as ce, Z as Ht, aj as Nt, x as At } from "./base-component-ylZzLp-h.mjs"; -import { E as pt, r as mt } from "./event-listener-C1-Yf9Z5.mjs"; -import { x as re } from "./index-gZuXW-3_.mjs"; -import { d as de } from "./dataBsToggle-B84TS15h.mjs"; -import { s as ht } from "./showClass-C8hdJfjQ.mjs"; -import { a as he, h as pe, m as ut, o as gt, r as me } from "./popupContainer-ymf2oGcv.mjs"; -import { f as bt } from "./fadeClass-CLIYI_zn.mjs"; -const X = "popover", Lt = "Popover", w = "tooltip", fe = (o) => { - const t = o === w, s = t ? `${o}-inner` : `${o}-body`, e = t ? "" : `

`, i = `
`, n = `
`; - return `
${e + i + n}
`; -}, Bt = { - top: "top", - bottom: "bottom", - left: "start", - right: "end" -}, vt = (o) => { - const t = /\b(top|bottom|start|end)+/, { element: s, tooltip: e, container: i, options: n, arrow: c } = o; - if (e) { - const p = { ...Bt }, h = Pt(s); - ct(e, { - // top: '0px', left: '0px', right: '', bottom: '', - top: "", - left: "", - right: "", - bottom: "" - }); - const f = o.name === Lt, { offsetWidth: l, offsetHeight: u } = e, { clientWidth: x, clientHeight: b, offsetWidth: O } = It(s); - let { placement: a } = n; - const { clientWidth: v, offsetWidth: T } = i, S = tt( - i, - "position" - ) === "fixed", r = Math.abs(S ? v - T : x - O), H = h && S ? r : 0, $ = x - (h ? 0 : r) - 1, { - width: m, - height: g, - left: d, - right: Mt, - top: R - } = kt(s, !0), { x: Y, y: M } = { - x: d, - y: R - }; - ct(c, { - top: "", - left: "", - right: "", - bottom: "" - }); - let N = 0, _ = "", E = 0, it = "", D = "", Z = "", nt = ""; - const A = c.offsetWidth || 0, C = c.offsetHeight || 0, at = A / 2; - let I = R - u - C < 0, k = R + u + g + C >= b, F = d - l - A < H, j = d + l + m + A >= $; - const G = ["left", "right"], lt = ["top", "bottom"]; - I = G.includes(a) ? R + g / 2 - u / 2 - C < 0 : I, k = G.includes(a) ? R + u / 2 + g / 2 + C >= b : k, F = lt.includes(a) ? d + m / 2 - l / 2 < H : F, j = lt.includes(a) ? d + l / 2 + m / 2 >= $ : j, a = G.includes(a) && F && j ? "top" : a, a = a === "top" && I ? "bottom" : a, a = a === "bottom" && k ? "top" : a, a = a === "left" && F ? "right" : a, a = a === "right" && j ? "left" : a, e.className.includes(a) || (e.className = e.className.replace( - t, - p[a] - )), G.includes(a) ? (a === "left" ? E = Y - l - (f ? A : 0) : E = Y + m + (f ? A : 0), I && k ? (N = 0, _ = 0, D = R + g / 2 - C / 2) : I ? (N = M, _ = "", D = g / 2 - A) : k ? (N = M - u + g, _ = "", D = u - g / 2 - A) : (N = M - u / 2 + g / 2, D = u / 2 - C / 2)) : lt.includes(a) && (a === "top" ? N = M - u - (f ? C : 0) : N = M + g + (f ? C : 0), F ? (E = 0, Z = Y + m / 2 - at) : j ? (E = "auto", it = 0, nt = m / 2 + $ - Mt - at) : (E = Y - l / 2 + m / 2, Z = l / 2 - at)), ct(e, { - top: `${N}px`, - bottom: _ === "" ? "" : `${_}px`, - left: E === "auto" ? E : `${E}px`, - right: it !== "" ? `${it}px` : "" - }), y(c) && (D !== "" && (c.style.top = `${D}px`), Z !== "" ? c.style.left = `${Z}px` : nt !== "" && (c.style.right = `${nt}px`)); - const _t = Q( - `updated.bs.${U(o.name)}` - ); - V(s, _t); - } -}, Tt = { - template: fe(w), - title: "", - customClass: "", - trigger: "hover focus", - placement: "top", - sanitizeFn: void 0, - animation: !0, - delay: 200, - container: document.body, - content: "", - dismissible: !1, - btnClose: "" -}, Wt = "data-original-title", W = "Tooltip", P = (o, t, s) => { - if (Ft(t) && t.length) { - let e = t.trim(); - jt(s) && (e = s(e)); - const n = new DOMParser().parseFromString(e, "text/html"); - o.append(...n.body.childNodes); - } else y(t) ? o.append(t) : (zt(t) || qt(t) && t.every(Kt)) && o.append(...t); -}, ue = (o) => { - const t = o.name === W, { id: s, element: e, options: i } = o, { - title: n, - placement: c, - template: p, - animation: h, - customClass: f, - sanitizeFn: l, - dismissible: u, - content: x, - btnClose: b - } = i, O = t ? w : X, a = { ...Bt }; - let v = [], T = []; - Pt(e) && (a.left = "end", a.right = "start"); - const ot = `bs-${O}-${a[c]}`; - let S; - if (y(p)) - S = p; - else { - const H = z("div"); - P(H, p, l), S = H.firstChild; - } - o.tooltip = y(S) ? S.cloneNode(!0) : void 0; - const { tooltip: r } = o; - if (r) { - et(r, "id", s), et(r, "role", w); - const H = t ? `${w}-inner` : `${X}-body`, $ = t ? null : J(`.${X}-header`, r), m = J(`.${H}`, r); - o.arrow = J(`.${O}-arrow`, r); - const { arrow: g } = o; - if (y(n)) v = [n.cloneNode(!0)]; - else { - const d = z("div"); - P(d, n, l), v = [...d.childNodes]; - } - if (y(x)) T = [x.cloneNode(!0)]; - else { - const d = z("div"); - P(d, x, l), T = [...d.childNodes]; - } - if (u) - if (n) - if (y(b)) - v = [...v, b.cloneNode(!0)]; - else { - const d = z("div"); - P(d, b, l), v = [...v, d.firstChild]; - } - else if ($ && $.remove(), y(b)) - T = [...T, b.cloneNode(!0)]; - else { - const d = z("div"); - P(d, b, l), T = [...T, d.firstChild]; - } - t ? n && m && P(m, n, l) : (n && $ && P($, v, l), x && m && P(m, T, l), o.btn = J(".btn-close", r) || void 0), L(r, "position-fixed"), L(g, "position-absolute"), K(r, O) || L(r, O), h && !K(r, bt) && L(r, bt), f && !K(r, f) && L(r, f), K(r, ot) || L(r, ot); - } -}, ge = (o) => { - const t = ["HTML", "BODY"], s = []; - let { parentNode: e } = o; - for (; e && !t.includes(e.nodeName); ) - e = Qt(e), Ut(e) || Vt(e) || s.push(e); - return s.find((i, n) => tt(i, "position") !== "relative" && s.slice(n + 1).every( - (c) => tt(c, "position") === "static" - ) ? i : null) || // istanbul ignore next: optional guard - st(o).body; -}, be = `[${de}="${w}"],[data-tip="${w}"]`, Ot = "title"; -let wt = (o) => yt(o, W); -const ve = (o) => new $e(o), Te = (o) => { - const { element: t, tooltip: s, container: e, offsetParent: i } = o; - Ht(t, Nt), me( - s, - e === i ? e : i - ); -}, q = (o) => { - const { tooltip: t, container: s, offsetParent: e } = o; - return t && pe(t, s === e ? s : e); -}, we = (o, t) => { - const { element: s } = o; - o._toggleEventListeners(), xt(s, Wt) && o.name === W && Dt(o), t && t(); -}, Rt = (o, t) => { - const s = t ? pt : mt, { element: e } = o; - s( - st(e), - St, - o.handleTouch, - At - ); -}, $t = (o) => { - const { element: t } = o, s = Q( - `shown.bs.${U(o.name)}` - ); - Rt(o, !0), V(t, s), B.clear(t, "in"); -}, Et = (o) => { - const { element: t } = o, s = Q( - `hidden.bs.${U(o.name)}` - ); - Rt(o), Te(o), V(t, s), B.clear(t, "out"); -}, Ct = (o, t) => { - const s = t ? pt : mt, { element: e } = o, i = ft(e, `.${ut}`), n = ft(e, `.${gt}`); - t ? o._observer.observe(o.element) : o._observer.disconnect(), i && s(i, `hide.bs.${ut}`, o.handleHide), n && s(n, `hide.bs.${gt}`, o.handleHide); -}, Dt = (o, t) => { - const s = [Wt, Ot], { element: e } = o; - et( - e, - s[t ? 0 : 1], - t || ce(e, s[0]) || // istanbul ignore next @preserve - "" - ), Ht(e, s[t ? 1 : 0]); -}; -class $e extends Yt { - static selector = be; - static init = ve; - static getInstance = wt; - static styleTip = vt; - /** - * @param target the target element - * @param config the instance options - */ - constructor(t, s) { - super(t, s); - const { element: e } = this, i = this.name === W, n = i ? w : X, c = i ? W : Lt; - wt = (h) => yt(h, c), this.enabled = !0, this.id = `${n}-${Zt(e, n)}`; - const { options: p } = this; - !p.title && i || !i && !p.content || (Gt(Tt, { titleAttr: "" }), xt(e, Ot) && i && typeof p.title == "string" && Dt(this, p.title), this.container = ge(e), this.offsetParent = ["sticky", "fixed"].some( - (h) => tt(this.container, "position") === h - ) ? this.container : st(this.element).body, ue(this), this._observer = new re(() => this.update()), this._toggleEventListeners(!0)); - } - /** - * Returns component name string. - */ - get name() { - return W; - } - /** - * Returns component default options. - */ - get defaults() { - return Tt; - } - // TOOLTIP PUBLIC METHODS - // ====================== - /** Handles the focus event on iOS. */ - // istanbul ignore next @preserve - impossible to test without Apple device - handleFocus = () => Jt(this.element); - /** Shows the tooltip. */ - handleShow = () => this.show(); - show() { - const { options: t, tooltip: s, element: e, container: i, offsetParent: n, id: c } = this, { animation: p } = t, h = B.get(e, "out"), f = i === n ? i : n; - B.clear(e, "out"), s && !h && !q(this) && B.set( - e, - () => { - const l = Q( - `show.bs.${U(this.name)}` - ); - V(e, l), l.defaultPrevented || (he(s, f), et(e, Nt, `#${c}`), this.update(), Ct(this, !0), K(s, ht) || L(s, ht), p ? rt(s, () => $t(this)) : $t(this)); - }, - 17, - "in" - ); - } - /** Hides the tooltip. */ - handleHide = () => this.hide(); - hide() { - const { options: t, tooltip: s, element: e } = this, { animation: i, delay: n } = t; - B.clear(e, "in"), s && q(this) && B.set( - e, - () => { - const c = Q( - `hide.bs.${U(this.name)}` - ); - V(e, c), c.defaultPrevented || (this.update(), Xt(s, ht), Ct(this), i ? rt(s, () => Et(this)) : Et(this)); - }, - n + 17, - "out" - ); - } - /** Updates the tooltip position. */ - update = () => { - vt(this); - }; - /** Toggles the tooltip visibility. */ - toggle = () => { - const { tooltip: t } = this; - t && !q(this) ? this.show() : this.hide(); - }; - /** Enables the tooltip. */ - enable() { - const { enabled: t } = this; - t || (this._toggleEventListeners(!0), this.enabled = !t); - } - /** Disables the tooltip. */ - disable() { - const { tooltip: t, enabled: s } = this; - s && (t && q(this) && this.hide(), this._toggleEventListeners(), this.enabled = !s); - } - /** Toggles the `disabled` property. */ - toggleEnabled() { - this.enabled ? this.disable() : this.enable(); - } - /** - * Handles the `touchstart` event listener for `Tooltip` - * - * @this {Tooltip} - * @param {TouchEvent} e the `Event` object - */ - handleTouch = ({ target: t }) => { - const { tooltip: s, element: e } = this; - s && s.contains(t) || t === e || t && e.contains(t) || this.hide(); - }; - /** - * Toggles on/off the `Tooltip` event listeners. - * - * @param add when `true`, event listeners are added - */ - _toggleEventListeners = (t) => { - const s = t ? pt : mt, { element: e, options: i, btn: n } = this, { trigger: c } = i, h = !!(this.name !== W && i.dismissible); - c.includes("manual") || (this.enabled = !!t, c.split(" ").forEach((l) => { - l === te ? (s(e, ee, this.handleShow), s(e, se, this.handleShow), h || (s(e, oe, this.handleHide), s( - st(e), - St, - this.handleTouch, - At - ))) : l === dt ? s(e, l, h ? this.handleShow : this.toggle) : l === ie && (s(e, ne, this.handleShow), h || s(e, ae, this.handleHide), le() && s(e, dt, this.handleFocus)), h && n && s(n, dt, this.handleHide); - })); - }; - /** Removes the `Tooltip` from the target element. */ - dispose() { - const { tooltip: t, options: s } = this, e = { ...this, name: this.name }, i = () => setTimeout( - () => we(e, () => super.dispose()), - 17 - ); - s.animation && q(e) ? (this.options.delay = 0, this.hide(), rt(t, i)) : i(); - } -} -export { - $e as T, - X as a, - fe as g, - Lt as p, - vt as s, - Tt as t -}; -//# sourceMappingURL=tooltip-B5F6ZNW7.mjs.map diff --git a/dist/components/tooltip-B5F6ZNW7.mjs.map b/dist/components/tooltip-B5F6ZNW7.mjs.map deleted file mode 100644 index d73c738b..00000000 --- a/dist/components/tooltip-B5F6ZNW7.mjs.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"tooltip-B5F6ZNW7.mjs","sources":["../../src/strings/popoverString.ts","../../src/strings/popoverComponent.ts","../../src/strings/tooltipString.ts","../../src/util/getTipTemplate.ts","../../src/util/tipClassPositions.ts","../../src/util/styleTip.ts","../../src/util/tooltipDefaults.ts","../../src/strings/dataOriginalTitle.ts","../../src/strings/tooltipComponent.ts","../../src/util/setHtml.ts","../../src/util/createTip.ts","../../src/util/getElementContainer.ts","../../src/components/tooltip.ts"],"sourcesContent":["/** @type {string} */\nconst popoverString = \"popover\";\nexport default popoverString;\n","/** @type {string} */\nconst popoverComponent = \"Popover\";\nexport default popoverComponent;\n","/** @type {string} */\nconst tooltipString = \"tooltip\";\nexport default tooltipString;\n","import tooltipString from \"../strings/tooltipString\";\n\n/**\n * Returns a template for Popover / Tooltip.\n *\n * @param tipType the expected markup type\n * @returns the template markup\n */\nconst getTipTemplate = (tipType: string) => {\n const isTooltip = tipType === tooltipString;\n const bodyClass = isTooltip ? `${tipType}-inner` : `${tipType}-body`;\n const header = !isTooltip ? `

` : \"\";\n const arrow = `
`;\n const body = `
`;\n return `
${\n header + arrow + body\n }
`;\n};\n\nexport default getTipTemplate;\n","const tipClassPositions = {\n top: \"top\",\n bottom: \"bottom\",\n left: \"start\",\n right: \"end\",\n};\n\nexport default tipClassPositions;\n","import {\n createCustomEvent,\n dispatchEvent,\n getBoundingClientRect,\n getDocumentElement,\n getElementStyle,\n isHTMLElement,\n isRTL,\n setElementStyle,\n toLowerCase,\n} from \"@thednp/shorty\";\n\nimport popoverComponent from \"../strings/popoverComponent\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport Tooltip from \"../components/tooltip\";\nimport type { TooltipEvent } from \"../interface/tooltip\";\nimport type { PopoverEvent } from \"../interface/popover\";\n\n/**\n * Style popovers and tooltips.\n *\n * @param self the `Popover` / `Tooltip` instance\n */\nconst styleTip = (self: T) => {\n const tipClasses = /\\b(top|bottom|start|end)+/;\n const { element, tooltip, container, options, arrow } = self;\n\n // istanbul ignore else @preserve\n if (tooltip) {\n const tipPositions = { ...tipClassPositions };\n const RTL = isRTL(element);\n\n // reset tooltip style (top: 0, left: 0 works best)\n setElementStyle(tooltip, {\n // top: '0px', left: '0px', right: '', bottom: '',\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n const isPopover = self.name === popoverComponent;\n const { offsetWidth: tipWidth, offsetHeight: tipHeight } = tooltip;\n const { clientWidth: htmlcw, clientHeight: htmlch, offsetWidth: htmlow } =\n getDocumentElement(element);\n let { placement } = options;\n const { clientWidth: parentCWidth, offsetWidth: parentOWidth } =\n container as HTMLElement;\n const parentPosition = getElementStyle(\n container as HTMLElement,\n \"position\",\n );\n const fixedParent = parentPosition === \"fixed\";\n const scrollbarWidth = fixedParent\n ? Math.abs(parentCWidth - parentOWidth)\n : Math.abs(htmlcw - htmlow);\n const leftBoundry = RTL && fixedParent\n // istanbul ignore next @preserve\n ? scrollbarWidth\n : 0;\n const rightBoundry = htmlcw - (!RTL ? scrollbarWidth : 0) - 1;\n const {\n width: elemWidth,\n height: elemHeight,\n left: elemRectLeft,\n right: elemRectRight,\n top: elemRectTop,\n } = getBoundingClientRect(element, true);\n const { x, y } = {\n x: elemRectLeft,\n y: elemRectTop,\n };\n // reset arrow style\n setElementStyle(arrow as HTMLElement, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n let topPosition: number | string = 0;\n let bottomPosition: number | string = \"\";\n let leftPosition: number | string = 0;\n let rightPosition: number | string = \"\";\n let arrowTop: number | string = \"\";\n let arrowLeft: number | string = \"\";\n let arrowRight: number | string = \"\";\n\n const arrowWidth = (arrow as HTMLElement).offsetWidth || 0;\n const arrowHeight = (arrow as HTMLElement).offsetHeight || 0;\n const arrowAdjust = arrowWidth / 2;\n\n // check placement\n let topExceed = elemRectTop - tipHeight - arrowHeight < 0;\n let bottomExceed =\n elemRectTop + tipHeight + elemHeight + arrowHeight >= htmlch;\n let leftExceed = elemRectLeft - tipWidth - arrowWidth < leftBoundry;\n let rightExceed =\n elemRectLeft + tipWidth + elemWidth + arrowWidth >= rightBoundry;\n\n const horizontals = [\"left\", \"right\"];\n const verticals = [\"top\", \"bottom\"];\n\n topExceed = horizontals.includes(placement)\n ? elemRectTop + elemHeight / 2 - tipHeight / 2 - arrowHeight < 0\n : topExceed;\n bottomExceed = horizontals.includes(placement)\n ? elemRectTop + tipHeight / 2 + elemHeight / 2 + arrowHeight >= htmlch\n : bottomExceed;\n leftExceed = verticals.includes(placement)\n ? elemRectLeft + elemWidth / 2 - tipWidth / 2 < leftBoundry\n : leftExceed;\n rightExceed = verticals.includes(placement)\n ? elemRectLeft + tipWidth / 2 + elemWidth / 2 >= rightBoundry\n : rightExceed;\n\n // first remove side positions if both left and right limits are exceeded\n // we usually fall back to top|bottom\n placement = horizontals.includes(placement) && leftExceed && rightExceed\n ? \"top\"\n : placement;\n // recompute placement\n placement = placement === \"top\" && topExceed ? \"bottom\" : placement;\n placement = placement === \"bottom\" && bottomExceed ? \"top\" : placement;\n placement = placement === \"left\" && leftExceed ? \"right\" : placement;\n placement = placement === \"right\" && rightExceed\n ? \"left\"\n // istanbul ignore next @preserve\n : placement;\n\n // update tooltip/popover class\n if (!tooltip.className.includes(placement)) {\n tooltip.className = tooltip.className.replace(\n tipClasses,\n tipPositions[placement],\n );\n }\n\n // compute tooltip / popover coordinates\n // istanbul ignore else @preserve\n if (horizontals.includes(placement)) {\n // secondary|side positions\n if (placement === \"left\") {\n // LEFT\n leftPosition = x - tipWidth - (isPopover ? arrowWidth : 0);\n } else {\n // RIGHT\n leftPosition = x + elemWidth + (isPopover ? arrowWidth : 0);\n }\n\n // adjust top and arrow\n if (topExceed && bottomExceed) {\n topPosition = 0;\n bottomPosition = 0;\n arrowTop = elemRectTop + elemHeight / 2 - arrowHeight / 2;\n } else if (topExceed) {\n topPosition = y;\n bottomPosition = \"\";\n arrowTop = elemHeight / 2 - arrowWidth;\n } else if (bottomExceed) {\n topPosition = y - tipHeight + elemHeight;\n bottomPosition = \"\";\n arrowTop = tipHeight - elemHeight / 2 - arrowWidth;\n } else {\n topPosition = y - tipHeight / 2 + elemHeight / 2;\n arrowTop = tipHeight / 2 - arrowHeight / 2;\n }\n } else if (verticals.includes(placement)) {\n if (placement === \"top\") {\n topPosition = y - tipHeight - (isPopover ? arrowHeight : 0);\n } else {\n // BOTTOM\n topPosition = y + elemHeight + (isPopover ? arrowHeight : 0);\n }\n\n // adjust left | right and also the arrow\n if (leftExceed) {\n leftPosition = 0;\n arrowLeft = x + elemWidth / 2 - arrowAdjust;\n } else if (rightExceed) {\n leftPosition = \"auto\";\n rightPosition = 0;\n arrowRight = elemWidth / 2 + rightBoundry - elemRectRight - arrowAdjust;\n } else {\n leftPosition = x - tipWidth / 2 + elemWidth / 2;\n arrowLeft = tipWidth / 2 - arrowAdjust;\n }\n }\n\n // apply style to tooltip/popover\n setElementStyle(tooltip, {\n top: `${topPosition}px`,\n bottom: bottomPosition === \"\" ? \"\" : `${bottomPosition}px`,\n left: leftPosition === \"auto\" ? leftPosition : `${leftPosition}px`,\n right: rightPosition !== \"\" ? `${rightPosition}px` : \"\",\n });\n\n // update arrow placement\n // istanbul ignore else @preserve\n if (isHTMLElement(arrow)) {\n if (arrowTop !== \"\") {\n arrow.style.top = `${arrowTop}px`;\n }\n if (arrowLeft !== \"\") {\n arrow.style.left = `${arrowLeft}px`;\n } else if (arrowRight !== \"\") {\n arrow.style.right = `${arrowRight}px`;\n }\n }\n const updatedTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `updated.bs.${toLowerCase(self.name)}`,\n );\n dispatchEvent(element, updatedTooltipEvent);\n }\n};\n\nexport default styleTip;\n","import getTipTemplate from \"./getTipTemplate\";\nimport tooltipString from \"../strings/tooltipString\";\nimport { TooltipOptions } from \"../interface/tooltip\";\n\nconst tooltipDefaults: TooltipOptions = {\n template: getTipTemplate(tooltipString),\n title: \"\",\n customClass: \"\",\n trigger: \"hover focus\",\n placement: \"top\",\n sanitizeFn: undefined,\n animation: true,\n delay: 200,\n container: document.body,\n content: \"\",\n dismissible: false,\n btnClose: \"\",\n};\nexport default tooltipDefaults;\n","/**\n * Global namespace for `data-bs-title` attribute.\n */\nconst dataOriginalTitle = \"data-original-title\";\nexport default dataOriginalTitle;\n","/** @type {string} */\nconst tooltipComponent = \"Tooltip\";\nexport default tooltipComponent;\n","import {\n isArray,\n isFunction,\n isHTMLElement,\n isNode,\n isNodeList,\n isString,\n} from \"@thednp/shorty\";\n\n/**\n * Append an existing `Element` to Popover / Tooltip component or HTML\n * markup string to be parsed & sanitized to be used as popover / tooltip content.\n *\n * @param element target\n * @param content the `Element` to append / string\n * @param sanitizeFn a function to sanitize string content\n */\nconst setHtml = (\n element: HTMLElement,\n content: Node[] | Node | string,\n sanitizeFn?: (s: string) => string,\n) => {\n // istanbul ignore else @preserve\n if (isString(content) && content.length) {\n let dirty = content.trim(); // fixing #233\n if (isFunction(sanitizeFn)) dirty = sanitizeFn(dirty);\n\n const domParser = new DOMParser();\n const tempDocument = domParser.parseFromString(dirty, \"text/html\");\n element.append(...[...tempDocument.body.childNodes]);\n } else if (isHTMLElement(content)) {\n element.append(content);\n } else if (\n isNodeList(content) || (isArray(content) && content.every(isNode))\n ) {\n element.append(...[...content]);\n }\n};\nexport default setHtml;\n","import {\n addClass,\n createElement,\n hasClass,\n isHTMLElement,\n isRTL,\n querySelector,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport tooltipString from \"../strings/tooltipString\";\nimport popoverString from \"../strings/popoverString\";\nimport fadeClass from \"../strings/fadeClass\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport setHtml from \"./setHtml\";\nimport Tooltip from \"../components/tooltip\";\nimport Popover from \"../components/popover\";\n\n/**\n * Creates a new tooltip / popover.\n *\n * @param self the `Tooltip` / `Popover` instance\n */\nconst createTip = (self: Tooltip | Popover) => {\n const isTooltip = self.name === tooltipComponent;\n\n const { id, element, options } = self;\n const {\n title,\n placement,\n template,\n animation,\n customClass,\n sanitizeFn,\n dismissible,\n content,\n btnClose,\n } = options;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipPositions = { ...tipClassPositions };\n let titleParts: Node[] = [];\n let contentParts: Node[] = [];\n\n if (isRTL(element)) {\n tipPositions.left = \"end\";\n tipPositions.right = \"start\";\n }\n\n // set initial popover class\n const placementClass = `bs-${tipString}-${tipPositions[placement]}`;\n\n // load template\n let tooltipTemplate: Node | string;\n if (isHTMLElement(template)) {\n tooltipTemplate = template;\n } else {\n const htmlMarkup = createElement(\"div\") as HTMLElement;\n setHtml(htmlMarkup, template, sanitizeFn);\n tooltipTemplate = htmlMarkup.firstChild as HTMLElement;\n }\n\n // set popover markup\n self.tooltip = isHTMLElement(tooltipTemplate)\n ? (tooltipTemplate.cloneNode(true) as HTMLElement)\n // istanbul ignore next @preserve\n : undefined;\n\n const { tooltip } = self;\n // istanbul ignore else @preserve\n if (tooltip) {\n // set id and role attributes\n setAttribute(tooltip, \"id\", id);\n setAttribute(tooltip, \"role\", tooltipString);\n\n const bodyClass = isTooltip\n ? `${tooltipString}-inner`\n : `${popoverString}-body`;\n const tooltipHeader = isTooltip\n ? null\n : querySelector(`.${popoverString}-header`, tooltip);\n const tooltipBody = querySelector(`.${bodyClass}`, tooltip);\n\n // set arrow and enable access for styleTip\n self.arrow = querySelector(`.${tipString}-arrow`, tooltip) as HTMLElement;\n const { arrow } = self;\n\n if (isHTMLElement(title)) titleParts = [title.cloneNode(true)];\n else {\n const tempTitle = createElement(\"div\") as HTMLElement;\n setHtml(tempTitle, title, sanitizeFn);\n titleParts = [...[...tempTitle.childNodes]];\n }\n\n if (isHTMLElement(content)) contentParts = [content.cloneNode(true)];\n else {\n const tempContent = createElement(\"div\") as HTMLElement;\n setHtml(tempContent, content, sanitizeFn);\n contentParts = [...[...tempContent.childNodes]];\n }\n\n // set dismissible button\n if (dismissible) {\n if (title) {\n if (isHTMLElement(btnClose)) {\n titleParts = [...titleParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n titleParts = [...titleParts, tempBtn.firstChild as Node];\n }\n } else {\n // istanbul ignore else @preserve\n if (tooltipHeader) tooltipHeader.remove();\n if (isHTMLElement(btnClose)) {\n contentParts = [...contentParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n contentParts = [...contentParts, tempBtn.firstChild as Node];\n }\n }\n }\n\n // fill the template with content from options / data attributes\n // also sanitize title && content\n // istanbul ignore else @preserve\n if (!isTooltip) {\n // istanbul ignore else @preserve\n if (title && tooltipHeader) {\n setHtml(tooltipHeader, titleParts, sanitizeFn);\n }\n // istanbul ignore else @preserve\n if (content && tooltipBody) {\n setHtml(tooltipBody, contentParts, sanitizeFn);\n }\n // set btn\n self.btn = querySelector(\".btn-close\", tooltip) || undefined;\n } else if (title && tooltipBody) setHtml(tooltipBody, title, sanitizeFn);\n\n // Bootstrap 5.2.x\n // addClass(tooltip, 'position-absolute');\n addClass(tooltip, \"position-fixed\");\n addClass(arrow, \"position-absolute\");\n\n // set popover animation and placement\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, tipString)) addClass(tooltip, tipString);\n // istanbul ignore else @preserve\n if (animation && !hasClass(tooltip, fadeClass)) {\n addClass(tooltip, fadeClass);\n }\n // istanbul ignore else @preserve\n if (customClass && !hasClass(tooltip, customClass)) {\n addClass(tooltip, customClass);\n }\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, placementClass)) addClass(tooltip, placementClass);\n }\n};\n\nexport default createTip;\n","import {\n getDocument,\n getElementStyle,\n getParentNode,\n isShadowRoot,\n isTableElement,\n} from \"@thednp/shorty\";\n\n/**\n * Returns an `HTMLElement` to be used as default value for *options.container*\n * for `Tooltip` / `Popover` components.\n *\n * @see https://github.com/floating-ui/floating-ui\n *\n * @param element the target\n * @returns the query result\n */\nconst getElementContainer = (element: HTMLElement): ParentNode => {\n const majorBlockTags = [\"HTML\", \"BODY\"];\n const containers: ParentNode[] = [];\n let { parentNode } = element as Node;\n\n while (parentNode && !majorBlockTags.includes(parentNode.nodeName)) {\n parentNode = getParentNode(parentNode) as ParentNode;\n // istanbul ignore else @preserve\n if (!(isShadowRoot(parentNode) || isTableElement(parentNode))) {\n containers.push(parentNode);\n }\n }\n\n return (\n containers.find((c, i) => {\n if (\n getElementStyle(c as HTMLElement, \"position\") !== \"relative\" &&\n containers.slice(i + 1).every((r) =>\n getElementStyle(r as HTMLElement, \"position\") === \"static\"\n )\n ) {\n return c;\n }\n return null;\n }) ||\n // istanbul ignore next: optional guard\n getDocument(element).body\n );\n};\n\nexport default getElementContainer;\n","/* Native JavaScript for Bootstrap 5 | Tooltip\n---------------------------------------------- */\nimport {\n addClass,\n ariaDescribedBy,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focus,\n focusEvent,\n focusinEvent,\n focusoutEvent,\n getAttribute,\n getDocument,\n getElementStyle,\n getInstance,\n getUID,\n hasAttribute,\n hasClass,\n isApple,\n mouseclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseleaveEvent,\n ObjectAssign,\n passiveHandler,\n removeAttribute,\n removeClass,\n setAttribute,\n Timer,\n toLowerCase,\n touchstartEvent,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport dataOriginalTitle from \"../strings/dataOriginalTitle\";\nimport showClass from \"../strings/showClass\";\nimport tooltipString from \"../strings/tooltipString\";\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\nimport modalString from \"../strings/modalString\";\nimport offcanvasString from \"../strings/offcanvasString\";\n\nimport styleTip from \"../util/styleTip\";\nimport createTip from \"../util/createTip\";\nimport { appendPopup, hasPopup, removePopup } from \"../util/popupContainer\";\nimport getElementContainer from \"../util/getElementContainer\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport BaseComponent from \"./base-component\";\nimport type { TooltipEvent, TooltipOptions } from \"../interface/tooltip\";\nimport type { PopoverEvent, PopoverOptions } from \"../interface/popover\";\n\n// TOOLTIP PRIVATE GC\n// ==================\nconst tooltipSelector =\n `[${dataBsToggle}=\"${tooltipString}\"],[data-tip=\"${tooltipString}\"]`;\nconst titleAttr = \"title\";\n\n/**\n * Static method which returns an existing `Tooltip` instance associated\n * to a target `Element`.\n */\nlet getTooltipInstance = (element: HTMLElement) =>\n getInstance(element, tooltipComponent);\n\n/**\n * A `Tooltip` initialization callback.\n */\nconst tooltipInitCallback = (element: HTMLElement) => new Tooltip(element);\n\n// TOOLTIP PRIVATE METHODS\n// =======================\n/**\n * Removes the tooltip from the DOM.\n *\n * @param self the `Tooltip` instance\n */\nconst removeTooltip = (self: Tooltip) => {\n const { element, tooltip, container, offsetParent } = self;\n removeAttribute(element, ariaDescribedBy);\n removePopup(\n tooltip as HTMLElement,\n container === offsetParent ? container : offsetParent,\n );\n};\n\n/**\n * Check if container contains the tooltip.\n *\n * @param self Tooltip\n */\nconst hasTip = (self: Tooltip): boolean | undefined => {\n const { tooltip, container, offsetParent } = self;\n\n return tooltip &&\n hasPopup(tooltip, container === offsetParent ? container : offsetParent);\n};\n\n/**\n * Executes after the instance has been disposed.\n *\n * @param self the `Tooltip` instance\n * @param callback the parent dispose callback\n */\nconst disposeTooltipComplete = (self: Tooltip, callback?: () => void) => {\n const { element } = self;\n self._toggleEventListeners();\n\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, dataOriginalTitle) && self.name === tooltipComponent\n ) {\n toggleTooltipTitle(self);\n }\n // istanbul ignore else @preserve\n if (callback) callback();\n};\n\n/**\n * Toggles on/off the special `Tooltip` event listeners.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipAction = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n\n action(\n getDocument(element),\n touchstartEvent,\n self.handleTouch,\n passiveHandler,\n );\n};\n\n/**\n * Executes after the tooltip was shown to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipShownAction = (self: Tooltip) => {\n const { element } = self;\n const shownTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `shown.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self, true);\n dispatchEvent(element, shownTooltipEvent);\n Timer.clear(element, \"in\");\n};\n\n/**\n * Executes after the tooltip was hidden to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipHiddenAction = (self: Tooltip) => {\n const { element } = self;\n const hiddenTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hidden.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self);\n removeTooltip(self);\n dispatchEvent(element, hiddenTooltipEvent);\n\n Timer.clear(element, \"out\");\n};\n\n/**\n * Toggles on/off the `Tooltip` event listeners that hide/update the tooltip.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipOpenHandlers = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n // const { offsetHeight, scrollHeight } = container as HTMLElement;\n const parentModal = closest(element, `.${modalString}`);\n const parentOffcanvas = closest(element, `.${offcanvasString}`);\n\n if (add) self._observer.observe(self.element);\n else self._observer.disconnect();\n\n // dismiss tooltips inside modal / offcanvas\n if (parentModal) {\n action(parentModal, `hide.bs.${modalString}`, self.handleHide);\n }\n if (parentOffcanvas) {\n action(parentOffcanvas, `hide.bs.${offcanvasString}`, self.handleHide);\n }\n};\n\n/**\n * Toggles the `title` and `data-original-title` attributes.\n *\n * @param self the `Tooltip` instance\n * @param content when `true`, event listeners are added\n */\nconst toggleTooltipTitle = (self: Tooltip, content?: string) => {\n // [0 - add, 1 - remove] | [0 - remove, 1 - add]\n const titleAtt = [dataOriginalTitle, titleAttr];\n const { element } = self;\n\n setAttribute(\n element,\n titleAtt[content ? 0 : 1],\n content ||\n getAttribute(element, titleAtt[0]) ||\n // istanbul ignore next @preserve\n \"\",\n );\n removeAttribute(element, titleAtt[content ? 1 : 0]);\n};\n\n// TOOLTIP DEFINITION\n// ==================\n/** Creates a new `Tooltip` instance. */\nexport default class Tooltip extends BaseComponent {\n static selector = tooltipSelector;\n static init = tooltipInitCallback;\n static getInstance = getTooltipInstance;\n static styleTip = styleTip;\n declare options: TooltipOptions;\n declare btn?: HTMLElement;\n declare tooltip?: HTMLElement;\n declare container: ParentNode;\n declare arrow?: HTMLElement;\n declare offsetParent?: HTMLElement;\n declare enabled: boolean;\n declare id: string;\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n\n const { element } = this;\n const isTooltip = this.name === tooltipComponent;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipComponent = isTooltip ? tooltipComponent : popoverComponent;\n\n // istanbul ignore next @preserve: this is to set Popover too\n getTooltipInstance = (elem: HTMLElement) =>\n getInstance(elem, tipComponent);\n\n // additional properties\n this.enabled = true;\n /** Set unique ID for `aria-describedby`. */\n this.id = `${tipString}-${getUID(element, tipString)}`;\n\n // instance options\n const { options } = this;\n\n // invalidate\n if (!((!options.title && isTooltip) || (!isTooltip && !options.content))) {\n // reset default options\n ObjectAssign(tooltipDefaults, { titleAttr: \"\" });\n\n // set title attributes and add event listeners\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, titleAttr) && isTooltip &&\n typeof options.title === \"string\"\n ) {\n toggleTooltipTitle(this, options.title);\n }\n\n // set containers\n this.container = getElementContainer(element);\n this.offsetParent = [\"sticky\", \"fixed\"].some(\n (position) =>\n getElementStyle(this.container as HTMLElement, \"position\") ===\n position,\n )\n ? (this.container as HTMLElement)\n : getDocument(this.element).body;\n\n // create tooltip here\n createTip(this);\n\n // create observer\n this._observer = new PositionObserver(() => this.update());\n\n // attach events\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tooltipComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return tooltipDefaults;\n }\n\n // TOOLTIP PUBLIC METHODS\n // ======================\n /** Handles the focus event on iOS. */\n // istanbul ignore next @preserve - impossible to test without Apple device\n handleFocus = () => focus(this.element);\n /** Shows the tooltip. */\n handleShow = () => this.show();\n show() {\n const { options, tooltip, element, container, offsetParent, id } = this;\n const { animation } = options;\n const outTimer = Timer.get(element, \"out\");\n const tipContainer = container === offsetParent ? container : offsetParent;\n\n Timer.clear(element, \"out\");\n\n if (tooltip && !outTimer && !hasTip(this)) {\n Timer.set(\n element,\n () => {\n const showTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `show.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, showTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!showTooltipEvent.defaultPrevented) {\n // append to container\n appendPopup(tooltip, tipContainer);\n\n setAttribute(element, ariaDescribedBy, `#${id}`);\n\n this.update();\n toggleTooltipOpenHandlers(this, true);\n\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, showClass)) addClass(tooltip, showClass);\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipShownAction(this));\n } else tooltipShownAction(this);\n }\n },\n 17,\n \"in\",\n );\n }\n }\n\n /** Hides the tooltip. */\n handleHide = () => this.hide();\n hide() {\n const { options, tooltip, element } = this;\n const { animation, delay } = options;\n\n Timer.clear(element, \"in\");\n\n // istanbul ignore else @preserve\n if (tooltip && hasTip(this)) {\n Timer.set(\n element,\n () => {\n const hideTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hide.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, hideTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!hideTooltipEvent.defaultPrevented) {\n this.update();\n removeClass(tooltip, showClass);\n toggleTooltipOpenHandlers(this);\n\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipHiddenAction(this));\n } else tooltipHiddenAction(this);\n }\n },\n delay + 17,\n \"out\",\n );\n }\n }\n\n /** Updates the tooltip position. */\n update = () => {\n styleTip(this);\n };\n\n /** Toggles the tooltip visibility. */\n toggle = () => {\n const { tooltip } = this;\n\n if (tooltip && !hasTip(this)) this.show();\n else this.hide();\n };\n\n /** Enables the tooltip. */\n enable() {\n const { enabled } = this;\n // istanbul ignore else @preserve\n if (!enabled) {\n this._toggleEventListeners(true);\n this.enabled = !enabled;\n }\n }\n\n /** Disables the tooltip. */\n disable() {\n const { tooltip, enabled } = this;\n // istanbul ignore else @preserve\n if (enabled) {\n if (tooltip && hasTip(this)) this.hide();\n this._toggleEventListeners();\n this.enabled = !enabled;\n }\n }\n\n /** Toggles the `disabled` property. */\n toggleEnabled() {\n if (!this.enabled) this.enable();\n else this.disable();\n }\n\n /**\n * Handles the `touchstart` event listener for `Tooltip`\n *\n * @this {Tooltip}\n * @param {TouchEvent} e the `Event` object\n */\n handleTouch = ({ target }: TouchEvent) => {\n const { tooltip, element } = this;\n\n // istanbul ignore if @preserve\n if (\n (tooltip && tooltip.contains(target as HTMLElement)) ||\n target === element ||\n (target && element.contains(target as HTMLElement))\n ) {\n // smile for ESLint\n } else {\n this.hide();\n }\n };\n\n /**\n * Toggles on/off the `Tooltip` event listeners.\n *\n * @param add when `true`, event listeners are added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n // btn is only for dismissible popover\n const { element, options, btn } = this;\n const { trigger } = options;\n const isPopover = this.name !== tooltipComponent;\n const dismissible = isPopover && (options as PopoverOptions).dismissible\n ? true\n : false;\n\n // istanbul ignore else @preserve\n if (!trigger.includes(\"manual\")) {\n this.enabled = !!add;\n\n const triggerOptions = trigger.split(\" \");\n\n triggerOptions.forEach((tr) => {\n // istanbul ignore else @preserve\n if (tr === mousehoverEvent) {\n action(element, mousedownEvent, this.handleShow);\n action(element, mouseenterEvent, this.handleShow);\n\n // istanbul ignore else @preserve\n if (!dismissible) {\n action(element, mouseleaveEvent, this.handleHide);\n action(\n getDocument(element),\n touchstartEvent,\n this.handleTouch,\n passiveHandler,\n );\n }\n } else if (tr === mouseclickEvent) {\n action(element, tr, !dismissible ? this.toggle : this.handleShow);\n } else if (tr === focusEvent) {\n action(element, focusinEvent, this.handleShow);\n // istanbul ignore else @preserve\n if (!dismissible) action(element, focusoutEvent, this.handleHide);\n // istanbul ignore else @preserve\n if (isApple()) {\n action(element, mouseclickEvent, this.handleFocus);\n }\n }\n // istanbul ignore else @preserve\n if (dismissible && btn) {\n action(btn, mouseclickEvent, this.handleHide);\n }\n });\n }\n };\n\n /** Removes the `Tooltip` from the target element. */\n dispose() {\n const { tooltip, options } = this;\n const clone = { ...this, name: this.name };\n const callback = () =>\n setTimeout(\n () => disposeTooltipComplete(clone, () => super.dispose()),\n 17,\n );\n\n if (options.animation && hasTip(clone)) {\n this.options.delay = 0; // reset delay\n this.hide();\n emulateTransitionEnd(tooltip as HTMLElement, callback);\n } else {\n callback();\n }\n }\n}\n"],"names":["popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","arrow","body","tipClassPositions","styleTip","self","tipClasses","element","tooltip","container","options","tipPositions","RTL","isRTL","setElementStyle","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","getDocumentElement","placement","parentCWidth","parentOWidth","fixedParent","getElementStyle","scrollbarWidth","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","getBoundingClientRect","x","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","topExceed","bottomExceed","leftExceed","rightExceed","horizontals","verticals","isHTMLElement","updatedTooltipEvent","createCustomEvent","toLowerCase","dispatchEvent","tooltipDefaults","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","isString","dirty","isFunction","tempDocument","isNodeList","isArray","isNode","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","createElement","setAttribute","tooltipHeader","querySelector","tooltipBody","tempTitle","tempContent","tempBtn","addClass","hasClass","fadeClass","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","c","i","r","getDocument","tooltipSelector","dataBsToggle","titleAttr","getTooltipInstance","getInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","removeAttribute","ariaDescribedBy","removePopup","hasTip","hasPopup","disposeTooltipComplete","callback","hasAttribute","toggleTooltipTitle","toggleTooltipAction","add","action","addListener","removeListener","touchstartEvent","passiveHandler","tooltipShownAction","shownTooltipEvent","Timer","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","closest","modalString","parentOffcanvas","offcanvasString","titleAtt","getAttribute","BaseComponent","target","config","tipComponent","elem","getUID","ObjectAssign","position","PositionObserver","focus","outTimer","tipContainer","showTooltipEvent","appendPopup","showClass","emulateTransitionEnd","delay","hideTooltipEvent","removeClass","enabled","btn","trigger","tr","mousehoverEvent","mousedownEvent","mouseenterEvent","mouseleaveEvent","mouseclickEvent","focusEvent","focusinEvent","focusoutEvent","isApple","clone"],"mappings":";;;;;;;AACA,MAAMA,IAAgB,WCAhBC,KAAmB,WCAnBC,IAAgB,WCOhBC,KAAiB,CAACC,MAAoB;AAC1C,QAAMC,IAAYD,MAAYF,GACxBI,IAAYD,IAAY,GAAGD,CAAO,WAAW,GAAGA,CAAO,SACvDG,IAAUF,IAAoD,KAAxC,cAAcD,CAAO,kBAC3CI,IAAQ,eAAeJ,CAAO,kBAC9BK,IAAO,eAAeH,CAAS;AACrC,SAAO,eAAeF,CAAO,WAAWF,CAAa,KACnDK,IAASC,IAAQC,CACnB;AACF,GCjBMC,KAAoB;AAAA,EACxB,KAAK;AAAA,EACL,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,OAAO;AACT,GCkBMC,KAAW,CAAoBC,MAAY;AAC/C,QAAMC,IAAa,6BACb,EAAE,SAAAC,GAAS,SAAAC,GAAS,WAAAC,GAAW,SAAAC,GAAS,OAAAT,MAAUI;AAGxD,MAAIG,GAAS;AACL,UAAAG,IAAe,EAAE,GAAGR,GAAkB,GACtCS,IAAMC,GAAMN,CAAO;AAGzB,IAAAO,GAAgBN,GAAS;AAAA;AAAA,MAEvB,KAAK;AAAA,MACL,MAAM;AAAA,MACN,OAAO;AAAA,MACP,QAAQ;AAAA,IAAA,CACT;AACK,UAAAO,IAAYV,EAAK,SAASX,IA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zC,EAAAzH,GAASmK,IAAgB,KAAK,UAAU,GACxC1C,EAAAzH,GAASoK,IAAiB,KAAK,UAAU,GAG3C7F,MACIkD,EAAAzH,GAASqK,IAAiB,KAAK,UAAU,GAChD5C;AAAA,QACErB,GAAYpG,CAAO;AAAA,QACnB4H;AAAA,QACA,KAAK;AAAA,QACLC;AAAA,MACF,MAEOoC,MAAOK,KAChB7C,EAAOzH,GAASiK,GAAK1F,IAA4B,KAAK,aAAnB,KAAK,MAAwB,IACvD0F,MAAOM,OACT9C,EAAAzH,GAASwK,IAAc,KAAK,UAAU,GAExCjG,KAAakD,EAAOzH,GAASyK,IAAe,KAAK,UAAU,GAE5DC,QACKjD,EAAAzH,GAASsK,IAAiB,KAAK,WAAW,IAIjD/F,KAAewF,KACVtC,EAAAsC,GAAKO,IAAiB,KAAK,UAAU;AAAA,IAC9C,CACD;AAAA,EAEL;AAAA;AAAA,EAGA,UAAU;AACF,UAAA,EAAE,SAAArK,GAAS,SAAAE,EAAA,IAAY,MACvBwK,IAAQ,EAAE,GAAG,MAAM,MAAM,KAAK,KAAK,GACnCvD,IAAW,MACf;AAAA,MACE,MAAMD,GAAuBwD,GAAO,MAAM,MAAM,SAAS;AAAA,MACzD;AAAA,IACF;AAEF,IAAIxK,EAAQ,aAAa8G,EAAO0D,CAAK,KACnC,KAAK,QAAQ,QAAQ,GACrB,KAAK,KAAK,GACVjB,GAAqBzJ,GAAwBmH,CAAQ,KAE5CA,EAAA;AAAA,EACX;AAEJ;"} \ No newline at end of file diff --git a/dist/components/tooltip-Cxy40RjE.mjs b/dist/components/tooltip-Cxy40RjE.mjs new file mode 100644 index 00000000..abfc0eaf --- /dev/null +++ b/dist/components/tooltip-Cxy40RjE.mjs @@ -0,0 +1,325 @@ +import { U as xt, a8 as Dt, F as ct, S as jt, J as q, K as zt, a9 as It, f as C, v as Y, aa as Q, q as U, A as qt, ab as Yt, ac as Qt, ad as Ut, ae as Vt, a3 as j, Q as st, R as et, b as N, Y as I, af as Zt, ag as Gt, ah as Jt, d as ft, B as Kt, t as Ht, ai as Xt, N as te, H as St, a2 as ee, I as oe, y as L, r as ht, Z as se, aj as ie, P as ne, g as ae, w as le, l as Nt, m as dt, L as re, a6 as ce, a7 as he, ak as de, p as gt, j as pe, X as Lt, al as Wt, h as At } from "./base-component-Jx2aafTJ.mjs"; +import { E as mt, r as ut } from "./event-listener-CUwvA4j6.mjs"; +import { E as fe } from "./index-DinhT6Jq.mjs"; +import { d as me } from "./dataBsToggle-B84TS15h.mjs"; +import { s as pt } from "./showClass-C8hdJfjQ.mjs"; +import { a as ue, h as ge, m as bt, o as vt, r as be } from "./popupContainer-CgZsH2ur.mjs"; +import { f as $t } from "./fadeClass-CLIYI_zn.mjs"; +const ot = "popover", ve = "Popover", v = "tooltip", $e = (s) => { + const t = s === v, e = t ? `${s}-inner` : `${s}-body`, o = t ? "" : `

`, n = `
`, a = `
`; + return `
${o + n + a}
`; +}, Bt = { + top: "top", + bottom: "bottom", + left: "start", + right: "end" +}, wt = (s) => { + requestAnimationFrame(() => { + const t = /\b(top|bottom|start|end)+/, { element: e, tooltip: o, container: n, offsetParent: a, options: h, arrow: r } = s; + if (!o) return; + const p = xt(e), { x: $, y: c } = Dt(a); + ct(o, { + top: "", + left: "", + right: "", + bottom: "" + }); + const { offsetWidth: m, offsetHeight: f } = o, { clientWidth: u, clientHeight: E, offsetWidth: O } = jt(e); + let { placement: i } = h; + const { clientWidth: g, offsetWidth: V } = n, d = q( + n, + "position" + ) === "fixed", Z = Math.abs(d ? g - V : u - O), x = p && d ? Z : 0, w = u - (p ? 0 : Z) - 1, it = s._observer.getEntry(e), { + width: l, + height: b, + left: G, + right: Ft, + top: J + } = it?.boundingClientRect || zt(e, !0), { + x: K, + y: A + } = It( + e, + a, + { x: $, y: c } + ); + ct(r, { + top: "", + left: "", + right: "", + bottom: "" + }); + let H = 0, _ = "", T = 0, nt = "", B = "", X = "", at = ""; + const S = r.offsetWidth || 0, y = r.offsetHeight || 0, lt = S / 2; + let k = J - f - y < 0, F = J + f + b + y >= E, M = G - m - S < x, D = G + m + l + S >= w; + const tt = ["left", "right"], rt = ["top", "bottom"]; + k = tt.includes(i) ? J + b / 2 - f / 2 - y < 0 : k, F = tt.includes(i) ? J + f / 2 + b / 2 + y >= E : F, M = rt.includes(i) ? G + l / 2 - m / 2 < x : M, D = rt.includes(i) ? G + m / 2 + l / 2 >= w : D, i = tt.includes(i) && M && D ? "top" : i, i = i === "top" && k ? "bottom" : i, i = i === "bottom" && F ? "top" : i, i = i === "left" && M ? "right" : i, i = i === "right" && D ? "left" : i, o.className.includes(i) || (o.className = o.className.replace( + t, + Bt[i] + )), tt.includes(i) ? (i === "left" ? T = K - m - S : T = K + l + S, k && F ? (H = 0, _ = 0, B = A + b / 2 - y / 2) : k ? (H = A, _ = "", B = b / 2 - S) : F ? (H = A - f + b, _ = "", B = f - b / 2 - S) : (H = A - f / 2 + b / 2, B = f / 2 - y / 2)) : rt.includes(i) && (i === "top" ? H = A - f - y : H = A + b + y, M ? (T = 0, X = K + l / 2 - lt) : D ? (T = "auto", nt = 0, at = l / 2 + w - Ft - lt) : (T = K - m / 2 + l / 2, X = m / 2 - lt)), ct(o, { + top: `${H}px`, + bottom: _ === "" ? "" : `${_}px`, + left: T === "auto" ? T : `${T}px`, + right: nt !== "" ? `${nt}px` : "" + }), C(r) && (B !== "" && (r.style.top = `${B}px`), X !== "" ? r.style.left = `${X}px` : at !== "" && (r.style.right = `${at}px`)); + const Mt = Y( + `updated.bs.${Q(s.name)}` + ); + U(e, Mt); + }); +}, Tt = { + template: $e(v), + title: "", + customClass: "", + trigger: "hover focus", + placement: "top", + sanitizeFn: void 0, + animation: !0, + delay: 200, + container: document.body, + content: "", + dismissible: !1, + btnClose: "" +}, Ot = "data-original-title", W = "Tooltip", P = (s, t, e) => { + if (qt(t) && t.length) { + let o = t.trim(); + Yt(e) && (o = e(o)); + const a = new DOMParser().parseFromString(o, "text/html"); + s.append(...a.body.childNodes); + } else C(t) ? s.append(t) : (Qt(t) || Ut(t) && t.every(Vt)) && s.append(...t); +}, we = (s) => { + const t = s.name === W, { id: e, element: o, options: n } = s, { + title: a, + placement: h, + template: r, + animation: p, + customClass: $, + sanitizeFn: c, + dismissible: m, + content: f, + btnClose: u + } = n, E = t ? v : ot, O = { ...Bt }; + let i = [], g = []; + xt(o) && (O.left = "end", O.right = "start"); + const V = `bs-${E}-${O[h]}`; + let R; + if (C(r)) + R = r; + else { + const l = j("div"); + P(l, r, c), R = l.firstChild; + } + if (!C(R)) return; + s.tooltip = R.cloneNode(!0); + const { tooltip: d } = s; + st(d, "id", e), st(d, "role", v); + const Z = t ? `${v}-inner` : `${ot}-body`, x = t ? null : et(`.${ot}-header`, d), w = et(`.${Z}`, d); + s.arrow = et( + `.${E}-arrow`, + d + ); + const { arrow: it } = s; + if (C(a)) i = [a.cloneNode(!0)]; + else { + const l = j("div"); + P(l, a, c), i = [...l.childNodes]; + } + if (C(f)) g = [f.cloneNode(!0)]; + else { + const l = j("div"); + P(l, f, c), g = [...l.childNodes]; + } + if (m) + if (a) + if (C(u)) + i = [...i, u.cloneNode(!0)]; + else { + const l = j("div"); + P(l, u, c), i = [...i, l.firstChild]; + } + else if (x && x.remove(), C(u)) + g = [...g, u.cloneNode(!0)]; + else { + const l = j("div"); + P(l, u, c), g = [...g, l.firstChild]; + } + t ? a && w && P(w, a, c) : (a && x && P(x, i, c), f && w && P(w, g, c), s.btn = et(".btn-close", d) || void 0), N(d, "position-absolute"), N(it, "position-absolute"), I(d, E) || N(d, E), p && !I(d, $t) && N(d, $t), $ && !I(d, $) && N(d, $), I(d, V) || N(d, V); +}, Te = (s) => { + const t = ["HTML", "BODY"], e = []; + let { parentNode: o } = s; + for (; o && !t.includes(o.nodeName); ) + o = Zt(o), Gt(o) || Jt(o) || e.push(o); + return e.find((n, a) => (q(n, "position") !== "relative" || q(n, "position") === "relative" && n.offsetHeight !== n.scrollHeight) && e.slice(a + 1).every( + (h) => q(h, "position") === "static" + ) ? n : null) || ft(s).body; +}, ye = `[${me}="${v}"],[data-tip="${v}"]`, Rt = "title"; +let yt = (s) => Ht(s, W); +const Pe = (s) => new xe(s), Ce = (s) => { + const { element: t, tooltip: e, container: o } = s; + Lt(t, Wt), be( + e, + o + ); +}, z = (s) => { + const { tooltip: t, container: e } = s; + return t && ge(t, e); +}, Ee = (s, t) => { + const { element: e } = s; + s._toggleEventListeners(), St(e, Ot) && s.name === W && kt(s), t && t(); +}, _t = (s, t) => { + const e = t ? mt : ut, { element: o } = s; + e( + ft(o), + Nt, + s.handleTouch, + At + ); +}, Pt = (s) => { + const { element: t } = s, e = Y( + `shown.bs.${Q(s.name)}` + ); + _t(s, !0), U(t, e), L.clear(t, "in"); +}, Ct = (s) => { + const { element: t } = s, e = Y( + `hidden.bs.${Q(s.name)}` + ); + _t(s), Ce(s), U(t, e), L.clear(t, "out"); +}, Et = (s, t) => { + const e = t ? mt : ut, { element: o, tooltip: n } = s, a = gt(o, `.${bt}`), h = gt(o, `.${vt}`); + t ? [o, n].forEach((r) => s._observer.observe(r)) : s._observer.disconnect(), a && e(a, `hide.bs.${bt}`, s.handleHide), h && e(h, `hide.bs.${vt}`, s.handleHide); +}, kt = (s, t) => { + const e = [Ot, Rt], { element: o } = s; + st( + o, + e[t ? 0 : 1], + t || pe(o, e[0]) || "" + ), Lt(o, e[t ? 1 : 0]); +}; +class xe extends Kt { + static selector = ye; + static init = Pe; + static getInstance = yt; + static styleTip = wt; + /** + * @param target the target element + * @param config the instance options + */ + constructor(t, e) { + super(t, e); + const { element: o } = this, n = this.name === W, a = n ? v : ot, h = n ? W : ve; + yt = (c) => Ht(c, h), this.enabled = !0, this.id = `${a}-${Xt(o, a)}`; + const { options: r } = this; + if (!r.title && n || !n && !r.content) + return; + te(Tt, { titleAttr: "" }), St(o, Rt) && n && typeof r.title == "string" && kt(this, r.title); + const p = Te(o), $ = ["sticky", "fixed", "relative"].some( + (c) => q(p, "position") === c + ) ? p : ee(o); + this.container = p, this.offsetParent = $, we(this), this.tooltip && (this._observer = new fe((c) => { + c.some((m) => m.isVisible) && this.update(); + }), this._toggleEventListeners(!0)); + } + /** + * Returns component name string. + */ + get name() { + return W; + } + /** + * Returns component default options. + */ + get defaults() { + return Tt; + } + handleFocus = () => oe(this.element); + handleShow = () => this.show(); + show() { + const { options: t, tooltip: e, element: o, container: n, id: a } = this, { animation: h } = t, r = L.get(o, "out"); + L.clear(o, "out"), e && !r && !z(this) && L.set( + o, + () => { + const p = Y( + `show.bs.${Q(this.name)}` + ); + U(o, p), p.defaultPrevented || (ue(e, n), st(o, Wt, `#${a}`), this.update(), Et(this, !0), I(e, pt) || N(e, pt), h ? ht(e, () => Pt(this)) : Pt(this)); + }, + 17, + "in" + ); + } + handleHide = () => this.hide(); + hide() { + const { options: t, tooltip: e, element: o } = this, { animation: n, delay: a } = t; + L.clear(o, "in"), e && z(this) && L.set( + o, + () => { + const h = Y( + `hide.bs.${Q(this.name)}` + ); + U(o, h), h.defaultPrevented || (this.update(), se(e, pt), Et(this), n ? ht(e, () => Ct(this)) : Ct(this)); + }, + a + 17, + "out" + ); + } + update = () => { + wt(this); + }; + toggle = () => { + const { tooltip: t } = this; + t && !z(this) ? this.show() : this.hide(); + }; + enable() { + const { enabled: t } = this; + t || (this._toggleEventListeners(!0), this.enabled = !t); + } + disable() { + const { tooltip: t, enabled: e } = this; + e && (t && z(this) && this.hide(), this._toggleEventListeners(), this.enabled = !e); + } + toggleEnabled() { + this.enabled ? this.disable() : this.enable(); + } + /** + * Handles the `touchstart` event listener for `Tooltip` + * + * @this {Tooltip} + * @param {TouchEvent} e the `Event` object + */ + handleTouch = ({ target: t }) => { + const { tooltip: e, element: o } = this; + e && e.contains(t) || t === o || t && o.contains(t) || this.hide(); + }; + /** + * Toggles on/off the `Tooltip` event listeners. + * + * @param add when `true`, event listeners are added + */ + _toggleEventListeners = (t) => { + const e = t ? mt : ut, { element: o, options: n, btn: a } = this, { trigger: h } = n, p = !!(this.name !== W && n.dismissible); + h.includes("manual") || (this.enabled = !!t, h.split(" ").forEach((c) => { + c === ie ? (e(o, ne, this.handleShow), e(o, ae, this.handleShow), p || (e(o, le, this.handleHide), e( + ft(o), + Nt, + this.handleTouch, + At + ))) : c === dt ? e(o, c, p ? this.handleShow : this.toggle) : c === re && (e(o, ce, this.handleShow), p || e(o, he, this.handleHide), de() && e(o, dt, this.handleFocus)), p && a && e(a, dt, this.handleHide); + })); + }; + dispose() { + const { tooltip: t, options: e } = this, o = { ...this, name: this.name }, n = () => setTimeout( + () => Ee(o, () => super.dispose()), + 17 + ); + e.animation && z(o) ? (this.options.delay = 0, this.hide(), ht(t, n)) : n(); + } +} +export { + xe as T, + ot as a, + $e as g, + ve as p, + wt as s, + Tt as t +}; +//# sourceMappingURL=tooltip-Cxy40RjE.mjs.map diff --git a/dist/components/tooltip-Cxy40RjE.mjs.map b/dist/components/tooltip-Cxy40RjE.mjs.map new file mode 100644 index 00000000..1eba1429 --- /dev/null +++ b/dist/components/tooltip-Cxy40RjE.mjs.map @@ -0,0 +1 @@ +{"version":3,"file":"tooltip-Cxy40RjE.mjs","sources":["../../src/strings/popoverString.ts","../../src/strings/popoverComponent.ts","../../src/strings/tooltipString.ts","../../src/util/getTipTemplate.ts","../../src/util/tipClassPositions.ts","../../src/util/styleTip.ts","../../src/util/tooltipDefaults.ts","../../src/strings/dataOriginalTitle.ts","../../src/strings/tooltipComponent.ts","../../src/util/setHtml.ts","../../src/util/createTip.ts","../../src/util/getElementContainer.ts","../../src/components/tooltip.ts"],"sourcesContent":["/** @type {string} */\nconst popoverString = \"popover\";\nexport default popoverString;\n","/** @type {string} */\nconst popoverComponent = \"Popover\";\nexport default popoverComponent;\n","/** @type {string} */\nconst tooltipString = \"tooltip\";\nexport default tooltipString;\n","import tooltipString from \"../strings/tooltipString\";\n\n/**\n * Returns a template for Popover / Tooltip.\n *\n * @param tipType the expected markup type\n * @returns the template markup\n */\nconst getTipTemplate = (tipType: string) => {\n const isTooltip = tipType === tooltipString;\n const bodyClass = isTooltip ? `${tipType}-inner` : `${tipType}-body`;\n const header = !isTooltip ? `

` : \"\";\n const arrow = `
`;\n const body = `
`;\n return `
${\n header + arrow + body\n }
`;\n};\n\nexport default getTipTemplate;\n","const tipClassPositions = {\n top: \"top\",\n bottom: \"bottom\",\n left: \"start\",\n right: \"end\",\n};\n\nexport default tipClassPositions;\n","import {\n createCustomEvent,\n dispatchEvent,\n getBoundingClientRect,\n getDocumentElement,\n getElementStyle,\n getNodeScroll,\n getRectRelativeToOffsetParent,\n isHTMLElement,\n isRTL,\n setElementStyle,\n toLowerCase,\n} from \"@thednp/shorty\";\n\nimport tipClassPositions from \"./tipClassPositions\";\nimport Tooltip from \"../components/tooltip\";\nimport type { TooltipEvent } from \"../interface/tooltip\";\nimport type { PopoverEvent } from \"../interface/popover\";\n\n/**\n * Style popovers and tooltips.\n *\n * @param self the `Popover` / `Tooltip` instance\n */\nconst styleTip = (self: Tooltip) => {\n requestAnimationFrame(() => {\n const tipClasses = /\\b(top|bottom|start|end)+/;\n const { element, tooltip, container, offsetParent, options, arrow } = self;\n\n // istanbul ignore if @preserve\n if (!tooltip) return;\n const RTL = isRTL(element);\n const { x: scrollLeft, y: scrollTop } = getNodeScroll(offsetParent);\n\n // reset tooltip style (top: 0, left: 0 works best)\n setElementStyle(tooltip, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n const { offsetWidth: tipWidth, offsetHeight: tipHeight } = tooltip;\n const { clientWidth: htmlcw, clientHeight: htmlch, offsetWidth: htmlow } =\n getDocumentElement(element);\n let { placement } = options;\n const { clientWidth: parentCWidth, offsetWidth: parentOWidth } = container;\n const parentPosition = getElementStyle(\n container,\n \"position\",\n );\n const fixedParent = parentPosition === \"fixed\";\n const scrollbarWidth = fixedParent\n ? Math.abs(parentCWidth - parentOWidth)\n : Math.abs(htmlcw - htmlow);\n const leftBoundry = RTL && fixedParent\n ? /* istanbul ignore next @preserve */ scrollbarWidth\n : 0;\n const rightBoundry = htmlcw - (!RTL ? scrollbarWidth : 0) - 1;\n\n // reuse observer entry bounding box\n const observerEntry = self._observer.getEntry(element);\n const {\n width: elemWidth,\n height: elemHeight,\n left: elemRectLeft,\n right: elemRectRight,\n top: elemRectTop,\n } = observerEntry?.boundingClientRect ||\n getBoundingClientRect(element, true);\n\n const {\n x: elemOffsetLeft,\n y: elemOffsetTop,\n } = getRectRelativeToOffsetParent(\n element,\n offsetParent,\n { x: scrollLeft, y: scrollTop },\n );\n\n // reset arrow style\n setElementStyle(arrow as HTMLElement, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n let topPosition: number | string = 0;\n let bottomPosition: number | string = \"\";\n let leftPosition: number | string = 0;\n let rightPosition: number | string = \"\";\n let arrowTop: number | string = \"\";\n let arrowLeft: number | string = \"\";\n let arrowRight: number | string = \"\";\n\n const arrowWidth = arrow.offsetWidth || 0;\n const arrowHeight = arrow.offsetHeight || 0;\n const arrowAdjust = arrowWidth / 2;\n\n // check placement\n let topExceed = elemRectTop - tipHeight - arrowHeight < 0;\n let bottomExceed =\n elemRectTop + tipHeight + elemHeight + arrowHeight >= htmlch;\n let leftExceed = elemRectLeft - tipWidth - arrowWidth < leftBoundry;\n let rightExceed =\n elemRectLeft + tipWidth + elemWidth + arrowWidth >= rightBoundry;\n\n const horizontals = [\"left\", \"right\"];\n const verticals = [\"top\", \"bottom\"];\n\n topExceed = horizontals.includes(placement)\n ? elemRectTop + elemHeight / 2 - tipHeight / 2 - arrowHeight < 0\n : topExceed;\n bottomExceed = horizontals.includes(placement)\n ? elemRectTop + tipHeight / 2 + elemHeight / 2 + arrowHeight >= htmlch\n : bottomExceed;\n leftExceed = verticals.includes(placement)\n ? elemRectLeft + elemWidth / 2 - tipWidth / 2 < leftBoundry\n : leftExceed;\n rightExceed = verticals.includes(placement)\n ? elemRectLeft + tipWidth / 2 + elemWidth / 2 >= rightBoundry\n : rightExceed;\n\n // first remove side positions if both left and right limits are exceeded\n // we usually fall back to top|bottom\n placement = horizontals.includes(placement) && leftExceed && rightExceed\n ? \"top\"\n : placement;\n // recompute placement\n placement = placement === \"top\" && topExceed ? \"bottom\" : placement;\n placement = placement === \"bottom\" && bottomExceed ? \"top\" : placement;\n placement = placement === \"left\" && leftExceed ? \"right\" : placement;\n placement = placement === \"right\" && rightExceed\n ? \"left\"\n // istanbul ignore next @preserve\n : placement;\n\n // update tooltip/popover class\n // istanbul ignore else @preserve\n if (!tooltip.className.includes(placement)) {\n tooltip.className = tooltip.className.replace(\n tipClasses,\n tipClassPositions[placement],\n );\n }\n\n // compute tooltip / popover coordinates\n // istanbul ignore else @preserve\n if (horizontals.includes(placement)) {\n // secondary|side positions\n if (placement === \"left\") {\n // LEFT\n leftPosition = elemOffsetLeft - tipWidth - arrowWidth;\n } else {\n // RIGHT\n leftPosition = elemOffsetLeft + elemWidth + arrowWidth;\n }\n\n // adjust top and arrow\n if (topExceed && bottomExceed) {\n topPosition = 0;\n bottomPosition = 0;\n arrowTop = elemOffsetTop + elemHeight / 2 - arrowHeight / 2;\n } else if (topExceed) {\n topPosition = elemOffsetTop;\n bottomPosition = \"\";\n arrowTop = elemHeight / 2 - arrowWidth;\n } else if (bottomExceed) {\n topPosition = elemOffsetTop - tipHeight + elemHeight;\n bottomPosition = \"\";\n arrowTop = tipHeight - elemHeight / 2 - arrowWidth;\n } else {\n topPosition = elemOffsetTop - tipHeight / 2 + elemHeight / 2;\n arrowTop = tipHeight / 2 - arrowHeight / 2;\n }\n } else if (verticals.includes(placement)) {\n if (placement === \"top\") {\n topPosition = elemOffsetTop - tipHeight - arrowHeight;\n } else {\n // BOTTOM\n topPosition = elemOffsetTop + elemHeight + arrowHeight;\n }\n\n // adjust left | right and also the arrow\n if (leftExceed) {\n leftPosition = 0;\n arrowLeft = elemOffsetLeft + elemWidth / 2 - arrowAdjust;\n } else if (rightExceed) {\n leftPosition = \"auto\";\n rightPosition = 0;\n arrowRight = elemWidth / 2 + rightBoundry - elemRectRight - arrowAdjust;\n } else {\n leftPosition = elemOffsetLeft - tipWidth / 2 + elemWidth / 2;\n arrowLeft = tipWidth / 2 - arrowAdjust;\n }\n }\n\n // apply style to tooltip/popover\n setElementStyle(tooltip, {\n top: `${topPosition}px`,\n bottom: bottomPosition === \"\" ? \"\" : `${bottomPosition}px`,\n left: leftPosition === \"auto\" ? leftPosition : `${leftPosition}px`,\n right: rightPosition !== \"\" ? `${rightPosition}px` : \"\",\n });\n\n // update arrow placement\n // istanbul ignore else @preserve\n if (isHTMLElement(arrow)) {\n if (arrowTop !== \"\") {\n arrow.style.top = `${arrowTop}px`;\n }\n if (arrowLeft !== \"\") {\n arrow.style.left = `${arrowLeft}px`;\n } else if (arrowRight !== \"\") {\n arrow.style.right = `${arrowRight}px`;\n }\n }\n const updatedTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `updated.bs.${toLowerCase(self.name)}`,\n );\n dispatchEvent(element, updatedTooltipEvent);\n });\n};\n\nexport default styleTip;\n","import getTipTemplate from \"./getTipTemplate\";\nimport tooltipString from \"../strings/tooltipString\";\nimport { TooltipOptions } from \"../interface/tooltip\";\n\nconst tooltipDefaults: TooltipOptions = {\n template: getTipTemplate(tooltipString),\n title: \"\",\n customClass: \"\",\n trigger: \"hover focus\",\n placement: \"top\",\n sanitizeFn: undefined,\n animation: true,\n delay: 200,\n container: document.body,\n content: \"\",\n dismissible: false,\n btnClose: \"\",\n};\nexport default tooltipDefaults;\n","/**\n * Global namespace for `data-bs-title` attribute.\n */\nconst dataOriginalTitle = \"data-original-title\";\nexport default dataOriginalTitle;\n","/** @type {string} */\nconst tooltipComponent = \"Tooltip\";\nexport default tooltipComponent;\n","import {\n isArray,\n isFunction,\n isHTMLElement,\n isNode,\n isNodeList,\n isString,\n} from \"@thednp/shorty\";\n\n/**\n * Append an existing `Element` to Popover / Tooltip component or HTML\n * markup string to be parsed & sanitized to be used as popover / tooltip content.\n *\n * @param element target\n * @param content the `Element` to append / string\n * @param sanitizeFn a function to sanitize string content\n */\nconst setHtml = (\n element: HTMLElement,\n content: Node[] | Node | string,\n sanitizeFn?: (s: string) => string,\n) => {\n // istanbul ignore else @preserve\n if (isString(content) && content.length) {\n let dirty = content.trim(); // fixing #233\n if (isFunction(sanitizeFn)) dirty = sanitizeFn(dirty);\n\n const domParser = new DOMParser();\n const tempDocument = domParser.parseFromString(dirty, \"text/html\");\n element.append(...[...tempDocument.body.childNodes]);\n } else if (isHTMLElement(content)) {\n element.append(content);\n } else if (\n isNodeList(content) || (isArray(content) && content.every(isNode))\n ) {\n element.append(...[...content]);\n }\n};\nexport default setHtml;\n","import {\n addClass,\n createElement,\n hasClass,\n isHTMLElement,\n isRTL,\n querySelector,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport tooltipString from \"../strings/tooltipString\";\nimport popoverString from \"../strings/popoverString\";\nimport fadeClass from \"../strings/fadeClass\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport setHtml from \"./setHtml\";\nimport Tooltip from \"../components/tooltip\";\nimport Popover from \"../components/popover\";\n\n/**\n * Creates a new tooltip / popover.\n *\n * @param self the `Tooltip` / `Popover` instance\n */\nconst createTip = (self: Tooltip | Popover) => {\n const isTooltip = self.name === tooltipComponent;\n\n const { id, element, options } = self;\n const {\n title,\n placement,\n template,\n animation,\n customClass,\n sanitizeFn,\n dismissible,\n content,\n btnClose,\n } = options;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipPositions = { ...tipClassPositions };\n let titleParts: Node[] = [];\n let contentParts: Node[] = [];\n\n if (isRTL(element)) {\n tipPositions.left = \"end\";\n tipPositions.right = \"start\";\n }\n\n // set initial popover class\n const placementClass = `bs-${tipString}-${tipPositions[placement]}`;\n\n // load template\n let tooltipTemplate: Node | string;\n if (isHTMLElement(template)) {\n tooltipTemplate = template;\n } else {\n const htmlMarkup = createElement(\"div\") as HTMLElement;\n setHtml(htmlMarkup, template, sanitizeFn);\n tooltipTemplate = htmlMarkup.firstChild as HTMLElement;\n }\n\n /* istanbul ignore if @preserve */\n if (!isHTMLElement(tooltipTemplate)) return;\n\n // set popover markup\n self.tooltip = tooltipTemplate.cloneNode(true) as HTMLElement;\n const { tooltip } = self;\n\n // set id and role attributes\n setAttribute(tooltip, \"id\", id);\n setAttribute(tooltip, \"role\", tooltipString);\n\n const bodyClass = isTooltip\n ? `${tooltipString}-inner`\n : `${popoverString}-body`;\n const tooltipHeader = isTooltip\n ? null\n : querySelector(`.${popoverString}-header`, tooltip);\n const tooltipBody = querySelector(`.${bodyClass}`, tooltip);\n\n // set arrow and enable access for styleTip\n self.arrow = querySelector(\n `.${tipString}-arrow`,\n tooltip,\n ) as HTMLElement;\n const { arrow } = self;\n\n if (isHTMLElement(title)) titleParts = [title.cloneNode(true)];\n else {\n const tempTitle = createElement(\"div\") as HTMLElement;\n setHtml(tempTitle, title, sanitizeFn);\n titleParts = [...[...tempTitle.childNodes]];\n }\n\n if (isHTMLElement(content)) contentParts = [content.cloneNode(true)];\n else {\n const tempContent = createElement(\"div\") as HTMLElement;\n setHtml(tempContent, content, sanitizeFn);\n contentParts = [...[...tempContent.childNodes]];\n }\n\n // set dismissible button\n if (dismissible) {\n if (title) {\n if (isHTMLElement(btnClose)) {\n titleParts = [...titleParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n titleParts = [...titleParts, tempBtn.firstChild as Node];\n }\n } else {\n // istanbul ignore else @preserve\n if (tooltipHeader) tooltipHeader.remove();\n if (isHTMLElement(btnClose)) {\n contentParts = [...contentParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n contentParts = [...contentParts, tempBtn.firstChild as Node];\n }\n }\n }\n\n // fill the template with content from options / data attributes\n // also sanitize title && content\n // istanbul ignore else @preserve\n if (!isTooltip) {\n // istanbul ignore else @preserve\n if (title && tooltipHeader) {\n setHtml(tooltipHeader, titleParts, sanitizeFn);\n }\n // istanbul ignore else @preserve\n if (content && tooltipBody) {\n setHtml(tooltipBody, contentParts, sanitizeFn);\n }\n // set btn\n self.btn = querySelector(\".btn-close\", tooltip) ||\n undefined;\n } else if (title && tooltipBody) setHtml(tooltipBody, title, sanitizeFn);\n\n // Bootstrap 5.2.x\n addClass(tooltip, \"position-absolute\");\n addClass(arrow, \"position-absolute\");\n\n // set popover animation and placement\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, tipString)) addClass(tooltip, tipString);\n // istanbul ignore else @preserve\n if (animation && !hasClass(tooltip, fadeClass)) {\n addClass(tooltip, fadeClass);\n }\n // istanbul ignore else @preserve\n if (customClass && !hasClass(tooltip, customClass)) {\n addClass(tooltip, customClass);\n }\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, placementClass)) addClass(tooltip, placementClass);\n};\n\nexport default createTip;\n","import {\n getDocument,\n getElementStyle,\n getParentNode,\n isShadowRoot,\n isTableElement,\n} from \"@thednp/shorty\";\n\n/**\n * Returns an `HTMLElement` to be used as default value for *options.container*\n * for `Tooltip` / `Popover` components.\n *\n * @see https://github.com/floating-ui/floating-ui\n *\n * @param element the target\n * @returns the query result\n */\nconst getElementContainer = (element: Element) => {\n const majorBlockTags = [\"HTML\", \"BODY\"];\n const containers: HTMLElement[] = [];\n let { parentNode } = element;\n\n while (parentNode && !majorBlockTags.includes(parentNode.nodeName)) {\n parentNode = getParentNode(parentNode) as HTMLElement;\n // istanbul ignore else @preserve\n if (!(isShadowRoot(parentNode) || isTableElement(parentNode))) {\n containers.push(parentNode as HTMLElement);\n }\n }\n\n return (\n containers.find((c, i) => {\n if (\n ((getElementStyle(c, \"position\") !== \"relative\" ||\n getElementStyle(c, \"position\") === \"relative\" &&\n c.offsetHeight !== c.scrollHeight) &&\n containers.slice(i + 1).every((r) =>\n getElementStyle(r, \"position\") === \"static\"\n ))\n ) {\n return c;\n }\n return null;\n }) ||\n /* istanbul ignore next: optional guard */\n getDocument(element).body\n );\n};\n\nexport default getElementContainer;\n","/* Native JavaScript for Bootstrap 5 | Tooltip\n---------------------------------------------- */\nimport {\n addClass,\n ariaDescribedBy,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focus,\n focusEvent,\n focusinEvent,\n focusoutEvent,\n getAttribute,\n getDocument,\n getElementStyle,\n getInstance,\n getUID,\n getWindow,\n hasAttribute,\n hasClass,\n isApple,\n mouseclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseleaveEvent,\n ObjectAssign,\n passiveHandler,\n removeAttribute,\n removeClass,\n setAttribute,\n Timer,\n toLowerCase,\n TouchEvent,\n touchstartEvent,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport dataOriginalTitle from \"../strings/dataOriginalTitle\";\nimport showClass from \"../strings/showClass\";\nimport tooltipString from \"../strings/tooltipString\";\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\nimport modalString from \"../strings/modalString\";\nimport offcanvasString from \"../strings/offcanvasString\";\n\nimport styleTip from \"../util/styleTip\";\nimport createTip from \"../util/createTip\";\nimport { appendPopup, hasPopup, removePopup } from \"../util/popupContainer\";\nimport getElementContainer from \"../util/getElementContainer\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport BaseComponent from \"./base-component\";\nimport type { TooltipEvent, TooltipOptions } from \"../interface/tooltip\";\nimport type { PopoverEvent, PopoverOptions } from \"../interface/popover\";\n\n// TOOLTIP PRIVATE GC\n// ==================\nconst tooltipSelector =\n `[${dataBsToggle}=\"${tooltipString}\"],[data-tip=\"${tooltipString}\"]`;\nconst titleAttr = \"title\";\n\n/**\n * Static method which returns an existing `Tooltip` instance associated\n * to a target `Element`.\n */\nlet getTooltipInstance = (element: Element) =>\n getInstance(element, tooltipComponent);\n\n/**\n * A `Tooltip` initialization callback.\n */\nconst tooltipInitCallback = (element: Element) => new Tooltip(element);\n\n// TOOLTIP PRIVATE METHODS\n// =======================\n/**\n * Removes the tooltip from the DOM.\n *\n * @param self the `Tooltip` instance\n */\nconst removeTooltip = (self: Tooltip) => {\n const { element, tooltip, container } = self;\n removeAttribute(element, ariaDescribedBy);\n removePopup(\n tooltip,\n container,\n );\n};\n\n/**\n * Check if container contains the tooltip.\n *\n * @param self Tooltip\n */\nconst hasTip = (self: Tooltip): boolean | undefined => {\n const { tooltip, container } = self;\n\n return tooltip &&\n hasPopup(tooltip, container);\n};\n\n/**\n * Executes after the instance has been disposed.\n *\n * @param self the `Tooltip` instance\n * @param callback the parent dispose callback\n */\nconst disposeTooltipComplete = (self: Tooltip, callback?: () => void) => {\n const { element } = self;\n self._toggleEventListeners();\n\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, dataOriginalTitle) && self.name === tooltipComponent\n ) {\n toggleTooltipTitle(self);\n }\n // istanbul ignore else @preserve\n if (callback) callback();\n};\n\n/**\n * Toggles on/off the special `Tooltip` event listeners.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipAction = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n\n action(\n getDocument(element),\n touchstartEvent,\n self.handleTouch,\n passiveHandler,\n );\n};\n\n/**\n * Executes after the tooltip was shown to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipShownAction = (self: Tooltip) => {\n const { element } = self;\n const shownTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `shown.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self, true);\n dispatchEvent(element, shownTooltipEvent);\n Timer.clear(element, \"in\");\n};\n\n/**\n * Executes after the tooltip was hidden to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipHiddenAction = (self: Tooltip) => {\n const { element } = self;\n const hiddenTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hidden.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self);\n removeTooltip(self);\n dispatchEvent(element, hiddenTooltipEvent);\n\n Timer.clear(element, \"out\");\n};\n\n/**\n * Toggles on/off the `Tooltip` event listeners that hide/update the tooltip.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipOpenHandlers = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, tooltip } = self;\n const parentModal = closest(element, `.${modalString}`);\n const parentOffcanvas = closest(element, `.${offcanvasString}`);\n\n if (add) {\n [element, tooltip]\n .forEach((target) => self._observer.observe(target));\n } else self._observer.disconnect();\n\n // dismiss tooltips inside modal / offcanvas\n if (parentModal) {\n action(parentModal, `hide.bs.${modalString}`, self.handleHide);\n }\n if (parentOffcanvas) {\n action(parentOffcanvas, `hide.bs.${offcanvasString}`, self.handleHide);\n }\n};\n\n/**\n * Toggles the `title` and `data-original-title` attributes.\n *\n * @param self the `Tooltip` instance\n * @param content when `true`, event listeners are added\n */\nconst toggleTooltipTitle = (self: Tooltip, content?: string) => {\n // [0 - add, 1 - remove] | [0 - remove, 1 - add]\n const titleAtt = [dataOriginalTitle, titleAttr];\n const { element } = self;\n\n setAttribute(\n element,\n titleAtt[content ? 0 : 1],\n content ||\n getAttribute(element, titleAtt[0]) ||\n // istanbul ignore next @preserve\n \"\",\n );\n removeAttribute(element, titleAtt[content ? 1 : 0]);\n};\n\n// TOOLTIP DEFINITION\n// ==================\n/** Creates a new `Tooltip` instance. */\nexport default class Tooltip extends BaseComponent {\n static selector = tooltipSelector;\n static init = tooltipInitCallback;\n static getInstance = getTooltipInstance;\n static styleTip = styleTip;\n declare element: Element & HTMLOrSVGElement;\n declare options: TooltipOptions;\n declare btn?: HTMLElement;\n declare tooltip: HTMLElement;\n declare container: HTMLElement;\n declare offsetParent: Element | Window;\n declare arrow: HTMLElement;\n declare enabled: boolean;\n declare id: string;\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n\n const { element } = this;\n const isTooltip = this.name === tooltipComponent;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipComponent = isTooltip ? tooltipComponent : popoverComponent;\n\n // istanbul ignore next @preserve: this is to set Popover too\n getTooltipInstance = (elem: Element) =>\n getInstance(elem, tipComponent);\n\n // additional properties\n this.enabled = true;\n /** Set unique ID for `aria-describedby`. */\n this.id = `${tipString}-${getUID(element, tipString)}`;\n\n // instance options\n const { options } = this;\n\n // invalidate\n // istanbul ignore else @preserve\n if (((!options.title && isTooltip) || (!isTooltip && !options.content))) {\n return;\n }\n\n // reset default options\n ObjectAssign(tooltipDefaults, { titleAttr: \"\" });\n\n // set title attributes and add event listeners\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, titleAttr) && isTooltip &&\n typeof options.title === \"string\"\n ) {\n toggleTooltipTitle(this, options.title);\n }\n\n // set containers\n const container = getElementContainer(element);\n const offsetParent = [\"sticky\", \"fixed\", \"relative\"].some(\n (position) =>\n getElementStyle(container, \"position\") ===\n position,\n )\n ? container\n : getWindow(element);\n\n this.container = container;\n this.offsetParent = offsetParent;\n\n // create tooltip here\n createTip(this);\n\n /* istanbul ignore if @preserve */\n if (!this.tooltip) return;\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n /* istanbul ignore else */\n if (!entries.some((entry) => entry.isVisible)) return;\n this.update();\n });\n\n // attach events\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tooltipComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return tooltipDefaults;\n }\n\n // TOOLTIP PUBLIC METHODS\n // ======================\n /** Handles the focus event on iOS. */\n // istanbul ignore next @preserve - impossible to test without Apple device\n handleFocus = () => focus(this.element as HTMLElement);\n /** Shows the tooltip. */\n handleShow = () => this.show();\n show() {\n const { options, tooltip, element, container, id } = this;\n const { animation } = options;\n const outTimer = Timer.get(element, \"out\");\n\n Timer.clear(element, \"out\");\n\n if (tooltip && !outTimer && !hasTip(this)) {\n Timer.set(\n element,\n () => {\n const showTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `show.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, showTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!showTooltipEvent.defaultPrevented) {\n // append to container\n appendPopup(tooltip, container);\n\n setAttribute(element, ariaDescribedBy, `#${id}`);\n\n this.update();\n toggleTooltipOpenHandlers(this, true);\n\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, showClass)) addClass(tooltip, showClass);\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipShownAction(this));\n } else tooltipShownAction(this);\n }\n },\n 17,\n \"in\",\n );\n }\n }\n\n /** Hides the tooltip. */\n handleHide = () => this.hide();\n hide() {\n const { options, tooltip, element } = this;\n const { animation, delay } = options;\n\n Timer.clear(element, \"in\");\n\n // istanbul ignore else @preserve\n if (tooltip && hasTip(this)) {\n Timer.set(\n element,\n () => {\n const hideTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hide.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, hideTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!hideTooltipEvent.defaultPrevented) {\n this.update();\n removeClass(tooltip, showClass);\n toggleTooltipOpenHandlers(this);\n\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipHiddenAction(this));\n } else tooltipHiddenAction(this);\n }\n },\n delay + 17,\n \"out\",\n );\n }\n }\n\n /** Updates the tooltip position. */\n update = () => {\n styleTip(this);\n };\n\n /** Toggles the tooltip visibility. */\n toggle = () => {\n const { tooltip } = this;\n\n if (tooltip && !hasTip(this)) this.show();\n else this.hide();\n };\n\n /** Enables the tooltip. */\n enable() {\n const { enabled } = this;\n // istanbul ignore else @preserve\n if (!enabled) {\n this._toggleEventListeners(true);\n this.enabled = !enabled;\n }\n }\n\n /** Disables the tooltip. */\n disable() {\n const { tooltip, enabled } = this;\n // istanbul ignore else @preserve\n if (enabled) {\n if (tooltip && hasTip(this)) this.hide();\n this._toggleEventListeners();\n this.enabled = !enabled;\n }\n }\n\n /** Toggles the `disabled` property. */\n toggleEnabled() {\n if (!this.enabled) this.enable();\n else this.disable();\n }\n\n /**\n * Handles the `touchstart` event listener for `Tooltip`\n *\n * @this {Tooltip}\n * @param {TouchEvent} e the `Event` object\n */\n handleTouch = ({ target }: TouchEvent) => {\n const { tooltip, element } = this;\n\n // istanbul ignore if @preserve\n if (\n (tooltip && tooltip.contains(target)) ||\n target === element ||\n (target && element.contains(target))\n ) {\n // smile for ESLint\n } else {\n this.hide();\n }\n };\n\n /**\n * Toggles on/off the `Tooltip` event listeners.\n *\n * @param add when `true`, event listeners are added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n // btn is only for dismissible popover\n const { element, options, btn } = this;\n const { trigger } = options;\n const isPopover = this.name !== tooltipComponent;\n const dismissible = isPopover && (options as PopoverOptions).dismissible\n ? true\n : false;\n\n // istanbul ignore else @preserve\n if (!trigger.includes(\"manual\")) {\n this.enabled = !!add;\n\n const triggerOptions = trigger.split(\" \");\n\n triggerOptions.forEach((tr) => {\n // istanbul ignore else @preserve\n if (tr === mousehoverEvent) {\n action(element, mousedownEvent, this.handleShow);\n action(element, mouseenterEvent, this.handleShow);\n\n // istanbul ignore else @preserve\n if (!dismissible) {\n action(element, mouseleaveEvent, this.handleHide);\n action(\n getDocument(element),\n touchstartEvent,\n this.handleTouch,\n passiveHandler,\n );\n }\n } else if (tr === mouseclickEvent) {\n action(element, tr, !dismissible ? this.toggle : this.handleShow);\n } else if (tr === focusEvent) {\n action(element, focusinEvent, this.handleShow);\n // istanbul ignore else @preserve\n if (!dismissible) action(element, focusoutEvent, this.handleHide);\n // istanbul ignore else @preserve\n if (isApple()) {\n action(element, mouseclickEvent, this.handleFocus);\n }\n }\n // istanbul ignore else @preserve\n if (dismissible && btn) {\n action(btn, mouseclickEvent, this.handleHide);\n }\n });\n }\n };\n\n /** Removes the `Tooltip` from the target element. */\n dispose() {\n const { tooltip, options } = this;\n const clone = { ...this, name: this.name };\n const callback = () =>\n setTimeout(\n () => disposeTooltipComplete(clone, () => super.dispose()),\n 17,\n );\n\n if (options.animation && hasTip(clone)) {\n this.options.delay = 0; // reset delay\n this.hide();\n emulateTransitionEnd(tooltip, callback);\n } else {\n callback();\n }\n }\n}\n"],"names":["popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","arrow","body","tipClassPositions","styleTip","self","tipClasses","element","tooltip","container","offsetParent","options","RTL","isRTL","scrollLeft","scrollTop","getNodeScroll","setElementStyle","tipWidth","tipHeight","htmlcw","htmlch","htmlow","getDocumentElement","placement","parentCWidth","parentOWidth","fixedParent","getElementStyle","scrollbarWidth","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","getBoundingClientRect","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","topExceed","bottomExceed","leftExceed","rightExceed","horizontals","verticals","isHTMLElement","updatedTooltipEvent","createCustomEvent","toLowerCase","dispatchEvent","tooltipDefaults","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","isString","dirty","isFunction","tempDocument","isNodeList","isArray","isNode","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","createElement","setAttribute","tooltipHeader","querySelector","tooltipBody","tempTitle","tempContent","tempBtn","addClass","hasClass","fadeClass","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","c","i","r","getDocument","tooltipSelector","dataBsToggle","titleAttr","getTooltipInstance","getInstance","tooltipInitCallback","Tooltip","removeTooltip","removeAttribute","ariaDescribedBy","removePopup","hasTip","hasPopup","disposeTooltipComplete","callback","hasAttribute","toggleTooltipTitle","toggleTooltipAction","add","action","addListener","removeListener","touchstartEvent","passiveHandler","tooltipShownAction","shownTooltipEvent","Timer","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","closest","modalString","parentOffcanvas","offcanvasString","target","titleAtt","getAttribute","BaseComponent","config","tipComponent","elem","getUID","ObjectAssign","position","getWindow","PositionObserver","entries","entry","focus","outTimer","showTooltipEvent","appendPopup","showClass","emulateTransitionEnd","delay","hideTooltipEvent","removeClass","enabled","btn","trigger","tr","mousehoverEvent","mousedownEvent","mouseenterEvent","mouseleaveEvent","mouseclickEvent","focusEvent","focusinEvent","focusoutEvent","isApple","clone"],"mappings":";;;;;;;AACA,MAAMA,KAAgB,WCAhBC,KAAmB,WCAnBC,IAAgB,WCOhBC,KAAiB,CAACC,MAAoB;AAC1C,QAAMC,IAAYD,MAAYF,GACxBI,IAAYD,IAAY,GAAGD,CAAO,WAAW,GAAGA,CAAO,SACvDG,IAAUF,IAAoD,KAAxC,cAAcD,CAAO,kBAC3CI,IAAQ,eAAeJ,CAAO,kBAC9BK,IAAO,eAAeH,CAAS;AACrC,SAAO,eAAeF,CAAO,WAAWF,CAAa,KACnDK,IAASC,IAAQC,CACnB;AACF,GCjBMC,KAAoB;AAAA,EACxB,KAAK;AAAA,EACL,QAAQ;AAAA,EACR,MAAM;AAAA,EACN,OAAO;AACT,GCmBMC,KAAW,CAACC,MAAkB;AAClC,wBAAsB,MAAM;AAC1B,UAAMC,IAAa,6BACb,EAAE,SAAAC,GAAS,SAAAC,GAAS,WAAAC,GAAW,cAAAC,GAAc,SAAAC,GAAS,OAAAV,MAAUI;AAGtE,QAAI,CAACG,EAAS;AACR,UAAAI,IAAMC,GAAMN,CAAO,GACnB,EAAE,GAAGO,GAAY,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,EAAA;AAAA,EACX;AAEJ;"} \ No newline at end of file diff --git a/dist/components/tooltip-DKh6RNNg.js b/dist/components/tooltip-DKh6RNNg.js new file mode 100644 index 00000000..138ab6c6 --- /dev/null +++ b/dist/components/tooltip-DKh6RNNg.js @@ -0,0 +1,2 @@ +"use strict";const t=require("./base-component-DaZCwW-u.js"),W=require("./event-listener-BQdA_KAC.js"),Tt=require("./index-DlQfhTUb.js"),wt=require("./dataBsToggle-Dj-Ng54N.js"),et=require("./showClass-D_Ms1FgG.js"),S=require("./popupContainer-CSoNJ-n6.js"),st=require("./fadeClass-Co6nOzNJ.js"),F="popover",ct="Popover",T="tooltip",ht=s=>{const e=s===T,o=e?`${s}-inner`:`${s}-body`,i=e?"":`

`,l=`
`,r=`
`;return`
${i+l+r}
`},dt={top:"top",bottom:"bottom",left:"start",right:"end"},ot=s=>{requestAnimationFrame(()=>{const e=/\b(top|bottom|start|end)+/,{element:o,tooltip:i,container:l,offsetParent:r,options:d,arrow:c}=s;if(!i)return;const f=t.Uo(o),{x:w,y:h}=t.ko(r);t.ho(i,{top:"",left:"",right:"",bottom:""});const{offsetWidth:u,offsetHeight:m}=i,{clientWidth:g,clientHeight:E,offsetWidth:A}=t.S(o);let{placement:n}=d;const{clientWidth:b,offsetWidth:z}=l,p=t.g(l,"position")==="fixed",Q=Math.abs(p?b-z:g-A),q=f&&p?Q:0,$=g-(f?0:Q)-1,Z=s._observer.getEntry(o),{width:a,height:v,left:j,right:bt,top:I}=Z?.boundingClientRect||t.w(o,!0),{x:G,y:R}=t.Co(o,r,{x:w,y:h});t.ho(c,{top:"",left:"",right:"",bottom:""});let x=0,O="",y=0,J="",L="",U="",K="";const H=c.offsetWidth||0,C=c.offsetHeight||0,X=H/2;let _=I-m-C<0,k=I+m+v+C>=E,D=j-u-H=$;const V=["left","right"],tt=["top","bottom"];_=V.includes(n)?I+v/2-m/2-C<0:_,k=V.includes(n)?I+m/2+v/2+C>=E:k,D=tt.includes(n)?j+a/2-u/2=$:M,n=V.includes(n)&&D&&M?"top":n,n=n==="top"&&_?"bottom":n,n=n==="bottom"&&k?"top":n,n=n==="left"&&D?"right":n,n=n==="right"&&M?"left":n,i.className.includes(n)||(i.className=i.className.replace(e,dt[n])),V.includes(n)?(n==="left"?y=G-u-H:y=G+a+H,_&&k?(x=0,O=0,L=R+v/2-C/2):_?(x=R,O="",L=v/2-H):k?(x=R-m+v,O="",L=m-v/2-H):(x=R-m/2+v/2,L=m/2-C/2)):tt.includes(n)&&(n==="top"?x=R-m-C:x=R+v+C,D?(y=0,U=G+a/2-X):M?(y="auto",J=0,K=a/2+$-bt-X):(y=G-u/2+a/2,U=u/2-X)),t.ho(i,{top:`${x}px`,bottom:O===""?"":`${O}px`,left:y==="auto"?y:`${y}px`,right:J!==""?`${J}px`:""}),t.m(c)&&(L!==""&&(c.style.top=`${L}px`),U!==""?c.style.left=`${U}px`:K!==""&&(c.style.right=`${K}px`));const vt=t.vo(`updated.bs.${t.ue(s.name)}`);t.q(o,vt)})},it={template:ht(T),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},pt="data-original-title",N="Tooltip",P=(s,e,o)=>{if(t.k(e)&&e.length){let i=e.trim();t.zo(o)&&(i=o(i));const r=new DOMParser().parseFromString(i,"text/html");s.append(...r.body.childNodes)}else t.m(e)?s.append(e):(t.Vo(e)||t.Se(e)&&e.every(t.l))&&s.append(...e)},$t=s=>{const e=s.name===N,{id:o,element:i,options:l}=s,{title:r,placement:d,template:c,animation:f,customClass:w,sanitizeFn:h,dismissible:u,content:m,btnClose:g}=l,E=e?T:F,A={...dt};let n=[],b=[];t.Uo(i)&&(A.left="end",A.right="start");const z=`bs-${E}-${A[d]}`;let B;if(t.m(c))B=c;else{const a=t.oe("div");P(a,c,h),B=a.firstChild}if(!t.m(B))return;s.tooltip=B.cloneNode(!0);const{tooltip:p}=s;t.Qn(p,"id",o),t.Qn(p,"role",T);const Q=e?`${T}-inner`:`${F}-body`,q=e?null:t.Ro(`.${F}-header`,p),$=t.Ro(`.${Q}`,p);s.arrow=t.Ro(`.${E}-arrow`,p);const{arrow:Z}=s;if(t.m(r))n=[r.cloneNode(!0)];else{const a=t.oe("div");P(a,r,h),n=[...a.childNodes]}if(t.m(m))b=[m.cloneNode(!0)];else{const a=t.oe("div");P(a,m,h),b=[...a.childNodes]}if(u)if(r)if(t.m(g))n=[...n,g.cloneNode(!0)];else{const a=t.oe("div");P(a,g,h),n=[...n,a.firstChild]}else if(q&&q.remove(),t.m(g))b=[...b,g.cloneNode(!0)];else{const a=t.oe("div");P(a,g,h),b=[...b,a.firstChild]}e?r&&$&&P($,r,h):(r&&q&&P(q,n,h),m&&$&&P($,b,h),s.btn=t.Ro(".btn-close",p)||void 0),t.qn(p,"position-absolute"),t.qn(Z,"position-absolute"),t.Yn(p,E)||t.qn(p,E),f&&!t.Yn(p,st.fadeClass)&&t.qn(p,st.fadeClass),w&&!t.Yn(p,w)&&t.qn(p,w),t.Yn(p,z)||t.qn(p,z)},yt=s=>{const e=["HTML","BODY"],o=[];let{parentNode:i}=s;for(;i&&!e.includes(i.nodeName);)i=t.A(i),t.me(i)||t.be(i)||o.push(i);return o.find((l,r)=>(t.g(l,"position")!=="relative"||t.g(l,"position")==="relative"&&l.offsetHeight!==l.scrollHeight)&&o.slice(r+1).every(d=>t.g(d,"position")==="static")?l:null)||t.d(s).body},Ct=`[${wt.dataBsToggle}="${T}"],[data-tip="${T}"]`,ft="title";let nt=s=>t.to(s,N);const Pt=s=>new gt(s),Et=s=>{const{element:e,tooltip:o,container:i}=s;t.Gn(e,t.De),S.removePopup(o,i)},Y=s=>{const{tooltip:e,container:o}=s;return e&&S.hasPopup(e,o)},qt=(s,e)=>{const{element:o}=s;s._toggleEventListeners(),t.ne(o,pt)&&s.name===N&&ut(s),e&&e()},mt=(s,e)=>{const o=e?W.E:W.r,{element:i}=s;o(t.d(i),t.Rt,s.handleTouch,t.bo)},lt=s=>{const{element:e}=s,o=t.vo(`shown.bs.${t.ue(s.name)}`);mt(s,!0),t.q(e,o),t.yo.clear(e,"in")},rt=s=>{const{element:e}=s,o=t.vo(`hidden.bs.${t.ue(s.name)}`);mt(s),Et(s),t.q(e,o),t.yo.clear(e,"out")},at=(s,e)=>{const o=e?W.E:W.r,{element:i,tooltip:l}=s,r=t.ke(i,`.${S.modalString}`),d=t.ke(i,`.${S.offcanvasString}`);e?[i,l].forEach(c=>s._observer.observe(c)):s._observer.disconnect(),r&&o(r,`hide.bs.${S.modalString}`,s.handleHide),d&&o(d,`hide.bs.${S.offcanvasString}`,s.handleHide)},ut=(s,e)=>{const o=[pt,ft],{element:i}=s;t.Qn(i,o[e?0:1],e||t.j(i,o[0])||""),t.Gn(i,o[e?1:0])};class gt extends t.BaseComponent{static selector=Ct;static init=Pt;static getInstance=nt;static styleTip=ot;constructor(e,o){super(e,o);const{element:i}=this,l=this.name===N,r=l?T:F,d=l?N:ct;nt=h=>t.to(h,d),this.enabled=!0,this.id=`${r}-${t.Ae(i,r)}`;const{options:c}=this;if(!c.title&&l||!l&&!c.content)return;t.N(it,{titleAttr:""}),t.ne(i,ft)&&l&&typeof c.title=="string"&&ut(this,c.title);const f=yt(i),w=["sticky","fixed","relative"].some(h=>t.g(f,"position")===h)?f:t.ve(i);this.container=f,this.offsetParent=w,$t(this),this.tooltip&&(this._observer=new Tt.E(h=>{h.some(u=>u.isVisible)&&this.update()}),this._toggleEventListeners(!0))}get name(){return N}get defaults(){return it}handleFocus=()=>t.io(this.element);handleShow=()=>this.show();show(){const{options:e,tooltip:o,element:i,container:l,id:r}=this,{animation:d}=e,c=t.yo.get(i,"out");t.yo.clear(i,"out"),o&&!c&&!Y(this)&&t.yo.set(i,()=>{const f=t.vo(`show.bs.${t.ue(this.name)}`);t.q(i,f),f.defaultPrevented||(S.appendPopup(o,l),t.Qn(i,t.De,`#${r}`),this.update(),at(this,!0),t.Yn(o,et.showClass)||t.qn(o,et.showClass),d?t.ro(o,()=>lt(this)):lt(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:e,tooltip:o,element:i}=this,{animation:l,delay:r}=e;t.yo.clear(i,"in"),o&&Y(this)&&t.yo.set(i,()=>{const d=t.vo(`hide.bs.${t.ue(this.name)}`);t.q(i,d),d.defaultPrevented||(this.update(),t.Zn(o,et.showClass),at(this),l?t.ro(o,()=>rt(this)):rt(this))},r+17,"out")}update=()=>{ot(this)};toggle=()=>{const{tooltip:e}=this;e&&!Y(this)?this.show():this.hide()};enable(){const{enabled:e}=this;e||(this._toggleEventListeners(!0),this.enabled=!e)}disable(){const{tooltip:e,enabled:o}=this;o&&(e&&Y(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!o)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:e})=>{const{tooltip:o,element:i}=this;o&&o.contains(e)||e===i||e&&i.contains(e)||this.hide()};_toggleEventListeners=e=>{const o=e?W.E:W.r,{element:i,options:l,btn:r}=this,{trigger:d}=l,f=!!(this.name!==N&&l.dismissible);d.includes("manual")||(this.enabled=!!e,d.split(" ").forEach(h=>{h===t.ht?(o(i,t.bt,this.handleShow),o(i,t.yt,this.handleShow),f||(o(i,t.wt,this.handleHide),o(t.d(i),t.Rt,this.handleTouch,t.bo))):h===t.mt?o(i,h,f?this.handleShow:this.toggle):h===t.rt&&(o(i,t.ct,this.handleShow),f||o(i,t.at,this.handleHide),t.zn()&&o(i,t.mt,this.handleFocus)),f&&r&&o(r,t.mt,this.handleHide)}))};dispose(){const{tooltip:e,options:o}=this,i={...this,name:this.name},l=()=>setTimeout(()=>qt(i,()=>super.dispose()),17);o.animation&&Y(i)?(this.options.delay=0,this.hide(),t.ro(e,l)):l()}}exports.Tooltip=gt;exports.getTipTemplate=ht;exports.popoverComponent=ct;exports.popoverString=F;exports.styleTip=ot;exports.tooltipDefaults=it; +//# sourceMappingURL=tooltip-DKh6RNNg.js.map diff --git a/dist/components/tooltip-DKh6RNNg.js.map b/dist/components/tooltip-DKh6RNNg.js.map new file mode 100644 index 00000000..c9cf8131 --- /dev/null +++ b/dist/components/tooltip-DKh6RNNg.js.map @@ -0,0 +1 @@ +{"version":3,"file":"tooltip-DKh6RNNg.js","sources":["../../src/strings/popoverString.ts","../../src/strings/popoverComponent.ts","../../src/strings/tooltipString.ts","../../src/util/getTipTemplate.ts","../../src/util/tipClassPositions.ts","../../src/util/styleTip.ts","../../src/util/tooltipDefaults.ts","../../src/strings/dataOriginalTitle.ts","../../src/strings/tooltipComponent.ts","../../src/util/setHtml.ts","../../src/util/createTip.ts","../../src/util/getElementContainer.ts","../../src/components/tooltip.ts"],"sourcesContent":["/** @type {string} */\nconst popoverString = \"popover\";\nexport default popoverString;\n","/** @type {string} */\nconst popoverComponent = \"Popover\";\nexport default popoverComponent;\n","/** @type {string} */\nconst tooltipString = \"tooltip\";\nexport default tooltipString;\n","import tooltipString from \"../strings/tooltipString\";\n\n/**\n * Returns a template for Popover / Tooltip.\n *\n * @param tipType the expected markup type\n * @returns the template markup\n */\nconst getTipTemplate = (tipType: string) => {\n const isTooltip = tipType === tooltipString;\n const bodyClass = isTooltip ? `${tipType}-inner` : `${tipType}-body`;\n const header = !isTooltip ? `

` : \"\";\n const arrow = `
`;\n const body = `
`;\n return `
${\n header + arrow + body\n }
`;\n};\n\nexport default getTipTemplate;\n","const tipClassPositions = {\n top: \"top\",\n bottom: \"bottom\",\n left: \"start\",\n right: \"end\",\n};\n\nexport default tipClassPositions;\n","import {\n createCustomEvent,\n dispatchEvent,\n getBoundingClientRect,\n getDocumentElement,\n getElementStyle,\n getNodeScroll,\n getRectRelativeToOffsetParent,\n isHTMLElement,\n isRTL,\n setElementStyle,\n toLowerCase,\n} from \"@thednp/shorty\";\n\nimport tipClassPositions from \"./tipClassPositions\";\nimport Tooltip from \"../components/tooltip\";\nimport type { TooltipEvent } from \"../interface/tooltip\";\nimport type { PopoverEvent } from \"../interface/popover\";\n\n/**\n * Style popovers and tooltips.\n *\n * @param self the `Popover` / `Tooltip` instance\n */\nconst styleTip = (self: Tooltip) => {\n requestAnimationFrame(() => {\n const tipClasses = /\\b(top|bottom|start|end)+/;\n const { element, tooltip, container, offsetParent, options, arrow } = self;\n\n // istanbul ignore if @preserve\n if (!tooltip) return;\n const RTL = isRTL(element);\n const { x: scrollLeft, y: scrollTop } = getNodeScroll(offsetParent);\n\n // reset tooltip style (top: 0, left: 0 works best)\n setElementStyle(tooltip, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n const { offsetWidth: tipWidth, offsetHeight: tipHeight } = tooltip;\n const { clientWidth: htmlcw, clientHeight: htmlch, offsetWidth: htmlow } =\n getDocumentElement(element);\n let { placement } = options;\n const { clientWidth: parentCWidth, offsetWidth: parentOWidth } = container;\n const parentPosition = getElementStyle(\n container,\n \"position\",\n );\n const fixedParent = parentPosition === \"fixed\";\n const scrollbarWidth = fixedParent\n ? Math.abs(parentCWidth - parentOWidth)\n : Math.abs(htmlcw - htmlow);\n const leftBoundry = RTL && fixedParent\n ? /* istanbul ignore next @preserve */ scrollbarWidth\n : 0;\n const rightBoundry = htmlcw - (!RTL ? scrollbarWidth : 0) - 1;\n\n // reuse observer entry bounding box\n const observerEntry = self._observer.getEntry(element);\n const {\n width: elemWidth,\n height: elemHeight,\n left: elemRectLeft,\n right: elemRectRight,\n top: elemRectTop,\n } = observerEntry?.boundingClientRect ||\n getBoundingClientRect(element, true);\n\n const {\n x: elemOffsetLeft,\n y: elemOffsetTop,\n } = getRectRelativeToOffsetParent(\n element,\n offsetParent,\n { x: scrollLeft, y: scrollTop },\n );\n\n // reset arrow style\n setElementStyle(arrow as HTMLElement, {\n top: \"\",\n left: \"\",\n right: \"\",\n bottom: \"\",\n });\n let topPosition: number | string = 0;\n let bottomPosition: number | string = \"\";\n let leftPosition: number | string = 0;\n let rightPosition: number | string = \"\";\n let arrowTop: number | string = \"\";\n let arrowLeft: number | string = \"\";\n let arrowRight: number | string = \"\";\n\n const arrowWidth = arrow.offsetWidth || 0;\n const arrowHeight = arrow.offsetHeight || 0;\n const arrowAdjust = arrowWidth / 2;\n\n // check placement\n let topExceed = elemRectTop - tipHeight - arrowHeight < 0;\n let bottomExceed =\n elemRectTop + tipHeight + elemHeight + arrowHeight >= htmlch;\n let leftExceed = elemRectLeft - tipWidth - arrowWidth < leftBoundry;\n let rightExceed =\n elemRectLeft + tipWidth + elemWidth + arrowWidth >= rightBoundry;\n\n const horizontals = [\"left\", \"right\"];\n const verticals = [\"top\", \"bottom\"];\n\n topExceed = horizontals.includes(placement)\n ? elemRectTop + elemHeight / 2 - tipHeight / 2 - arrowHeight < 0\n : topExceed;\n bottomExceed = horizontals.includes(placement)\n ? elemRectTop + tipHeight / 2 + elemHeight / 2 + arrowHeight >= htmlch\n : bottomExceed;\n leftExceed = verticals.includes(placement)\n ? elemRectLeft + elemWidth / 2 - tipWidth / 2 < leftBoundry\n : leftExceed;\n rightExceed = verticals.includes(placement)\n ? elemRectLeft + tipWidth / 2 + elemWidth / 2 >= rightBoundry\n : rightExceed;\n\n // first remove side positions if both left and right limits are exceeded\n // we usually fall back to top|bottom\n placement = horizontals.includes(placement) && leftExceed && rightExceed\n ? \"top\"\n : placement;\n // recompute placement\n placement = placement === \"top\" && topExceed ? \"bottom\" : placement;\n placement = placement === \"bottom\" && bottomExceed ? \"top\" : placement;\n placement = placement === \"left\" && leftExceed ? \"right\" : placement;\n placement = placement === \"right\" && rightExceed\n ? \"left\"\n // istanbul ignore next @preserve\n : placement;\n\n // update tooltip/popover class\n // istanbul ignore else @preserve\n if (!tooltip.className.includes(placement)) {\n tooltip.className = tooltip.className.replace(\n tipClasses,\n tipClassPositions[placement],\n );\n }\n\n // compute tooltip / popover coordinates\n // istanbul ignore else @preserve\n if (horizontals.includes(placement)) {\n // secondary|side positions\n if (placement === \"left\") {\n // LEFT\n leftPosition = elemOffsetLeft - tipWidth - arrowWidth;\n } else {\n // RIGHT\n leftPosition = elemOffsetLeft + elemWidth + arrowWidth;\n }\n\n // adjust top and arrow\n if (topExceed && bottomExceed) {\n topPosition = 0;\n bottomPosition = 0;\n arrowTop = elemOffsetTop + elemHeight / 2 - arrowHeight / 2;\n } else if (topExceed) {\n topPosition = elemOffsetTop;\n bottomPosition = \"\";\n arrowTop = elemHeight / 2 - arrowWidth;\n } else if (bottomExceed) {\n topPosition = elemOffsetTop - tipHeight + elemHeight;\n bottomPosition = \"\";\n arrowTop = tipHeight - elemHeight / 2 - arrowWidth;\n } else {\n topPosition = elemOffsetTop - tipHeight / 2 + elemHeight / 2;\n arrowTop = tipHeight / 2 - arrowHeight / 2;\n }\n } else if (verticals.includes(placement)) {\n if (placement === \"top\") {\n topPosition = elemOffsetTop - tipHeight - arrowHeight;\n } else {\n // BOTTOM\n topPosition = elemOffsetTop + elemHeight + arrowHeight;\n }\n\n // adjust left | right and also the arrow\n if (leftExceed) {\n leftPosition = 0;\n arrowLeft = elemOffsetLeft + elemWidth / 2 - arrowAdjust;\n } else if (rightExceed) {\n leftPosition = \"auto\";\n rightPosition = 0;\n arrowRight = elemWidth / 2 + rightBoundry - elemRectRight - arrowAdjust;\n } else {\n leftPosition = elemOffsetLeft - tipWidth / 2 + elemWidth / 2;\n arrowLeft = tipWidth / 2 - arrowAdjust;\n }\n }\n\n // apply style to tooltip/popover\n setElementStyle(tooltip, {\n top: `${topPosition}px`,\n bottom: bottomPosition === \"\" ? \"\" : `${bottomPosition}px`,\n left: leftPosition === \"auto\" ? leftPosition : `${leftPosition}px`,\n right: rightPosition !== \"\" ? `${rightPosition}px` : \"\",\n });\n\n // update arrow placement\n // istanbul ignore else @preserve\n if (isHTMLElement(arrow)) {\n if (arrowTop !== \"\") {\n arrow.style.top = `${arrowTop}px`;\n }\n if (arrowLeft !== \"\") {\n arrow.style.left = `${arrowLeft}px`;\n } else if (arrowRight !== \"\") {\n arrow.style.right = `${arrowRight}px`;\n }\n }\n const updatedTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `updated.bs.${toLowerCase(self.name)}`,\n );\n dispatchEvent(element, updatedTooltipEvent);\n });\n};\n\nexport default styleTip;\n","import getTipTemplate from \"./getTipTemplate\";\nimport tooltipString from \"../strings/tooltipString\";\nimport { TooltipOptions } from \"../interface/tooltip\";\n\nconst tooltipDefaults: TooltipOptions = {\n template: getTipTemplate(tooltipString),\n title: \"\",\n customClass: \"\",\n trigger: \"hover focus\",\n placement: \"top\",\n sanitizeFn: undefined,\n animation: true,\n delay: 200,\n container: document.body,\n content: \"\",\n dismissible: false,\n btnClose: \"\",\n};\nexport default tooltipDefaults;\n","/**\n * Global namespace for `data-bs-title` attribute.\n */\nconst dataOriginalTitle = \"data-original-title\";\nexport default dataOriginalTitle;\n","/** @type {string} */\nconst tooltipComponent = \"Tooltip\";\nexport default tooltipComponent;\n","import {\n isArray,\n isFunction,\n isHTMLElement,\n isNode,\n isNodeList,\n isString,\n} from \"@thednp/shorty\";\n\n/**\n * Append an existing `Element` to Popover / Tooltip component or HTML\n * markup string to be parsed & sanitized to be used as popover / tooltip content.\n *\n * @param element target\n * @param content the `Element` to append / string\n * @param sanitizeFn a function to sanitize string content\n */\nconst setHtml = (\n element: HTMLElement,\n content: Node[] | Node | string,\n sanitizeFn?: (s: string) => string,\n) => {\n // istanbul ignore else @preserve\n if (isString(content) && content.length) {\n let dirty = content.trim(); // fixing #233\n if (isFunction(sanitizeFn)) dirty = sanitizeFn(dirty);\n\n const domParser = new DOMParser();\n const tempDocument = domParser.parseFromString(dirty, \"text/html\");\n element.append(...[...tempDocument.body.childNodes]);\n } else if (isHTMLElement(content)) {\n element.append(content);\n } else if (\n isNodeList(content) || (isArray(content) && content.every(isNode))\n ) {\n element.append(...[...content]);\n }\n};\nexport default setHtml;\n","import {\n addClass,\n createElement,\n hasClass,\n isHTMLElement,\n isRTL,\n querySelector,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport tooltipString from \"../strings/tooltipString\";\nimport popoverString from \"../strings/popoverString\";\nimport fadeClass from \"../strings/fadeClass\";\nimport tipClassPositions from \"./tipClassPositions\";\nimport setHtml from \"./setHtml\";\nimport Tooltip from \"../components/tooltip\";\nimport Popover from \"../components/popover\";\n\n/**\n * Creates a new tooltip / popover.\n *\n * @param self the `Tooltip` / `Popover` instance\n */\nconst createTip = (self: Tooltip | Popover) => {\n const isTooltip = self.name === tooltipComponent;\n\n const { id, element, options } = self;\n const {\n title,\n placement,\n template,\n animation,\n customClass,\n sanitizeFn,\n dismissible,\n content,\n btnClose,\n } = options;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipPositions = { ...tipClassPositions };\n let titleParts: Node[] = [];\n let contentParts: Node[] = [];\n\n if (isRTL(element)) {\n tipPositions.left = \"end\";\n tipPositions.right = \"start\";\n }\n\n // set initial popover class\n const placementClass = `bs-${tipString}-${tipPositions[placement]}`;\n\n // load template\n let tooltipTemplate: Node | string;\n if (isHTMLElement(template)) {\n tooltipTemplate = template;\n } else {\n const htmlMarkup = createElement(\"div\") as HTMLElement;\n setHtml(htmlMarkup, template, sanitizeFn);\n tooltipTemplate = htmlMarkup.firstChild as HTMLElement;\n }\n\n /* istanbul ignore if @preserve */\n if (!isHTMLElement(tooltipTemplate)) return;\n\n // set popover markup\n self.tooltip = tooltipTemplate.cloneNode(true) as HTMLElement;\n const { tooltip } = self;\n\n // set id and role attributes\n setAttribute(tooltip, \"id\", id);\n setAttribute(tooltip, \"role\", tooltipString);\n\n const bodyClass = isTooltip\n ? `${tooltipString}-inner`\n : `${popoverString}-body`;\n const tooltipHeader = isTooltip\n ? null\n : querySelector(`.${popoverString}-header`, tooltip);\n const tooltipBody = querySelector(`.${bodyClass}`, tooltip);\n\n // set arrow and enable access for styleTip\n self.arrow = querySelector(\n `.${tipString}-arrow`,\n tooltip,\n ) as HTMLElement;\n const { arrow } = self;\n\n if (isHTMLElement(title)) titleParts = [title.cloneNode(true)];\n else {\n const tempTitle = createElement(\"div\") as HTMLElement;\n setHtml(tempTitle, title, sanitizeFn);\n titleParts = [...[...tempTitle.childNodes]];\n }\n\n if (isHTMLElement(content)) contentParts = [content.cloneNode(true)];\n else {\n const tempContent = createElement(\"div\") as HTMLElement;\n setHtml(tempContent, content, sanitizeFn);\n contentParts = [...[...tempContent.childNodes]];\n }\n\n // set dismissible button\n if (dismissible) {\n if (title) {\n if (isHTMLElement(btnClose)) {\n titleParts = [...titleParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n titleParts = [...titleParts, tempBtn.firstChild as Node];\n }\n } else {\n // istanbul ignore else @preserve\n if (tooltipHeader) tooltipHeader.remove();\n if (isHTMLElement(btnClose)) {\n contentParts = [...contentParts, btnClose.cloneNode(true)];\n } else {\n const tempBtn = createElement(\"div\") as HTMLElement;\n setHtml(tempBtn, btnClose, sanitizeFn);\n contentParts = [...contentParts, tempBtn.firstChild as Node];\n }\n }\n }\n\n // fill the template with content from options / data attributes\n // also sanitize title && content\n // istanbul ignore else @preserve\n if (!isTooltip) {\n // istanbul ignore else @preserve\n if (title && tooltipHeader) {\n setHtml(tooltipHeader, titleParts, sanitizeFn);\n }\n // istanbul ignore else @preserve\n if (content && tooltipBody) {\n setHtml(tooltipBody, contentParts, sanitizeFn);\n }\n // set btn\n self.btn = querySelector(\".btn-close\", tooltip) ||\n undefined;\n } else if (title && tooltipBody) setHtml(tooltipBody, title, sanitizeFn);\n\n // Bootstrap 5.2.x\n addClass(tooltip, \"position-absolute\");\n addClass(arrow, \"position-absolute\");\n\n // set popover animation and placement\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, tipString)) addClass(tooltip, tipString);\n // istanbul ignore else @preserve\n if (animation && !hasClass(tooltip, fadeClass)) {\n addClass(tooltip, fadeClass);\n }\n // istanbul ignore else @preserve\n if (customClass && !hasClass(tooltip, customClass)) {\n addClass(tooltip, customClass);\n }\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, placementClass)) addClass(tooltip, placementClass);\n};\n\nexport default createTip;\n","import {\n getDocument,\n getElementStyle,\n getParentNode,\n isShadowRoot,\n isTableElement,\n} from \"@thednp/shorty\";\n\n/**\n * Returns an `HTMLElement` to be used as default value for *options.container*\n * for `Tooltip` / `Popover` components.\n *\n * @see https://github.com/floating-ui/floating-ui\n *\n * @param element the target\n * @returns the query result\n */\nconst getElementContainer = (element: Element) => {\n const majorBlockTags = [\"HTML\", \"BODY\"];\n const containers: HTMLElement[] = [];\n let { parentNode } = element;\n\n while (parentNode && !majorBlockTags.includes(parentNode.nodeName)) {\n parentNode = getParentNode(parentNode) as HTMLElement;\n // istanbul ignore else @preserve\n if (!(isShadowRoot(parentNode) || isTableElement(parentNode))) {\n containers.push(parentNode as HTMLElement);\n }\n }\n\n return (\n containers.find((c, i) => {\n if (\n ((getElementStyle(c, \"position\") !== \"relative\" ||\n getElementStyle(c, \"position\") === \"relative\" &&\n c.offsetHeight !== c.scrollHeight) &&\n containers.slice(i + 1).every((r) =>\n getElementStyle(r, \"position\") === \"static\"\n ))\n ) {\n return c;\n }\n return null;\n }) ||\n /* istanbul ignore next: optional guard */\n getDocument(element).body\n );\n};\n\nexport default getElementContainer;\n","/* Native JavaScript for Bootstrap 5 | Tooltip\n---------------------------------------------- */\nimport {\n addClass,\n ariaDescribedBy,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focus,\n focusEvent,\n focusinEvent,\n focusoutEvent,\n getAttribute,\n getDocument,\n getElementStyle,\n getInstance,\n getUID,\n getWindow,\n hasAttribute,\n hasClass,\n isApple,\n mouseclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseleaveEvent,\n ObjectAssign,\n passiveHandler,\n removeAttribute,\n removeClass,\n setAttribute,\n Timer,\n toLowerCase,\n TouchEvent,\n touchstartEvent,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport dataOriginalTitle from \"../strings/dataOriginalTitle\";\nimport showClass from \"../strings/showClass\";\nimport tooltipString from \"../strings/tooltipString\";\nimport tooltipComponent from \"../strings/tooltipComponent\";\nimport popoverString from \"../strings/popoverString\";\nimport popoverComponent from \"../strings/popoverComponent\";\nimport modalString from \"../strings/modalString\";\nimport offcanvasString from \"../strings/offcanvasString\";\n\nimport styleTip from \"../util/styleTip\";\nimport createTip from \"../util/createTip\";\nimport { appendPopup, hasPopup, removePopup } from \"../util/popupContainer\";\nimport getElementContainer from \"../util/getElementContainer\";\nimport tooltipDefaults from \"../util/tooltipDefaults\";\nimport BaseComponent from \"./base-component\";\nimport type { TooltipEvent, TooltipOptions } from \"../interface/tooltip\";\nimport type { PopoverEvent, PopoverOptions } from \"../interface/popover\";\n\n// TOOLTIP PRIVATE GC\n// ==================\nconst tooltipSelector =\n `[${dataBsToggle}=\"${tooltipString}\"],[data-tip=\"${tooltipString}\"]`;\nconst titleAttr = \"title\";\n\n/**\n * Static method which returns an existing `Tooltip` instance associated\n * to a target `Element`.\n */\nlet getTooltipInstance = (element: Element) =>\n getInstance(element, tooltipComponent);\n\n/**\n * A `Tooltip` initialization callback.\n */\nconst tooltipInitCallback = (element: Element) => new Tooltip(element);\n\n// TOOLTIP PRIVATE METHODS\n// =======================\n/**\n * Removes the tooltip from the DOM.\n *\n * @param self the `Tooltip` instance\n */\nconst removeTooltip = (self: Tooltip) => {\n const { element, tooltip, container } = self;\n removeAttribute(element, ariaDescribedBy);\n removePopup(\n tooltip,\n container,\n );\n};\n\n/**\n * Check if container contains the tooltip.\n *\n * @param self Tooltip\n */\nconst hasTip = (self: Tooltip): boolean | undefined => {\n const { tooltip, container } = self;\n\n return tooltip &&\n hasPopup(tooltip, container);\n};\n\n/**\n * Executes after the instance has been disposed.\n *\n * @param self the `Tooltip` instance\n * @param callback the parent dispose callback\n */\nconst disposeTooltipComplete = (self: Tooltip, callback?: () => void) => {\n const { element } = self;\n self._toggleEventListeners();\n\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, dataOriginalTitle) && self.name === tooltipComponent\n ) {\n toggleTooltipTitle(self);\n }\n // istanbul ignore else @preserve\n if (callback) callback();\n};\n\n/**\n * Toggles on/off the special `Tooltip` event listeners.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipAction = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element } = self;\n\n action(\n getDocument(element),\n touchstartEvent,\n self.handleTouch,\n passiveHandler,\n );\n};\n\n/**\n * Executes after the tooltip was shown to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipShownAction = (self: Tooltip) => {\n const { element } = self;\n const shownTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `shown.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self, true);\n dispatchEvent(element, shownTooltipEvent);\n Timer.clear(element, \"in\");\n};\n\n/**\n * Executes after the tooltip was hidden to the user.\n *\n * @param self the `Tooltip` instance\n */\nconst tooltipHiddenAction = (self: Tooltip) => {\n const { element } = self;\n const hiddenTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hidden.bs.${toLowerCase(self.name)}`,\n );\n\n toggleTooltipAction(self);\n removeTooltip(self);\n dispatchEvent(element, hiddenTooltipEvent);\n\n Timer.clear(element, \"out\");\n};\n\n/**\n * Toggles on/off the `Tooltip` event listeners that hide/update the tooltip.\n *\n * @param self the `Tooltip` instance\n * @param add when `true`, event listeners are added\n */\nconst toggleTooltipOpenHandlers = (self: Tooltip, add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, tooltip } = self;\n const parentModal = closest(element, `.${modalString}`);\n const parentOffcanvas = closest(element, `.${offcanvasString}`);\n\n if (add) {\n [element, tooltip]\n .forEach((target) => self._observer.observe(target));\n } else self._observer.disconnect();\n\n // dismiss tooltips inside modal / offcanvas\n if (parentModal) {\n action(parentModal, `hide.bs.${modalString}`, self.handleHide);\n }\n if (parentOffcanvas) {\n action(parentOffcanvas, `hide.bs.${offcanvasString}`, self.handleHide);\n }\n};\n\n/**\n * Toggles the `title` and `data-original-title` attributes.\n *\n * @param self the `Tooltip` instance\n * @param content when `true`, event listeners are added\n */\nconst toggleTooltipTitle = (self: Tooltip, content?: string) => {\n // [0 - add, 1 - remove] | [0 - remove, 1 - add]\n const titleAtt = [dataOriginalTitle, titleAttr];\n const { element } = self;\n\n setAttribute(\n element,\n titleAtt[content ? 0 : 1],\n content ||\n getAttribute(element, titleAtt[0]) ||\n // istanbul ignore next @preserve\n \"\",\n );\n removeAttribute(element, titleAtt[content ? 1 : 0]);\n};\n\n// TOOLTIP DEFINITION\n// ==================\n/** Creates a new `Tooltip` instance. */\nexport default class Tooltip extends BaseComponent {\n static selector = tooltipSelector;\n static init = tooltipInitCallback;\n static getInstance = getTooltipInstance;\n static styleTip = styleTip;\n declare element: Element & HTMLOrSVGElement;\n declare options: TooltipOptions;\n declare btn?: HTMLElement;\n declare tooltip: HTMLElement;\n declare container: HTMLElement;\n declare offsetParent: Element | Window;\n declare arrow: HTMLElement;\n declare enabled: boolean;\n declare id: string;\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n\n const { element } = this;\n const isTooltip = this.name === tooltipComponent;\n const tipString = isTooltip ? tooltipString : popoverString;\n const tipComponent = isTooltip ? tooltipComponent : popoverComponent;\n\n // istanbul ignore next @preserve: this is to set Popover too\n getTooltipInstance = (elem: Element) =>\n getInstance(elem, tipComponent);\n\n // additional properties\n this.enabled = true;\n /** Set unique ID for `aria-describedby`. */\n this.id = `${tipString}-${getUID(element, tipString)}`;\n\n // instance options\n const { options } = this;\n\n // invalidate\n // istanbul ignore else @preserve\n if (((!options.title && isTooltip) || (!isTooltip && !options.content))) {\n return;\n }\n\n // reset default options\n ObjectAssign(tooltipDefaults, { titleAttr: \"\" });\n\n // set title attributes and add event listeners\n // istanbul ignore else @preserve\n if (\n hasAttribute(element, titleAttr) && isTooltip &&\n typeof options.title === \"string\"\n ) {\n toggleTooltipTitle(this, options.title);\n }\n\n // set containers\n const container = getElementContainer(element);\n const offsetParent = [\"sticky\", \"fixed\", \"relative\"].some(\n (position) =>\n getElementStyle(container, \"position\") ===\n position,\n )\n ? container\n : getWindow(element);\n\n this.container = container;\n this.offsetParent = offsetParent;\n\n // create tooltip here\n createTip(this);\n\n /* istanbul ignore if @preserve */\n if (!this.tooltip) return;\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n /* istanbul ignore else */\n if (!entries.some((entry) => entry.isVisible)) return;\n this.update();\n });\n\n // attach events\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tooltipComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return tooltipDefaults;\n }\n\n // TOOLTIP PUBLIC METHODS\n // ======================\n /** Handles the focus event on iOS. */\n // istanbul ignore next @preserve - impossible to test without Apple device\n handleFocus = () => focus(this.element as HTMLElement);\n /** Shows the tooltip. */\n handleShow = () => this.show();\n show() {\n const { options, tooltip, element, container, id } = this;\n const { animation } = options;\n const outTimer = Timer.get(element, \"out\");\n\n Timer.clear(element, \"out\");\n\n if (tooltip && !outTimer && !hasTip(this)) {\n Timer.set(\n element,\n () => {\n const showTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `show.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, showTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!showTooltipEvent.defaultPrevented) {\n // append to container\n appendPopup(tooltip, container);\n\n setAttribute(element, ariaDescribedBy, `#${id}`);\n\n this.update();\n toggleTooltipOpenHandlers(this, true);\n\n // istanbul ignore else @preserve\n if (!hasClass(tooltip, showClass)) addClass(tooltip, showClass);\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipShownAction(this));\n } else tooltipShownAction(this);\n }\n },\n 17,\n \"in\",\n );\n }\n }\n\n /** Hides the tooltip. */\n handleHide = () => this.hide();\n hide() {\n const { options, tooltip, element } = this;\n const { animation, delay } = options;\n\n Timer.clear(element, \"in\");\n\n // istanbul ignore else @preserve\n if (tooltip && hasTip(this)) {\n Timer.set(\n element,\n () => {\n const hideTooltipEvent = createCustomEvent<\n Record,\n TooltipEvent | PopoverEvent\n >(\n `hide.bs.${toLowerCase(this.name)}`,\n );\n dispatchEvent(element, hideTooltipEvent);\n\n // istanbul ignore else @preserve\n if (!hideTooltipEvent.defaultPrevented) {\n this.update();\n removeClass(tooltip, showClass);\n toggleTooltipOpenHandlers(this);\n\n // istanbul ignore else @preserve\n if (animation) {\n emulateTransitionEnd(tooltip, () => tooltipHiddenAction(this));\n } else tooltipHiddenAction(this);\n }\n },\n delay + 17,\n \"out\",\n );\n }\n }\n\n /** Updates the tooltip position. */\n update = () => {\n styleTip(this);\n };\n\n /** Toggles the tooltip visibility. */\n toggle = () => {\n const { tooltip } = this;\n\n if (tooltip && !hasTip(this)) this.show();\n else this.hide();\n };\n\n /** Enables the tooltip. */\n enable() {\n const { enabled } = this;\n // istanbul ignore else @preserve\n if (!enabled) {\n this._toggleEventListeners(true);\n this.enabled = !enabled;\n }\n }\n\n /** Disables the tooltip. */\n disable() {\n const { tooltip, enabled } = this;\n // istanbul ignore else @preserve\n if (enabled) {\n if (tooltip && hasTip(this)) this.hide();\n this._toggleEventListeners();\n this.enabled = !enabled;\n }\n }\n\n /** Toggles the `disabled` property. */\n toggleEnabled() {\n if (!this.enabled) this.enable();\n else this.disable();\n }\n\n /**\n * Handles the `touchstart` event listener for `Tooltip`\n *\n * @this {Tooltip}\n * @param {TouchEvent} e the `Event` object\n */\n handleTouch = ({ target }: TouchEvent) => {\n const { tooltip, element } = this;\n\n // istanbul ignore if @preserve\n if (\n (tooltip && tooltip.contains(target)) ||\n target === element ||\n (target && element.contains(target))\n ) {\n // smile for ESLint\n } else {\n this.hide();\n }\n };\n\n /**\n * Toggles on/off the `Tooltip` event listeners.\n *\n * @param add when `true`, event listeners are added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n // btn is only for dismissible popover\n const { element, options, btn } = this;\n const { trigger } = options;\n const isPopover = this.name !== tooltipComponent;\n const dismissible = isPopover && (options as PopoverOptions).dismissible\n ? true\n : false;\n\n // istanbul ignore else @preserve\n if (!trigger.includes(\"manual\")) {\n this.enabled = !!add;\n\n const triggerOptions = trigger.split(\" \");\n\n triggerOptions.forEach((tr) => {\n // istanbul ignore else @preserve\n if (tr === mousehoverEvent) {\n action(element, mousedownEvent, this.handleShow);\n action(element, mouseenterEvent, this.handleShow);\n\n // istanbul ignore else @preserve\n if (!dismissible) {\n action(element, mouseleaveEvent, this.handleHide);\n action(\n getDocument(element),\n touchstartEvent,\n this.handleTouch,\n passiveHandler,\n );\n }\n } else if (tr === mouseclickEvent) {\n action(element, tr, !dismissible ? this.toggle : this.handleShow);\n } else if (tr === focusEvent) {\n action(element, focusinEvent, this.handleShow);\n // istanbul ignore else @preserve\n if (!dismissible) action(element, focusoutEvent, this.handleHide);\n // istanbul ignore else @preserve\n if (isApple()) {\n action(element, mouseclickEvent, this.handleFocus);\n }\n }\n // istanbul ignore else @preserve\n if (dismissible && btn) {\n action(btn, mouseclickEvent, this.handleHide);\n }\n });\n }\n };\n\n /** Removes the `Tooltip` from the target element. */\n dispose() {\n const { tooltip, options } = this;\n const clone = { ...this, name: this.name };\n const callback = () =>\n setTimeout(\n () => disposeTooltipComplete(clone, () => super.dispose()),\n 17,\n );\n\n if (options.animation && hasTip(clone)) {\n this.options.delay = 0; // reset delay\n this.hide();\n emulateTransitionEnd(tooltip, callback);\n } else {\n callback();\n }\n }\n}\n"],"names":["popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","arrow","body","tipClassPositions","styleTip","self","tipClasses","element","tooltip","container","offsetParent","options","RTL","isRTL","scrollLeft","scrollTop","getNodeScroll","setElementStyle","tipWidth","tipHeight","htmlcw","htmlch","htmlow","getDocumentElement","placement","parentCWidth","parentOWidth","fixedParent","getElementStyle","scrollbarWidth","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","getBoundingClientRect","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","topExceed","bottomExceed","leftExceed","rightExceed","horizontals","verticals","isHTMLElement","updatedTooltipEvent","createCustomEvent","toLowerCase","dispatchEvent","tooltipDefaults","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","isString","dirty","isFunction","tempDocument","isNodeList","isArray","isNode","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","createElement","setAttribute","tooltipHeader","querySelector","tooltipBody","tempTitle","tempContent","tempBtn","addClass","hasClass","fadeClass","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","c","i","r","getDocument","tooltipSelector","dataBsToggle","titleAttr","getTooltipInstance","getInstance","tooltipInitCallback","Tooltip","removeTooltip","removeAttribute","ariaDescribedBy","removePopup","hasTip","hasPopup","disposeTooltipComplete","callback","hasAttribute","toggleTooltipTitle","toggleTooltipAction","add","action","addListener","removeListener","touchstartEvent","passiveHandler","tooltipShownAction","shownTooltipEvent","Timer","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","closest","modalString","parentOffcanvas","offcanvasString","target","titleAtt","getAttribute","BaseComponent","config","tipComponent","elem","getUID","ObjectAssign","position","getWindow","PositionObserver","entries","entry","focus","outTimer","showTooltipEvent","appendPopup","showClass","emulateTransitionEnd","delay","hideTooltipEvent","removeClass","enabled","btn","trigger","tr","mousehoverEvent","mousedownEvent","mouseenterEvent","mouseleaveEvent","mouseclickEvent","focusEvent","focusinEvent","focusoutEvent","isApple","clone"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IAAAiK,CAAQ,EAAA,KAC5B,CAAE,QAAAC,GAAYlK,EAEduE,EAAc,GADF,KAAK,OAASjB,GACEtD,EAA2B,aAKxDkK,EAAQ,SAAS,QAAQ,IACvB,KAAA,QAAU,CAAC,CAAC1C,EAEM0C,EAAQ,MAAM,GAAG,EAEzB,QAASC,GAAO,CAEzBA,IAAOC,EAAAA,IACF3C,EAAA7H,EAASyK,KAAgB,KAAK,UAAU,EACxC5C,EAAA7H,EAAS0K,KAAiB,KAAK,UAAU,EAG3C/F,IACIkD,EAAA7H,EAAS2K,KAAiB,KAAK,UAAU,EAChD9C,EACEpB,EAAAA,EAAYzG,CAAO,EACnBgI,EAAA,GACA,KAAK,YACLC,EAAAA,EACF,IAEOsC,IAAOK,KAChB/C,EAAO7H,EAASuK,EAAK5F,EAA4B,KAAK,WAAnB,KAAK,MAAwB,EACvD4F,IAAOM,OACThD,EAAA7H,EAAS8K,KAAc,KAAK,UAAU,EAExCnG,GAAakD,EAAO7H,EAAS+K,EAAA,GAAe,KAAK,UAAU,EAE5DC,QACKnD,EAAA7H,EAAS4K,KAAiB,KAAK,WAAW,GAIjDjG,GAAe0F,GACVxC,EAAAwC,EAAKO,KAAiB,KAAK,UAAU,CAC9C,CACD,EAEL,EAGA,SAAU,CACF,KAAA,CAAE,QAAA3K,EAAS,QAAAG,CAAA,EAAY,KACvB6K,EAAQ,CAAE,GAAG,KAAM,KAAM,KAAK,IAAK,EACnCzD,EAAW,IACf,WACE,IAAMD,GAAuB0D,EAAO,IAAM,MAAM,SAAS,EACzD,EACF,EAEE7K,EAAQ,WAAaiH,EAAO4D,CAAK,GACnC,KAAK,QAAQ,MAAQ,EACrB,KAAK,KAAK,EACVjB,EAAA,GAAqB/J,EAASuH,CAAQ,GAE7BA,EAAA,CACX,CAEJ"} \ No newline at end of file diff --git a/dist/components/tooltip.cjs b/dist/components/tooltip.cjs index 45e00ed8..cd3e3a85 100644 --- a/dist/components/tooltip.cjs +++ b/dist/components/tooltip.cjs @@ -1,2 +1,2 @@ -"use strict";require("./base-component-D3rSrWwH.js");require("./event-listener-W3RGkfJ6.js");require("./index-BRPRSfaI.js");require("./dataBsToggle-Dj-Ng54N.js");const e=require("./tooltip--Tnf23hE.js");require("./showClass-D_Ms1FgG.js");require("./popupContainer-D8In9VFi.js");module.exports=e.Tooltip; +"use strict";require("./base-component-DaZCwW-u.js");require("./event-listener-BQdA_KAC.js");require("./index-DlQfhTUb.js");require("./dataBsToggle-Dj-Ng54N.js");const e=require("./tooltip-DKh6RNNg.js");require("./showClass-D_Ms1FgG.js");require("./popupContainer-CSoNJ-n6.js");module.exports=e.Tooltip; //# sourceMappingURL=tooltip.cjs.map diff --git a/dist/components/tooltip.d.ts b/dist/components/tooltip.d.ts index a68030e1..4402d3dc 100644 --- a/dist/components/tooltip.d.ts +++ b/dist/components/tooltip.d.ts @@ -1,14 +1,15 @@ import { default as default_2 } from '@thednp/position-observer'; +import { TouchEvent as TouchEvent_2 } from '@thednp/shorty'; /** Returns a new `BaseComponent` instance. */ declare class BaseComponent { - element: HTMLElement; + element: Element; options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions); + constructor(target: Element | string, config?: BaseOptions); get version(): string; get name(): string; get defaults(): {}; @@ -25,15 +26,16 @@ declare interface BaseOptions { /** Creates a new `Tooltip` instance. */ declare class Tooltip extends BaseComponent { static selector: string; - static init: (element: HTMLElement) => Tooltip; - static getInstance: (element: HTMLElement) => Tooltip | null; - static styleTip: (self: T) => void; + static init: (element: Element) => Tooltip; + static getInstance: (element: Element) => Tooltip | null; + static styleTip: (self: Tooltip) => void; + element: Element & HTMLOrSVGElement; options: TooltipOptions; btn?: HTMLElement; - tooltip?: HTMLElement; - container: ParentNode; - arrow?: HTMLElement; - offsetParent?: HTMLElement; + tooltip: HTMLElement; + container: HTMLElement; + offsetParent: Element | Window; + arrow: HTMLElement; enabled: boolean; id: string; _observer: default_2; @@ -41,7 +43,7 @@ declare class Tooltip extends BaseComponent { * @param target the target element * @param config the instance options */ - constructor(target: HTMLElement | string, config?: Partial); + constructor(target: Element | string, config?: Partial); /** * Returns component name string. */ @@ -74,7 +76,7 @@ declare class Tooltip extends BaseComponent { * @this {Tooltip} * @param {TouchEvent} e the `Event` object */ - handleTouch: ({ target }: TouchEvent) => void; + handleTouch: ({ target }: TouchEvent_2) => void; /** * Toggles on/off the `Tooltip` event listeners. * diff --git a/dist/components/tooltip.mjs b/dist/components/tooltip.mjs index 01fcd97b..ed405b90 100644 --- a/dist/components/tooltip.mjs +++ b/dist/components/tooltip.mjs @@ -1,10 +1,10 @@ -import "./base-component-ylZzLp-h.mjs"; -import "./event-listener-C1-Yf9Z5.mjs"; -import "./index-gZuXW-3_.mjs"; +import "./base-component-Jx2aafTJ.mjs"; +import "./event-listener-CUwvA4j6.mjs"; +import "./index-DinhT6Jq.mjs"; import "./dataBsToggle-B84TS15h.mjs"; -import { T as f } from "./tooltip-B5F6ZNW7.mjs"; +import { T as f } from "./tooltip-Cxy40RjE.mjs"; import "./showClass-C8hdJfjQ.mjs"; -import "./popupContainer-ymf2oGcv.mjs"; +import "./popupContainer-CgZsH2ur.mjs"; export { f as default }; diff --git a/docs/assets/css/theme.css b/docs/assets/css/theme.css index 5032f2e0..7a40c511 100644 --- a/docs/assets/css/theme.css +++ b/docs/assets/css/theme.css @@ -191,7 +191,7 @@ nav.border-bottom { .img-tip-modal, .svg-tip-modal { - position: absolute; top:250px; + position: absolute; top: 170px; } .img-tip-modal {right:0} .svg-tip-modal {right:90px} diff --git a/docs/assets/js/bootstrap-native.js b/docs/assets/js/bootstrap-native.js index bff96e7d..3d50cf89 100644 --- a/docs/assets/js/bootstrap-native.js +++ b/docs/assets/js/bootstrap-native.js @@ -1,2 +1,2 @@ -var BSN=function(R){"use strict";const xs="aria-describedby",de="aria-expanded",Kt="aria-hidden",he="aria-modal",Is="aria-pressed",xe="aria-selected",Ie="focus",Le="focusin",Ls="focusout",fe="keydown",Oo="keyup",L="click",Os="mousedown",No="hover",ge="mouseenter",Oe="mouseleave",ko="pointerdown",_o="pointermove",Mo="pointerup",Ne="touchstart",Bo="dragstart",Ro='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',ke="ArrowDown",_e="ArrowUp",Ns="ArrowLeft",ks="ArrowRight",Me="Escape",Fo="transitionDuration",Wo="transitionDelay",Be="transitionend",_s="transitionProperty",Vo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},pe=()=>{},jo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},zo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},tt=(e,t)=>e.getAttribute(t),Ut=(e,t)=>e.hasAttribute(t),O=(e,t,s)=>e.setAttribute(t,s),St=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},m=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),Xt=e=>e!=null&&typeof e=="object"||!1,A=e=>Xt(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,T=e=>A(e)&&e.nodeType===1||!1,_t=new Map,Dt={data:_t,set:(e,t,s)=>{T(e)&&(_t.has(t)||_t.set(t,new Map),_t.get(t).set(e,s))},getAllFor:e=>_t.get(e)||null,get:(e,t)=>{if(!T(e)||!t)return null;const s=Dt.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=Dt.getAllFor(t);!s||!T(e)||(s.delete(e),s.size===0&&_t.delete(t))}},F=(e,t)=>Dt.get(e,t),qt=e=>typeof e=="string"||!1,Ko=e=>Xt(e)&&e.constructor.name==="Window"||!1,Ms=e=>A(e)&&e.nodeType===9||!1,b=e=>Ko(e)?e.document:Ms(e)?e:A(e)?e.ownerDocument:globalThis.document,at=(e,...t)=>Object.assign(e,...t),gt=e=>{if(!e)return;if(qt(e))return b().createElement(e);const{tagName:t}=e,s=gt(t);if(!s)return;const n={...e};return delete n.tagName,at(s,n)},E=(e,t)=>e.dispatchEvent(t),j=(e,t)=>{const s=getComputedStyle(e),n=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return s.getPropertyValue(n)},Uo=e=>{const t=j(e,_s),s=j(e,Wo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},Yt=e=>{const t=j(e,_s),s=j(e,Fo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},P=(e,t)=>{let s=0;const n=new Event(Be),o=Yt(e),i=Uo(e);if(o){const a=r=>{r.target===e&&(t.apply(e,[r]),e.removeEventListener(Be,a),s=1)};e.addEventListener(Be,a),setTimeout(()=>{s||E(e,n)},o+i+17)}else t.apply(e,[n])},rt=(e,t)=>e.focus(t),Bs=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,ue=e=>Object.entries(e),Mt=e=>e.toLowerCase(),Xo=(e,t,s,n)=>{const o={...s},i={...e.dataset},a={...t},r={},c="title";return ue(i).forEach(([l,d])=>{const g=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,$=>Mt($)):l;r[g]=Bs(d)}),ue(o).forEach(([l,d])=>{o[l]=Bs(d)}),ue(t).forEach(([l,d])=>{l in o?a[l]=o[l]:l in r?a[l]=r[l]:a[l]=l===c?tt(e,c):d}),a},Rs=e=>Object.keys(e),w=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return Xt(t)&&at(s,t),s},Zt={passive:!0},Ht=e=>e.offsetHeight,x=(e,t)=>{ue(t).forEach(([s,n])=>{if(n&&qt(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,at(e.style,o)}})},Re=e=>Xt(e)&&e.constructor.name==="Map"||!1,qo=e=>typeof e=="number"||!1,pt=new Map,p={set:(e,t,s,n)=>{T(e)&&(n&&n.length?(pt.has(e)||pt.set(e,new Map),pt.get(e).set(n,setTimeout(t,s))):pt.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!T(e))return null;const s=pt.get(e);return t&&s&&Re(s)?s.get(t)||null:qo(s)?s:null},clear:(e,t)=>{if(!T(e))return;const s=pt.get(e);t&&t.length&&Re(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&&pt.delete(e)):(clearTimeout(s),pt.delete(e))}},Z=(e,t)=>(A(t)?t:b()).querySelectorAll(e),Fe=new Map;function Yo(e){const{shiftKey:t,code:s}=e,n=b(this),o=[...Z(Ro,this)].filter(r=>!Ut(r,"disabled")&&!tt(r,Kt));if(!o.length)return;const i=o[0],a=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(a.focus(),e.preventDefault()):!t&&n.activeElement===a&&(i.focus(),e.preventDefault()))}const Zo=e=>Fe.has(e)===!0,me=e=>{const t=Zo(e);(t?zo:jo)(e,"keydown",Yo),t?Fe.delete(e):Fe.set(e,!0)},Gt=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:a,left:r}=e.getBoundingClientRect();let c=1,l=1;if(t&&T(e)){const{offsetWidth:d,offsetHeight:g}=e;c=d>0?Math.round(s)/d:1,l=g>0?Math.round(n)/g:1}return{width:s/c,height:n/l,top:o/l,right:i/c,bottom:a/l,left:r/c,x:r/c,y:o/l}},ut=e=>b(e).body,ct=e=>b(e).documentElement,Fs=e=>A(e)&&e.constructor.name==="ShadowRoot"||!1,Go=e=>e.nodeName==="HTML"?e:T(e)&&e.assignedSlot||A(e)&&e.parentNode||Fs(e)&&e.host||ct(e);let Ws=0,Vs=0;const Bt=new Map,js=(e,t)=>{let s=t?Ws:Vs;if(t){const n=js(e),o=Bt.get(n)||new Map;Bt.has(n)||Bt.set(n,o),Re(o)&&!o.has(t)?(o.set(t,s),Ws+=1):s=o.get(t)}else{const n=e.id||e;Bt.has(n)?s=Bt.get(n):(Bt.set(n,s),Vs+=1)}return s},Jo=e=>e?Ms(e)?e.defaultView:A(e)?e?.ownerDocument?.defaultView:e:window,Qo=e=>Array.isArray(e)||!1,zs=e=>{if(!A(e))return!1;const{top:t,bottom:s}=Gt(e),{clientHeight:n}=ct(e);return t<=n&&s>=0},ti=e=>typeof e=="function"||!1,ei=e=>Xt(e)&&e.constructor.name==="NodeList"||!1,mt=e=>ct(e).dir==="rtl",si=e=>A(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,N=(e,t)=>e?e.closest(t)||N(e.getRootNode().host,t):null,S=(e,t)=>T(e)?e:(A(t)?t:b()).querySelector(e),We=(e,t)=>(A(t)?t:b()).getElementsByTagName(e),lt=(e,t)=>(t&&A(t)?t:b()).getElementsByClassName(e),Ks=(e,t)=>e.matches(t),Rt={},Us=e=>{const{type:t,currentTarget:s}=e;[...Rt[t]].forEach(([n,o])=>{s===n&&[...o].forEach(([i,a])=>{i.apply(n,[e]),typeof a=="object"&&a.once&&M(n,t,i,a)})})},_=(e,t,s,n)=>{Rt[t]||(Rt[t]=new Map);const o=Rt[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:a}=i;i.set(s,n);a||e.addEventListener(t,Us,n)},M=(e,t,s,n)=>{const o=Rt[t],i=o&&o.get(e),a=i&&i.get(s),r=a!==void 0?a:n;i&&i.has(s)&&i.delete(s);o&&(!i||!i.size)&&o.delete(e);(!o||!o.size)&&delete Rt[t];(!i||!i.size)&&e.removeEventListener(t,Us,r)},B="fade",u="show",ve="data-bs-dismiss",be="alert",Xs="Alert",ni="5.1.0";class et{constructor(t,s){let n;try{if(T(t))n=t;else if(qt(t)){if(n=S(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=Dt.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&Rs(this.defaults).length?Xo(n,this.defaults,s||{},"bs"):{},Dt.set(n,this.name,this)}get version(){return ni}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){Dt.remove(this.element,this.name),Rs(this).forEach(t=>{delete this[t]})}}const oi=`.${be}`,ii=`[${ve}="${be}"]`,ai=e=>F(e,Xs),ri=e=>new Ve(e),qs=w(`close.bs.${be}`),ci=w(`closed.bs.${be}`),Ys=e=>{const{element:t}=e;E(t,ci),e._toggleEventListeners(),e.dispose(),t.remove()};class Ve extends et{static selector=oi;static init=ri;static getInstance=ai;dismiss;constructor(t){super(t),this.dismiss=S(ii,this.element),this._toggleEventListeners(!0)}get name(){return Xs}close=()=>{const{element:t}=this;t&&f(t,u)&&(E(t,qs),qs.defaultPrevented||(m(t,u),f(t,B)?P(t,()=>Ys(this)):Ys(this)))};_toggleEventListeners=t=>{const s=t?_:M,{dismiss:n,close:o}=this;n&&s(n,L,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const y="active",ot="data-bs-toggle",li="button",Zs="Button",di=`[${ot}="${li}"]`,hi=e=>F(e,Zs),fi=e=>new je(e);class je extends et{static selector=di;static init=fi;static getInstance=hi;isActive=!1;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,y),O(s,Is,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return Zs}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!tt(s,"disabled")&&((n?m:h)(s,y),O(s,Is,n?"false":"true"),this.isActive=f(s,y))};_toggleEventListeners=t=>{(t?_:M)(this.element,L,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const ze="data-bs-target",At="carousel",Gs="Carousel",Js="data-bs-parent",gi="data-bs-container",z=e=>{const t=[ze,Js,gi,"href"],s=b(e);return t.map(n=>{const o=tt(e,n);return o?n===Js?N(e,o):S(o,s):null}).filter(n=>n)[0]},Jt=`[data-bs-ride="${At}"]`,G=`${At}-item`,Ke="data-bs-slide-to",vt="data-bs-slide",bt="paused",Qs={pause:"hover",keyboard:!1,touch:!0,interval:5e3},dt=e=>F(e,Gs),pi=e=>new Ge(e);let Qt=0,Ee=0,Ue=0;const Xe=w(`slide.bs.${At}`),qe=w(`slid.bs.${At}`),tn=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const a=Ze(e),r=s==="left"?"next":"prev",c=s==="left"?"start":"end";h(o[t],y),m(o[t],`${G}-${r}`),m(o[t],`${G}-${c}`),m(o[a],y),m(o[a],`${G}-${c}`),E(n,qe),p.clear(n,vt),e.cycle&&!b(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function ui(){const e=dt(this);e&&!e.isPaused&&!p.get(this,bt)&&h(this,bt)}function mi(){const e=dt(this);e&&e.isPaused&&!p.get(this,bt)&&e.cycle()}function vi(e){e.preventDefault();const t=N(this,Jt)||z(this),s=dt(t);if(s&&!s.isAnimating){const n=+(tt(this,Ke)||0);this&&!f(this,y)&&!Number.isNaN(n)&&s.to(n)}}function bi(e){e.preventDefault();const t=N(this,Jt)||z(this),s=dt(t);if(s&&!s.isAnimating){const n=tt(this,vt);n==="next"?s.next():n==="prev"&&s.prev()}}const Ei=({code:e,target:t})=>{const s=b(t),[n]=[...Z(Jt,s)].filter(i=>zs(i)),o=dt(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=mt(n);e===(i?ks:Ns)?o.prev():e===(i?Ns:ks)&&o.next()}};function en(e){const{target:t}=e,s=dt(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function wi(e){const{target:t}=e,s=dt(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(Qt=e.pageX,this.contains(t)&&(s.isTouch=!0,sn(s,!0)))}}const Ti=e=>{Ee=e.pageX},yi=e=>{const{target:t}=e,s=b(t),n=[...Z(Jt,s)].map(o=>dt(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,a=mt(o);Ue=e.pageX,n.isTouch=!1,sn(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(Qt-Ue)>120&&(EeQt&&n.to(i+(a?1:-1))),Qt=0,Ee=0,Ue=0}},Ye=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>m(n,y)),e.indicators[t]&&h(s[t],y)},sn=(e,t)=>{const{element:s}=e,n=t?_:M;n(b(s),_o,Ti,Zt),n(b(s),Mo,yi,Zt)},Ze=e=>{const{slides:t,element:s}=e,n=S(`.${G}.${y}`,s);return T(n)?[...t].indexOf(n):-1};class Ge extends et{static selector=Jt;static init=pi;static getInstance=dt;constructor(t,s){super(t,s);const{element:n}=this;this.direction=mt(n)?"right":"left",this.isTouch=!1,this.slides=lt(G,n);const{slides:o}=this;if(o.length>=2){const i=Ze(this),a=[...o].find(l=>Ks(l,`.${G}-next,.${G}-next`));this.index=i;const r=b(n);this.controls=[...Z(`[${vt}]`,n),...Z(`[${vt}][${ze}="#${n.id}"]`,r)].filter((l,d,g)=>d===g.indexOf(l)),this.indicator=S(`.${At}-indicators`,n),this.indicators=[...this.indicator?Z(`[${Ke}]`,this.indicator):[],...Z(`[${Ke}][${ze}="#${n.id}"]`,r)].filter((l,d,g)=>d===g.indexOf(l));const{options:c}=this;this.options.interval=c.interval===!0?Qs.interval:c.interval,a?this.index=[...o].indexOf(a):i<0&&(this.index=0,h(o[0],y),this.indicators.length&&Ye(this,0)),this.indicators.length&&Ye(this,this.index),this._toggleEventListeners(!0),c.interval&&this.cycle()}}get name(){return Gs}get defaults(){return Qs}get isPaused(){return f(this.element,bt)}get isAnimating(){return S(`.${G}-next,.${G}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;p.clear(t,At),n&&(p.clear(t,bt),m(t,bt)),p.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&zs(t)&&this.to(o+1)},s.interval,At)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,bt),p.set(t,()=>{},1,bt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Ze(this),a=mt(s);let r=t;if(!this.isAnimating&&i!==r&&!p.get(s,vt)){ir||i===n.length-1&&r===0)&&(this.direction=a?"left":"right");const{direction:c}=this;r<0?r=n.length-1:r>=n.length&&(r=0);const l=c==="left"?"next":"prev",d=c==="left"?"start":"end",g={relatedTarget:n[r],from:i,to:r,direction:c};at(Xe,g),at(qe,g),E(s,Xe),Xe.defaultPrevented||(this.index=r,Ye(this,r),Yt(n[r])&&f(s,"slide")?p.set(s,()=>{h(n[r],`${G}-${l}`),Ht(n[r]),h(n[r],`${G}-${d}`),h(n[i],`${G}-${d}`),P(n[r],()=>this.slides&&this.slides.length&&tn(this))},0,vt):(h(n[r],y),m(n[i],y),p.set(s,()=>{p.clear(s,vt),s&&o.interval&&!this.isPaused&&this.cycle(),E(s,qe)},0,vt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:a}=this,{touch:r,pause:c,interval:l,keyboard:d}=n,g=t?_:M;c&&l&&(g(s,ge,ui),g(s,Oe,mi)),r&&o.length>2&&(g(s,ko,wi,Zt),g(s,Ne,en,{passive:!1}),g(s,Bo,en,{passive:!1})),i.length&&i.forEach($=>{$&&g($,L,bi)}),a.length&&a.forEach($=>{g($,L,vi)}),d&&g(b(s),fe,Ei)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&P(s.slides[s.index],()=>{tn(s)})}}const Pt="collapsing",K="collapse",nn="Collapse",$i=`.${K}`,on=`[${ot}="${K}"]`,Ci={parent:null},we=e=>F(e,nn),Si=e=>new Je(e),an=w(`show.bs.${K}`),Di=w(`shown.bs.${K}`),rn=w(`hide.bs.${K}`),Hi=w(`hidden.bs.${K}`),Ai=e=>{const{element:t,parent:s,triggers:n}=e;E(t,an),an.defaultPrevented||(p.set(t,pe,17),s&&p.set(s,pe,17),h(t,Pt),m(t,K),x(t,{height:`${t.scrollHeight}px`}),P(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>O(o,de,"true")),m(t,Pt),h(t,K),h(t,u),x(t,{height:""}),E(t,Di)}))},cn=e=>{const{element:t,parent:s,triggers:n}=e;E(t,rn),rn.defaultPrevented||(p.set(t,pe,17),s&&p.set(s,pe,17),x(t,{height:`${t.scrollHeight}px`}),m(t,K),m(t,u),h(t,Pt),Ht(t),x(t,{height:"0px"}),P(t,()=>{p.clear(t),s&&p.clear(s),n.forEach(o=>O(o,de,"false")),m(t,Pt),h(t,K),x(t,{height:""}),E(t,Hi)}))},Pi=e=>{const{target:t}=e,s=t&&N(t,on),n=s&&z(s),o=n&&we(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class Je extends et{static selector=$i;static init=Si;static getInstance=we;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=b(n);this.triggers=[...Z(on,i)].filter(a=>z(a)===n),this.parent=T(o.parent)?o.parent:qt(o.parent)?z(n)||S(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return nn}get defaults(){return Ci}hide(){const{triggers:t,element:s}=this;p.get(s)||(cn(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...Z(`.${K}.${u}`,s)].find(a=>we(a)),i=o&&we(o)),(!s||!p.get(s))&&!p.get(t)&&(i&&o!==t&&(cn(i),i.triggers.forEach(a=>{h(a,`${K}d`)})),Ai(this),n.length&&n.forEach(a=>m(a,`${K}d`)))}toggle(){f(this.element,u)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?_:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,L,Pi))};dispose(){this._toggleEventListeners(),super.dispose()}}const xt=["dropdown","dropup","dropstart","dropend"],ln="Dropdown",dn="dropdown-menu",hn=e=>{const t=N(e,"A");return e.tagName==="A"&&Ut(e,"href")&&tt(e,"href").slice(-1)==="#"||t&&Ut(t,"href")&&tt(t,"href").slice(-1)==="#"},[st,Qe,ts,es]=xt,fn=`[${ot}="${st}"]`,Ft=e=>F(e,ln),xi=e=>new os(e),Ii=`${dn}-end`,gn=[st,Qe],pn=[ts,es],un=["A","BUTTON"],Li={offset:5,display:"dynamic"},ss=w(`show.bs.${st}`),mn=w(`shown.bs.${st}`),ns=w(`hide.bs.${st}`),vn=w(`hidden.bs.${st}`),bn=w(`updated.bs.${st}`),En=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(j(s,"position")!=="static"){const a=mt(t),r=f(s,Ii);["margin","top","bottom","left","right"].forEach(k=>{const yt={};yt[k]="",x(s,yt)});let l=xt.find(k=>f(n,k))||st;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:a?[-1,0,0,i]:[-1,i,0],dropend:a?[-1,i,0]:[-1,0,0,i]},g={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:a?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:a?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:a?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:a?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:$,offsetHeight:D}=s,{clientWidth:W,clientHeight:v}=ct(t),{left:U,top:Y,width:Vt,height:ft}=Gt(t),C=U-$-i<0,nt=U+$+Vt+i>=W,it=Y+D+i>=v,V=Y+D+ft+i>=v,X=Y-D-i<0,H=(!a&&r||a&&!r)&&U+Vt-$<0,jt=(a&&r||!a&&!r)&&U+$>=W;if(pn.includes(l)&&C&&nt&&(l=st),l===ts&&(a?nt:C)&&(l=es),l===es&&(a?C:nt)&&(l=ts),l===Qe&&X&&!V&&(l=st),l===st&&V&&!X&&(l=Qe),pn.includes(l)&&it&&at(g[l],{top:"auto",bottom:0}),gn.includes(l)&&(H||jt)){let k={left:"auto",right:"auto"};!H&&jt&&!a&&(k={left:"auto",right:0}),H&&!jt&&a&&(k={left:0,right:"auto"}),k&&at(g[l],k)}const Tt=d[l];x(s,{...g[l],margin:`${Tt.map(k=>k&&`${k}px`).join(" ")}`}),gn.includes(l)&&r&&r&&x(s,g[!a&&H||a&&jt?"menuStart":"menuEnd"]),E(n,bn)}},Oi=e=>[...e.children].map(t=>{if(t&&un.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&un.includes(s.tagName)?s:null}).filter(t=>t),wn=e=>{const{element:t,options:s,menu:n}=e,o=e.open?_:M,i=b(t);o(i,L,Tn),o(i,Ie,Tn),o(i,fe,ki),o(i,Oo,_i),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},Te=e=>{const t=[...xt,"btn-group","input-group"].map(s=>lt(`${s} ${u}`,b(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>xt.some(n=>n===tt(s,ot)))},Tn=e=>{const{target:t,type:s}=e;if(t&&T(t)){const n=Te(t),o=n&&Ft(n);if(o){const{parentElement:i,menu:a}=o,r=i&&i.contains(t)&&(t.tagName==="form"||N(t,"form")!==null);[L,Os].includes(s)&&hn(t)&&e.preventDefault(),!r&&s!==Ie&&t!==n&&t!==a&&o.hide()}}},Ni=e=>{const{target:t}=e,s=t&&N(t,fn),n=s&&Ft(s);n&&(e.stopPropagation(),n.toggle(),s&&hn(s)&&e.preventDefault())},ki=e=>{[ke,_e].includes(e.code)&&e.preventDefault()};function _i(e){const{code:t}=e,s=Te(this),n=s&&Ft(s),{activeElement:o}=s&&b(s);if(n&&o){const{menu:i,open:a}=n,r=Oi(i);if(r&&r.length&&[ke,_e].includes(t)){let c=r.indexOf(o);o===s?c=0:t===_e?c=c>1?c-1:0:t===ke&&(c=cMi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return ln}get defaults(){return Li}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(!s){const i=Te(t),a=i&&Ft(i);a&&a.hide(),[ss,mn,bn].forEach(r=>{r.relatedTarget=t}),E(o,ss),ss.defaultPrevented||(h(n,u),h(o,u),O(t,de,"true"),En(this),this.open=!s,rt(t),wn(this),E(o,mn))}}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([ns,vn].forEach(i=>{i.relatedTarget=t}),E(o,ns),ns.defaultPrevented||(m(n,u),m(o,u),O(t,de,"false"),this.open=!s,wn(this),E(o,vn)))}_toggleEventListeners=t=>{(t?_:M)(this.element,L,Ni)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const q="modal",is="Modal",as="Offcanvas",Bi="fixed-top",Ri="fixed-bottom",yn="sticky-top",$n="position-sticky",Cn=e=>[...lt(Bi,e),...lt(Ri,e),...lt(yn,e),...lt($n,e),...lt("is-fixed",e)],Fi=e=>{const t=ut(e);x(t,{paddingRight:"",overflow:""});const s=Cn(t);s.length&&s.forEach(n=>{x(n,{paddingRight:"",marginRight:""})})},Sn=e=>{const{clientWidth:t}=ct(e),{innerWidth:s}=Jo(e);return Math.abs(s-t)},Dn=(e,t)=>{const s=ut(e),n=parseInt(j(s,"paddingRight"),10),i=j(s,"overflow")==="hidden"&&n?0:Sn(e),a=Cn(s);t&&(x(s,{overflow:"hidden",paddingRight:`${n+i}px`}),a.length&&a.forEach(r=>{const c=j(r,"paddingRight");if(r.style.paddingRight=`${parseInt(c,10)+i}px`,[yn,$n].some(l=>f(r,l))){const l=j(r,"marginRight");r.style.marginRight=`${parseInt(l,10)-i}px`}}))},J="offcanvas",Et=gt({tagName:"div",className:"popup-container"}),Hn=(e,t)=>{const s=A(t)&&t.nodeName==="BODY",n=A(t)&&!s?t:Et,o=s?t:ut(e);A(e)&&(n===Et&&o.append(Et),n.append(e))},An=(e,t)=>{const s=A(t)&&t.nodeName==="BODY",n=A(t)&&!s?t:Et;A(e)&&(e.remove(),n===Et&&!Et.children.length&&Et.remove())},rs=(e,t)=>{const s=A(t)&&t.nodeName!=="BODY"?t:Et;return A(e)&&s.contains(e)},Pn="backdrop",xn=`${q}-${Pn}`,In=`${J}-${Pn}`,Ln=`.${q}.${u}`,cs=`.${J}.${u}`,I=gt("div"),It=e=>S(`${Ln},${cs}`,b(e)),ls=e=>{const t=e?xn:In;[xn,In].forEach(s=>{m(I,s)}),h(I,t)},On=(e,t,s)=>{ls(s),Hn(I,ut(e)),t&&h(I,B)},Nn=()=>{f(I,u)||(h(I,u),Ht(I))},ye=()=>{m(I,u)},kn=e=>{It(e)||(m(I,B),An(I,ut(e)),Fi(e))},_n=e=>T(e)&&j(e,"visibility")!=="hidden"&&e.offsetParent!==null,Wi=`.${q}`,Mn=`[${ot}="${q}"]`,Vi=`[${ve}="${q}"]`,Bn=`${q}-static`,ji={backdrop:!0,keyboard:!0},te=e=>F(e,is),zi=e=>new hs(e),$e=w(`show.bs.${q}`),Rn=w(`shown.bs.${q}`),ds=w(`hide.bs.${q}`),Fn=w(`hidden.bs.${q}`),Wn=e=>{const{element:t}=e,s=Sn(t),{clientHeight:n,scrollHeight:o}=ct(t),{clientHeight:i,scrollHeight:a}=t,r=i!==a;if(!r&&s){const l={[mt(t)?"paddingLeft":"paddingRight"]:`${s}px`};x(t,l)}Dn(t,r||n!==o)},Vn=(e,t)=>{const s=t?_:M,{element:n}=e;s(n,L,Xi),s(b(n),fe,Ui),t?e._observer.observe(n):e._observer.disconnect()},jn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;kn(s),x(s,{paddingRight:"",display:""}),Vn(e);const o=$e.relatedTarget||t.find(_n);o&&rt(o),Fn.relatedTarget=n,E(s,Fn),me(s)},zn=e=>{const{element:t,relatedTarget:s}=e;rt(t),Vn(e,!0),Rn.relatedTarget=s,E(t,Rn),me(t)},Kn=e=>{const{element:t,hasFade:s}=e;x(t,{display:"block"}),Wn(e),It(t)||x(ut(t),{overflow:"hidden"}),h(t,u),St(t,Kt),O(t,he,"true"),s?P(t,()=>zn(e)):zn(e)},Un=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(I,u)&&!It(t)?(ye(),P(I,()=>jn(e))):jn(e)},Ki=e=>{const{target:t}=e,s=t&&N(t,Mn),n=s&&z(s),o=n&&te(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Ui=({code:e,target:t})=>{const s=S(Ln,b(t)),n=s&&te(s);if(n){const{options:o}=n;o.keyboard&&e===Me&&f(s,u)&&(n.relatedTarget=null,n.hide())}},Xi=e=>{const{currentTarget:t}=e,s=t&&te(t);if(s&&t&&!p.get(t)){const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:a}=n,{target:r}=e,c=b(t)?.getSelection()?.toString().length,l=i.contains(r),d=r&&N(r,Vi);o&&!l?p.set(t,()=>{h(t,Bn),P(i,()=>qi(s))},17):(d||!c&&!o&&!l&&a)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())}},qi=e=>{const{element:t,modalDialog:s}=e,n=(Yt(s)||0)+17;m(t,Bn),p.set(t,()=>p.clear(t),n)};class hs extends et{static selector=Wi;static init=zi;static getInstance=te;constructor(t,s){super(t,s);const{element:n}=this,o=S(`.${q}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...Z(Mn,b(n))].filter(i=>z(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,B),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return is}get defaults(){return ji}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let a=0;if(!f(t,u)&&($e.relatedTarget=o||void 0,E(t,$e),!$e.defaultPrevented)){const r=It(t);if(r&&r!==t){const c=te(r)||F(r,as);c&&c.hide()}i?(rs(I)?ls(!0):On(t,n,!0),a=Yt(I),Nn(),setTimeout(()=>Kn(this),a)):(Kn(this),r&&f(I,u)&&ye())}}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,u)&&(ds.relatedTarget=n||void 0,E(t,ds),ds.defaultPrevented||(m(t,u),O(t,Kt,"true"),St(t,he),s?P(t,()=>Un(this)):Un(this)))}update=()=>{f(this.element,u)&&Wn(this)};_toggleEventListeners=t=>{const s=t?_:M,{triggers:n}=this;n.length&&n.forEach(o=>s(o,L,Ki))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?P(s,o):o()}}const Yi=`.${J}`,fs=`[${ot}="${J}"]`,Zi=`[${ve}="${J}"]`,Ce=`${J}-toggling`,Gi={backdrop:!0,keyboard:!0,scroll:!1},ee=e=>F(e,as),Ji=e=>new ps(e),Se=w(`show.bs.${J}`),Xn=w(`shown.bs.${J}`),gs=w(`hide.bs.${J}`),qn=w(`hidden.bs.${J}`),Qi=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=ct(t);Dn(t,s!==n)},Yn=(e,t)=>{const s=t?_:M,n=b(e.element);s(n,fe,na),s(n,L,sa)},Zn=e=>{const{element:t,options:s}=e;s.scroll||(Qi(e),x(ut(t),{overflow:"hidden"})),h(t,Ce),h(t,u),x(t,{visibility:"visible"}),P(t,()=>oa(e))},ta=e=>{const{element:t,options:s}=e,n=It(t);t.blur(),!n&&s.backdrop&&f(I,u)&&ye(),P(t,()=>ia(e))},ea=e=>{const t=N(e.target,fs),s=t&&z(t),n=s&&ee(s);n&&(n.relatedTarget=t,n.toggle(),t&&t.tagName==="A"&&e.preventDefault())},sa=e=>{const{target:t}=e,s=S(cs,b(t)),n=S(Zi,s),o=s&&ee(s);if(o){const{options:i,triggers:a}=o,{backdrop:r}=i,c=N(t,fs),l=b(s).getSelection();(!I.contains(t)||r!=="static")&&(!(l&&l.toString().length)&&(!s.contains(t)&&r&&(!c||a.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:null,o.hide()),c&&c.tagName==="A"&&e.preventDefault())}},na=({code:e,target:t})=>{const s=S(cs,b(t)),n=s&&ee(s);n&&n.options.keyboard&&e===Me&&(n.relatedTarget=null,n.hide())},oa=e=>{const{element:t}=e;m(t,Ce),St(t,Kt),O(t,he,"true"),O(t,"role","dialog"),E(t,Xn),Yn(e,!0),rt(t),me(t)},ia=e=>{const{element:t,triggers:s}=e;O(t,Kt,"true"),St(t,he),St(t,"role"),x(t,{visibility:""});const n=Se.relatedTarget||s.find(_n);n&&rt(n),kn(t),E(t,qn),m(t,Ce),me(t),It(t)||Yn(e)};class ps extends et{static selector=Yi;static init=Ji;static getInstance=ee;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...Z(fs,b(n))].filter(o=>z(o)===n),this.relatedTarget=null,this._toggleEventListeners(!0)}get name(){return as}get defaults(){return Gi}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(!f(t,u)&&(Se.relatedTarget=n||void 0,Xn.relatedTarget=n||void 0,E(t,Se),!Se.defaultPrevented)){const i=It(t);if(i&&i!==t){const a=ee(i)||F(i,is);a&&a.hide()}s.backdrop?(rs(I)?ls():On(t,!0),o=Yt(I),Nn(),setTimeout(()=>Zn(this),o)):(Zn(this),i&&f(I,u)&&ye())}}hide(){const{element:t,relatedTarget:s}=this;f(t,u)&&(gs.relatedTarget=s||void 0,qn.relatedTarget=s||void 0,E(t,gs),gs.defaultPrevented||(h(t,Ce),m(t,u),ta(this)))}_toggleEventListeners=t=>{const s=t?_:M;this.triggers.forEach(n=>s(n,L,ea))};dispose(){const{element:t}=this,s=f(t,u),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?P(t,n):n()}}const Lt="popover",De="Popover",ht="tooltip",Gn=e=>{const t=e===ht,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},Jn={top:"top",bottom:"bottom",left:"start",right:"end"},us=e=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,options:i,arrow:a}=e;if(n){const r={...Jn},c=mt(s);x(n,{top:"",left:"",right:"",bottom:""});const l=e.name===De,{offsetWidth:d,offsetHeight:g}=n,{clientWidth:$,clientHeight:D,offsetWidth:W}=ct(s);let{placement:v}=i;const{clientWidth:U,offsetWidth:Y}=o,ft=j(o,"position")==="fixed",C=Math.abs(ft?U-Y:$-W),nt=c&&ft?C:0,it=$-(c?0:C)-1,{width:V,height:X,left:H,right:jt,top:Tt}=Gt(s,!0),{x:k,y:yt}={x:H,y:Tt};x(a,{top:"",left:"",right:"",bottom:""});let Nt=0,ie="",$t=0,Ds="",zt="",Ae="",Hs="";const kt=a.offsetWidth||0,Ct=a.offsetHeight||0,As=kt/2;let ae=Tt-g-Ct<0,re=Tt+g+X+Ct>=D,ce=H-d-kt=it;const Pe=["left","right"],Ps=["top","bottom"];ae=Pe.includes(v)?Tt+X/2-g/2-Ct<0:ae,re=Pe.includes(v)?Tt+g/2+X/2+Ct>=D:re,ce=Ps.includes(v)?H+V/2-d/2=it:le,v=Pe.includes(v)&&ce&&le?"top":v,v=v==="top"&&ae?"bottom":v,v=v==="bottom"&&re?"top":v,v=v==="left"&&ce?"right":v,v=v==="right"&&le?"left":v,n.className.includes(v)||(n.className=n.className.replace(t,r[v])),Pe.includes(v)?(v==="left"?$t=k-d-(l?kt:0):$t=k+V+(l?kt:0),ae&&re?(Nt=0,ie=0,zt=Tt+X/2-Ct/2):ae?(Nt=yt,ie="",zt=X/2-kt):re?(Nt=yt-g+X,ie="",zt=g-X/2-kt):(Nt=yt-g/2+X/2,zt=g/2-Ct/2)):Ps.includes(v)&&(v==="top"?Nt=yt-g-(l?Ct:0):Nt=yt+X+(l?Ct:0),ce?($t=0,Ae=k+V/2-As):le?($t="auto",Ds=0,Hs=V/2+it-jt-As):($t=k-d/2+V/2,Ae=d/2-As)),x(n,{top:`${Nt}px`,bottom:ie===""?"":`${ie}px`,left:$t==="auto"?$t:`${$t}px`,right:Ds!==""?`${Ds}px`:""}),T(a)&&(zt!==""&&(a.style.top=`${zt}px`),Ae!==""?a.style.left=`${Ae}px`:Hs!==""&&(a.style.right=`${Hs}px`));const Va=w(`updated.bs.${Mt(e.name)}`);E(s,Va)}},ms={template:Gn(ht),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},aa=e=>e!=null&&typeof e=="object"||!1,ra=e=>aa(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,Qn=e=>ra(e)&&e.nodeType===1||!1,ca=e=>typeof e=="function"||!1,to="PositionObserver Error";class eo{entries;_tick;_root;_callback;constructor(t,s){if(!ca(t))throw new Error(`${to}: ${t} is not a function.`);this.entries=[],this._callback=t,this._root=Qn(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!Qn(t))throw new Error(`${to}: ${t} is not an instance of HTMLElement.`);if(!this._root.contains(t))return;const{clientWidth:s,clientHeight:n}=this._root,o=t.getBoundingClientRect(),{left:i,top:a,bottom:r,right:c,width:l,height:d}=o,g=a>1-d&&i>1-l&&r<=n+d-1&&c<=s+l-1;this.entries.push({target:t,boundingBox:o,isVisible:g}),this._tick||(this._tick=requestAnimationFrame(this._runCallback))};unobserve=t=>{const s=this.entries.findIndex(n=>n.target===t);this.entries.splice(s,1)};_runCallback=()=>{if(!this.entries.length)return;const t=[],{clientWidth:s,clientHeight:n}=this._root;this.entries.forEach((o,i)=>{const{target:a,boundingBox:r}=o,c=a.getBoundingClientRect(),{left:l,top:d,bottom:g,right:$,width:D,height:W}=c;if(r.left!==l||r.top!==d||r.right!==$||r.bottom!==g){const v=d>1-W&&l>1-D&&g<=n+W-1&&$<=s+D-1;this.entries[i].boundingBox=c,this.entries[i].isVisible=v,t.push({target:a,boundingBox:c,isVisible:v})}}),t.length&&this._callback(t),requestAnimationFrame(this._runCallback)};disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.length=0,this._tick=0}}const so="data-original-title",Ot="Tooltip",wt=(e,t,s)=>{if(qt(t)&&t.length){let n=t.trim();ti(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else T(t)?e.append(t):(ei(t)||Qo(t)&&t.every(A))&&e.append(...t)},la=e=>{const t=e.name===Ot,{id:s,element:n,options:o}=e,{title:i,placement:a,template:r,animation:c,customClass:l,sanitizeFn:d,dismissible:g,content:$,btnClose:D}=o,W=t?ht:Lt,v={...Jn};let U=[],Y=[];mt(n)&&(v.left="end",v.right="start");const Vt=`bs-${W}-${v[a]}`;let ft;if(T(r))ft=r;else{const nt=gt("div");wt(nt,r,d),ft=nt.firstChild}e.tooltip=T(ft)?ft.cloneNode(!0):void 0;const{tooltip:C}=e;if(C){O(C,"id",s),O(C,"role",ht);const nt=t?`${ht}-inner`:`${Lt}-body`,it=t?null:S(`.${Lt}-header`,C),V=S(`.${nt}`,C);e.arrow=S(`.${W}-arrow`,C);const{arrow:X}=e;if(T(i))U=[i.cloneNode(!0)];else{const H=gt("div");wt(H,i,d),U=[...H.childNodes]}if(T($))Y=[$.cloneNode(!0)];else{const H=gt("div");wt(H,$,d),Y=[...H.childNodes]}if(g)if(i)if(T(D))U=[...U,D.cloneNode(!0)];else{const H=gt("div");wt(H,D,d),U=[...U,H.firstChild]}else if(it&&it.remove(),T(D))Y=[...Y,D.cloneNode(!0)];else{const H=gt("div");wt(H,D,d),Y=[...Y,H.firstChild]}t?i&&V&&wt(V,i,d):(i&&it&&wt(it,U,d),$&&V&&wt(V,Y,d),e.btn=S(".btn-close",C)||void 0),h(C,"position-fixed"),h(X,"position-absolute"),f(C,W)||h(C,W),c&&!f(C,B)&&h(C,B),l&&!f(C,l)&&h(C,l),f(C,Vt)||h(C,Vt)}},da=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=Go(n),Fs(n)||si(n)||s.push(n);return s.find((o,i)=>j(o,"position")!=="relative"&&s.slice(i+1).every(a=>j(a,"position")==="static")?o:null)||b(e).body},ha=`[${ot}="${ht}"],[data-tip="${ht}"]`,no="title";let oo=e=>F(e,Ot);const fa=e=>new He(e),ga=e=>{const{element:t,tooltip:s,container:n,offsetParent:o}=e;St(t,xs),An(s,n===o?n:o)},se=e=>{const{tooltip:t,container:s,offsetParent:n}=e;return t&&rs(t,s===n?s:n)},pa=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),Ut(s,so)&&e.name===Ot&&lo(e),t&&t()},io=(e,t)=>{const s=t?_:M,{element:n}=e;s(b(n),Ne,e.handleTouch,Zt)},ao=e=>{const{element:t}=e,s=w(`shown.bs.${Mt(e.name)}`);io(e,!0),E(t,s),p.clear(t,"in")},ro=e=>{const{element:t}=e,s=w(`hidden.bs.${Mt(e.name)}`);io(e),ga(e),E(t,s),p.clear(t,"out")},co=(e,t)=>{const s=t?_:M,{element:n}=e,o=N(n,`.${q}`),i=N(n,`.${J}`);t?e._observer.observe(e.element):e._observer.disconnect(),o&&s(o,`hide.bs.${q}`,e.handleHide),i&&s(i,`hide.bs.${J}`,e.handleHide)},lo=(e,t)=>{const s=[so,no],{element:n}=e;O(n,s[t?0:1],t||tt(n,s[0])||""),St(n,s[t?1:0])};class He extends et{static selector=ha;static init=fa;static getInstance=oo;static styleTip=us;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===Ot,i=o?ht:Lt,a=o?Ot:De;oo=c=>F(c,a),this.enabled=!0,this.id=`${i}-${js(n,i)}`;const{options:r}=this;!r.title&&o||!o&&!r.content||(at(ms,{titleAttr:""}),Ut(n,no)&&o&&typeof r.title=="string"&&lo(this,r.title),this.container=da(n),this.offsetParent=["sticky","fixed"].some(c=>j(this.container,"position")===c)?this.container:b(this.element).body,la(this),this._observer=new eo(()=>this.update()),this._toggleEventListeners(!0))}get name(){return Ot}get defaults(){return ms}handleFocus=()=>rt(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,offsetParent:i,id:a}=this,{animation:r}=t,c=p.get(n,"out"),l=o===i?o:i;p.clear(n,"out"),s&&!c&&!se(this)&&p.set(n,()=>{const d=w(`show.bs.${Mt(this.name)}`);E(n,d),d.defaultPrevented||(Hn(s,l),O(n,xs,`#${a}`),this.update(),co(this,!0),f(s,u)||h(s,u),r?P(s,()=>ao(this)):ao(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;p.clear(n,"in"),s&&se(this)&&p.set(n,()=>{const a=w(`hide.bs.${Mt(this.name)}`);E(n,a),a.defaultPrevented||(this.update(),m(s,u),co(this),o?P(s,()=>ro(this)):ro(this))},i+17,"out")}update=()=>{us(this)};toggle=()=>{const{tooltip:t}=this;t&&!se(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&se(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?_:M,{element:n,options:o,btn:i}=this,{trigger:a}=o,c=!!(this.name!==Ot&&o.dismissible);a.includes("manual")||(this.enabled=!!t,a.split(" ").forEach(d=>{d===No?(s(n,Os,this.handleShow),s(n,ge,this.handleShow),c||(s(n,Oe,this.handleHide),s(b(n),Ne,this.handleTouch,Zt))):d===L?s(n,d,c?this.handleShow:this.toggle):d===Ie&&(s(n,Le,this.handleShow),c||s(n,Ls,this.handleHide),Vo()&&s(n,L,this.handleFocus)),c&&i&&s(i,L,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>pa(n,()=>super.dispose()),17);s.animation&&se(n)?(this.options.delay=0,this.hide(),P(t,o)):o()}}const ua=`[${ot}="${Lt}"],[data-tip="${Lt}"]`,ma=at({},ms,{template:Gn(Lt),content:"",dismissible:!1,btnClose:''}),va=e=>F(e,De),ba=e=>new vs(e);class vs extends He{static selector=ua;static init=ba;static getInstance=va;static styleTip=us;constructor(t,s){super(t,s)}get name(){return De}get defaults(){return ma}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>rt(s),17)}}const Ea="scrollspy",ho="ScrollSpy",wa='[data-bs-spy="scroll"]',Ta={offset:10,target:null},ya=e=>F(e,ho),$a=e=>new bs(e),fo=w(`activate.bs.${Ea}`),Ca=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:a}=e,{offset:r}=n,c=s!==a,l=t&&We("A",t),d=b(a),g=s.scrollHeight;if(e.scrollTop=s.scrollTop,l&&(g!==i||o!==l.length)){let $,D,W;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=g,e.maxScroll=e.scrollHeight-Da(e),Array.from(l).forEach(v=>{$=tt(v,"href"),D=$&&$.charAt(0)==="#"&&$.slice(-1)!=="#"&&S($,d),D&&(e.items.push(v),e.targets.push(D),W=Gt(D),e.offsets.push((c?W.top+e.scrollTop:D.offsetTop)-r))}),e.itemsLength=e.items.length}},go=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},Sa=e=>e.scrollHeight,Da=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:Gt(e).height,po=e=>{[...We("A",e)].forEach(t=>{f(t,y)&&m(t,y)})},uo=(e,t)=>{const{target:s,element:n}=e;T(s)&&po(s),e.activeItem=t,h(t,y);const o=[];let i=t;for(;i!==ut(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(a=>{const r=a.previousElementSibling;r&&!f(r,y)&&h(r,y)}),fo.relatedTarget=t,E(n,fo)};class bs extends et{static selector=wa;static init=$a;static getInstance=ya;constructor(t,s){super(t,s);const{element:n,options:o}=this;this.target=S(o.target,b(n)),this.target&&(this.scrollTarget=n.clientHeightthis.refresh(),{root:this.scrollTarget}),go(this,!0))}get name(){return ho}get defaults(){return Ta}refresh=()=>{const{target:t}=this;if(T(t)&&t.offsetHeight>0){Ca(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:a}=this;if(s>=n){const c=i[o-1];a!==c&&uo(this,c);return}const{offsets:r}=this;if(a&&s0){this.activeItem=null,t&&po(t);return}i.forEach((c,l)=>{a!==c&&s>=r[l]&&(typeof r[l+1]>"u"||sF(e,mo),Ha=e=>new Ts(e),Es=w(`show.bs.${ne}`),Eo=w(`shown.bs.${ne}`),ws=w(`hide.bs.${ne}`),wo=w(`hidden.bs.${ne}`),oe=new Map,To=e=>{const{tabContent:t,nav:s}=e;t&&f(t,Pt)&&(t.style.height="",m(t,Pt)),s&&p.clear(s)},yo=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=T(o)&&oe.get(o)||{tab:null};if(s&&n&&f(n,B)){const{currentHeight:a,nextHeight:r}=oe.get(t)||{currentHeight:0,nextHeight:0};a!==r?setTimeout(()=>{s.style.height=`${r}px`,Ht(s),P(s,()=>To(e))},50):To(e)}else o&&p.clear(o);Eo.relatedTarget=i,E(t,Eo)},$o=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:a}=o&&oe.get(o)||{tab:null,content:null};let r=0;if(n&&s&&f(s,B)&&([a,s].forEach(c=>{T(c)&&h(c,"overflow-hidden")}),r=T(a)?a.scrollHeight:0),Es.relatedTarget=i,wo.relatedTarget=t,E(t,Es),!Es.defaultPrevented){if(s&&h(s,y),a&&m(a,y),n&&s&&f(s,B)){const c=s.scrollHeight;oe.set(t,{currentHeight:r,nextHeight:c,tab:null,content:null}),h(n,Pt),n.style.height=`${r}px`,Ht(n),[a,s].forEach(l=>{l&&m(l,"overflow-hidden")})}s&&s&&f(s,B)?setTimeout(()=>{h(s,u),P(s,()=>{yo(e)})},1):(s&&h(s,u),yo(e)),i&&E(i,wo)}},Co=e=>{const{nav:t}=e;if(!T(t))return{tab:null,content:null};const s=lt(y,t);let n=null;s.length===1&&!xt.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=T(n)?z(n):null;return{tab:n,content:o}},So=e=>{if(!T(e))return null;const t=N(e,`.${xt.join(",.")}`);return t?S(`.${xt[0]}-toggle`,t):null},Aa=e=>{const t=bo(e.target);t&&(e.preventDefault(),t.show())};class Ts extends et{static selector=vo;static init=Ha;static getInstance=bo;constructor(t){super(t);const{element:s}=this,n=z(s);if(n){const o=N(s,".nav"),i=N(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=So(s);const{tab:a}=Co(this);if(o&&!a){const r=S(vo,o),c=r&&z(r);c&&(h(r,y),h(c,u),h(c,y),O(s,xe,"true"))}this._toggleEventListeners(!0)}}get name(){return mo}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(!(n&&p.get(n))&&!f(t,y)){const{tab:i,content:a}=Co(this);if(n&&oe.set(n,{tab:i,content:a,currentHeight:0,nextHeight:0}),ws.relatedTarget=t,T(i)&&(E(i,ws),!ws.defaultPrevented)){h(t,y),O(t,xe,"true");const r=T(i)&&So(i);if(r&&f(r,y)&&m(r,y),n){const c=()=>{i&&(m(i,y),O(i,xe,"false")),o&&!f(o,y)&&h(o,y)};a&&(f(a,B)||s&&f(s,B))?p.set(n,c,1):c()}a&&(m(a,u),f(a,B)?P(a,()=>$o(this)):$o(this))}}}_toggleEventListeners=t=>{(t?_:M)(this.element,L,Aa)};dispose(){this._toggleEventListeners(),super.dispose()}}const Q="toast",Do="Toast",Pa=`.${Q}`,xa=`[${ve}="${Q}"]`,Ho=`[${ot}="${Q}"]`,Wt="showing",Ao="hide",Ia={animation:!0,autohide:!0,delay:5e3},ys=e=>F(e,Do),La=e=>new $s(e),Po=w(`show.bs.${Q}`),Oa=w(`shown.bs.${Q}`),xo=w(`hide.bs.${Q}`),Na=w(`hidden.bs.${Q}`),Io=e=>{const{element:t,options:s}=e;m(t,Wt),p.clear(t,Wt),E(t,Oa),s.autohide&&p.set(t,()=>e.hide(),s.delay,Q)},Lo=e=>{const{element:t}=e;m(t,Wt),m(t,u),h(t,Ao),p.clear(t,Q),E(t,Na)},ka=e=>{const{element:t,options:s}=e;h(t,Wt),s.animation?(Ht(t),P(t,()=>Lo(e))):Lo(e)},_a=e=>{const{element:t,options:s}=e;p.set(t,()=>{m(t,Ao),Ht(t),h(t,u),h(t,Wt),s.animation?P(t,()=>Io(e)):Io(e)},17,Wt)},Ma=e=>{const{target:t}=e,s=t&&N(t,Ho),n=s&&z(s),o=n&&ys(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},Ba=e=>{const t=e.target,s=ys(t),{type:n,relatedTarget:o}=e;s&&t!==o&&!t.contains(o)&&([ge,Le].includes(n)?p.clear(t,Q):p.set(t,()=>s.hide(),s.options.delay,Q))};class $s extends et{static selector=Pa;static init=La;static getInstance=ys;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,B)?h(n,B):!o.animation&&f(n,B)&&m(n,B),this.dismiss=S(xa,n),this.triggers=[...Z(Ho,b(n))].filter(i=>z(i)===n),this._toggleEventListeners(!0)}get name(){return Do}get defaults(){return Ia}get isShown(){return f(this.element,u)}show=()=>{const{element:t,isShown:s}=this;t&&!s&&(E(t,Po),Po.defaultPrevented||_a(this))};hide=()=>{const{element:t,isShown:s}=this;t&&s&&(E(t,xo),xo.defaultPrevented||ka(this))};_toggleEventListeners=t=>{const s=t?_:M,{element:n,triggers:o,dismiss:i,options:a,hide:r}=this;i&&s(i,L,r),a.autohide&&[Le,Ls,ge,Oe].forEach(c=>s(n,c,Ba)),o.length&&o.forEach(c=>s(c,L,Ma))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),p.clear(t,Q),s&&m(t,u),super.dispose()}}const Cs=new Map;[Ve,je,Ge,Je,os,hs,ps,vs,bs,Ts,$s,He].forEach(e=>Cs.set(e.prototype.name,e));const Ra=(e,t)=>{[...t].forEach(s=>e(s))},Fa=(e,t)=>{const s=Dt.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},Ss=e=>{const t=e&&e.nodeName?e:document,s=[...We("*",t)];Cs.forEach(n=>{const{init:o,selector:i}=n;Ra(o,s.filter(a=>Ks(a,i)))})},Wa=e=>{const t=e&&e.nodeName?e:document;Cs.forEach(s=>{Fa(s.prototype.name,t)})};return document.body?Ss():_(document,"DOMContentLoaded",()=>Ss(),{once:!0}),R.Alert=Ve,R.Button=je,R.Carousel=Ge,R.Collapse=Je,R.Dropdown=os,R.Modal=hs,R.Offcanvas=ps,R.Popover=vs,R.ScrollSpy=bs,R.Tab=Ts,R.Toast=$s,R.Tooltip=He,R.initCallback=Ss,R.removeDataAPI=Wa,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"}),R}({}); +var BSN=function(R){"use strict";const Ls="aria-describedby",fe="aria-expanded",Yt="aria-hidden",ge="aria-modal",_s="aria-pressed",Ie="aria-selected",Le="focus",_e="focusin",Os="focusout",ue="keydown",Ro="keyup",k="click",Ns="mousedown",Bo="hover",pe="mouseenter",Oe="mouseleave",Fo="pointerdown",Wo="pointermove",jo="pointerup",Ne="touchstart",zo="dragstart",Vo='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"]',Me="ArrowDown",Re="ArrowUp",Ms="ArrowLeft",Rs="ArrowRight",Be="Escape",Ko="transitionDuration",qo="transitionDelay",Fe="transitionend",Bs="transitionProperty",Xo=()=>{const e=/(iPhone|iPod|iPad)/;return navigator?.userAgentData?.brands.some(t=>e.test(t.brand))||e.test(navigator?.userAgent)||!1},me=()=>{},Yo=(e,t,s,n)=>{const o=n||!1;e.addEventListener(t,s,o)},Uo=(e,t,s,n)=>{const o=n||!1;e.removeEventListener(t,s,o)},tt=(e,t)=>e.getAttribute(t),Ut=(e,t)=>e.hasAttribute(t),I=(e,t,s)=>e.setAttribute(t,s),Ct=(e,t)=>e.removeAttribute(t),h=(e,...t)=>{e.classList.add(...t)},v=(e,...t)=>{e.classList.remove(...t)},f=(e,t)=>e.classList.contains(t),Gt=e=>e!=null&&typeof e=="object"||!1,D=e=>Gt(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,U=e=>D(e)&&e.nodeType===1||!1,Rt=new Map,St={data:Rt,set:(e,t,s)=>{U(e)&&(Rt.has(t)||Rt.set(t,new Map),Rt.get(t).set(e,s))},getAllFor:e=>Rt.get(e)||null,get:(e,t)=>{if(!U(e)||!t)return null;const s=St.getAllFor(t);return e&&s&&s.get(e)||null},remove:(e,t)=>{const s=St.getAllFor(t);!s||!U(e)||(s.delete(e),s.size===0&&Rt.delete(t))}},F=(e,t)=>St.get(e,t),Zt=e=>typeof e=="string"||!1,Fs=e=>Gt(e)&&e.constructor.name==="Window"||!1,Ws=e=>D(e)&&e.nodeType===9||!1,w=e=>Ws(e)?e:D(e)?e.ownerDocument:Fs(e)?e.document:globalThis.document,it=(e,...t)=>Object.assign(e,...t),ft=e=>{if(!e)return;if(Zt(e))return w().createElement(e);const{tagName:t}=e,s=ft(t);if(!s)return;const n={...e};return delete n.tagName,it(s,n)},b=(e,t)=>e.dispatchEvent(t),W=(e,t,s)=>{const n=getComputedStyle(e,s),o=t.replace("webkit","Webkit").replace(/([A-Z])/g,"-$1").toLowerCase();return n.getPropertyValue(o)},Go=e=>{const t=W(e,Bs),s=W(e,qo),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},Qt=e=>{const t=W(e,Bs),s=W(e,Ko),n=s.includes("ms")?1:1e3,o=t&&t!=="none"?parseFloat(s)*n:0;return Number.isNaN(o)?0:o},H=(e,t)=>{let s=0;const n=new Event(Fe),o=Qt(e),i=Go(e);if(o){const r=c=>{c.target===e&&(t.apply(e,[c]),e.removeEventListener(Fe,r),s=1)};e.addEventListener(Fe,r),setTimeout(()=>{s||b(e,n)},o+i+17)}else t.apply(e,[n])},rt=(e,t)=>e.focus(t),js=e=>["true",!0].includes(e)?!0:["false",!1].includes(e)?!1:["null","",null,void 0].includes(e)?null:e!==""&&!Number.isNaN(+e)?+e:e,ve=e=>Object.entries(e),Bt=e=>e.toLowerCase(),Zo=(e,t,s,n)=>{if(!U(e))return t;const o={...s},i={...e.dataset},r={...t},c={},a="title";return ve(i).forEach(([l,d])=>{const p=typeof l=="string"&&l.includes(n)?l.replace(n,"").replace(/[A-Z]/g,T=>Bt(T)):l;c[p]=js(d)}),ve(o).forEach(([l,d])=>{o[l]=js(d)}),ve(t).forEach(([l,d])=>{l in o?r[l]=o[l]:l in c?r[l]=c[l]:r[l]=l===a?tt(e,a):d}),r},zs=e=>Object.keys(e),E=(e,t)=>{const s=new CustomEvent(e,{cancelable:!0,bubbles:!0});return Gt(t)&&it(s,t),s},Jt={passive:!0},Ht=e=>e.offsetHeight,x=(e,t)=>{ve(t).forEach(([s,n])=>{if(n&&Zt(s)&&s.includes("--"))e.style.setProperty(s,n);else{const o={};o[s]=n,it(e.style,o)}})},We=e=>Gt(e)&&e.constructor.name==="Map"||!1,Qo=e=>typeof e=="number"||!1,gt=new Map,g={set:(e,t,s,n)=>{U(e)&&(n&&n.length?(gt.has(e)||gt.set(e,new Map),gt.get(e).set(n,setTimeout(t,s))):gt.set(e,setTimeout(t,s)))},get:(e,t)=>{if(!U(e))return null;const s=gt.get(e);return t&&s&&We(s)?s.get(t)||null:Qo(s)?s:null},clear:(e,t)=>{if(!U(e))return;const s=gt.get(e);t&&t.length&&We(s)?(clearTimeout(s.get(t)),s.delete(t),s.size===0&>.delete(e)):(clearTimeout(s),gt.delete(e))}},G=(e,t)=>(D(t)?t:w()).querySelectorAll(e),je=new Map;function Jo(e){const{shiftKey:t,code:s}=e,n=w(this),o=[...G(Vo,this)].filter(c=>!Ut(c,"disabled")&&!tt(c,Yt));if(!o.length)return;const i=o[0],r=o[o.length-1];s==="Tab"&&(t&&n.activeElement===i?(r.focus(),e.preventDefault()):!t&&n.activeElement===r&&(i.focus(),e.preventDefault()))}const ti=e=>je.has(e)===!0,be=e=>{const t=ti(e);(t?Uo:Yo)(e,"keydown",Jo),t?je.delete(e):je.set(e,!0)},C=e=>U(e)&&"offsetWidth"in e||!1,ut=(e,t)=>{const{width:s,height:n,top:o,right:i,bottom:r,left:c}=e.getBoundingClientRect();let a=1,l=1;if(t&&C(e)){const{offsetWidth:d,offsetHeight:p}=e;a=d>0?Math.round(s)/d:1,l=p>0?Math.round(n)/p:1}return{width:s/a,height:n/l,top:o/l,right:i/a,bottom:r/l,left:c/a,x:c/a,y:o/l}},pt=e=>w(e).body,ct=e=>w(e).documentElement,ei=e=>{const t=Fs(e),s=t?e.scrollX:e.scrollLeft,n=t?e.scrollY:e.scrollTop;return{x:s,y:n}},Vs=e=>D(e)&&e.constructor.name==="ShadowRoot"||!1,si=e=>e.nodeName==="HTML"?e:U(e)&&e.assignedSlot||D(e)&&e.parentNode||Vs(e)&&e.host||ct(e),Ks=e=>e?Ws(e)?e.defaultView:D(e)?e?.ownerDocument?.defaultView:e:window,ni=e=>D(e)&&["TABLE","TD","TH"].includes(e.nodeName)||!1,qs=(e,t)=>e.matches(t),oi=e=>{if(!C(e))return!1;const{width:t,height:s}=ut(e),{offsetWidth:n,offsetHeight:o}=e;return Math.round(t)!==n||Math.round(s)!==o},ii=(e,t,s)=>{const n=C(t),o=ut(e,n&&oi(t)),i={x:0,y:0};if(n){const r=ut(t,!0);i.x=r.x+t.clientLeft,i.y=r.y+t.clientTop}return{x:o.left+s.x-i.x,y:o.top+s.y-i.y,width:o.width,height:o.height}};let Xs=0,Ys=0;const Ft=new Map,Us=(e,t)=>{let s=t?Xs:Ys;if(t){const n=Us(e),o=Ft.get(n)||new Map;Ft.has(n)||Ft.set(n,o),We(o)&&!o.has(t)?(o.set(t,s),Xs+=1):s=o.get(t)}else{const n=e.id||e;Ft.has(n)?s=Ft.get(n):(Ft.set(n,s),Ys+=1)}return s},ri=e=>Array.isArray(e)||!1,Gs=e=>{if(!D(e))return!1;const{top:t,bottom:s}=ut(e),{clientHeight:n}=ct(e);return t<=n&&s>=0},ci=e=>typeof e=="function"||!1,ai=e=>Gt(e)&&e.constructor.name==="NodeList"||!1,mt=e=>ct(e).dir==="rtl",L=(e,t)=>!e||!t?null:e.closest(t)||L(e.getRootNode().host,t)||null,P=(e,t)=>U(e)?e:(U(t)?t:w()).querySelector(e),ze=(e,t)=>(D(t)?t:w()).getElementsByTagName(e),at=(e,t)=>(t&&D(t)?t:w()).getElementsByClassName(e),Wt={},Zs=e=>{const{type:t,currentTarget:s}=e;Wt[t].forEach((n,o)=>{s===o&&n.forEach((i,r)=>{r.apply(o,[e]),typeof i=="object"&&i.once&&N(o,t,r,i)})})},O=(e,t,s,n)=>{Wt[t]||(Wt[t]=new Map);const o=Wt[t];o.has(e)||o.set(e,new Map);const i=o.get(e),{size:r}=i;i.set(s,n),r||e.addEventListener(t,Zs,n)},N=(e,t,s,n)=>{const o=Wt[t],i=o&&o.get(e),r=i&&i.get(s),c=r!==void 0?r:n;i&&i.has(s)&&i.delete(s),o&&(!i||!i.size)&&o.delete(e),(!o||!o.size)&&delete Wt[t],(!i||!i.size)&&e.removeEventListener(t,Zs,c)},M="fade",u="show",we="data-bs-dismiss",Ee="alert",Qs="Alert",li="5.1.0";class et{constructor(t,s){let n;try{if(U(t))n=t;else if(Zt(t)){if(n=P(t),!n)throw Error(`"${t}" is not a valid selector.`)}else throw Error("your target is not an instance of HTMLElement.")}catch(i){throw Error(`${this.name} Error: ${i.message}`)}const o=St.get(n,this.name);o&&o._toggleEventListeners(),this.element=n,this.options=this.defaults&&zs(this.defaults).length?Zo(n,this.defaults,s||{},"bs"):{},St.set(n,this.name,this)}get version(){return li}get name(){return"BaseComponent"}get defaults(){return{}}_toggleEventListeners=()=>{};dispose(){St.remove(this.element,this.name),zs(this).forEach(t=>{delete this[t]})}}const di=`.${Ee}`,hi=`[${we}="${Ee}"]`,fi=e=>F(e,Qs),gi=e=>new Ve(e),Js=E(`close.bs.${Ee}`),ui=E(`closed.bs.${Ee}`),tn=e=>{const{element:t}=e;b(t,ui),e._toggleEventListeners(),e.dispose(),t.remove()};class Ve extends et{static selector=di;static init=gi;static getInstance=fi;dismiss;constructor(t){super(t),this.dismiss=P(hi,this.element),this._toggleEventListeners(!0)}get name(){return Qs}close=()=>{const{element:t}=this;t&&f(t,u)&&(b(t,Js),Js.defaultPrevented||(v(t,u),f(t,M)?H(t,()=>tn(this)):tn(this)))};_toggleEventListeners=t=>{const s=t?O:N,{dismiss:n,close:o}=this;n&&s(n,k,o)};dispose(){this._toggleEventListeners(),super.dispose()}}const $="active",ot="data-bs-toggle",pi="button",en="Button",mi=`[${ot}="${pi}"]`,vi=e=>F(e,en),bi=e=>new Ke(e);class Ke extends et{static selector=mi;static init=bi;static getInstance=vi;constructor(t){super(t);const{element:s}=this;this.isActive=f(s,$),I(s,_s,String(!!this.isActive)),this._toggleEventListeners(!0)}get name(){return en}toggle=t=>{t&&t.preventDefault();const{element:s,isActive:n}=this;!f(s,"disabled")&&!tt(s,"disabled")&&((n?v:h)(s,$),I(s,_s,n?"false":"true"),this.isActive=f(s,$))};_toggleEventListeners=t=>{(t?O:N)(this.element,k,this.toggle)};dispose(){this._toggleEventListeners(),super.dispose()}}const qe="data-bs-target",xt="carousel",sn="Carousel",nn="data-bs-parent",wi="data-bs-container",V=e=>{const t=[qe,nn,wi,"href"],s=w(e);return t.map(n=>{const o=tt(e,n);return o?n===nn?L(e,o):P(o,s):null}).filter(n=>n)[0]},te=`[data-bs-ride="${xt}"]`,Z=`${xt}-item`,Xe="data-bs-slide-to",vt="data-bs-slide",bt="paused",on={pause:"hover",keyboard:!1,touch:!0,interval:5e3},lt=e=>F(e,sn),Ei=e=>new Je(e);let ee=0,Te=0,Ye=0;const Ue=E(`slide.bs.${xt}`),Ge=E(`slid.bs.${xt}`),rn=e=>{const{index:t,direction:s,element:n,slides:o,options:i}=e;if(e.isAnimating){const r=Qe(e),c=s==="left"?"next":"prev",a=s==="left"?"start":"end";h(o[t],$),v(o[t],`${Z}-${c}`),v(o[t],`${Z}-${a}`),v(o[r],$),v(o[r],`${Z}-${a}`),b(n,Ge),g.clear(n,vt),e.cycle&&!w(n).hidden&&i.interval&&!e.isPaused&&e.cycle()}};function Ti(){const e=lt(this);e&&!e.isPaused&&!g.get(this,bt)&&h(this,bt)}function $i(){const e=lt(this);e&&e.isPaused&&!g.get(this,bt)&&e.cycle()}function yi(e){e.preventDefault();const t=L(this,te)||V(this),s=lt(t);if(s&&!s.isAnimating){const n=+(tt(this,Xe)||0);this&&!f(this,$)&&!Number.isNaN(n)&&s.to(n)}}function Ci(e){e.preventDefault();const t=L(this,te)||V(this),s=lt(t);if(s&&!s.isAnimating){const n=tt(this,vt);n==="next"?s.next():n==="prev"&&s.prev()}}const Si=({code:e,target:t})=>{const s=w(t),[n]=[...G(te,s)].filter(i=>Gs(i)),o=lt(n);if(o&&!o.isAnimating&&!/textarea|input/i.test(t.nodeName)){const i=mt(n);e===(i?Rs:Ms)?o.prev():e===(i?Ms:Rs)&&o.next()}};function cn(e){const{target:t}=e,s=lt(this);s&&s.isTouch&&(s.indicator&&!s.indicator.contains(t)||!s.controls.includes(t))&&(e.stopImmediatePropagation(),e.stopPropagation(),e.preventDefault())}function Hi(e){const{target:t}=e,s=lt(this);if(s&&!s.isAnimating&&!s.isTouch){const{controls:n,indicators:o}=s;[...n,...o].every(i=>i===t||i.contains(t))||(ee=e.pageX,this.contains(t)&&(s.isTouch=!0,an(s,!0)))}}const xi=e=>{Te=e.pageX},Pi=e=>{const{target:t}=e,s=w(t),n=[...G(te,s)].map(o=>lt(o)).find(o=>o.isTouch);if(n){const{element:o,index:i}=n,r=mt(o);Ye=e.pageX,n.isTouch=!1,an(n),!s.getSelection()?.toString().length&&o.contains(t)&&Math.abs(ee-Ye)>120&&(Teee&&n.to(i+(r?1:-1))),ee=0,Te=0,Ye=0}},Ze=(e,t)=>{const{indicators:s}=e;[...s].forEach(n=>v(n,$)),e.indicators[t]&&h(s[t],$)},an=(e,t)=>{const{element:s}=e,n=t?O:N;n(w(s),Wo,xi,Jt),n(w(s),jo,Pi,Jt)},Qe=e=>{const{slides:t,element:s}=e,n=P(`.${Z}.${$}`,s);return C(n)?[...t].indexOf(n):-1};class Je extends et{static selector=te;static init=Ei;static getInstance=lt;constructor(t,s){super(t,s);const{element:n}=this;this.direction=mt(n)?"right":"left",this.isTouch=!1,this.slides=at(Z,n);const{slides:o}=this;if(o.length>=2){const i=Qe(this),r=[...o].find(l=>qs(l,`.${Z}-next,.${Z}-next`));this.index=i;const c=w(n);this.controls=[...G(`[${vt}]`,n),...G(`[${vt}][${qe}="#${n.id}"]`,c)].filter((l,d,p)=>d===p.indexOf(l)),this.indicator=P(`.${xt}-indicators`,n),this.indicators=[...this.indicator?G(`[${Xe}]`,this.indicator):[],...G(`[${Xe}][${qe}="#${n.id}"]`,c)].filter((l,d,p)=>d===p.indexOf(l));const{options:a}=this;this.options.interval=a.interval===!0?on.interval:a.interval,r?this.index=[...o].indexOf(r):i<0&&(this.index=0,h(o[0],$),this.indicators.length&&Ze(this,0)),this.indicators.length&&Ze(this,this.index),this._toggleEventListeners(!0),a.interval&&this.cycle()}}get name(){return sn}get defaults(){return on}get isPaused(){return f(this.element,bt)}get isAnimating(){return P(`.${Z}-next,.${Z}-prev`,this.element)!==null}cycle(){const{element:t,options:s,isPaused:n,index:o}=this;g.clear(t,xt),n&&(g.clear(t,bt),v(t,bt)),g.set(t,()=>{this.element&&!this.isPaused&&!this.isTouch&&Gs(t)&&this.to(o+1)},s.interval,xt)}pause(){const{element:t,options:s}=this;!this.isPaused&&s.interval&&(h(t,bt),g.set(t,()=>{},1,bt))}next(){this.isAnimating||this.to(this.index+1)}prev(){this.isAnimating||this.to(this.index-1)}to(t){const{element:s,slides:n,options:o}=this,i=Qe(this),r=mt(s);let c=t;if(!this.isAnimating&&i!==c&&!g.get(s,vt)){ic||i===n.length-1&&c===0)&&(this.direction=r?"left":"right");const{direction:a}=this;c<0?c=n.length-1:c>=n.length&&(c=0);const l=a==="left"?"next":"prev",d=a==="left"?"start":"end",p={relatedTarget:n[c],from:i,to:c,direction:a};it(Ue,p),it(Ge,p),b(s,Ue),Ue.defaultPrevented||(this.index=c,Ze(this,c),Qt(n[c])&&f(s,"slide")?g.set(s,()=>{h(n[c],`${Z}-${l}`),Ht(n[c]),h(n[c],`${Z}-${d}`),h(n[i],`${Z}-${d}`),H(n[c],()=>this.slides&&this.slides.length&&rn(this))},0,vt):(h(n[c],$),v(n[i],$),g.set(s,()=>{g.clear(s,vt),s&&o.interval&&!this.isPaused&&this.cycle(),b(s,Ge)},0,vt)))}}_toggleEventListeners=t=>{const{element:s,options:n,slides:o,controls:i,indicators:r}=this,{touch:c,pause:a,interval:l,keyboard:d}=n,p=t?O:N;a&&l&&(p(s,pe,Ti),p(s,Oe,$i)),c&&o.length>2&&(p(s,Fo,Hi,Jt),p(s,Ne,cn,{passive:!1}),p(s,zo,cn,{passive:!1})),i.length&&i.forEach(T=>{T&&p(T,k,Ci)}),r.length&&r.forEach(T=>{p(T,k,yi)}),d&&p(w(s),ue,Si)};dispose(){const{isAnimating:t}=this,s={...this,isAnimating:t};this._toggleEventListeners(),super.dispose(),s.isAnimating&&H(s.slides[s.index],()=>{rn(s)})}}const Pt="collapsing",K="collapse",ln="Collapse",Di=`.${K}`,dn=`[${ot}="${K}"]`,Ai={parent:null},$e=e=>F(e,ln),ki=e=>new ts(e),hn=E(`show.bs.${K}`),Ii=E(`shown.bs.${K}`),fn=E(`hide.bs.${K}`),Li=E(`hidden.bs.${K}`),_i=e=>{const{element:t,parent:s,triggers:n}=e;b(t,hn),hn.defaultPrevented||(g.set(t,me,17),s&&g.set(s,me,17),h(t,Pt),v(t,K),x(t,{height:`${t.scrollHeight}px`}),H(t,()=>{g.clear(t),s&&g.clear(s),n.forEach(o=>I(o,fe,"true")),v(t,Pt),h(t,K),h(t,u),x(t,{height:""}),b(t,Ii)}))},gn=e=>{const{element:t,parent:s,triggers:n}=e;b(t,fn),fn.defaultPrevented||(g.set(t,me,17),s&&g.set(s,me,17),x(t,{height:`${t.scrollHeight}px`}),v(t,K),v(t,u),h(t,Pt),Ht(t),x(t,{height:"0px"}),H(t,()=>{g.clear(t),s&&g.clear(s),n.forEach(o=>I(o,fe,"false")),v(t,Pt),h(t,K),x(t,{height:""}),b(t,Li)}))},Oi=e=>{const{target:t}=e,s=t&&L(t,dn),n=s&&V(s),o=n&&$e(n);o&&o.toggle(),s&&s.tagName==="A"&&e.preventDefault()};class ts extends et{static selector=Di;static init=ki;static getInstance=$e;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=w(n);this.triggers=[...G(dn,i)].filter(r=>V(r)===n),this.parent=C(o.parent)?o.parent:Zt(o.parent)?V(n)||P(o.parent,i):null,this._toggleEventListeners(!0)}get name(){return ln}get defaults(){return Ai}hide(){const{triggers:t,element:s}=this;g.get(s)||(gn(this),t.length&&t.forEach(n=>h(n,`${K}d`)))}show(){const{element:t,parent:s,triggers:n}=this;let o,i;s&&(o=[...G(`.${K}.${u}`,s)].find(r=>$e(r)),i=o&&$e(o)),(!s||!g.get(s))&&!g.get(t)&&(i&&o!==t&&(gn(i),i.triggers.forEach(r=>{h(r,`${K}d`)})),_i(this),n.length&&n.forEach(r=>v(r,`${K}d`)))}toggle(){f(this.element,u)?this.hide():this.show()}_toggleEventListeners=t=>{const s=t?O:N,{triggers:n}=this;n.length&&n.forEach(o=>s(o,k,Oi))};dispose(){this._toggleEventListeners(),super.dispose()}}const Dt=["dropdown","dropup","dropstart","dropend"],un="Dropdown",pn="dropdown-menu",mn=e=>{const t=L(e,"A");return e.tagName==="A"&&Ut(e,"href")&&tt(e,"href").slice(-1)==="#"||t&&Ut(t,"href")&&tt(t,"href").slice(-1)==="#"},[st,es,ss,ns]=Dt,vn=`[${ot}="${st}"]`,jt=e=>F(e,un),Ni=e=>new rs(e),Mi=`${pn}-end`,bn=[st,es],wn=[ss,ns],En=["A","BUTTON"],Ri={offset:5,display:"dynamic"},os=E(`show.bs.${st}`),Tn=E(`shown.bs.${st}`),is=E(`hide.bs.${st}`),$n=E(`hidden.bs.${st}`),yn=E(`updated.bs.${st}`),Cn=e=>{const{element:t,menu:s,parentElement:n,options:o}=e,{offset:i}=o;if(W(s,"position")!=="static"){const r=mt(t),c=f(s,Mi);["margin","top","bottom","left","right"].forEach(z=>{const Ot={};Ot[z]="",x(s,Ot)});let l=Dt.find(z=>f(n,z))||st;const d={dropdown:[i,0,0],dropup:[0,0,i],dropstart:r?[-1,0,0,i]:[-1,i,0],dropend:r?[-1,i,0]:[-1,0,0,i]},p={dropdown:{top:"100%"},dropup:{top:"auto",bottom:"100%"},dropstart:r?{left:"100%",right:"auto"}:{left:"auto",right:"100%"},dropend:r?{left:"auto",right:"100%"}:{left:"100%",right:"auto"},menuStart:r?{right:"0",left:"auto"}:{right:"auto",left:"0"},menuEnd:r?{right:"auto",left:"0"}:{right:"0",left:"auto"}},{offsetWidth:T,offsetHeight:_}=s,{clientWidth:q,clientHeight:j}=ct(t),{left:m,top:B,width:Lt,height:_t}=ut(t),S=m-T-i<0,Tt=m+T+Lt+i>=q,ht=B+_+i>=j,nt=B+_+_t+i>=j,Vt=B-_-i<0,y=(!r&&c||r&&!c)&&m+Lt-T<0,X=(r&&c||!r&&!c)&&m+T>=q;if(wn.includes(l)&&S&&Tt&&(l=st),l===ss&&(r?Tt:S)&&(l=ns),l===ns&&(r?S:Tt)&&(l=ss),l===es&&Vt&&!nt&&(l=st),l===st&&nt&&!Vt&&(l=es),wn.includes(l)&&ht&&it(p[l],{top:"auto",bottom:0}),bn.includes(l)&&(y||X)){let z={left:"auto",right:"auto"};!y&&X&&!r&&(z={left:"auto",right:0}),y&&!X&&r&&(z={left:0,right:"auto"}),z&&it(p[l],z)}const Kt=d[l];x(s,{...p[l],margin:`${Kt.map(z=>z&&`${z}px`).join(" ")}`}),bn.includes(l)&&c&&c&&x(s,p[!r&&y||r&&X?"menuStart":"menuEnd"]),b(n,yn)}},Bi=e=>Array.from(e.children).map(t=>{if(t&&En.includes(t.tagName))return t;const{firstElementChild:s}=t;return s&&En.includes(s.tagName)?s:null}).filter(t=>t),Sn=e=>{const{element:t,options:s,menu:n}=e,o=e.open?O:N,i=w(t);o(i,k,Hn),o(i,Le,Hn),o(i,ue,Wi),o(i,Ro,ji),s.display==="dynamic"&&(e.open?e._observer.observe(n):e._observer.disconnect())},ye=e=>{const t=[...Dt,"btn-group","input-group"].map(s=>at(`${s} ${u}`,w(e))).find(s=>s.length);if(t&&t.length)return[...t[0].children].find(s=>Dt.some(n=>n===tt(s,ot)))},Hn=e=>{const{target:t,type:s}=e;if(!C(t))return;const n=ye(t),o=n&&jt(n);if(!o)return;const{parentElement:i,menu:r}=o,c=i&&i.contains(t)&&(t.tagName==="form"||L(t,"form")!==null);[k,Ns].includes(s)&&mn(t)&&e.preventDefault(),!c&&s!==Le&&t!==n&&t!==r&&o.hide()},Fi=e=>{const{target:t}=e,s=t&&L(t,vn),n=s&&jt(s);n&&(e.stopPropagation(),n.toggle(),s&&mn(s)&&e.preventDefault())},Wi=e=>{[Me,Re].includes(e.code)&&e.preventDefault()};function ji(e){const{code:t}=e,s=ye(this);if(!s)return;const n=jt(s),{activeElement:o}=w(s);if(!n||!o)return;const{menu:i,open:r}=n,c=Bi(i);if(c&&c.length&&[Me,Re].includes(t)){let a=c.indexOf(o);o===s?a=0:t===Re?a=a>1?a-1:0:t===Me&&(a=azi(i.target),{threshold:1}),this._toggleEventListeners(!0))}get name(){return un}get defaults(){return Ri}toggle(){this.open?this.hide():this.show()}show(){const{element:t,open:s,menu:n,parentElement:o}=this;if(s)return;const i=ye(t),r=i&&jt(i);r&&r.hide(),[os,Tn,yn].forEach(c=>{c.relatedTarget=t}),b(o,os),!os.defaultPrevented&&(h(n,u),h(o,u),I(t,fe,"true"),Cn(this),this.open=!s,rt(t),Sn(this),b(o,Tn))}hide(){const{element:t,open:s,menu:n,parentElement:o}=this;s&&([is,$n].forEach(i=>{i.relatedTarget=t}),b(o,is),!is.defaultPrevented&&(v(n,u),v(o,u),I(t,fe,"false"),this.open=!s,Sn(this),b(o,$n)))}_toggleEventListeners=t=>{(t?O:N)(this.element,k,Fi)};dispose(){this.open&&this.hide(),this._toggleEventListeners(),super.dispose()}}const Y="modal",cs="Modal",as="Offcanvas",Vi="fixed-top",Ki="fixed-bottom",xn="sticky-top",Pn="position-sticky",Dn=e=>[...at(Vi,e),...at(Ki,e),...at(xn,e),...at(Pn,e),...at("is-fixed",e)],qi=e=>{const t=pt(e);x(t,{paddingRight:"",overflow:""});const s=Dn(t);s.length&&s.forEach(n=>{x(n,{paddingRight:"",marginRight:""})})},An=e=>{const{clientWidth:t}=ct(e),{innerWidth:s}=Ks(e);return Math.abs(s-t)},kn=(e,t)=>{const s=pt(e),n=parseInt(W(s,"paddingRight"),10),i=W(s,"overflow")==="hidden"&&n?0:An(e),r=Dn(s);t&&(x(s,{overflow:"hidden",paddingRight:`${n+i}px`}),r.length&&r.forEach(c=>{const a=W(c,"paddingRight");if(c.style.paddingRight=`${parseInt(a,10)+i}px`,[xn,Pn].some(l=>f(c,l))){const l=W(c,"marginRight");c.style.marginRight=`${parseInt(l,10)-i}px`}}))},Q="offcanvas",wt=ft({tagName:"div",className:"popup-container"}),In=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt,o=s?t:pt(e);D(e)&&(n===wt&&o.append(wt),n.append(e))},Ln=(e,t)=>{const s=D(t)&&t.nodeName==="BODY",n=D(t)&&!s?t:wt;D(e)&&(e.remove(),n===wt&&!wt.children.length&&wt.remove())},ls=(e,t)=>{const s=D(t)&&t.nodeName!=="BODY"?t:wt;return D(e)&&s.contains(e)},_n="backdrop",On=`${Y}-${_n}`,Nn=`${Q}-${_n}`,Mn=`.${Y}.${u}`,ds=`.${Q}.${u}`,A=ft("div"),At=e=>P(`${Mn},${ds}`,w(e)),hs=e=>{const t=e?On:Nn;[On,Nn].forEach(s=>{v(A,s)}),h(A,t)},Rn=(e,t,s)=>{hs(s),In(A,pt(e)),t&&h(A,M)},Bn=()=>{f(A,u)||(h(A,u),Ht(A))},Ce=()=>{v(A,u)},Fn=e=>{At(e)||(v(A,M),Ln(A,pt(e)),qi(e))},Wn=e=>C(e)&&W(e,"visibility")!=="hidden"&&e.offsetParent!==null,Xi=`.${Y}`,jn=`[${ot}="${Y}"]`,Yi=`[${we}="${Y}"]`,zn=`${Y}-static`,Ui={backdrop:!0,keyboard:!0},se=e=>F(e,cs),Gi=e=>new gs(e),Se=E(`show.bs.${Y}`),Vn=E(`shown.bs.${Y}`),fs=E(`hide.bs.${Y}`),Kn=E(`hidden.bs.${Y}`),qn=e=>{const{element:t}=e,s=An(t),{clientHeight:n,scrollHeight:o}=ct(t),{clientHeight:i,scrollHeight:r}=t,c=i!==r;if(!c&&s){const l={[mt(t)?"paddingLeft":"paddingRight"]:`${s}px`};x(t,l)}kn(t,c||n!==o)},Xn=(e,t)=>{const s=t?O:N,{element:n}=e;s(n,k,Ji),s(w(n),ue,Qi),t?e._observer.observe(n):e._observer.disconnect()},Yn=e=>{const{triggers:t,element:s,relatedTarget:n}=e;Fn(s),x(s,{paddingRight:"",display:""}),Xn(e);const o=Se.relatedTarget||t.find(Wn);o&&rt(o),Kn.relatedTarget=n||void 0,b(s,Kn),be(s)},Un=e=>{const{element:t,relatedTarget:s}=e;rt(t),Xn(e,!0),Vn.relatedTarget=s||void 0,b(t,Vn),be(t)},Gn=e=>{const{element:t,hasFade:s}=e;x(t,{display:"block"}),qn(e),At(t)||x(pt(t),{overflow:"hidden"}),h(t,u),Ct(t,Yt),I(t,ge,"true"),s?H(t,()=>Un(e)):Un(e)},Zn=e=>{const{element:t,options:s,hasFade:n}=e;s.backdrop&&n&&f(A,u)&&!At(t)?(Ce(),H(A,()=>Yn(e))):Yn(e)},Zi=e=>{const{target:t}=e,s=t&&L(t,jn),n=s&&V(s),o=n&&se(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.toggle())},Qi=({code:e,target:t})=>{const s=P(Mn,w(t)),n=s&&se(s);if(!n)return;const{options:o}=n;o.keyboard&&e===Be&&f(s,u)&&(n.relatedTarget=null,n.hide())},Ji=e=>{const{currentTarget:t}=e,s=t&&se(t);if(!s||!t||g.get(t))return;const{options:n,isStatic:o,modalDialog:i}=s,{backdrop:r}=n,{target:c}=e,a=w(t)?.getSelection()?.toString().length,l=i.contains(c),d=c&&L(c,Yi);o&&!l?g.set(t,()=>{h(t,zn),H(i,()=>tr(s))},17):(d||!a&&!o&&!l&&r)&&(s.relatedTarget=d||null,s.hide(),e.preventDefault())},tr=e=>{const{element:t,modalDialog:s}=e,n=(Qt(s)||0)+17;v(t,zn),g.set(t,()=>g.clear(t),n)};class gs extends et{static selector=Xi;static init=Gi;static getInstance=se;constructor(t,s){super(t,s);const{element:n}=this,o=P(`.${Y}-dialog`,n);o&&(this.modalDialog=o,this.triggers=[...G(jn,w(n))].filter(i=>V(i)===n),this.isStatic=this.options.backdrop==="static",this.hasFade=f(n,M),this.relatedTarget=null,this._observer=new ResizeObserver(()=>this.update()),this._toggleEventListeners(!0))}get name(){return cs}get defaults(){return Ui}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,hasFade:n,relatedTarget:o}=this,{backdrop:i}=s;let r=0;if(f(t,u)||(Se.relatedTarget=o||void 0,b(t,Se),Se.defaultPrevented))return;const c=At(t);if(c&&c!==t){const a=se(c)||F(c,as);a&&a.hide()}i?(ls(A)?hs(!0):Rn(t,n,!0),r=Qt(A),Bn(),setTimeout(()=>Gn(this),r)):(Gn(this),c&&f(A,u)&&Ce())}hide(){const{element:t,hasFade:s,relatedTarget:n}=this;f(t,u)&&(fs.relatedTarget=n||void 0,b(t,fs),!fs.defaultPrevented&&(v(t,u),I(t,Yt,"true"),Ct(t,ge),s?H(t,()=>Zn(this)):Zn(this)))}update=()=>{f(this.element,u)&&qn(this)};_toggleEventListeners=t=>{const s=t?O:N,{triggers:n}=this;n.length&&n.forEach(o=>s(o,k,Zi))};dispose(){const t={...this},{modalDialog:s,hasFade:n}=t,o=()=>setTimeout(()=>super.dispose(),17);this.hide(),this._toggleEventListeners(),n?H(s,o):o()}}const er=`.${Q}`,us=`[${ot}="${Q}"]`,sr=`[${we}="${Q}"]`,He=`${Q}-toggling`,nr={backdrop:!0,keyboard:!0,scroll:!1},ne=e=>F(e,as),or=e=>new ms(e),xe=E(`show.bs.${Q}`),Qn=E(`shown.bs.${Q}`),ps=E(`hide.bs.${Q}`),Jn=E(`hidden.bs.${Q}`),ir=e=>{const{element:t}=e,{clientHeight:s,scrollHeight:n}=ct(t);kn(t,s!==n)},to=(e,t)=>{const s=t?O:N,n=w(e.element);s(n,ue,lr),s(n,k,ar)},eo=e=>{const{element:t,options:s}=e;s.scroll||(ir(e),x(pt(t),{overflow:"hidden"})),h(t,He),h(t,u),x(t,{visibility:"visible"}),H(t,()=>dr(e))},rr=e=>{const{element:t,options:s}=e,n=At(t);t.blur(),!n&&s.backdrop&&f(A,u)&&Ce(),H(t,()=>hr(e))},cr=e=>{const t=L(e.target,us),s=t&&V(t),n=s&&ne(s);n&&(n.relatedTarget=t,n.toggle(),t?.tagName==="A"&&e.preventDefault())},ar=e=>{const{target:t}=e,s=P(ds,w(t));if(!s)return;const n=P(sr,s),o=ne(s);if(!o)return;const{options:i,triggers:r}=o,{backdrop:c}=i,a=L(t,us),l=w(s).getSelection();A.contains(t)&&c==="static"||(!(l&&l.toString().length)&&(!s.contains(t)&&c&&(!a||r.includes(t))||n&&n.contains(t))&&(o.relatedTarget=n&&n.contains(t)?n:void 0,o.hide()),a&&a.tagName==="A"&&e.preventDefault())},lr=({code:e,target:t})=>{const s=P(ds,w(t)),n=s&&ne(s);n&&n.options.keyboard&&e===Be&&(n.relatedTarget=void 0,n.hide())},dr=e=>{const{element:t}=e;v(t,He),Ct(t,Yt),I(t,ge,"true"),I(t,"role","dialog"),b(t,Qn),to(e,!0),rt(t),be(t)},hr=e=>{const{element:t,triggers:s}=e;I(t,Yt,"true"),Ct(t,ge),Ct(t,"role"),x(t,{visibility:""});const n=xe.relatedTarget||s.find(Wn);n&&rt(n),Fn(t),b(t,Jn),v(t,He),be(t),At(t)||to(e)};class ms extends et{static selector=er;static init=or;static getInstance=ne;constructor(t,s){super(t,s);const{element:n}=this;this.triggers=[...G(us,w(n))].filter(o=>V(o)===n),this.relatedTarget=void 0,this._toggleEventListeners(!0)}get name(){return as}get defaults(){return nr}toggle(){f(this.element,u)?this.hide():this.show()}show(){const{element:t,options:s,relatedTarget:n}=this;let o=0;if(f(t,u)||(xe.relatedTarget=n||void 0,Qn.relatedTarget=n||void 0,b(t,xe),xe.defaultPrevented))return;const i=At(t);if(i&&i!==t){const r=ne(i)||F(i,cs);r&&r.hide()}s.backdrop?(ls(A)?hs():Rn(t,!0),o=Qt(A),Bn(),setTimeout(()=>eo(this),o)):(eo(this),i&&f(A,u)&&Ce())}hide(){const{element:t,relatedTarget:s}=this;f(t,u)&&(ps.relatedTarget=s||void 0,Jn.relatedTarget=s||void 0,b(t,ps),!ps.defaultPrevented&&(h(t,He),v(t,u),rr(this)))}_toggleEventListeners=t=>{const s=t?O:N;this.triggers.forEach(n=>s(n,k,cr))};dispose(){const{element:t}=this,s=f(t,u),n=()=>setTimeout(()=>super.dispose(),1);this.hide(),this._toggleEventListeners(),s?H(t,n):n()}}const kt="popover",vs="Popover",dt="tooltip",so=e=>{const t=e===dt,s=t?`${e}-inner`:`${e}-body`,n=t?"":`

`,o=`
`,i=`
`;return`
${n+o+i}
`},no={top:"top",bottom:"bottom",left:"start",right:"end"},bs=e=>{requestAnimationFrame(()=>{const t=/\b(top|bottom|start|end)+/,{element:s,tooltip:n,container:o,offsetParent:i,options:r,arrow:c}=e;if(!n)return;const a=mt(s),{x:l,y:d}=ei(i);x(n,{top:"",left:"",right:"",bottom:""});const{offsetWidth:p,offsetHeight:T}=n,{clientWidth:_,clientHeight:q,offsetWidth:j}=ct(s);let{placement:m}=r;const{clientWidth:B,offsetWidth:Lt}=o,S=W(o,"position")==="fixed",Tt=Math.abs(S?B-Lt:_-j),ht=a&&S?Tt:0,nt=_-(a?0:Tt)-1,Vt=e._observer.getEntry(s),{width:y,height:X,left:Kt,right:z,top:Ot}=Vt?.boundingClientRect||ut(s,!0),{x:De,y:qt}=ii(s,i,{x:l,y:d});x(c,{top:"",left:"",right:"",bottom:""});let Nt=0,ce="",$t=0,Ds="",Xt="",Ae="",As="";const Mt=c.offsetWidth||0,yt=c.offsetHeight||0,ks=Mt/2;let ae=Ot-T-yt<0,le=Ot+T+X+yt>=q,de=Kt-p-Mt=nt;const ke=["left","right"],Is=["top","bottom"];ae=ke.includes(m)?Ot+X/2-T/2-yt<0:ae,le=ke.includes(m)?Ot+T/2+X/2+yt>=q:le,de=Is.includes(m)?Kt+y/2-p/2=nt:he,m=ke.includes(m)&&de&&he?"top":m,m=m==="top"&&ae?"bottom":m,m=m==="bottom"&&le?"top":m,m=m==="left"&&de?"right":m,m=m==="right"&&he?"left":m,n.className.includes(m)||(n.className=n.className.replace(t,no[m])),ke.includes(m)?(m==="left"?$t=De-p-Mt:$t=De+y+Mt,ae&&le?(Nt=0,ce=0,Xt=qt+X/2-yt/2):ae?(Nt=qt,ce="",Xt=X/2-Mt):le?(Nt=qt-T+X,ce="",Xt=T-X/2-Mt):(Nt=qt-T/2+X/2,Xt=T/2-yt/2)):Is.includes(m)&&(m==="top"?Nt=qt-T-yt:Nt=qt+X+yt,de?($t=0,Ae=De+y/2-ks):he?($t="auto",Ds=0,As=y/2+nt-z-ks):($t=De-p/2+y/2,Ae=p/2-ks)),x(n,{top:`${Nt}px`,bottom:ce===""?"":`${ce}px`,left:$t==="auto"?$t:`${$t}px`,right:Ds!==""?`${Ds}px`:""}),C(c)&&(Xt!==""&&(c.style.top=`${Xt}px`),Ae!==""?c.style.left=`${Ae}px`:As!==""&&(c.style.right=`${As}px`));const Ur=E(`updated.bs.${Bt(e.name)}`);b(s,Ur)})},ws={template:so(dt),title:"",customClass:"",trigger:"hover focus",placement:"top",sanitizeFn:void 0,animation:!0,delay:200,container:document.body,content:"",dismissible:!1,btnClose:""},fr=e=>e!=null&&typeof e=="object"||!1,gr=e=>fr(e)&&typeof e.nodeType=="number"&&[1,2,3,4,5,6,7,8,9,10,11].some(t=>e.nodeType===t)||!1,oo=e=>gr(e)&&e.nodeType===1||!1,ur=e=>typeof e=="function"||!1,pr="1.0.2",io="PositionObserver Error";class ro{entries;static version=pr;_tick;_root;_callback;constructor(t,s){if(!ur(t))throw new Error(`${io}: ${t} is not a function.`);this.entries=new Map,this._callback=t,this._root=oo(s?.root)?s.root:document?.documentElement,this._tick=0}observe=t=>{if(!oo(t))throw new Error(`${io}: ${t} is not an instance of Element.`);this._root.contains(t)&&this._new(t).then(s=>{this.getEntry(t)||this.entries.set(t,s),this._tick||(this._tick=requestAnimationFrame(this._runCallback))})};unobserve=t=>{this.entries.has(t)&&this.entries.delete(t)};_runCallback=()=>{if(!this.entries.size)return;const t=new Promise(s=>{const n=[];this.entries.forEach(({target:o,boundingClientRect:i})=>{this._root.contains(o)&&this._new(o).then(({boundingClientRect:r,isVisible:c})=>{const{left:a,top:l,bottom:d,right:p}=r;if(i.top!==l||i.left!==a||i.right!==p||i.bottom!==d){const T={target:o,boundingClientRect:r,isVisible:c};this.entries.set(o,T),n.push(T)}})}),s(n)});this._tick=requestAnimationFrame(async()=>{const s=await t;s.length&&this._callback(s,this),this._runCallback()})};_new=t=>{const{clientWidth:s,clientHeight:n}=this._root;return new Promise(o=>{new IntersectionObserver(([{boundingClientRect:i}],r)=>{r.disconnect();const{left:c,top:a,bottom:l,right:d,width:p,height:T}=i,_=a>1-T&&c>1-p&&l<=n+T-1&&d<=s+p-1;o({target:t,isVisible:_,boundingClientRect:i})}).observe(t)})};getEntry=t=>this.entries.get(t);disconnect=()=>{cancelAnimationFrame(this._tick),this.entries.clear(),this._tick=0}}const co="data-original-title",It="Tooltip",Et=(e,t,s)=>{if(Zt(t)&&t.length){let n=t.trim();ci(s)&&(n=s(n));const i=new DOMParser().parseFromString(n,"text/html");e.append(...i.body.childNodes)}else C(t)?e.append(t):(ai(t)||ri(t)&&t.every(D))&&e.append(...t)},mr=e=>{const t=e.name===It,{id:s,element:n,options:o}=e,{title:i,placement:r,template:c,animation:a,customClass:l,sanitizeFn:d,dismissible:p,content:T,btnClose:_}=o,q=t?dt:kt,j={...no};let m=[],B=[];mt(n)&&(j.left="end",j.right="start");const Lt=`bs-${q}-${j[r]}`;let _t;if(C(c))_t=c;else{const y=ft("div");Et(y,c,d),_t=y.firstChild}if(!C(_t))return;e.tooltip=_t.cloneNode(!0);const{tooltip:S}=e;I(S,"id",s),I(S,"role",dt);const Tt=t?`${dt}-inner`:`${kt}-body`,ht=t?null:P(`.${kt}-header`,S),nt=P(`.${Tt}`,S);e.arrow=P(`.${q}-arrow`,S);const{arrow:Vt}=e;if(C(i))m=[i.cloneNode(!0)];else{const y=ft("div");Et(y,i,d),m=[...y.childNodes]}if(C(T))B=[T.cloneNode(!0)];else{const y=ft("div");Et(y,T,d),B=[...y.childNodes]}if(p)if(i)if(C(_))m=[...m,_.cloneNode(!0)];else{const y=ft("div");Et(y,_,d),m=[...m,y.firstChild]}else if(ht&&ht.remove(),C(_))B=[...B,_.cloneNode(!0)];else{const y=ft("div");Et(y,_,d),B=[...B,y.firstChild]}t?i&&nt&&Et(nt,i,d):(i&&ht&&Et(ht,m,d),T&&nt&&Et(nt,B,d),e.btn=P(".btn-close",S)||void 0),h(S,"position-absolute"),h(Vt,"position-absolute"),f(S,q)||h(S,q),a&&!f(S,M)&&h(S,M),l&&!f(S,l)&&h(S,l),f(S,Lt)||h(S,Lt)},vr=e=>{const t=["HTML","BODY"],s=[];let{parentNode:n}=e;for(;n&&!t.includes(n.nodeName);)n=si(n),Vs(n)||ni(n)||s.push(n);return s.find((o,i)=>(W(o,"position")!=="relative"||W(o,"position")==="relative"&&o.offsetHeight!==o.scrollHeight)&&s.slice(i+1).every(r=>W(r,"position")==="static")?o:null)||w(e).body},br=`[${ot}="${dt}"],[data-tip="${dt}"]`,ao="title";let lo=e=>F(e,It);const wr=e=>new Pe(e),Er=e=>{const{element:t,tooltip:s,container:n}=e;Ct(t,Ls),Ln(s,n)},oe=e=>{const{tooltip:t,container:s}=e;return t&&ls(t,s)},Tr=(e,t)=>{const{element:s}=e;e._toggleEventListeners(),Ut(s,co)&&e.name===It&&po(e),t&&t()},ho=(e,t)=>{const s=t?O:N,{element:n}=e;s(w(n),Ne,e.handleTouch,Jt)},fo=e=>{const{element:t}=e,s=E(`shown.bs.${Bt(e.name)}`);ho(e,!0),b(t,s),g.clear(t,"in")},go=e=>{const{element:t}=e,s=E(`hidden.bs.${Bt(e.name)}`);ho(e),Er(e),b(t,s),g.clear(t,"out")},uo=(e,t)=>{const s=t?O:N,{element:n,tooltip:o}=e,i=L(n,`.${Y}`),r=L(n,`.${Q}`);t?[n,o].forEach(c=>e._observer.observe(c)):e._observer.disconnect(),i&&s(i,`hide.bs.${Y}`,e.handleHide),r&&s(r,`hide.bs.${Q}`,e.handleHide)},po=(e,t)=>{const s=[co,ao],{element:n}=e;I(n,s[t?0:1],t||tt(n,s[0])||""),Ct(n,s[t?1:0])};class Pe extends et{static selector=br;static init=wr;static getInstance=lo;static styleTip=bs;constructor(t,s){super(t,s);const{element:n}=this,o=this.name===It,i=o?dt:kt,r=o?It:vs;lo=d=>F(d,r),this.enabled=!0,this.id=`${i}-${Us(n,i)}`;const{options:c}=this;if(!c.title&&o||!o&&!c.content)return;it(ws,{titleAttr:""}),Ut(n,ao)&&o&&typeof c.title=="string"&&po(this,c.title);const a=vr(n),l=["sticky","fixed","relative"].some(d=>W(a,"position")===d)?a:Ks(n);this.container=a,this.offsetParent=l,mr(this),this.tooltip&&(this._observer=new ro(d=>{d.some(p=>p.isVisible)&&this.update()}),this._toggleEventListeners(!0))}get name(){return It}get defaults(){return ws}handleFocus=()=>rt(this.element);handleShow=()=>this.show();show(){const{options:t,tooltip:s,element:n,container:o,id:i}=this,{animation:r}=t,c=g.get(n,"out");g.clear(n,"out"),s&&!c&&!oe(this)&&g.set(n,()=>{const a=E(`show.bs.${Bt(this.name)}`);b(n,a),a.defaultPrevented||(In(s,o),I(n,Ls,`#${i}`),this.update(),uo(this,!0),f(s,u)||h(s,u),r?H(s,()=>fo(this)):fo(this))},17,"in")}handleHide=()=>this.hide();hide(){const{options:t,tooltip:s,element:n}=this,{animation:o,delay:i}=t;g.clear(n,"in"),s&&oe(this)&&g.set(n,()=>{const r=E(`hide.bs.${Bt(this.name)}`);b(n,r),r.defaultPrevented||(this.update(),v(s,u),uo(this),o?H(s,()=>go(this)):go(this))},i+17,"out")}update=()=>{bs(this)};toggle=()=>{const{tooltip:t}=this;t&&!oe(this)?this.show():this.hide()};enable(){const{enabled:t}=this;t||(this._toggleEventListeners(!0),this.enabled=!t)}disable(){const{tooltip:t,enabled:s}=this;s&&(t&&oe(this)&&this.hide(),this._toggleEventListeners(),this.enabled=!s)}toggleEnabled(){this.enabled?this.disable():this.enable()}handleTouch=({target:t})=>{const{tooltip:s,element:n}=this;s&&s.contains(t)||t===n||t&&n.contains(t)||this.hide()};_toggleEventListeners=t=>{const s=t?O:N,{element:n,options:o,btn:i}=this,{trigger:r}=o,a=!!(this.name!==It&&o.dismissible);r.includes("manual")||(this.enabled=!!t,r.split(" ").forEach(d=>{d===Bo?(s(n,Ns,this.handleShow),s(n,pe,this.handleShow),a||(s(n,Oe,this.handleHide),s(w(n),Ne,this.handleTouch,Jt))):d===k?s(n,d,a?this.handleShow:this.toggle):d===Le&&(s(n,_e,this.handleShow),a||s(n,Os,this.handleHide),Xo()&&s(n,k,this.handleFocus)),a&&i&&s(i,k,this.handleHide)}))};dispose(){const{tooltip:t,options:s}=this,n={...this,name:this.name},o=()=>setTimeout(()=>Tr(n,()=>super.dispose()),17);s.animation&&oe(n)?(this.options.delay=0,this.hide(),H(t,o)):o()}}const $r=`[${ot}="${kt}"],[data-tip="${kt}"]`,yr=it({},ws,{template:so(kt),content:"",dismissible:!1,btnClose:''}),Cr=e=>F(e,vs),Sr=e=>new Es(e);class Es extends Pe{static selector=$r;static init=Sr;static getInstance=Cr;static styleTip=bs;constructor(t,s){super(t,s)}get name(){return vs}get defaults(){return yr}show=()=>{super.show();const{options:t,btn:s}=this;t.dismissible&&s&&setTimeout(()=>rt(s),17)}}const Hr="scrollspy",mo="ScrollSpy",xr='[data-bs-spy="scroll"]',Pr={offset:10,target:void 0},Dr=e=>F(e,mo),Ar=e=>new Ts(e),vo=E(`activate.bs.${Hr}`),kr=e=>{const{target:t,scrollTarget:s,options:n,itemsLength:o,scrollHeight:i,element:r,_observer:c}=e,{offset:a}=n,l=s!==r,d=t&&ze("A",t),p=w(r),T=s.scrollHeight;if(e.scrollTop=s.scrollTop,d&&(T!==i||o!==d.length)){let _,q,j,m;e.items=[],e.targets=[],e.offsets=[],e.scrollHeight=T,e.maxScroll=e.scrollHeight-Lr(e),Array.from(d).forEach(B=>{_=tt(B,"href"),q=_?.slice(1),j=q?.length?p.getElementById(q):null,j&&(e.items.push(B),e.targets.push(j),m=c?.getEntry(j)?.boundingClientRect||ut(j),e.offsets.push((l?m.top+e.scrollTop:j.offsetTop)-a))}),e.itemsLength=e.items.length}},bo=({targets:e,scrollTarget:t,element:s,_observer:n},o)=>{o?t===s?e?.forEach(i=>n.observe(i)):n.observe(s):n.disconnect()},Ir=e=>e.scrollHeight,Lr=({element:e,scrollTarget:t})=>t!==e?t.clientHeight:ut(e).height,wo=e=>{Array.from(ze("A",e)).forEach(t=>{f(t,$)&&v(t,$)})},Eo=(e,t)=>{const{target:s,element:n}=e;C(s)&&wo(s),e.activeItem=t,h(t,$);const o=[];let i=t;for(;i!==pt(n);)i=i.parentElement,(f(i,"nav")||f(i,"dropdown-menu"))&&o.push(i);o.forEach(r=>{const c=r.previousElementSibling;c&&!f(c,$)&&h(c,$)}),vo.relatedTarget=t,b(n,vo)};class Ts extends et{static selector=xr;static init=Ar;static getInstance=Dr;constructor(t,s){super(t,s);const{element:n,options:o}=this,i=P(o.target,w(n));i&&(this.target=i,this.scrollTarget=n.clientHeight{requestAnimationFrame(()=>{r.some(c=>c.isVisible)&&this.refresh()})},{root:this.scrollTarget}),bo(this,!0))}get name(){return mo}get defaults(){return Pr}refresh=()=>{const{target:t}=this;if(!C(t)||t.offsetHeight===0)return;kr(this);const{scrollTop:s,maxScroll:n,itemsLength:o,items:i,activeItem:r}=this;if(s>=n){const a=i[o-1];r!==a&&Eo(this,a);return}const{offsets:c}=this;if(r&&s0){this.activeItem=null,t&&wo(t);return}i.forEach((a,l)=>{r!==a&&s>=c[l]&&(typeof c[l+1]>"u"||sF(e,To),_r=e=>new Cs(e),$s=E(`show.bs.${ie}`),Co=E(`shown.bs.${ie}`),ys=E(`hide.bs.${ie}`),So=E(`hidden.bs.${ie}`),re=new Map,Ho=e=>{const{tabContent:t,nav:s}=e;t&&f(t,Pt)&&(t.style.height="",v(t,Pt)),s&&g.clear(s)},xo=e=>{const{element:t,tabContent:s,content:n,nav:o}=e,{tab:i}=C(o)&&re.get(o)||{tab:null};if(s&&n&&f(n,M)){const{currentHeight:r,nextHeight:c}=re.get(t)||{currentHeight:0,nextHeight:0};r!==c?setTimeout(()=>{s.style.height=`${c}px`,Ht(s),H(s,()=>Ho(e))},50):Ho(e)}else o&&g.clear(o);Co.relatedTarget=i,b(t,Co)},Po=e=>{const{element:t,content:s,tabContent:n,nav:o}=e,{tab:i,content:r}=o&&re.get(o)||{tab:null,content:null};let c=0;if(n&&s&&f(s,M)&&([r,s].forEach(a=>{a&&h(a,"overflow-hidden")}),c=r?r.scrollHeight:0),$s.relatedTarget=i,So.relatedTarget=t,b(t,$s),!$s.defaultPrevented){if(s&&h(s,$),r&&v(r,$),n&&s&&f(s,M)){const a=s.scrollHeight;re.set(t,{currentHeight:c,nextHeight:a,tab:null,content:null}),h(n,Pt),n.style.height=`${c}px`,Ht(n),[r,s].forEach(l=>{l&&v(l,"overflow-hidden")})}s&&s&&f(s,M)?setTimeout(()=>{h(s,u),H(s,()=>{xo(e)})},1):(s&&h(s,u),xo(e)),i&&b(i,So)}},Do=e=>{const{nav:t}=e;if(!C(t))return{tab:null,content:null};const s=at($,t);let n=null;s.length===1&&!Dt.some(i=>f(s[0].parentElement,i))?[n]=s:s.length>1&&(n=s[s.length-1]);const o=C(n)?V(n):null;return{tab:n,content:o}},Ao=e=>{if(!C(e))return null;const t=L(e,`.${Dt.join(",.")}`);return t?P(`.${Dt[0]}-toggle`,t):null},Or=e=>{const t=yo(e.target);e.preventDefault(),t&&t.show()};class Cs extends et{static selector=$o;static init=_r;static getInstance=yo;constructor(t){super(t);const{element:s}=this,n=V(s);if(!n)return;const o=L(s,".nav"),i=L(n,".tab-content");this.nav=o,this.content=n,this.tabContent=i,this.dropdown=Ao(s);const{tab:r}=Do(this);if(o&&!r){const c=P($o,o),a=c&&V(c);a&&(h(c,$),h(a,u),h(a,$),I(s,Ie,"true"))}this._toggleEventListeners(!0)}get name(){return To}show(){const{element:t,content:s,nav:n,dropdown:o}=this;if(n&&g.get(n)||f(t,$))return;const{tab:i,content:r}=Do(this);if(n&&i&&re.set(n,{tab:i,content:r,currentHeight:0,nextHeight:0}),ys.relatedTarget=t,!C(i)||(b(i,ys),ys.defaultPrevented))return;h(t,$),I(t,Ie,"true");const c=C(i)&&Ao(i);if(c&&f(c,$)&&v(c,$),n){const a=()=>{i&&(v(i,$),I(i,Ie,"false")),o&&!f(o,$)&&h(o,$)};r&&(f(r,M)||s&&f(s,M))?g.set(n,a,1):a()}r&&(v(r,u),f(r,M)?H(r,()=>Po(this)):Po(this))}_toggleEventListeners=t=>{(t?O:N)(this.element,k,Or)};dispose(){this._toggleEventListeners(),super.dispose()}}const J="toast",ko="Toast",Nr=`.${J}`,Mr=`[${we}="${J}"]`,Io=`[${ot}="${J}"]`,zt="showing",Lo="hide",Rr={animation:!0,autohide:!0,delay:5e3},Ss=e=>F(e,ko),Br=e=>new Hs(e),_o=E(`show.bs.${J}`),Fr=E(`shown.bs.${J}`),Oo=E(`hide.bs.${J}`),Wr=E(`hidden.bs.${J}`),No=e=>{const{element:t,options:s}=e;v(t,zt),g.clear(t,zt),b(t,Fr),s.autohide&&g.set(t,()=>e.hide(),s.delay,J)},Mo=e=>{const{element:t}=e;v(t,zt),v(t,u),h(t,Lo),g.clear(t,J),b(t,Wr)},jr=e=>{const{element:t,options:s}=e;h(t,zt),s.animation?(Ht(t),H(t,()=>Mo(e))):Mo(e)},zr=e=>{const{element:t,options:s}=e;g.set(t,()=>{v(t,Lo),Ht(t),h(t,u),h(t,zt),s.animation?H(t,()=>No(e)):No(e)},17,zt)},Vr=e=>{const{target:t}=e,s=t&&L(t,Io),n=s&&V(s),o=n&&Ss(n);o&&(s&&s.tagName==="A"&&e.preventDefault(),o.relatedTarget=s,o.show())},Kr=e=>{const t=e.target,s=Ss(t),{type:n,relatedTarget:o}=e;!s||t===o||t.contains(o)||([pe,_e].includes(n)?g.clear(t,J):g.set(t,()=>s.hide(),s.options.delay,J))};class Hs extends et{static selector=Nr;static init=Br;static getInstance=Ss;constructor(t,s){super(t,s);const{element:n,options:o}=this;o.animation&&!f(n,M)?h(n,M):!o.animation&&f(n,M)&&v(n,M),this.dismiss=P(Mr,n),this.triggers=[...G(Io,w(n))].filter(i=>V(i)===n),this._toggleEventListeners(!0)}get name(){return ko}get defaults(){return Rr}get isShown(){return f(this.element,u)}show=()=>{const{element:t,isShown:s}=this;!t||s||(b(t,_o),_o.defaultPrevented||zr(this))};hide=()=>{const{element:t,isShown:s}=this;!t||!s||(b(t,Oo),Oo.defaultPrevented||jr(this))};_toggleEventListeners=t=>{const s=t?O:N,{element:n,triggers:o,dismiss:i,options:r,hide:c}=this;i&&s(i,k,c),r.autohide&&[_e,Os,pe,Oe].forEach(a=>s(n,a,Kr)),o.length&&o.forEach(a=>s(a,k,Vr))};dispose(){const{element:t,isShown:s}=this;this._toggleEventListeners(),g.clear(t,J),s&&v(t,u),super.dispose()}}const xs=new Map;[Ve,Ke,Je,ts,rs,gs,ms,Es,Ts,Cs,Hs,Pe].forEach(e=>xs.set(e.prototype.name,e));const qr=(e,t)=>{[...t].forEach(s=>e(s))},Xr=(e,t)=>{const s=St.getAllFor(e);s&&[...s].forEach(([n,o])=>{t.contains(n)&&o.dispose()})},Ps=e=>{const t=e&&e.nodeName?e:document,s=[...ze("*",t)];xs.forEach(n=>{const{init:o,selector:i}=n;qr(o,s.filter(r=>qs(r,i)))})},Yr=e=>{const t=e&&e.nodeName?e:document;xs.forEach(s=>{Xr(s.prototype.name,t)})};return document.body?Ps():O(document,"DOMContentLoaded",()=>Ps(),{once:!0}),R.Alert=Ve,R.Button=Ke,R.Carousel=Je,R.Collapse=ts,R.Dropdown=rs,R.Modal=gs,R.Offcanvas=ms,R.Popover=Es,R.ScrollSpy=Ts,R.Tab=Cs,R.Toast=Hs,R.Tooltip=Pe,R.initCallback=Ps,R.removeDataAPI=Yr,Object.defineProperty(R,Symbol.toStringTag,{value:"Module"}),R}({}); //# sourceMappingURL=bootstrap-native.js.map diff --git a/docs/assets/js/bootstrap-native.js.map b/docs/assets/js/bootstrap-native.js.map index b49fc64f..dc1de01b 100644 --- a/docs/assets/js/bootstrap-native.js.map +++ b/docs/assets/js/bootstrap-native.js.map @@ -1 +1 @@ -{"version":3,"file":"bootstrap-native.js","sources":["../node_modules/.pnpm/@thednp+shorty@2.0.7/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.6/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@0.0.3/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const ariaChecked = \"aria-checked\", ariaDescription = \"aria-description\", ariaDescribedBy = \"aria-describedby\", ariaExpanded = \"aria-expanded\", ariaHasPopup = \"aria-haspopup\", ariaHidden = \"aria-hidden\", ariaLabel = \"aria-label\", ariaLabelledBy = \"aria-labelledby\", ariaModal = \"aria-modal\", ariaPressed = \"aria-pressed\", ariaSelected = \"aria-selected\", ariaValueMin = \"aria-valuemin\", ariaValueMax = \"aria-valuemax\", ariaValueNow = \"aria-valuenow\", ariaValueText = \"aria-valuetext\", abortEvent = \"abort\", beforeunloadEvent = \"beforeunload\", blurEvent = \"blur\", changeEvent = \"change\", contextmenuEvent = \"contextmenu\", DOMContentLoadedEvent = \"DOMContentLoaded\", DOMMouseScrollEvent = \"DOMMouseScroll\", errorEvent = \"error\", focusEvent = \"focus\", focusinEvent = \"focusin\", focusoutEvent = \"focusout\", gesturechangeEvent = \"gesturechange\", gestureendEvent = \"gestureend\", gesturestartEvent = \"gesturestart\", keydownEvent = \"keydown\", keypressEvent = \"keypress\", keyupEvent = \"keyup\", loadEvent = \"load\", mouseclickEvent = \"click\", mousedblclickEvent = \"dblclick\", mousedownEvent = \"mousedown\", mouseupEvent = \"mouseup\", mousehoverEvent = \"hover\", mouseenterEvent = \"mouseenter\", mouseleaveEvent = \"mouseleave\", mouseinEvent = \"mousein\", mouseoutEvent = \"mouseout\", mouseoverEvent = \"mouseover\", mousemoveEvent = \"mousemove\", mousewheelEvent = \"mousewheel\", moveEvent = \"move\", orientationchangeEvent = \"orientationchange\", pointercancelEvent = \"pointercancel\", pointerdownEvent = \"pointerdown\", pointerleaveEvent = \"pointerleave\", pointermoveEvent = \"pointermove\", pointerupEvent = \"pointerup\", readystatechangeEvent = \"readystatechange\", resetEvent = \"reset\", resizeEvent = \"resize\", selectEvent = \"select\", selectendEvent = \"selectend\", selectstartEvent = \"selectstart\", scrollEvent = \"scroll\", submitEvent = \"submit\", touchstartEvent = \"touchstart\", touchmoveEvent = \"touchmove\", touchcancelEvent = \"touchcancel\", touchendEvent = \"touchend\", unloadEvent = \"unload\", nativeEvents = {\n DOMContentLoaded: DOMContentLoadedEvent,\n DOMMouseScroll: DOMMouseScrollEvent,\n abort: abortEvent,\n beforeunload: beforeunloadEvent,\n blur: blurEvent,\n change: changeEvent,\n click: mouseclickEvent,\n contextmenu: contextmenuEvent,\n dblclick: mousedblclickEvent,\n error: errorEvent,\n focus: focusEvent,\n focusin: focusinEvent,\n focusout: focusoutEvent,\n gesturechange: gesturechangeEvent,\n gestureend: gestureendEvent,\n gesturestart: gesturestartEvent,\n hover: mousehoverEvent,\n keydown: keydownEvent,\n keypress: keypressEvent,\n keyup: keyupEvent,\n load: loadEvent,\n mousedown: mousedownEvent,\n mousemove: mousemoveEvent,\n mousein: mouseinEvent,\n mouseout: mouseoutEvent,\n mouseenter: mouseenterEvent,\n mouseleave: mouseleaveEvent,\n mouseover: mouseoverEvent,\n mouseup: mouseupEvent,\n mousewheel: mousewheelEvent,\n move: moveEvent,\n orientationchange: orientationchangeEvent,\n pointercancel: pointercancelEvent,\n pointerdown: pointerdownEvent,\n pointerleave: pointerleaveEvent,\n pointermove: pointermoveEvent,\n pointerup: pointerupEvent,\n readystatechange: readystatechangeEvent,\n reset: resetEvent,\n resize: resizeEvent,\n scroll: scrollEvent,\n select: selectEvent,\n selectend: selectendEvent,\n selectstart: selectstartEvent,\n submit: submitEvent,\n touchcancel: touchcancelEvent,\n touchend: touchendEvent,\n touchmove: touchmoveEvent,\n touchstart: touchstartEvent,\n unload: unloadEvent\n}, dragEvent = \"drag\", dragstartEvent = \"dragstart\", dragenterEvent = \"dragenter\", dragleaveEvent = \"dragleave\", dragoverEvent = \"dragover\", dragendEvent = \"dragend\", loadstartEvent = \"loadstart\", mouseSwipeEvents = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, mouseClickEvents = { down: \"mousedown\", up: \"mouseup\" }, mouseHoverEvents = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : (\n /* istanbul ignore next @preserve */\n [\"mouseover\", \"mouseout\"]\n), touchEvents = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, focusEvents = { in: \"focusin\", out: \"focusout\" }, focusableSelector = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', keyboardEventKeys = {\n Backspace: \"Backspace\",\n // 8\n Tab: \"Tab\",\n // 9\n Enter: \"Enter\",\n // 13\n Shift: \"Shift\",\n // 16\n Control: \"Control\",\n // 17\n Alt: \"Alt\",\n // 18\n Pause: \"Pause\",\n // 19\n CapsLock: \"CapsLock\",\n // 20\n Escape: \"Escape\",\n // 27\n Scape: \"Space\",\n // 32\n ArrowLeft: \"ArrowLeft\",\n // 37\n ArrowUp: \"ArrowUp\",\n // 38\n ArrowRight: \"ArrowRight\",\n // 39\n ArrowDown: \"ArrowDown\",\n // 40\n Insert: \"Insert\",\n // 45\n Delete: \"Delete\",\n // 46\n Meta: \"Meta\",\n // 91 windows key\n ContextMenu: \"ContextMenu\",\n // 93\n ScrollLock: \"ScrollLock\"\n // 145\n}, keyAlt = \"Alt\", keyArrowDown = \"ArrowDown\", keyArrowUp = \"ArrowUp\", keyArrowLeft = \"ArrowLeft\", keyArrowRight = \"ArrowRight\", keyBackspace = \"Backspace\", keyCapsLock = \"CapsLock\", keyControl = \"Control\", keyDelete = \"Delete\", keyEnter = \"Enter\", keyNumpadEnter = \"NumpadEnter\", keyEscape = \"Escape\", keyInsert = \"Insert\", keyMeta = \"Meta\", keyPause = \"Pause\", keyScrollLock = \"ScrollLock\", keyShift = \"Shift\", keySpace = \"Space\", keyTab = \"Tab\", animationDuration = \"animationDuration\", animationDelay = \"animationDelay\", animationName = \"animationName\", animationEndEvent = \"animationend\", transitionDuration = \"transitionDuration\", transitionDelay = \"transitionDelay\", transitionEndEvent = \"transitionend\", transitionProperty = \"transitionProperty\", addEventListener = \"addEventListener\", removeEventListener = \"removeEventListener\", bezierEasings = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, offsetHeight = \"offsetHeight\", offsetWidth = \"offsetWidth\", scrollHeight = \"scrollHeight\", scrollWidth = \"scrollWidth\", tabindex = \"tabindex\", userAgentData = navigator.userAgentData, { userAgent: userAgentString } = navigator, userAgent = userAgentString, isMobile = () => {\n const mobileBrands = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (x) => mobileBrands.test(x.brand)\n ) || mobileBrands.test(navigator?.userAgent) || !1;\n}, isApple = () => {\n const appleBrands = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (x) => appleBrands.test(x.brand)\n ) || /* istanbul ignore next @preserve */\n appleBrands.test(\n navigator?.userAgent\n ) || !1;\n}, isFirefox = () => navigator?.userAgent?.includes(\"Firefox\") || /* istanbul ignore next @preserve */\n!1, support3DTransform = () => [\"webkitPerspective\", \"perspective\"].some((p) => p in document.head.style), noop = () => {\n}, on = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.addEventListener(\n eventName,\n listener,\n ops\n );\n}, off = (element, eventName, listener, options) => {\n const ops = options || !1;\n element.removeEventListener(\n eventName,\n listener,\n ops\n );\n}, one = (element, eventName, listener, options) => {\n const handlerWrapper = (e) => {\n (e.target === element || e.currentTarget === element) && (listener.apply(element, [e]), off(element, eventName, handlerWrapper, options));\n };\n on(element, eventName, handlerWrapper, options);\n}, supportPassive = () => {\n let result = !1;\n try {\n const opts = Object.defineProperty({}, \"passive\", {\n get: () => (result = !0, result)\n });\n one(document, DOMContentLoadedEvent, noop, opts);\n } catch {\n }\n return result;\n}, supportTransform = () => [\"webkitTransform\", \"transform\"].some((p) => p in document.head.style), supportTouch = () => \"ontouchstart\" in window || /* istanbul ignore next @preserve */\n\"msMaxTouchPoints\" in navigator, supportAnimation = () => [\"webkitAnimation\", \"animation\"].some((p) => p in document.head.style), supportTransition = () => [\"webkitTransition\", \"transition\"].some((p) => p in document.head.style), getAttribute = (element, att) => element.getAttribute(att), getAttributeNS = (ns, element, att) => element.getAttributeNS(ns, att), hasAttribute = (element, att) => element.hasAttribute(att), hasAttributeNS = (ns, element, att) => element.hasAttributeNS(ns, att), setAttribute = (element, att, value) => element.setAttribute(att, value), setAttributeNS = (ns, element, att, value) => element.setAttributeNS(ns, att, value), removeAttribute = (element, att) => element.removeAttribute(att), removeAttributeNS = (ns, element, att) => element.removeAttributeNS(ns, att), addClass = (element, ...classNAME) => {\n element.classList.add(...classNAME);\n}, removeClass = (element, ...classNAME) => {\n element.classList.remove(...classNAME);\n}, hasClass = (element, classNAME) => element.classList.contains(classNAME), { body: documentBody } = document, { documentElement } = document, { head: documentHead } = document, ArrayFrom = (arr) => Array.from(arr), isObject = (obj) => obj != null && typeof obj == \"object\" || !1, isNode = (node) => isObject(node) && typeof node.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (x) => node.nodeType === x\n) || !1, isHTMLElement = (element) => isNode(element) && element.nodeType === 1 || !1, componentData = /* @__PURE__ */ new Map(), Data = {\n data: componentData,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (element, component, instance) => {\n if (!isHTMLElement(element)) return;\n componentData.has(component) || componentData.set(component, /* @__PURE__ */ new Map()), componentData.get(component).set(element, instance);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (component) => componentData.get(component) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (element, component) => {\n if (!isHTMLElement(element) || !component) return null;\n const instanceMap = Data.getAllFor(component);\n return element && instanceMap && instanceMap.get(element) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (element, component) => {\n const instanceMap = Data.getAllFor(component);\n !instanceMap || !isHTMLElement(element) || (instanceMap.delete(element), instanceMap.size === 0 && componentData.delete(component));\n }\n}, getInstance = (target, component) => Data.get(target, component), isString = (str) => typeof str == \"string\" || !1, isWindow = (obj) => isObject(obj) && obj.constructor.name === \"Window\" || !1, isDocument = (obj) => isNode(obj) && obj.nodeType === 9 || !1, getDocument = (node) => isWindow(node) ? node.document : isDocument(node) ? node : isNode(node) ? node.ownerDocument : globalThis.document, ObjectAssign = (obj, ...source) => Object.assign(obj, ...source), createElement = (param) => {\n if (!param) return;\n if (isString(param))\n return getDocument().createElement(param);\n const { tagName } = param, newElement = createElement(tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, createElementNS = (ns, param) => {\n if (!ns || !param) return;\n if (isString(param))\n return getDocument().createElementNS(ns, param);\n const { tagName } = param, newElement = createElementNS(ns, tagName);\n if (!newElement) return;\n const attr = { ...param };\n return delete attr.tagName, ObjectAssign(newElement, attr);\n}, dispatchEvent = (element, event) => element.dispatchEvent(event), distinct = (value, index, arr) => arr.indexOf(value) === index, getElementStyle = (element, property) => {\n const computedStyle = getComputedStyle(element), prop = property.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return computedStyle.getPropertyValue(prop);\n}, getElementAnimationDelay = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDelay), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementAnimationDuration = (element) => {\n const propertyValue = getElementStyle(element, animationName), durationValue = getElementStyle(element, animationDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : 0;\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateAnimationEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(animationEndEvent), duration = getElementAnimationDuration(element), delay = getElementAnimationDelay(element);\n if (duration) {\n const animationEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(animationEndEvent, animationEndWrapper), called = 1);\n };\n element.addEventListener(animationEndEvent, animationEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, getElementTransitionDelay = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), delayValue = getElementStyle(element, transitionDelay), delayScale = delayValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(delayValue) * delayScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, getElementTransitionDuration = (element) => {\n const propertyValue = getElementStyle(element, transitionProperty), durationValue = getElementStyle(element, transitionDuration), durationScale = durationValue.includes(\"ms\") ? (\n /* istanbul ignore next */\n 1\n ) : 1e3, duration = propertyValue && propertyValue !== \"none\" ? parseFloat(durationValue) * durationScale : (\n /* istanbul ignore next */\n 0\n );\n return Number.isNaN(duration) ? (\n /* istanbul ignore next */\n 0\n ) : duration;\n}, emulateTransitionEnd = (element, handler) => {\n let called = 0;\n const endEvent = new Event(transitionEndEvent), duration = getElementTransitionDuration(element), delay = getElementTransitionDelay(element);\n if (duration) {\n const transitionEndWrapper = (e) => {\n e.target === element && (handler.apply(element, [e]), element.removeEventListener(transitionEndEvent, transitionEndWrapper), called = 1);\n };\n element.addEventListener(transitionEndEvent, transitionEndWrapper), setTimeout(() => {\n called || dispatchEvent(element, endEvent);\n }, duration + delay + 17);\n } else\n handler.apply(element, [endEvent]);\n}, Float32ArrayFrom = (arr) => Float32Array.from(Array.from(arr)), Float64ArrayFrom = (arr) => Float64Array.from(Array.from(arr)), focus = (element, options) => element.focus(options), normalizeValue = (value) => [\"true\", !0].includes(value) ? !0 : [\"false\", !1].includes(value) ? !1 : [\"null\", \"\", null, void 0].includes(value) ? null : value !== \"\" && !Number.isNaN(+value) ? +value : value, ObjectEntries = (obj) => Object.entries(obj), toLowerCase = (source) => source.toLowerCase(), normalizeOptions = (element, defaultOps, inputOps, ns) => {\n const INPUT = { ...inputOps }, data = { ...element.dataset }, normalOps = { ...defaultOps }, dataOps = {}, title = \"title\";\n return ObjectEntries(data).forEach(([k, v]) => {\n const key = ns && typeof k == \"string\" && k.includes(ns) ? k.replace(ns, \"\").replace(\n /[A-Z]/g,\n (match) => toLowerCase(match)\n ) : (\n /* istanbul ignore next @preserve */\n k\n );\n dataOps[key] = normalizeValue(v);\n }), ObjectEntries(INPUT).forEach(([k, v]) => {\n INPUT[k] = normalizeValue(v);\n }), ObjectEntries(defaultOps).forEach(([k, v]) => {\n k in INPUT ? normalOps[k] = INPUT[k] : k in dataOps ? normalOps[k] = dataOps[k] : normalOps[k] = k === title ? getAttribute(element, title) : v;\n }), normalOps;\n}, ObjectHasOwn = (obj, prop) => isObject(obj) && (Object.hasOwn(obj, prop) || prop in obj), ObjectKeys = (obj) => Object.keys(obj), ObjectValues = (obj) => Object.values(obj), ObjectFromEntries = (entries) => Object.fromEntries(entries), createCustomEvent = (eventType, config) => {\n const OriginalCustomEvent = new CustomEvent(eventType, {\n cancelable: !0,\n bubbles: !0\n });\n return isObject(config) && ObjectAssign(OriginalCustomEvent, config), OriginalCustomEvent;\n}, passiveHandler = { passive: !0 }, reflow = (element) => element.offsetHeight, setElementStyle = (element, styles) => {\n ObjectEntries(styles).forEach(([key, value]) => {\n if (value && isString(key) && key.includes(\"--\"))\n element.style.setProperty(key, value);\n else {\n const propObject = {};\n propObject[key] = value, ObjectAssign(element.style, propObject);\n }\n });\n}, isMap = (obj) => isObject(obj) && obj.constructor.name === \"Map\" || !1, isNumber = (num) => typeof num == \"number\" || !1, TimeCache = /* @__PURE__ */ new Map(), Timer = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (element, callback, delay, key) => {\n isHTMLElement(element) && (key && key.length ? (TimeCache.has(element) || TimeCache.set(element, /* @__PURE__ */ new Map()), TimeCache.get(element).set(key, setTimeout(callback, delay))) : TimeCache.set(element, setTimeout(callback, delay)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (element, key) => {\n if (!isHTMLElement(element)) return null;\n const keyTimers = TimeCache.get(element);\n return key && keyTimers && isMap(keyTimers) ? keyTimers.get(key) || /* istanbul ignore next @preserve */\n null : isNumber(keyTimers) ? keyTimers : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (element, key) => {\n if (!isHTMLElement(element)) return;\n const keyTimers = TimeCache.get(element);\n key && key.length && isMap(keyTimers) ? (clearTimeout(keyTimers.get(key)), keyTimers.delete(key), keyTimers.size === 0 && TimeCache.delete(element)) : (clearTimeout(keyTimers), TimeCache.delete(element));\n }\n}, toUpperCase = (source) => source.toUpperCase(), querySelectorAll = (selector, parent) => (isNode(parent) ? parent : getDocument()).querySelectorAll(selector), focusTrapMap = /* @__PURE__ */ new Map();\nfunction handleKeyboardNavigation(event) {\n const { shiftKey, code } = event, doc = getDocument(this), focusableElements = [\n ...querySelectorAll(focusableSelector, this)\n ].filter(\n (el) => !hasAttribute(el, \"disabled\") && !getAttribute(el, ariaHidden)\n );\n if (!focusableElements.length) return;\n const firstFocusable = focusableElements[0], lastFocusable = focusableElements[focusableElements.length - 1];\n code === \"Tab\" && (shiftKey && doc.activeElement === firstFocusable ? (lastFocusable.focus(), event.preventDefault()) : !shiftKey && doc.activeElement === lastFocusable && (firstFocusable.focus(), event.preventDefault()));\n}\nconst hasFocusTrap = (target) => focusTrapMap.has(target) === !0, toggleFocusTrap = (target) => {\n const isCurrentlyTrapped = hasFocusTrap(target);\n (isCurrentlyTrapped ? off : on)(target, \"keydown\", handleKeyboardNavigation), isCurrentlyTrapped ? focusTrapMap.delete(target) : focusTrapMap.set(target, !0);\n}, getBoundingClientRect = (element, includeScale) => {\n const { width, height, top, right, bottom, left } = element.getBoundingClientRect();\n let scaleX = 1, scaleY = 1;\n if (includeScale && isHTMLElement(element)) {\n const { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n scaleX = offsetWidth2 > 0 ? Math.round(width) / offsetWidth2 : (\n /* istanbul ignore next @preserve */\n 1\n ), scaleY = offsetHeight2 > 0 ? Math.round(height) / offsetHeight2 : (\n /* istanbul ignore next @preserve */\n 1\n );\n }\n return {\n width: width / scaleX,\n height: height / scaleY,\n top: top / scaleY,\n right: right / scaleX,\n bottom: bottom / scaleY,\n left: left / scaleX,\n x: left / scaleX,\n y: top / scaleY\n };\n}, getDocumentBody = (node) => getDocument(node).body, getDocumentElement = (node) => getDocument(node).documentElement, getDocumentHead = (node) => getDocument(node).head, getNodeScroll = (element) => {\n const isWin = isWindow(element), x = isWin ? element.scrollX : element.scrollLeft, y = isWin ? element.scrollY : element.scrollTop;\n return { x, y };\n}, isShadowRoot = (element) => isNode(element) && element.constructor.name === \"ShadowRoot\" || !1, getParentNode = (node) => node.nodeName === \"HTML\" ? node : isHTMLElement(node) && node.assignedSlot || // step into the shadow DOM of the parent of a slotted node\nisNode(node) && node.parentNode || // DOM Element detected\nisShadowRoot(node) && node.host || // ShadowRoot detected\ngetDocumentElement(node), isScaledElement = (element) => {\n if (!isHTMLElement(element)) return !1;\n const { width, height } = getBoundingClientRect(element), { offsetWidth: offsetWidth2, offsetHeight: offsetHeight2 } = element;\n return Math.round(width) !== offsetWidth2 || Math.round(height) !== offsetHeight2;\n}, getRectRelativeToOffsetParent = (element, offsetParent, scroll) => {\n const isParentAnElement = isHTMLElement(offsetParent), rect = getBoundingClientRect(\n element,\n isParentAnElement && isScaledElement(offsetParent)\n ), offsets = { x: 0, y: 0 };\n if (isParentAnElement) {\n const offsetRect = getBoundingClientRect(offsetParent, !0);\n offsets.x = offsetRect.x + offsetParent.clientLeft, offsets.y = offsetRect.y + offsetParent.clientTop;\n }\n return {\n x: rect.left + scroll.x - offsets.x,\n y: rect.top + scroll.y - offsets.y,\n width: rect.width,\n height: rect.height\n };\n};\nlet elementUID = 0, elementMapUID = 0;\nconst elementIDMap = /* @__PURE__ */ new Map(), getUID = (element, key) => {\n let result = key ? elementUID : elementMapUID;\n if (key) {\n const elID = getUID(element), elMap = elementIDMap.get(elID) || /* @__PURE__ */ new Map();\n elementIDMap.has(elID) || elementIDMap.set(elID, elMap), isMap(elMap) && !elMap.has(key) ? (elMap.set(key, result), elementUID += 1) : result = elMap.get(key);\n } else {\n const elkey = element.id || element;\n elementIDMap.has(elkey) ? result = elementIDMap.get(elkey) : (elementIDMap.set(elkey, result), elementMapUID += 1);\n }\n return result;\n}, getWindow = (node) => node ? isDocument(node) ? node.defaultView : isNode(node) ? node?.ownerDocument?.defaultView : node : window, isArray = (obj) => Array.isArray(obj) || !1, isCanvas = (element) => isNode(element) && element.nodeName === \"CANVAS\" || !1, isCustomElement = (element) => isHTMLElement(element) && !!element.shadowRoot || !1, isElement = (element) => isNode(element) && [1, 2, 3, 4, 5, 6, 7, 8].some((x) => element.nodeType === x) || !1, isElementInScrollRange = (element) => {\n if (!isNode(element)) return !1;\n const { top, bottom } = getBoundingClientRect(element), { clientHeight } = getDocumentElement(element);\n return top <= clientHeight && bottom >= 0;\n}, isElementInViewport = (element) => {\n if (!isNode(element)) return !1;\n const { clientWidth, clientHeight } = getDocumentElement(element), { top, left, bottom, right } = getBoundingClientRect(element, !0);\n return top >= 0 && left >= 0 && bottom <= clientHeight && right <= clientWidth;\n}, isElementsArray = (obj) => isArray(obj) && obj.every(isHTMLElement) || !1, isFunction = (fn) => typeof fn == \"function\" || !1, isHTMLCollection = (obj) => isObject(obj) && obj.constructor.name === \"HTMLCollection\" || !1, isHTMLImageElement = (element) => isHTMLElement(element) && element.tagName === \"IMG\" || !1, isJSON = (str) => {\n if (!isString(str)) return !1;\n try {\n JSON.parse(str);\n } catch {\n return !1;\n }\n return !0;\n}, isWeakMap = (obj) => isObject(obj) && obj.constructor.name === \"WeakMap\" || !1, isMedia = (element) => isNode(element) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (s) => element.constructor.name.includes(s)\n) || !1, isNodeList = (obj) => isObject(obj) && obj.constructor.name === \"NodeList\" || !1, isRTL = (node) => getDocumentElement(node).dir === \"rtl\", isSVGElement = (element) => isNode(element) && element.constructor.name.includes(\"SVG\") || !1, isTableElement = (element) => isNode(element) && [\"TABLE\", \"TD\", \"TH\"].includes(element.nodeName) || !1, closest = (element, selector) => element ? element.closest(selector) || // break out of `ShadowRoot`\nclosest(element.getRootNode().host, selector) : null, querySelector = (selector, parent) => isHTMLElement(selector) ? selector : (isNode(parent) ? parent : getDocument()).querySelector(selector), getElementsByTagName = (selector, parent) => (isNode(parent) ? parent : getDocument()).getElementsByTagName(\n selector\n), getCustomElements = (parent) => [...getElementsByTagName(\"*\", parent)].filter(isCustomElement), getElementById = (id, context) => getDocument(context).getElementById(id) || null, getElementsByClassName = (selector, parent) => (parent && isNode(parent) ? parent : getDocument()).getElementsByClassName(\n selector\n), matches = (target, selector) => target.matches(selector), version = \"2.0.7\";\nexport {\n ArrayFrom,\n DOMContentLoadedEvent,\n DOMMouseScrollEvent,\n Data,\n Float32ArrayFrom,\n Float64ArrayFrom,\n ObjectAssign,\n ObjectEntries,\n ObjectFromEntries,\n ObjectHasOwn,\n ObjectKeys,\n ObjectValues,\n Timer,\n abortEvent,\n addClass,\n addEventListener,\n animationDelay,\n animationDuration,\n animationEndEvent,\n animationName,\n ariaChecked,\n ariaDescribedBy,\n ariaDescription,\n ariaExpanded,\n ariaHasPopup,\n ariaHidden,\n ariaLabel,\n ariaLabelledBy,\n ariaModal,\n ariaPressed,\n ariaSelected,\n ariaValueMax,\n ariaValueMin,\n ariaValueNow,\n ariaValueText,\n beforeunloadEvent,\n bezierEasings,\n blurEvent,\n changeEvent,\n closest,\n contextmenuEvent,\n createCustomEvent,\n createElement,\n createElementNS,\n dispatchEvent,\n distinct,\n documentBody,\n documentElement,\n documentHead,\n dragEvent,\n dragendEvent,\n dragenterEvent,\n dragleaveEvent,\n dragoverEvent,\n dragstartEvent,\n emulateAnimationEnd,\n emulateTransitionEnd,\n errorEvent,\n focus,\n focusEvent,\n focusEvents,\n focusableSelector,\n focusinEvent,\n focusoutEvent,\n gesturechangeEvent,\n gestureendEvent,\n gesturestartEvent,\n getAttribute,\n getAttributeNS,\n getBoundingClientRect,\n getCustomElements,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getDocumentHead,\n getElementAnimationDelay,\n getElementAnimationDuration,\n getElementById,\n getElementStyle,\n getElementTransitionDelay,\n getElementTransitionDuration,\n getElementsByClassName,\n getElementsByTagName,\n getInstance,\n getNodeScroll,\n getParentNode,\n getRectRelativeToOffsetParent,\n getUID,\n getWindow,\n hasAttribute,\n hasAttributeNS,\n hasClass,\n hasFocusTrap,\n isApple,\n isArray,\n isCanvas,\n isCustomElement,\n isDocument,\n isElement,\n isElementInScrollRange,\n isElementInViewport,\n isElementsArray,\n isFirefox,\n isFunction,\n isHTMLCollection,\n isHTMLElement,\n isHTMLImageElement,\n isJSON,\n isMap,\n isMedia,\n isMobile,\n isNode,\n isNodeList,\n isNumber,\n isObject,\n isRTL,\n isSVGElement,\n isScaledElement,\n isShadowRoot,\n isString,\n isTableElement,\n isWeakMap,\n isWindow,\n keyAlt,\n keyArrowDown,\n keyArrowLeft,\n keyArrowRight,\n keyArrowUp,\n keyBackspace,\n keyCapsLock,\n keyControl,\n keyDelete,\n keyEnter,\n keyEscape,\n keyInsert,\n keyMeta,\n keyNumpadEnter,\n keyPause,\n keyScrollLock,\n keyShift,\n keySpace,\n keyTab,\n keyboardEventKeys,\n keydownEvent,\n keypressEvent,\n keyupEvent,\n loadEvent,\n loadstartEvent,\n matches,\n mouseClickEvents,\n mouseHoverEvents,\n mouseSwipeEvents,\n mouseclickEvent,\n mousedblclickEvent,\n mousedownEvent,\n mouseenterEvent,\n mousehoverEvent,\n mouseinEvent,\n mouseleaveEvent,\n mousemoveEvent,\n mouseoutEvent,\n mouseoverEvent,\n mouseupEvent,\n mousewheelEvent,\n moveEvent,\n nativeEvents,\n noop,\n normalizeOptions,\n normalizeValue,\n off,\n offsetHeight,\n offsetWidth,\n on,\n one,\n orientationchangeEvent,\n passiveHandler,\n pointercancelEvent,\n pointerdownEvent,\n pointerleaveEvent,\n pointermoveEvent,\n pointerupEvent,\n querySelector,\n querySelectorAll,\n readystatechangeEvent,\n reflow,\n removeAttribute,\n removeAttributeNS,\n removeClass,\n removeEventListener,\n resetEvent,\n resizeEvent,\n scrollEvent,\n scrollHeight,\n scrollWidth,\n selectEvent,\n selectendEvent,\n selectstartEvent,\n setAttribute,\n setAttributeNS,\n setElementStyle,\n submitEvent,\n support3DTransform,\n supportAnimation,\n supportPassive,\n supportTouch,\n supportTransform,\n supportTransition,\n tabindex,\n toLowerCase,\n toUpperCase,\n toggleFocusTrap,\n touchEvents,\n touchcancelEvent,\n touchendEvent,\n touchmoveEvent,\n touchstartEvent,\n transitionDelay,\n transitionDuration,\n transitionEndEvent,\n transitionProperty,\n unloadEvent,\n userAgent,\n userAgentData,\n version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const e = {}, f = (t) => {\n const { type: c, currentTarget: i } = t;\n [...e[c]].forEach(([n, s]) => {\n /* istanbul ignore else @preserve */\n i === n && [...s].forEach(([o, a]) => {\n o.apply(n, [t]), typeof a == \"object\" && a.once && r(n, c, o, a);\n });\n });\n}, E = (t, c, i, n) => {\n /* istanbul ignore else @preserve */\n e[c] || (e[c] = /* @__PURE__ */ new Map());\n const s = e[c];\n /* istanbul ignore else @preserve */\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(t), { size: a } = o;\n o.set(i, n);\n /* istanbul ignore else @preserve */\n a || t.addEventListener(c, f, n);\n}, r = (t, c, i, n) => {\n const s = e[c], o = s && s.get(t), a = o && o.get(i), d = a !== void 0 ? a : n;\n /* istanbul ignore else @preserve */\n o && o.has(i) && o.delete(i);\n /* istanbul ignore else @preserve */\n s && (!o || !o.size) && s.delete(t);\n /* istanbul ignore else @preserve */\n (!s || !s.size) && delete e[c];\n /* istanbul ignore else @preserve */\n (!o || !o.size) && t.removeEventListener(\n c,\n f,\n d\n );\n}, g = E, M = r;\nexport {\n E as addListener,\n f as globalListener,\n M as off,\n g as on,\n e as registry,\n r as removeListener\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isHTMLElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: HTMLElement;\n declare options?: BaseOptions;\n\n /**\n * @param target `HTMLElement` or selector string\n * @param config component instance options\n */\n constructor(target: HTMLElement | string, config?: BaseOptions) {\n let element: HTMLElement | null;\n\n try {\n if (isHTMLElement(target)) {\n element = target;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n // istanbul ignore else @preserve\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: HTMLElement) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: HTMLElement) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: HTMLElement | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(alertDismissSelector, this.element);\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: HTMLElement) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: HTMLElement) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: HTMLElement) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: ScrollSpyOptions = {\n offset: 10,\n target: null,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: HTMLElement) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: HTMLElement) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const { target, scrollTarget, options, itemsLength, scrollHeight, element } =\n self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href;\n let targetItem;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n targetItem = href && href.charAt(0) === \"#\" && href.slice(-1) !== \"#\" &&\n querySelector(href, doc);\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: HTMLElement) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: HTMLElement) => {\n [...getElementsByTagName(\"A\", target)].forEach((item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n });\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: HTMLElement | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // additional properties\n this.target = querySelector(\n options.target as HTMLElement | string,\n getDocument(element),\n );\n\n // invalidate\n if (this.target) {\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver(() => this.refresh(), {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n\n // check if target is visible and invalidate\n // istanbul ignore else @preserve\n if (isHTMLElement(target) && target.offsetHeight > 0) {\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) {\n activate(this, newActiveItem);\n }\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n }\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: HTMLElement) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: HTMLElement) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: HTMLElement | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (isHTMLElement(c)) addClass(c, \"overflow-hidden\");\n });\n currentHeight = isHTMLElement(content)\n ? content.scrollHeight // istanbul ignore next @preserve\n : 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore else @preserve\n if (!showTabEvent.defaultPrevented) {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n }\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav as HTMLElement | undefined)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(activeClass, nav as HTMLElement);\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab as HTMLElement)\n ? getTargetElement(tab as HTMLElement)\n : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement): HTMLElement | null => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: Event) => {\n const self = getTabInstance(e.target as HTMLElement);\n\n // istanbul ignore else @preserve\n if (self) {\n e.preventDefault();\n self.show();\n }\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: HTMLElement | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (content) {\n const nav = closest(element, \".nav\");\n const container = closest(content, \".tab-content\");\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if (!(nav && Timer.get(nav)) && !hasClass(element, activeClass)) {\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(tab)) {\n dispatchEvent(tab as EventTarget, hideTabEvent);\n // istanbul ignore else @preserve\n if (!hideTabEvent.defaultPrevented) {\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: HTMLElement) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: HTMLElement) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore else @preserve\n if (self) {\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n }\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target as HTMLElement;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore else @preserve: a solid filter is required\n if (\n self && element !== relatedTarget &&\n !element.contains(relatedTarget as Node)\n ) {\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: HTMLElement | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(toastToggleSelector, getDocument(element)),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && !isShown) {\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) {\n showToast(this);\n }\n }\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore else @preserve\n if (element && isShown) {\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) {\n hideToast(this);\n }\n }\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) {\n removeClass(element, showClass);\n }\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: HTMLElement) => Component,\n collection: HTMLCollectionOf | HTMLElement[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["exports","ariaDescribedBy","ariaExpanded","ariaHidden","ariaModal","ariaPressed","ariaSelected","focusEvent","focusinEvent","focusoutEvent","keydownEvent","keyupEvent","mouseclickEvent","mousedownEvent","mousehoverEvent","mouseenterEvent","mouseleaveEvent","pointerdownEvent","pointermoveEvent","pointerupEvent","touchstartEvent","dragstartEvent","focusableSelector","keyArrowDown","keyArrowUp","keyArrowLeft","keyArrowRight","keyEscape","transitionDuration","transitionDelay","transitionEndEvent","transitionProperty","isApple","appleBrands","x","noop","on","element","eventName","listener","options","ops","off","getAttribute","att","hasAttribute","setAttribute","value","removeAttribute","addClass","classNAME","removeClass","hasClass","isObject","obj","isNode","node","isHTMLElement","componentData","Data","component","instance","instanceMap","getInstance","target","isString","str","isWindow","isDocument","getDocument","ObjectAssign","source","createElement","param","tagName","newElement","attr","dispatchEvent","event","getElementStyle","property","computedStyle","prop","getElementTransitionDelay","propertyValue","delayValue","delayScale","duration","getElementTransitionDuration","durationValue","durationScale","emulateTransitionEnd","handler","called","endEvent","delay","transitionEndWrapper","e","focus","normalizeValue","ObjectEntries","toLowerCase","normalizeOptions","defaultOps","inputOps","ns","INPUT","data","normalOps","dataOps","title","k","v","key","match","ObjectKeys","createCustomEvent","eventType","config","OriginalCustomEvent","passiveHandler","reflow","setElementStyle","styles","propObject","isMap","isNumber","num","TimeCache","Timer","callback","keyTimers","querySelectorAll","selector","parent","focusTrapMap","handleKeyboardNavigation","shiftKey","code","doc","focusableElements","el","firstFocusable","lastFocusable","hasFocusTrap","toggleFocusTrap","isCurrentlyTrapped","getBoundingClientRect","includeScale","width","height","top","right","bottom","left","scaleX","scaleY","offsetWidth2","offsetHeight2","getDocumentBody","getDocumentElement","isShadowRoot","getParentNode","elementUID","elementMapUID","elementIDMap","getUID","result","elID","elMap","elkey","getWindow","isArray","isElementInScrollRange","clientHeight","isFunction","fn","isNodeList","isRTL","isTableElement","closest","querySelector","getElementsByTagName","getElementsByClassName","matches","f","t","c","i","s","o","r","E","d","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","BaseComponent","prevInstance","alertSelector","alertDismissSelector","getAlertInstance","alertInitCallback","Alert","closeAlertEvent","closedAlertEvent","alertTransitionEnd","self","add","action","addListener","removeListener","dismiss","close","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","isActive","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","attValue","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","activeItem","getActiveIndex","orientation","directionClass","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","RTL","carouselDragHandler","carouselPointerDownHandler","controls","indicators","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","activeIndex","transitionItem","ar","isPaused","idx","next","eventProperties","touch","pause","interval","keyboard","arrow","indicator","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","triggers","btn","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","menuEnd","p","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","targetLeft","targetTop","targetWidth","targetHeight","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","dropdownPreventScroll","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","dropdownClickHandler","activeElement","open","menuItems","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","fixedItems","fixed","measureScrollbar","innerWidth","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","appendPopup","customContainer","containerIsBody","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","afterModalShow","beforeModalShow","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","overlayDelay","currentOpen","that","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","tipPositions","isPopover","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","y","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","tooltipDefaults","_","B","m","n","h","l","u","a","b","g","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","tempDocument","createTip","id","template","animation","customClass","dismissible","btnClose","tipString","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","offsetParent","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","position","PositionObserver","outTimer","tipContainer","showTooltipEvent","hideTooltipEvent","enabled","tr","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","isRoot","links","scrollHEIGHT","href","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","_observer","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","scrollTop","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","context","compData","initCallback","lookUp","elemCollection","cs","init","removeDataAPI","comp"],"mappings":"AAAK,IAAA,IAAA,SAAAA,EAAA,CAAA,aAAA,MAAqEC,GAAkB,mBAAoBC,GAAe,gBAAiDC,GAAa,cAA6EC,GAAY,aAAcC,GAAc,eAAgBC,GAAe,gBAAqYC,GAAa,QAASC,GAAe,UAAWC,GAAgB,WAAsHC,GAAe,UAAuCC,GAAa,QAA6BC,EAAkB,QAA0CC,GAAiB,YAAuCC,GAAkB,QAASC,GAAkB,aAAcC,GAAkB,aAAwQC,GAAmB,cAAmDC,GAAmB,cAAeC,GAAiB,YAA+OC,GAAkB,aAmDxxDC,GAAiB,YAaaC,GAAoB,oFAuCtDC,GAAe,YAAaC,GAAa,UAAWC,GAAe,YAAaC,GAAgB,aAAsKC,GAAY,SAA6SC,GAAqB,qBAAsBC,GAAkB,kBAAmBC,GAAqB,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AC,EAE7CP,GAAA,QAASS,GAAO,CACvB,KAAA,CAAE,KAAAC,EAAM,SAAAxjB,CAAA,EAAaujB,EAC3BR,GACES,EACAF,EAAe,OAAQvE,GAAS5b,GAAQ4b,EAAM/e,CAAQ,CAAC,CACzD,CAAA,CACD,CACH,EAOayjB,GAAiBP,GAAyB,CACrD,MAAMG,EAASH,GAAWA,EAAQ,SAAWA,EAAU,SAExCJ,GAAA,QAASY,GAAS,CACRT,GAAAS,EAAK,UAAU,KAAML,CAAM,CAAA,CACnD,CACH,EAGA,OAAI,SAAS,KAAmBD,GAAA,EAE9Bpe,EAAY,SAAU,mBAAoB,IAAMoe,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP,EACHzrB,EAAA,MAAA8M,GAAA9M,EAAA,OAAAgO,GAAAhO,EAAA,SAAAkP,GAAAlP,EAAA,SAAAsS,GAAAtS,EAAA,SAAAgU,GAAAhU,EAAA,MAAA2a,GAAA3a,EAAA,UAAAkd,GAAAld,EAAA,QAAA2lB,GAAA3lB,EAAA,UAAAkmB,GAAAlmB,EAAA,IAAAooB,GAAApoB,EAAA,MAAAsqB,GAAAtqB,EAAA,QAAA8jB,GAAA9jB,EAAA,aAAAyrB,GAAAzrB,EAAA,cAAA8rB,GAAA,OAAA,eAAA9rB,EAAA,OAAA,YAAA,CAAA,MAAA,QAAA,CAAA,EAAAA,CAAA,EAAA,CAAA,CAAA","x_google_ignoreList":[0,1,52]} \ No newline at end of file +{"version":3,"file":"bootstrap-native.js","sources":["../node_modules/.pnpm/@thednp+shorty@https+++codeload.github.com+thednp+shorty+tar.gz+309d581b370f747cb15531ca6c201def3827e05c/node_modules/@thednp/shorty/dist/shorty.mjs","../node_modules/.pnpm/@thednp+event-listener@2.0.8/node_modules/@thednp/event-listener/dist/event-listener.mjs","../src/strings/fadeClass.ts","../src/strings/showClass.ts","../src/strings/dataBsDismiss.ts","../src/strings/alertString.ts","../src/strings/alertComponent.ts","../src/version.ts","../src/components/base-component.ts","../src/components/alert.ts","../src/strings/activeClass.ts","../src/strings/dataBsToggle.ts","../src/strings/buttonString.ts","../src/strings/buttonComponent.ts","../src/components/button.ts","../src/strings/dataBsTarget.ts","../src/strings/carouselString.ts","../src/strings/carouselComponent.ts","../src/strings/dataBsParent.ts","../src/strings/dataBsContainer.ts","../src/util/getTargetElement.ts","../src/components/carousel.ts","../src/strings/collapsingClass.ts","../src/strings/collapseString.ts","../src/strings/collapseComponent.ts","../src/components/collapse.ts","../src/strings/dropdownClasses.ts","../src/strings/dropdownComponent.ts","../src/strings/dropdownMenuClass.ts","../src/util/isEmptyAnchor.ts","../src/components/dropdown.ts","../src/strings/modalString.ts","../src/strings/modalComponent.ts","../src/strings/offcanvasComponent.ts","../src/strings/fixedTopClass.ts","../src/strings/fixedBottomClass.ts","../src/strings/stickyTopClass.ts","../src/strings/positionStickyClass.ts","../src/util/scrollbar.ts","../src/strings/offcanvasString.ts","../src/util/popupContainer.ts","../src/util/backdrop.ts","../src/util/isVisible.ts","../src/components/modal.ts","../src/components/offcanvas.ts","../src/strings/popoverString.ts","../src/strings/popoverComponent.ts","../src/strings/tooltipString.ts","../src/util/getTipTemplate.ts","../src/util/tipClassPositions.ts","../src/util/styleTip.ts","../src/util/tooltipDefaults.ts","../node_modules/.pnpm/@thednp+position-observer@https+++codeload.github.com+thednp+position-observer+tar.gz+d693d53_hyk7lpzuqi6vnifksl6nzudy5a/node_modules/@thednp/position-observer/dist/index.mjs","../src/strings/dataOriginalTitle.ts","../src/strings/tooltipComponent.ts","../src/util/setHtml.ts","../src/util/createTip.ts","../src/util/getElementContainer.ts","../src/components/tooltip.ts","../src/components/popover.ts","../src/strings/scrollspyString.ts","../src/strings/scrollspyComponent.ts","../src/components/scrollspy.ts","../src/strings/tabString.ts","../src/strings/tabComponent.ts","../src/components/tab.ts","../src/strings/toastString.ts","../src/strings/toastComponent.ts","../src/components/toast.ts","../src/util/init.ts"],"sourcesContent":["const Ce = \"2.0.8\", Le = \"aria-checked\", Me = \"aria-description\", De = \"aria-describedby\", Oe = \"aria-expanded\", xe = \"aria-haspopup\", $ = \"aria-hidden\", ze = \"aria-label\", Ie = \"aria-labelledby\", Pe = \"aria-modal\", Be = \"aria-pressed\", Fe = \"aria-selected\", He = \"aria-valuemin\", Ve = \"aria-valuemax\", Ue = \"aria-valuenow\", We = \"aria-valuetext\", J = \"abort\", X = \"beforeunload\", tt = \"blur\", et = \"change\", nt = \"contextmenu\", V = \"DOMContentLoaded\", ot = \"DOMMouseScroll\", st = \"error\", rt = \"focus\", ct = \"focusin\", at = \"focusout\", it = \"gesturechange\", ut = \"gestureend\", lt = \"gesturestart\", dt = \"keydown\", ft = \"keypress\", pt = \"keyup\", gt = \"load\", mt = \"click\", vt = \"dblclick\", bt = \"mousedown\", Et = \"mouseup\", ht = \"hover\", yt = \"mouseenter\", wt = \"mouseleave\", At = \"mousein\", St = \"mouseout\", Tt = \"mouseover\", kt = \"mousemove\", Nt = \"mousewheel\", Ct = \"move\", Lt = \"orientationchange\", Mt = \"pointercancel\", Dt = \"pointerdown\", Ot = \"pointerleave\", xt = \"pointermove\", zt = \"pointerup\", It = \"readystatechange\", Pt = \"reset\", Bt = \"resize\", Ft = \"select\", Ht = \"selectend\", Vt = \"selectstart\", Ut = \"scroll\", Wt = \"submit\", Rt = \"touchstart\", Qt = \"touchmove\", jt = \"touchcancel\", Gt = \"touchend\", Kt = \"unload\", Re = {\n DOMContentLoaded: V,\n DOMMouseScroll: ot,\n abort: J,\n beforeunload: X,\n blur: tt,\n change: et,\n click: mt,\n contextmenu: nt,\n dblclick: vt,\n error: st,\n focus: rt,\n focusin: ct,\n focusout: at,\n gesturechange: it,\n gestureend: ut,\n gesturestart: lt,\n hover: ht,\n keydown: dt,\n keypress: ft,\n keyup: pt,\n load: gt,\n mousedown: bt,\n mousemove: kt,\n mousein: At,\n mouseout: St,\n mouseenter: yt,\n mouseleave: wt,\n mouseover: Tt,\n mouseup: Et,\n mousewheel: Nt,\n move: Ct,\n orientationchange: Lt,\n pointercancel: Mt,\n pointerdown: Dt,\n pointerleave: Ot,\n pointermove: xt,\n pointerup: zt,\n readystatechange: It,\n reset: Pt,\n resize: Bt,\n scroll: Ut,\n select: Ft,\n selectend: Ht,\n selectstart: Vt,\n submit: Wt,\n touchcancel: jt,\n touchend: Gt,\n touchmove: Qt,\n touchstart: Rt,\n unload: Kt\n}, Qe = \"drag\", je = \"dragstart\", Ge = \"dragenter\", Ke = \"dragleave\", qe = \"dragover\", Ze = \"dragend\", Ye = \"loadstart\", _e = {\n start: \"mousedown\",\n end: \"mouseup\",\n move: \"mousemove\",\n cancel: \"mouseleave\"\n}, $e = { down: \"mousedown\", up: \"mouseup\" }, Je = \"onmouseleave\" in document ? [\"mouseenter\", \"mouseleave\"] : [\"mouseover\", \"mouseout\"], Xe = {\n start: \"touchstart\",\n end: \"touchend\",\n move: \"touchmove\",\n cancel: \"touchcancel\"\n}, tn = { in: \"focusin\", out: \"focusout\" }, qt = 'a[href], button, input, textarea, select, details, [tabindex]:not([tabindex=\"-1\"]', en = {\n Backspace: \"Backspace\",\n Tab: \"Tab\",\n Enter: \"Enter\",\n Shift: \"Shift\",\n Control: \"Control\",\n Alt: \"Alt\",\n Pause: \"Pause\",\n CapsLock: \"CapsLock\",\n Escape: \"Escape\",\n Scape: \"Space\",\n ArrowLeft: \"ArrowLeft\",\n ArrowUp: \"ArrowUp\",\n ArrowRight: \"ArrowRight\",\n ArrowDown: \"ArrowDown\",\n Insert: \"Insert\",\n Delete: \"Delete\",\n Meta: \"Meta\",\n ContextMenu: \"ContextMenu\",\n ScrollLock: \"ScrollLock\"\n}, nn = \"Alt\", on = \"ArrowDown\", sn = \"ArrowUp\", rn = \"ArrowLeft\", cn = \"ArrowRight\", an = \"Backspace\", un = \"CapsLock\", ln = \"Control\", dn = \"Delete\", fn = \"Enter\", pn = \"NumpadEnter\", gn = \"Escape\", mn = \"Insert\", vn = \"Meta\", bn = \"Pause\", En = \"ScrollLock\", hn = \"Shift\", yn = \"Space\", wn = \"Tab\", Zt = \"animationDuration\", Yt = \"animationDelay\", U = \"animationName\", L = \"animationend\", _t = \"transitionDuration\", $t = \"transitionDelay\", M = \"transitionend\", W = \"transitionProperty\", An = \"addEventListener\", Sn = \"removeEventListener\", Tn = {\n linear: \"linear\",\n easingSinusoidalIn: \"cubic-bezier(0.47,0,0.745,0.715)\",\n easingSinusoidalOut: \"cubic-bezier(0.39,0.575,0.565,1)\",\n easingSinusoidalInOut: \"cubic-bezier(0.445,0.05,0.55,0.95)\",\n easingQuadraticIn: \"cubic-bezier(0.550,0.085,0.680,0.530)\",\n easingQuadraticOut: \"cubic-bezier(0.250,0.460,0.450,0.940)\",\n easingQuadraticInOut: \"cubic-bezier(0.455,0.030,0.515,0.955)\",\n easingCubicIn: \"cubic-bezier(0.55,0.055,0.675,0.19)\",\n easingCubicOut: \"cubic-bezier(0.215,0.61,0.355,1)\",\n easingCubicInOut: \"cubic-bezier(0.645,0.045,0.355,1)\",\n easingQuarticIn: \"cubic-bezier(0.895,0.03,0.685,0.22)\",\n easingQuarticOut: \"cubic-bezier(0.165,0.84,0.44,1)\",\n easingQuarticInOut: \"cubic-bezier(0.77,0,0.175,1)\",\n easingQuinticIn: \"cubic-bezier(0.755,0.05,0.855,0.06)\",\n easingQuinticOut: \"cubic-bezier(0.23,1,0.32,1)\",\n easingQuinticInOut: \"cubic-bezier(0.86,0,0.07,1)\",\n easingExponentialIn: \"cubic-bezier(0.95,0.05,0.795,0.035)\",\n easingExponentialOut: \"cubic-bezier(0.19,1,0.22,1)\",\n easingExponentialInOut: \"cubic-bezier(1,0,0,1)\",\n easingCircularIn: \"cubic-bezier(0.6,0.04,0.98,0.335)\",\n easingCircularOut: \"cubic-bezier(0.075,0.82,0.165,1)\",\n easingCircularInOut: \"cubic-bezier(0.785,0.135,0.15,0.86)\",\n easingBackIn: \"cubic-bezier(0.6,-0.28,0.735,0.045)\",\n easingBackOut: \"cubic-bezier(0.175,0.885,0.32,1.275)\",\n easingBackInOut: \"cubic-bezier(0.68,-0.55,0.265,1.55)\"\n}, kn = \"offsetHeight\", Nn = \"offsetWidth\", Cn = \"scrollHeight\", Ln = \"scrollWidth\", Mn = \"tabindex\", Dn = navigator.userAgentData, { userAgent: Jt } = navigator, On = Jt, xn = () => {\n const t = /iPhone|iPad|iPod|Android/i;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(navigator?.userAgent) || !1;\n}, zn = () => {\n const t = /(iPhone|iPod|iPad)/;\n return navigator?.userAgentData?.brands.some(\n (e) => t.test(e.brand)\n ) || t.test(\n navigator?.userAgent\n ) || !1;\n}, In = () => navigator?.userAgent?.includes(\"Firefox\") || !1, Xt = () => typeof CSS > \"u\" || !CSS.supports ? !1 : CSS.supports(\"-webkit-backdrop-filter\", \"none\"), Pn = () => [\"webkitPerspective\", \"perspective\"].some((t) => t in document.head.style), te = () => {\n}, R = (t, e, n, o) => {\n const s = o || !1;\n t.addEventListener(\n e,\n n,\n s\n );\n}, Q = (t, e, n, o) => {\n const s = o || !1;\n t.removeEventListener(\n e,\n n,\n s\n );\n}, ee = (t, e, n, o) => {\n const s = (r) => {\n (r.target === t || r.currentTarget === t) && (n.apply(t, [r]), Q(t, e, s, o));\n };\n R(t, e, s, o);\n}, Bn = () => {\n let t = !1;\n try {\n const e = Object.defineProperty({}, \"passive\", {\n get: () => (t = !0, t)\n });\n ee(document, V, te, e);\n } catch {\n }\n return t;\n}, Fn = () => [\"webkitTransform\", \"transform\"].some((t) => t in document.head.style), Hn = () => \"ontouchstart\" in window || \"msMaxTouchPoints\" in navigator, Vn = () => [\"webkitAnimation\", \"animation\"].some((t) => t in document.head.style), Un = () => [\"webkitTransition\", \"transition\"].some((t) => t in document.head.style), j = (t, e) => t.getAttribute(e), Wn = (t, e, n) => e.getAttributeNS(t, n), ne = (t, e) => t.hasAttribute(e), Rn = (t, e, n) => e.hasAttributeNS(t, n), Qn = (t, e, n) => t.setAttribute(e, n), jn = (t, e, n, o) => e.setAttributeNS(t, n, o), Gn = (t, e) => t.removeAttribute(e), Kn = (t, e, n) => e.removeAttributeNS(t, n), qn = (t, ...e) => {\n t.classList.add(...e);\n}, Zn = (t, ...e) => {\n t.classList.remove(...e);\n}, Yn = (t, e) => t.classList.contains(e), { body: _n } = document, { documentElement: $n } = document, { head: Jn } = document, Xn = (t) => Array.from(t), b = (t) => t != null && typeof t == \"object\" || !1, l = (t) => b(t) && typeof t.nodeType == \"number\" && [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11].some(\n (e) => t.nodeType === e\n) || !1, u = (t) => l(t) && t.nodeType === 1 || !1, h = /* @__PURE__ */ new Map(), O = {\n data: h,\n /**\n * Sets web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @param instance the component instance\n */\n set: (t, e, n) => {\n if (!u(t)) return;\n h.has(e) || h.set(e, /* @__PURE__ */ new Map()), h.get(e).set(t, n);\n },\n /**\n * Returns all instances for specified component.\n *\n * @param component the component's name or a unique key\n * @returns all the component instances\n */\n getAllFor: (t) => h.get(t) || null,\n /**\n * Returns the instance associated with the target.\n *\n * @param element target element\n * @param component the component's name or a unique key\n * @returns the instance\n */\n get: (t, e) => {\n if (!u(t) || !e) return null;\n const n = O.getAllFor(e);\n return t && n && n.get(t) || null;\n },\n /**\n * Removes web components data.\n *\n * @param element target element\n * @param component the component's name or a unique key\n */\n remove: (t, e) => {\n const n = O.getAllFor(e);\n !n || !u(t) || (n.delete(t), n.size === 0 && h.delete(e));\n }\n}, to = (t, e) => O.get(t, e), eo = (t) => t?.charAt(0).toUpperCase() + t?.slice(1), no = (t) => t?.trim().replace(\n /(?:^\\w|[A-Z]|\\b\\w)/g,\n (e, n) => n === 0 ? e.toLowerCase() : e.toUpperCase()\n).replace(/\\s+/g, \"\"), k = (t) => typeof t == \"string\" || !1, G = (t) => b(t) && t.constructor.name === \"Window\" || !1, K = (t) => l(t) && t.nodeType === 9 || !1, d = (t) => K(t) ? t : l(t) ? t.ownerDocument : G(t) ? t.document : globalThis.document, N = (t, ...e) => Object.assign(t, ...e), oe = (t) => {\n if (!t) return;\n if (k(t))\n return d().createElement(t);\n const { tagName: e } = t, n = oe(e);\n if (!n) return;\n const o = { ...t };\n return delete o.tagName, N(n, o);\n}, se = (t, e) => {\n if (!t || !e) return;\n if (k(e))\n return d().createElementNS(t, e);\n const { tagName: n } = e, o = se(t, n);\n if (!o) return;\n const s = { ...e };\n return delete s.tagName, N(o, s);\n}, q = (t, e) => t.dispatchEvent(e), oo = (t, e, n) => n.indexOf(t) === e, g = (t, e, n) => {\n const o = getComputedStyle(t, n), s = e.replace(\"webkit\", \"Webkit\").replace(/([A-Z])/g, \"-$1\").toLowerCase();\n return o.getPropertyValue(s);\n}, re = (t) => {\n const e = g(t, U), n = g(t, Yt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ce = (t) => {\n const e = g(t, U), n = g(t, Zt), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, so = (t, e) => {\n let n = 0;\n const o = new Event(L), s = ce(t), r = re(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(L, a), n = 1);\n };\n t.addEventListener(L, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, ae = (t) => {\n const e = g(t, W), n = g(t, $t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ie = (t) => {\n const e = g(t, W), n = g(t, _t), o = n.includes(\"ms\") ? 1 : 1e3, s = e && e !== \"none\" ? parseFloat(n) * o : 0;\n return Number.isNaN(s) ? 0 : s;\n}, ro = (t, e) => {\n let n = 0;\n const o = new Event(M), s = ie(t), r = ae(t);\n if (s) {\n const a = (i) => {\n i.target === t && (e.apply(t, [i]), t.removeEventListener(M, a), n = 1);\n };\n t.addEventListener(M, a), setTimeout(() => {\n n || q(t, o);\n }, s + r + 17);\n } else\n e.apply(t, [o]);\n}, co = (t) => Float32Array.from(Array.from(t)), ao = (t) => Float64Array.from(Array.from(t)), io = (t, e) => t.focus(e), uo = (t) => t?.trim().replace(/([a-z])([A-Z])/g, \"$1-$2\").replace(/\\s+/g, \"-\").toLowerCase(), P = (t) => [\"true\", !0].includes(t) ? !0 : [\"false\", !1].includes(t) ? !1 : [\"null\", \"\", null, void 0].includes(t) ? null : t !== \"\" && !Number.isNaN(+t) ? +t : t, T = (t) => Object.entries(t), ue = (t) => t.toLowerCase(), lo = (t, e, n, o) => {\n if (!u(t)) return e;\n const s = { ...n }, r = { ...t.dataset }, a = { ...e }, i = {}, f = \"title\";\n return T(r).forEach(([c, p]) => {\n const E = o && typeof c == \"string\" && c.includes(o) ? c.replace(o, \"\").replace(\n /[A-Z]/g,\n (C) => ue(C)\n ) : c;\n i[E] = P(p);\n }), T(s).forEach(([c, p]) => {\n s[c] = P(p);\n }), T(e).forEach(([c, p]) => {\n c in s ? a[c] = s[c] : c in i ? a[c] = i[c] : a[c] = c === f ? j(t, f) : p;\n }), a;\n}, fo = (t, e) => b(t) && (Object.hasOwn(t, e) || e in t), po = (t) => Object.keys(t), go = (t) => Object.values(t), mo = (t) => Object.fromEntries(t), vo = (t, e) => {\n const n = new CustomEvent(t, {\n cancelable: !0,\n bubbles: !0\n });\n return b(e) && N(n, e), n;\n}, bo = { passive: !0 }, Eo = (t) => t.offsetHeight, ho = (t, e) => {\n T(e).forEach(([n, o]) => {\n if (o && k(n) && n.includes(\"--\"))\n t.style.setProperty(n, o);\n else {\n const s = {};\n s[n] = o, N(t.style, s);\n }\n });\n}, x = (t) => b(t) && t.constructor.name === \"Map\" || !1, le = (t) => typeof t == \"number\" || !1, v = /* @__PURE__ */ new Map(), yo = {\n /**\n * Sets a new timeout timer for an element, or element -> key association.\n *\n * @param element target element\n * @param callback the callback\n * @param delay the execution delay\n * @param key a unique key\n */\n set: (t, e, n, o) => {\n u(t) && (o && o.length ? (v.has(t) || v.set(t, /* @__PURE__ */ new Map()), v.get(t).set(o, setTimeout(e, n))) : v.set(t, setTimeout(e, n)));\n },\n /**\n * Returns the timer associated with the target.\n *\n * @param element target element\n * @param key a unique\n * @returns the timer\n */\n get: (t, e) => {\n if (!u(t)) return null;\n const n = v.get(t);\n return e && n && x(n) ? n.get(e) || null : le(n) ? n : null;\n },\n /**\n * Clears the element's timer.\n *\n * @param element target element\n * @param key a unique key\n */\n clear: (t, e) => {\n if (!u(t)) return;\n const n = v.get(t);\n e && e.length && x(n) ? (clearTimeout(n.get(e)), n.delete(e), n.size === 0 && v.delete(t)) : (clearTimeout(n), v.delete(t));\n }\n}, wo = (t) => t.toUpperCase(), de = (t, e) => (l(e) ? e : d()).querySelectorAll(t), z = /* @__PURE__ */ new Map();\nfunction fe(t) {\n const { shiftKey: e, code: n } = t, o = d(this), s = [\n ...de(qt, this)\n ].filter(\n (i) => !ne(i, \"disabled\") && !j(i, $)\n );\n if (!s.length) return;\n const r = s[0], a = s[s.length - 1];\n n === \"Tab\" && (e && o.activeElement === r ? (a.focus(), t.preventDefault()) : !e && o.activeElement === a && (r.focus(), t.preventDefault()));\n}\nconst pe = (t) => z.has(t) === !0, Ao = (t) => {\n const e = pe(t);\n (e ? Q : R)(t, \"keydown\", fe), e ? z.delete(t) : z.set(t, !0);\n}, m = (t) => u(t) && \"offsetWidth\" in t || !1, w = (t, e) => {\n const { width: n, height: o, top: s, right: r, bottom: a, left: i } = t.getBoundingClientRect();\n let f = 1, c = 1;\n if (e && m(t)) {\n const { offsetWidth: p, offsetHeight: E } = t;\n f = p > 0 ? Math.round(n) / p : 1, c = E > 0 ? Math.round(o) / E : 1;\n }\n return {\n width: n / f,\n height: o / c,\n top: s / c,\n right: r / f,\n bottom: a / c,\n left: i / f,\n x: i / f,\n y: s / c\n };\n}, So = (t) => d(t).body, S = (t) => d(t).documentElement, To = (t) => d(t).head, ge = (t) => l(t) ? (t.nodeName || \"\").toLowerCase() : \"#document\", ko = (t) => {\n const e = G(t), n = e ? t.scrollX : t.scrollLeft, o = e ? t.scrollY : t.scrollTop;\n return { x: n, y: o };\n}, me = (t) => l(t) && t.constructor.name === \"ShadowRoot\" || !1, A = (t) => t.nodeName === \"HTML\" ? t : u(t) && t.assignedSlot || l(t) && t.parentNode || me(t) && t.host || S(t), ve = (t) => t ? K(t) ? t.defaultView : l(t) ? t?.ownerDocument?.defaultView : t : window, be = (t) => l(t) && [\"TABLE\", \"TD\", \"TH\"].includes(t.nodeName) || !1, Ee = (t, e) => t.matches(e), D = (t) => g(t, \"position\") === \"static\", he = (t) => g(t, \"position\") === \"fixed\", Z = (t) => [\":popover-open\", \":modal\"].some((e) => {\n try {\n return Ee(t, e);\n } catch {\n return !1;\n }\n}), Y = (t) => {\n const e = Xt(), n = u(t) ? getComputedStyle(t) : t;\n return n.transform !== \"none\" || n.perspective !== \"none\" || (n.containerType ? n.containerType !== \"normal\" : !1) || !e && (n.backdropFilter ? n.backdropFilter !== \"none\" : !1) || !e && (n.filter ? n.filter !== \"none\" : !1) || [\"transform\", \"perspective\", \"filter\"].some(\n (o) => (n.willChange || \"\").includes(o)\n ) || [\"paint\", \"layout\", \"strict\", \"content\"].some(\n (o) => (n.contain || \"\").includes(o)\n );\n}, ye = (t) => {\n let e = A(t);\n for (; u(e) && !I(e); ) {\n if (Y(e))\n return e;\n if (Z(e))\n return null;\n e = A(e);\n }\n return null;\n}, I = (t) => [\"html\", \"body\", \"#document\"].includes(ge(t)), B = (t) => {\n if (!m(t) || he(t))\n return null;\n let e = t.offsetParent;\n return S(t) === e && (e = e.ownerDocument.body), e;\n}, No = (t) => {\n const e = ve(t);\n if (!l(t) || Z(t))\n return e;\n if (!m(t)) {\n let o = A(t);\n for (; o && !I(o); ) {\n if (u(o) && !D(o))\n return o;\n o = A(o);\n }\n return e;\n }\n let n = B(t);\n for (; n && be(n) && D(n); )\n n = B(n);\n return n && I(n) && D(n) && !Y(n) ? e : n || ye(t) || e;\n}, we = (t) => {\n if (!m(t)) return !1;\n const { width: e, height: n } = w(t), { offsetWidth: o, offsetHeight: s } = t;\n return Math.round(e) !== o || Math.round(n) !== s;\n}, Co = (t, e, n) => {\n const o = m(e), s = w(\n t,\n o && we(e)\n ), r = { x: 0, y: 0 };\n if (o) {\n const a = w(e, !0);\n r.x = a.x + e.clientLeft, r.y = a.y + e.clientTop;\n }\n return {\n x: s.left + n.x - r.x,\n y: s.top + n.y - r.y,\n width: s.width,\n height: s.height\n };\n};\nlet F = 0, H = 0;\nconst y = /* @__PURE__ */ new Map(), Ae = (t, e) => {\n let n = e ? F : H;\n if (e) {\n const o = Ae(t), s = y.get(o) || /* @__PURE__ */ new Map();\n y.has(o) || y.set(o, s), x(s) && !s.has(e) ? (s.set(e, n), F += 1) : n = s.get(e);\n } else {\n const o = t.id || t;\n y.has(o) ? n = y.get(o) : (y.set(o, n), H += 1);\n }\n return n;\n}, Lo = (t) => {\n const e = [\"HTML\", \"BODY\"];\n let { parentNode: n } = t;\n if (!m(n))\n for (; n && !e.includes(n.nodeName) && (n = A(n), !m(n)); )\n ;\n const {\n offsetLeft: o,\n offsetTop: s,\n offsetParent: r\n } = n, { top: a, left: i } = n.getBoundingClientRect(), { top: f, left: c, width: p, height: E } = t.getBoundingClientRect(), C = s + (f - a), _ = o + (c - i);\n return {\n offsetTop: C,\n offsetLeft: _,\n offsetWidth: p,\n offsetHeight: E,\n offsetParent: r\n };\n}, Se = (t) => Array.isArray(t) || !1, Mo = (t) => l(t) && t.nodeName === \"CANVAS\" || !1, Te = (t) => m(t) && !!t.shadowRoot || !1, Do = (t) => {\n if (!l(t)) return !1;\n const { top: e, bottom: n } = w(t), { clientHeight: o } = S(t);\n return e <= o && n >= 0;\n}, Oo = (t) => {\n if (!u(t)) return !1;\n const { clientWidth: e, clientHeight: n } = S(t), { top: o, left: s, bottom: r, right: a } = w(t, !0);\n return o >= 0 && s >= 0 && r <= n && a <= e;\n}, xo = (t) => Se(t) && t.every(u) || !1, zo = (t) => typeof t == \"function\" || !1, Io = (t) => b(t) && t.constructor.name === \"HTMLCollection\" || !1, Po = (t) => m(t) && t.tagName === \"IMG\" || !1, Bo = (t) => {\n if (!k(t)) return !1;\n try {\n JSON.parse(t);\n } catch {\n return !1;\n }\n return !0;\n}, Fo = (t) => b(t) && t.constructor.name === \"WeakMap\" || !1, Ho = (t) => l(t) && [\"SVG\", \"Image\", \"Video\", \"Canvas\"].some(\n (e) => t.constructor.name.includes(e)\n) || !1, Vo = (t) => b(t) && t.constructor.name === \"NodeList\" || !1, Uo = (t) => S(t).dir === \"rtl\", Wo = (t) => l(t) && t.constructor.name.includes(\"SVG\") || !1, ke = (t, e) => !t || !e ? null : t.closest(e) || ke(t.getRootNode().host, e) || null, Ro = (t, e) => u(t) ? t : (u(e) ? e : d()).querySelector(t), Ne = (t, e) => (l(e) ? e : d()).getElementsByTagName(\n t\n), Qo = (t) => [...Ne(\"*\", t)].filter(Te), jo = (t, e) => d(e).getElementById(t), Go = (t, e) => (e && l(e) ? e : d()).getElementsByClassName(\n t\n);\nexport {\n Xn as ArrayFrom,\n V as DOMContentLoadedEvent,\n ot as DOMMouseScrollEvent,\n O as Data,\n co as Float32ArrayFrom,\n ao as Float64ArrayFrom,\n N as ObjectAssign,\n T as ObjectEntries,\n mo as ObjectFromEntries,\n fo as ObjectHasOwn,\n po as ObjectKeys,\n go as ObjectValues,\n yo as Timer,\n J as abortEvent,\n qn as addClass,\n An as addEventListener,\n Yt as animationDelay,\n Zt as animationDuration,\n L as animationEndEvent,\n U as animationName,\n Le as ariaChecked,\n De as ariaDescribedBy,\n Me as ariaDescription,\n Oe as ariaExpanded,\n xe as ariaHasPopup,\n $ as ariaHidden,\n ze as ariaLabel,\n Ie as ariaLabelledBy,\n Pe as ariaModal,\n Be as ariaPressed,\n Fe as ariaSelected,\n Ve as ariaValueMax,\n He as ariaValueMin,\n Ue as ariaValueNow,\n We as ariaValueText,\n X as beforeunloadEvent,\n Tn as bezierEasings,\n tt as blurEvent,\n no as camelCase,\n eo as capitalize,\n et as changeEvent,\n ke as closest,\n nt as contextmenuEvent,\n vo as createCustomEvent,\n oe as createElement,\n se as createElementNS,\n q as dispatchEvent,\n oo as distinct,\n _n as documentBody,\n $n as documentElement,\n Jn as documentHead,\n Qe as dragEvent,\n Ze as dragendEvent,\n Ge as dragenterEvent,\n Ke as dragleaveEvent,\n qe as dragoverEvent,\n je as dragstartEvent,\n so as emulateAnimationEnd,\n ro as emulateTransitionEnd,\n st as errorEvent,\n io as focus,\n rt as focusEvent,\n tn as focusEvents,\n qt as focusableSelector,\n ct as focusinEvent,\n at as focusoutEvent,\n it as gesturechangeEvent,\n ut as gestureendEvent,\n lt as gesturestartEvent,\n j as getAttribute,\n Wn as getAttributeNS,\n w as getBoundingClientRect,\n Qo as getCustomElements,\n d as getDocument,\n So as getDocumentBody,\n S as getDocumentElement,\n To as getDocumentHead,\n re as getElementAnimationDelay,\n ce as getElementAnimationDuration,\n jo as getElementById,\n g as getElementStyle,\n ae as getElementTransitionDelay,\n ie as getElementTransitionDuration,\n Go as getElementsByClassName,\n Ne as getElementsByTagName,\n to as getInstance,\n ge as getNodeName,\n ko as getNodeScroll,\n No as getOffsetParent,\n A as getParentNode,\n Co as getRectRelativeToOffsetParent,\n Lo as getSVGOffset,\n Ae as getUID,\n ve as getWindow,\n ne as hasAttribute,\n Rn as hasAttributeNS,\n Yn as hasClass,\n pe as hasFocusTrap,\n zn as isApple,\n Se as isArray,\n Mo as isCanvas,\n Te as isCustomElement,\n K as isDocument,\n u as isElement,\n Do as isElementInScrollRange,\n Oo as isElementInViewport,\n xo as isElementsArray,\n In as isFirefox,\n zo as isFunction,\n Io as isHTMLCollection,\n m as isHTMLElement,\n Po as isHTMLImageElement,\n Bo as isJSON,\n x as isMap,\n Ho as isMedia,\n xn as isMobile,\n l as isNode,\n Vo as isNodeList,\n le as isNumber,\n b as isObject,\n Uo as isRTL,\n Wo as isSVGElement,\n we as isScaledElement,\n me as isShadowRoot,\n k as isString,\n be as isTableElement,\n Fo as isWeakMap,\n Xt as isWebKit,\n G as isWindow,\n uo as kebabCase,\n nn as keyAlt,\n on as keyArrowDown,\n rn as keyArrowLeft,\n cn as keyArrowRight,\n sn as keyArrowUp,\n an as keyBackspace,\n un as keyCapsLock,\n ln as keyControl,\n dn as keyDelete,\n fn as keyEnter,\n gn as keyEscape,\n mn as keyInsert,\n vn as keyMeta,\n pn as keyNumpadEnter,\n bn as keyPause,\n En as keyScrollLock,\n hn as keyShift,\n yn as keySpace,\n wn as keyTab,\n en as keyboardEventKeys,\n dt as keydownEvent,\n ft as keypressEvent,\n pt as keyupEvent,\n gt as loadEvent,\n Ye as loadstartEvent,\n Ee as matches,\n $e as mouseClickEvents,\n Je as mouseHoverEvents,\n _e as mouseSwipeEvents,\n mt as mouseclickEvent,\n vt as mousedblclickEvent,\n bt as mousedownEvent,\n yt as mouseenterEvent,\n ht as mousehoverEvent,\n At as mouseinEvent,\n wt as mouseleaveEvent,\n kt as mousemoveEvent,\n St as mouseoutEvent,\n Tt as mouseoverEvent,\n Et as mouseupEvent,\n Nt as mousewheelEvent,\n Ct as moveEvent,\n Re as nativeEvents,\n te as noop,\n lo as normalizeOptions,\n P as normalizeValue,\n Q as off,\n kn as offsetHeight,\n Nn as offsetWidth,\n R as on,\n ee as one,\n Lt as orientationchangeEvent,\n bo as passiveHandler,\n Mt as pointercancelEvent,\n Dt as pointerdownEvent,\n Ot as pointerleaveEvent,\n xt as pointermoveEvent,\n zt as pointerupEvent,\n Ro as querySelector,\n de as querySelectorAll,\n It as readystatechangeEvent,\n Eo as reflow,\n Gn as removeAttribute,\n Kn as removeAttributeNS,\n Zn as removeClass,\n Sn as removeEventListener,\n Pt as resetEvent,\n Bt as resizeEvent,\n Ut as scrollEvent,\n Cn as scrollHeight,\n Ln as scrollWidth,\n Ft as selectEvent,\n Ht as selectendEvent,\n Vt as selectstartEvent,\n Qn as setAttribute,\n jn as setAttributeNS,\n ho as setElementStyle,\n Wt as submitEvent,\n Pn as support3DTransform,\n Vn as supportAnimation,\n Bn as supportPassive,\n Hn as supportTouch,\n Fn as supportTransform,\n Un as supportTransition,\n Mn as tabindex,\n ue as toLowerCase,\n wo as toUpperCase,\n Ao as toggleFocusTrap,\n Xe as touchEvents,\n jt as touchcancelEvent,\n Gt as touchendEvent,\n Qt as touchmoveEvent,\n Rt as touchstartEvent,\n $t as transitionDelay,\n _t as transitionDuration,\n M as transitionEndEvent,\n W as transitionProperty,\n Kt as unloadEvent,\n On as userAgent,\n Dn as userAgentData,\n Ce as version\n};\n//# sourceMappingURL=shorty.mjs.map\n","const g = \"2.0.8\", e = {}, f = (t) => {\n const { type: n, currentTarget: c } = t;\n e[n].forEach((a, s) => {\n c === s && a.forEach((o, i) => {\n i.apply(s, [t]), typeof o == \"object\" && o.once && r(s, n, i, o);\n });\n });\n}, E = (t, n, c, a) => {\n e[n] || (e[n] = /* @__PURE__ */ new Map());\n const s = e[n];\n s.has(t) || s.set(t, /* @__PURE__ */ new Map());\n const o = s.get(\n t\n ), { size: i } = o;\n o.set(c, a), i || t.addEventListener(\n n,\n f,\n a\n );\n}, r = (t, n, c, a) => {\n const s = e[n], o = s && s.get(t), i = o && o.get(c), d = i !== void 0 ? i : a;\n o && o.has(c) && o.delete(c), s && (!o || !o.size) && s.delete(t), (!s || !s.size) && delete e[n], (!o || !o.size) && t.removeEventListener(\n n,\n f,\n d\n );\n}, M = E, p = r;\nexport {\n E as addListener,\n f as globalListener,\n p as off,\n M as on,\n e as registry,\n r as removeListener,\n g as version\n};\n//# sourceMappingURL=event-listener.mjs.map\n","/**\n * Global namespace for most components `fade` class.\n */\nconst fadeClass = \"fade\";\nexport default fadeClass;\n","/**\n * Global namespace for most components `show` class.\n */\nconst showClass = \"show\";\nexport default showClass;\n","/**\n * Global namespace for most components `dismiss` option.\n */\nconst dataBsDismiss = \"data-bs-dismiss\";\nexport default dataBsDismiss;\n","/** @type {string} */\nconst alertString = \"alert\";\nexport default alertString;\n","/** @type {string} */\nconst alertComponent = \"Alert\";\nexport default alertComponent;\n","import { version } from \"../package.json\";\n\nconst Version = version;\n\nexport default Version;\n","/* Native JavaScript for Bootstrap 5 | Base Component\n----------------------------------------------------- */\nimport {\n Data,\n isElement,\n isString,\n normalizeOptions,\n ObjectKeys,\n querySelector,\n} from \"@thednp/shorty\";\n\nimport type { BaseOptions } from \"../interface/baseComponent\";\nimport Version from \"../version\";\n\n/** Returns a new `BaseComponent` instance. */\nexport default class BaseComponent {\n declare element: Element;\n declare options?: BaseOptions;\n\n /**\n * @param target `Element` or selector string\n * @param config component instance options\n */\n constructor(target: Element | string, config?: BaseOptions) {\n let element: Element | null;\n\n try {\n if (isElement(target)) {\n element = target as Element;\n } else if (isString(target)) {\n element = querySelector(target);\n // istanbul ignore else @preserve\n if (!element) throw Error(`\"${target}\" is not a valid selector.`);\n } else {\n throw Error(`your target is not an instance of HTMLElement.`);\n }\n } catch (e) {\n throw Error(`${this.name} Error: ${(e as Error).message}`);\n }\n\n const prevInstance = Data.get(element, this.name);\n /* istanbul ignore else @preserve */\n if (prevInstance) {\n // remove previously attached event listeners\n // to avoid memory leaks\n prevInstance._toggleEventListeners();\n }\n\n this.element = element;\n this.options = this.defaults && ObjectKeys(this.defaults).length\n ? normalizeOptions(element, this.defaults, config || {}, \"bs\")\n // istanbul ignore next @preserve\n : {};\n\n Data.set(element, this.name, this);\n }\n\n // istanbul ignore next @preserve\n get version() {\n return Version;\n }\n\n // istanbul ignore next @preserve\n get name() {\n return \"BaseComponent\";\n }\n\n // istanbul ignore next @preserve\n get defaults() {\n return {};\n }\n\n /** just to have something to extend from */\n // istanbul ignore next @preserve coverage wise this isn't important\n _toggleEventListeners = () => {\n // do something to please linters\n };\n\n /** Removes component from target element. */\n dispose() {\n Data.remove(this.element, this.name);\n ObjectKeys(this).forEach((prop) => {\n delete this[prop];\n });\n }\n}\n","/* Native JavaScript for Bootstrap 5 | Alert\n-------------------------------------------- */\nimport {\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getInstance,\n hasClass,\n mouseclickEvent,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport alertString from \"../strings/alertString\";\nimport alertComponent from \"../strings/alertComponent\";\nimport type { AlertEvent } from \"../interface/alert\";\n\nimport BaseComponent from \"./base-component\";\n\n// ALERT PRIVATE GC\n// ================\nconst alertSelector = `.${alertString}`;\nconst alertDismissSelector = `[${dataBsDismiss}=\"${alertString}\"]`;\n\n/**\n * Static method which returns an existing `Alert` instance associated\n * to a target `Element`.\n */\nconst getAlertInstance = (element: Element) =>\n getInstance(element, alertComponent);\n\n/**\n * An `Alert` initialization callback.\n */\nconst alertInitCallback = (element: Element) => new Alert(element);\n\n// ALERT CUSTOM EVENTS\n// ===================\nconst closeAlertEvent = createCustomEvent, AlertEvent>(\n `close.bs.${alertString}`,\n);\nconst closedAlertEvent = createCustomEvent, AlertEvent>(\n `closed.bs.${alertString}`,\n);\n\n// ALERT EVENT HANDLER\n// ===================\n/**\n * Alert `transitionend` callback.\n *\n * @param that target Alert instance\n */\nconst alertTransitionEnd = (self: Alert) => {\n const { element } = self;\n dispatchEvent(element, closedAlertEvent);\n\n self._toggleEventListeners();\n self.dispose();\n element.remove();\n};\n\n// ALERT DEFINITION\n// ================\n/** Creates a new Alert instance. */\nexport default class Alert extends BaseComponent {\n static selector = alertSelector;\n static init = alertInitCallback;\n static getInstance = getAlertInstance;\n dismiss: HTMLElement | null;\n\n constructor(target: Element | string) {\n super(target);\n\n // the dismiss button\n this.dismiss = querySelector(\n alertDismissSelector,\n this.element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /** Returns component name string. */\n get name() {\n return alertComponent;\n }\n\n // ALERT PUBLIC METHODS\n // ====================\n /**\n * Public method that hides the `.alert` element from the user,\n * disposes the instance once animation is complete, then\n * removes the element from the DOM.\n */\n close = () => {\n const { element } = this;\n\n // istanbul ignore else @preserve\n if (element && hasClass(element, showClass)) {\n dispatchEvent(element, closeAlertEvent);\n\n if (!closeAlertEvent.defaultPrevented) {\n removeClass(element, showClass);\n\n if (hasClass(element, fadeClass)) {\n emulateTransitionEnd(element, () => alertTransitionEnd(this));\n } else alertTransitionEnd(this);\n }\n }\n };\n /**\n * Toggle on / off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { dismiss, close } = this;\n // istanbul ignore else @preserve\n if (dismiss) action(dismiss, mouseclickEvent, close);\n };\n\n /** Remove the component from target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/**\n * Global namespace for most components active class.\n */\nconst activeClass = \"active\";\nexport default activeClass;\n","/**\n * Global namespace for most components `toggle` option.\n */\nconst dataBsToggle = \"data-bs-toggle\";\nexport default dataBsToggle;\n","/** @type {string} */\nconst buttonString = \"button\";\nexport default buttonString;\n","/** @type {string} */\nconst buttonComponent = \"Button\";\nexport default buttonComponent;\n","/* Native JavaScript for Bootstrap 5 | Button\n---------------------------------------------*/\nimport {\n addClass,\n ariaPressed,\n getAttribute,\n getInstance,\n hasClass,\n mouseclickEvent,\n removeClass,\n setAttribute,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport activeClass from \"../strings/activeClass\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport buttonString from \"../strings/buttonString\";\nimport buttonComponent from \"../strings/buttonComponent\";\n\nimport BaseComponent from \"./base-component\";\n\n// BUTTON PRIVATE GC\n// =================\nconst buttonSelector = `[${dataBsToggle}=\"${buttonString}\"]`;\n\n/**\n * Static method which returns an existing `Button` instance associated\n * to a target `Element`.\n */\nconst getButtonInstance = (element: Element) =>\n getInstance',\n});\n\n/**\n * Static method which returns an existing `Popover` instance associated\n * to a target `Element`.\n */\nconst getPopoverInstance = (element: Element) =>\n getInstance(element, popoverComponent);\n\n/**\n * A `Popover` initialization callback.\n */\nconst popoverInitCallback = (element: Element) => new Popover(element);\n\n// POPOVER DEFINITION\n// ==================\n/** Returns a new `Popover` instance. */\nexport default class Popover extends Tooltip {\n static selector = popoverSelector;\n static init = popoverInitCallback;\n static getInstance = getPopoverInstance;\n static styleTip = styleTip;\n declare options: PopoverOptions;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return popoverComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return popoverDefaults;\n }\n\n /* extend original `show()` */\n show = () => {\n super.show();\n // btn only exists within dismissible popover\n const { options, btn } = this;\n // istanbul ignore else @preserve\n if (options.dismissible && btn) setTimeout(() => focus(btn), 17);\n };\n}\n","/** @type {string} */\nconst scrollspyString = \"scrollspy\";\nexport default scrollspyString;\n","/** @type {string} */\nconst scrollspyComponent = \"ScrollSpy\";\nexport default scrollspyComponent;\n","/* Native JavaScript for Bootstrap 5 | ScrollSpy\n------------------------------------------------ */\nimport {\n addClass,\n createCustomEvent,\n dispatchEvent,\n getAttribute,\n getBoundingClientRect,\n getDocument,\n getDocumentBody,\n getDocumentElement,\n getElementsByTagName,\n getInstance,\n hasClass,\n isHTMLElement,\n querySelector,\n removeClass,\n} from \"@thednp/shorty\";\n\nimport PositionObserver from \"@thednp/position-observer\";\n\nimport activeClass from \"../strings/activeClass\";\nimport scrollspyString from \"../strings/scrollspyString\";\nimport scrollspyComponent from \"../strings/scrollspyComponent\";\n\nimport BaseComponent from \"./base-component\";\nimport { ScrollSpyEvent, ScrollSpyOptions } from \"../interface/scrollspy\";\n\n// SCROLLSPY PRIVATE GC\n// ====================\nconst scrollspySelector = '[data-bs-spy=\"scroll\"]';\n\nconst scrollspyDefaults: Partial = {\n offset: 10,\n target: undefined,\n};\n\ntype ScrollSpyEventProps = {\n relatedTarget: HTMLElement;\n};\n\n/**\n * Static method which returns an existing `ScrollSpy` instance associated\n * to a target `Element`.\n */\nconst getScrollSpyInstance = (element: Element) =>\n getInstance(element, scrollspyComponent);\n\n/**\n * A `ScrollSpy` initialization callback.\n */\nconst scrollspyInitCallback = (element: Element) => new ScrollSpy(element);\n\n// SCROLLSPY CUSTOM EVENT\n// ======================\nconst activateScrollSpy = createCustomEvent<\n ScrollSpyEventProps,\n ScrollSpyEvent\n>(`activate.bs.${scrollspyString}`);\n\n// SCROLLSPY PRIVATE METHODS\n// =========================\n/**\n * Update the state of all items.\n *\n * @param self the `ScrollSpy` instance\n */\nconst updateSpyTargets = (self: ScrollSpy) => {\n const {\n target,\n scrollTarget,\n options,\n itemsLength,\n scrollHeight,\n element,\n _observer,\n } = self;\n const { offset } = options;\n const isRoot = scrollTarget !== element;\n\n const links = target && getElementsByTagName(\"A\", target);\n const doc = getDocument(element);\n const scrollHEIGHT = scrollTarget.scrollHeight;\n\n self.scrollTop = scrollTarget.scrollTop;\n\n // only update items/offsets once or with each mutation\n // istanbul ignore else @preserve\n if (\n links && (scrollHEIGHT !== scrollHeight || itemsLength !== links.length)\n ) {\n let href: string | null;\n let ref: string | undefined;\n let targetItem: HTMLElement | null;\n let rect;\n\n // reset arrays & update\n self.items = [];\n self.targets = [];\n self.offsets = [];\n self.scrollHeight = scrollHEIGHT;\n self.maxScroll = self.scrollHeight - getOffsetHeight(self);\n\n Array.from(links).forEach((link) => {\n href = getAttribute(link, \"href\");\n ref = href?.slice(1);\n targetItem = ref?.length ? doc.getElementById(ref) : null;\n\n if (targetItem) {\n self.items.push(link);\n self.targets.push(targetItem);\n rect = _observer?.getEntry(targetItem)?.boundingClientRect ||\n getBoundingClientRect(targetItem);\n self.offsets.push(\n (isRoot ? rect.top + self.scrollTop : targetItem.offsetTop) - offset,\n );\n }\n });\n self.itemsLength = self.items.length;\n }\n};\n\n/**\n * Toggles on/off the component observer.\n *\n * @param self the ScrollSpy instance\n * @param add when `true`, listener is added\n */\nconst toggleObservers = (\n { targets, scrollTarget, element, _observer }: ScrollSpy,\n add?: boolean,\n) => {\n if (add) {\n if (scrollTarget === element) {\n targets?.forEach((targetItem) => _observer.observe(targetItem));\n } else {\n _observer.observe(element);\n }\n } else _observer.disconnect();\n};\n\n/**\n * Returns the `scrollHeight` property of the scrolling element.\n *\n * @param scrollTarget the `ScrollSpy` instance\n * @return `scrollTarget` height\n */\nconst getScrollHeight = (scrollTarget: Element) => {\n return scrollTarget.scrollHeight;\n};\n\n/**\n * Returns the height property of the scrolling element.\n *\n * @param params the `ScrollSpy` instance\n */\nconst getOffsetHeight = ({ element, scrollTarget }: ScrollSpy) => {\n return scrollTarget !== element\n ? scrollTarget.clientHeight\n : getBoundingClientRect(element).height;\n};\n\n/**\n * Clear all items of the target.\n *\n * @param target a single item\n */\nconst clear = (target: Element) => {\n Array.from(getElementsByTagName(\"A\", target)).forEach(\n (item) => {\n if (hasClass(item, activeClass)) removeClass(item, activeClass);\n },\n );\n};\n\n/**\n * Activates a new item.\n *\n * @param self the `ScrollSpy` instance\n * @param item a single item\n */\nconst activate = (self: ScrollSpy, item: HTMLElement) => {\n const { target, element } = self;\n\n // istanbul ignore else @preserve\n if (isHTMLElement(target)) clear(target);\n\n self.activeItem = item;\n addClass(item, activeClass);\n\n // activate all parents\n const parents: HTMLElement[] = [];\n let parentItem = item;\n while (parentItem !== getDocumentBody(element)) {\n parentItem = parentItem.parentElement as HTMLElement;\n if (hasClass(parentItem, \"nav\") || hasClass(parentItem, \"dropdown-menu\")) {\n parents.push(parentItem);\n }\n }\n\n parents.forEach((menuItem) => {\n const parentLink = menuItem.previousElementSibling as HTMLElement | null;\n\n // istanbul ignore else @preserve\n if (parentLink && !hasClass(parentLink, activeClass)) {\n addClass(parentLink, activeClass);\n }\n });\n\n // dispatch\n activateScrollSpy.relatedTarget = item;\n dispatchEvent(element, activateScrollSpy);\n};\n\n// SCROLLSPY DEFINITION\n// ====================\n/** Returns a new `ScrollSpy` instance. */\nexport default class ScrollSpy extends BaseComponent {\n static selector = scrollspySelector;\n static init = scrollspyInitCallback;\n static getInstance = getScrollSpyInstance;\n declare element: HTMLElement;\n declare options: ScrollSpyOptions;\n declare target: HTMLElement | null;\n declare scrollTarget: HTMLElement;\n declare scrollTop: number;\n declare maxScroll: number;\n declare scrollHeight: number;\n declare activeItem: HTMLElement | null;\n declare items: HTMLElement[];\n declare targets: HTMLElement[];\n declare itemsLength: number;\n declare offsets: number[];\n declare _observer: PositionObserver;\n\n /**\n * @param target the target element\n * @param config the instance options\n */\n constructor(\n target: Element | string,\n config?: Partial,\n ) {\n super(target, config);\n\n // initialization element & options\n const { element, options } = this;\n\n // get target\n const spyTarget = querySelector(\n options.target,\n getDocument(element),\n );\n\n // invalidate\n if (!spyTarget) return;\n this.target = spyTarget;\n\n // set initial state\n this.scrollTarget = element.clientHeight < element.scrollHeight\n ? element\n : getDocumentElement(element);\n this.scrollHeight = getScrollHeight(this.scrollTarget);\n\n // run an initial burst, we need to know the targets\n this.refresh();\n\n // create observer\n this._observer = new PositionObserver((entries) => {\n requestAnimationFrame(() => {\n // istanbul ignore else @preserve\n if (entries.some((entry) => entry.isVisible)) {\n this.refresh();\n }\n });\n }, {\n root: this.scrollTarget,\n });\n\n // add event handlers\n toggleObservers(this, true);\n }\n\n /* eslint-disable */\n /**\n * Returns component name string.\n */\n get name() {\n return scrollspyComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return scrollspyDefaults;\n }\n /* eslint-enable */\n\n // SCROLLSPY PUBLIC METHODS\n // ========================\n /** Updates all items. */\n refresh = () => {\n const { target } = this;\n // check if target is visible and invalidate\n // istanbul ignore if @preserve\n if (!isHTMLElement(target) || target.offsetHeight === 0) return;\n\n updateSpyTargets(this);\n\n const { scrollTop, maxScroll, itemsLength, items, activeItem } = this;\n\n if (scrollTop >= maxScroll) {\n const newActiveItem = items[itemsLength - 1];\n\n // istanbul ignore else @preserve\n if (activeItem !== newActiveItem) activate(this, newActiveItem);\n return;\n }\n\n const { offsets } = this;\n\n // istanbul ignore else @preserve\n if (activeItem && scrollTop < offsets[0] && offsets[0] > 0) {\n this.activeItem = null;\n // istanbul ignore else @preserve\n if (target) clear(target);\n return;\n }\n\n items.forEach((item, i) => {\n if (\n activeItem !== item &&\n scrollTop >= offsets[i] &&\n (typeof offsets[i + 1] === \"undefined\" || scrollTop < offsets[i + 1])\n ) {\n activate(this, item);\n }\n });\n };\n\n /** Removes `ScrollSpy` from the target element. */\n dispose() {\n const clone = { ...this };\n toggleObservers(clone);\n super.dispose();\n }\n}\n","/** @type {string} */\nconst tabString = \"tab\";\nexport default tabString;\n","/** @type {string} */\nconst tabComponent = \"Tab\";\nexport default tabComponent;\n","/* Native JavaScript for Bootstrap 5 | Tab\n------------------------------------------ */\nimport {\n addClass,\n ariaSelected,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n getElementsByClassName,\n getInstance,\n hasClass,\n isHTMLElement,\n mouseclickEvent,\n MouseEvent,\n querySelector,\n reflow,\n removeClass,\n setAttribute,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport collapsingClass from \"../strings/collapsingClass\";\nimport activeClass from \"../strings/activeClass\";\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dropdownClasses from \"../strings/dropdownClasses\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport tabString from \"../strings/tabString\";\nimport tabComponent from \"../strings/tabComponent\";\n\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport type { /* TabOptions, */ TabEvent } from \"../interface/tab\";\n\n// TAB PRIVATE GC\n// ================\nconst tabSelector = `[${dataBsToggle}=\"${tabString}\"]`;\n\n/**\n * Static method which returns an existing `Tab` instance associated\n * to a target `Element`.\n */\nconst getTabInstance = (element: Element) =>\n getInstance(element, tabComponent);\n\n/** A `Tab` initialization callback. */\nconst tabInitCallback = (element: Element) => new Tab(element);\n\ntype TabEventProps = {\n relatedTarget: Element & EventTarget | undefined;\n};\n\n// TAB CUSTOM EVENTS\n// =================\nconst showTabEvent = createCustomEvent(\n `show.bs.${tabString}`,\n);\nconst shownTabEvent = createCustomEvent(\n `shown.bs.${tabString}`,\n);\nconst hideTabEvent = createCustomEvent(\n `hide.bs.${tabString}`,\n);\nconst hiddenTabEvent = createCustomEvent(\n `hidden.bs.${tabString}`,\n);\n\ninterface TabPrivate {\n tab: HTMLElement | null;\n content: HTMLElement | null;\n currentHeight: number;\n nextHeight: number;\n}\n\n/**\n * Stores the current active tab and its content\n * for a given `.nav` element.\n */\nconst tabPrivate: Map = new Map();\n\n// TAB PRIVATE METHODS\n// ===================\n/**\n * Executes after tab transition has finished.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabEnd = (self: Tab) => {\n const { tabContent, nav } = self;\n\n // istanbul ignore else @preserve\n if (tabContent && hasClass(tabContent, collapsingClass)) {\n tabContent.style.height = \"\";\n removeClass(tabContent, collapsingClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) Timer.clear(nav);\n};\n\n/**\n * Executes before showing the tab content.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabShow = (self: Tab) => {\n const { element, tabContent, content: nextContent, nav } = self;\n const { tab } = (isHTMLElement(nav) && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null };\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const { currentHeight, nextHeight } = tabPrivate.get(element) ||\n // istanbul ignore next @preserve\n { currentHeight: 0, nextHeight: 0 };\n // istanbul ignore else @preserve: vitest won't validate this branch\n if (currentHeight !== nextHeight) {\n // enables height animation\n setTimeout(() => {\n tabContent.style.height = `${nextHeight}px`;\n reflow(tabContent);\n emulateTransitionEnd(tabContent, () => triggerTabEnd(self));\n }, 50);\n } else {\n triggerTabEnd(self);\n }\n } else if (nav) Timer.clear(nav);\n\n shownTabEvent.relatedTarget = tab as HTMLElement | undefined;\n\n dispatchEvent(element, shownTabEvent);\n};\n\n/**\n * Executes before hiding the tab.\n *\n * @param self the `Tab` instance\n */\nconst triggerTabHide = (self: Tab) => {\n const { element, content: nextContent, tabContent, nav } = self;\n const { tab, content } = (nav && tabPrivate.get(nav)) ||\n // istanbul ignore next @preserve\n { tab: null, content: null };\n let currentHeight = 0;\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) addClass(c, \"overflow-hidden\");\n });\n currentHeight = content\n ? content.scrollHeight\n : /* istanbul ignore next @preserve */ 0;\n }\n\n // update relatedTarget and dispatch event\n showTabEvent.relatedTarget = tab as HTMLElement | undefined;\n hiddenTabEvent.relatedTarget = element as HTMLElement;\n dispatchEvent(element, showTabEvent);\n\n // istanbul ignore if @preserve\n if (showTabEvent.defaultPrevented) return;\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, activeClass);\n // istanbul ignore else @preserve\n if (content) removeClass(content, activeClass);\n\n // istanbul ignore else @preserve\n if (tabContent && nextContent && hasClass(nextContent, fadeClass)) {\n const nextHeight = nextContent.scrollHeight;\n tabPrivate.set(element, {\n currentHeight,\n nextHeight,\n tab: null,\n content: null,\n });\n\n addClass(tabContent, collapsingClass);\n tabContent.style.height = `${currentHeight}px`;\n reflow(tabContent);\n [content, nextContent].forEach((c) => {\n // istanbul ignore else @preserve\n if (c) removeClass(c, \"overflow-hidden\");\n });\n }\n\n if (nextContent && nextContent && hasClass(nextContent, fadeClass)) {\n setTimeout(() => {\n addClass(nextContent, showClass);\n emulateTransitionEnd(nextContent, () => {\n triggerTabShow(self);\n });\n }, 1);\n } else {\n // istanbul ignore else @preserve\n if (nextContent) addClass(nextContent, showClass);\n triggerTabShow(self);\n }\n\n // istanbul ignore else @preserve\n if (tab) dispatchEvent(tab, hiddenTabEvent);\n};\n\n/**\n * Returns the current active tab and its target content.\n *\n * @param self the `Tab` instance\n * @returns the query result\n */\nconst getActiveTab = (\n self: Tab,\n): { tab: HTMLElement | null; content: HTMLElement | null } => {\n const { nav } = self;\n // istanbul ignore next @preserve\n if (!isHTMLElement(nav)) {\n return { tab: null, content: null };\n }\n\n const activeTabs = getElementsByClassName(\n activeClass,\n nav,\n );\n let tab: HTMLElement | null = null;\n // istanbul ignore else @preserve\n if (\n activeTabs.length === 1 &&\n !dropdownClasses.some((c) =>\n hasClass(activeTabs[0].parentElement as HTMLElement, c)\n )\n ) {\n [tab] = activeTabs;\n } else if (activeTabs.length > 1) {\n tab = activeTabs[activeTabs.length - 1];\n }\n const content = isHTMLElement(tab) ? getTargetElement(tab) : null;\n return { tab, content };\n};\n\n/**\n * Returns a parent dropdown.\n *\n * @param element the `Tab` element\n * @returns the parent dropdown\n */\nconst getParentDropdown = (element?: HTMLElement) => {\n // istanbul ignore next @preserve\n if (!isHTMLElement(element)) return null;\n const dropdown = closest(element, `.${dropdownClasses.join(\",.\")}`);\n return dropdown\n ? querySelector(`.${dropdownClasses[0]}-toggle`, dropdown)\n : null;\n};\n\n// TAB EVENT HANDLER\n// =================\n/**\n * Handles the `click` event listener.\n *\n * @param e the `Event` object\n */\nconst tabClickHandler = (e: MouseEvent) => {\n const self = getTabInstance(e.target);\n e.preventDefault();\n\n // istanbul ignore else @preserve\n if (self) self.show();\n};\n\n// TAB DEFINITION\n// ==============\n/** Creates a new `Tab` instance. */\nexport default class Tab extends BaseComponent {\n static selector = tabSelector;\n static init = tabInitCallback;\n static getInstance = getTabInstance;\n declare element: HTMLElement;\n declare nav: HTMLElement | null;\n declare content: HTMLElement | null;\n declare tabContent: HTMLElement | null;\n declare nextContent: HTMLElement | null;\n declare dropdown: HTMLElement | null;\n\n /** @param target the target element */\n constructor(target: Element | string) {\n super(target);\n\n // initialization element\n const { element } = this;\n const content = getTargetElement(element);\n\n // no point initializing a tab without a corresponding content\n // istanbul ignore else @preserve\n if (!content) return;\n\n const nav = closest(element, \".nav\");\n const container = closest(\n content as HTMLElement,\n \".tab-content\",\n );\n\n this.nav = nav;\n this.content = content;\n this.tabContent = container;\n\n // event targets\n this.dropdown = getParentDropdown(element as HTMLElement);\n\n // show first Tab instance of none is shown\n // suggested on #432\n const { tab } = getActiveTab(this);\n if (nav && !tab) {\n const firstTab = querySelector(tabSelector, nav);\n const firstTabContent = firstTab && getTargetElement(firstTab);\n\n // istanbul ignore else @preserve\n if (firstTabContent) {\n addClass(firstTab, activeClass);\n addClass(firstTabContent, showClass);\n addClass(firstTabContent, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n }\n }\n\n // add event listener\n this._toggleEventListeners(true);\n }\n\n /**\n * Returns component name string.\n */\n get name() {\n return tabComponent;\n }\n\n // TAB PUBLIC METHODS\n // ==================\n /** Shows the tab to the user. */\n show() {\n const { element, content: nextContent, nav, dropdown } = this;\n\n // istanbul ignore else @preserve\n if ((nav && Timer.get(nav)) || hasClass(element, activeClass)) return;\n const { tab, content } = getActiveTab(this);\n\n // istanbul ignore else @preserve\n if (nav && tab) {\n tabPrivate.set(nav, { tab, content, currentHeight: 0, nextHeight: 0 });\n }\n\n // update relatedTarget and dispatch\n hideTabEvent.relatedTarget = element as HTMLElement;\n\n // istanbul ignore if @preserve\n if (!isHTMLElement(tab)) return;\n\n dispatchEvent(tab, hideTabEvent);\n\n // istanbul ignore else @preserve\n if (hideTabEvent.defaultPrevented) return;\n\n addClass(element, activeClass);\n setAttribute(element, ariaSelected, \"true\");\n\n const activeDropdown = isHTMLElement(tab) && getParentDropdown(tab);\n if (activeDropdown && hasClass(activeDropdown, activeClass)) {\n removeClass(activeDropdown, activeClass);\n }\n\n // istanbul ignore else @preserve\n if (nav) {\n const toggleTab = () => {\n // istanbul ignore else @preserve\n if (tab) {\n removeClass(tab, activeClass);\n setAttribute(tab, ariaSelected, \"false\");\n }\n if (dropdown && !hasClass(dropdown, activeClass)) {\n addClass(dropdown, activeClass);\n }\n };\n\n if (\n content &&\n (hasClass(content, fadeClass) ||\n (nextContent && hasClass(nextContent, fadeClass)))\n ) {\n Timer.set(nav, toggleTab, 1);\n } else toggleTab();\n }\n\n // istanbul ignore else @preserve\n if (content) {\n removeClass(content, showClass);\n if (hasClass(content, fadeClass)) {\n emulateTransitionEnd(content, () => triggerTabHide(this));\n } else {\n triggerTabHide(this);\n }\n }\n }\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, event listener is added\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n action(this.element, mouseclickEvent, tabClickHandler);\n };\n\n /** Removes the `Tab` component from the target element. */\n dispose() {\n this._toggleEventListeners();\n super.dispose();\n }\n}\n","/** @type {string} */\nconst toastString = \"toast\";\nexport default toastString;\n","/** @type {string} */\nconst toastComponent = \"Toast\";\nexport default toastComponent;\n","/* Native JavaScript for Bootstrap 5 | Toast\n-------------------------------------------- */\nimport {\n addClass,\n closest,\n createCustomEvent,\n dispatchEvent,\n emulateTransitionEnd,\n focusinEvent,\n focusoutEvent,\n getDocument,\n getInstance,\n hasClass,\n mouseclickEvent,\n mouseenterEvent,\n MouseEvent,\n mouseleaveEvent,\n querySelector,\n querySelectorAll,\n reflow,\n removeClass,\n Timer,\n} from \"@thednp/shorty\";\n\nimport { addListener, removeListener } from \"@thednp/event-listener\";\n\nimport fadeClass from \"../strings/fadeClass\";\nimport showClass from \"../strings/showClass\";\nimport dataBsDismiss from \"../strings/dataBsDismiss\";\nimport dataBsToggle from \"../strings/dataBsToggle\";\nimport toastString from \"../strings/toastString\";\nimport toastComponent from \"../strings/toastComponent\";\nimport getTargetElement from \"../util/getTargetElement\";\nimport BaseComponent from \"./base-component\";\nimport { ToastEvent, ToastOptions } from \"../interface/toast\";\n\n// TOAST PRIVATE GC\n// ================\nconst toastSelector = `.${toastString}`;\nconst toastDismissSelector = `[${dataBsDismiss}=\"${toastString}\"]`;\nconst toastToggleSelector = `[${dataBsToggle}=\"${toastString}\"]`;\nconst showingClass = \"showing\";\n/** @deprecated */\nconst hideClass = \"hide\";\n\nconst toastDefaults = {\n animation: true,\n autohide: true,\n delay: 5000,\n};\n\n/**\n * Static method which returns an existing `Toast` instance associated\n * to a target `Element`.\n */\nconst getToastInstance = (element: Element) =>\n getInstance(element, toastComponent);\n\n/**\n * A `Toast` initialization callback.\n */\nconst toastInitCallback = (element: Element) => new Toast(element);\n\n// TOAST CUSTOM EVENTS\n// ===================\nconst showToastEvent = createCustomEvent, ToastEvent>(\n `show.bs.${toastString}`,\n);\nconst shownToastEvent = createCustomEvent, ToastEvent>(\n `shown.bs.${toastString}`,\n);\nconst hideToastEvent = createCustomEvent, ToastEvent>(\n `hide.bs.${toastString}`,\n);\nconst hiddenToastEvent = createCustomEvent, ToastEvent>(\n `hidden.bs.${toastString}`,\n);\n\n// TOAST PRIVATE METHODS\n// =====================\n/**\n * Executes after the toast is shown to the user.\n *\n * @param self the `Toast` instance\n */\nconst showToastComplete = (self: Toast) => {\n const { element, options } = self;\n removeClass(element, showingClass);\n Timer.clear(element, showingClass);\n\n dispatchEvent(element, shownToastEvent);\n // istanbul ignore else @preserve\n if (options.autohide) {\n Timer.set(element, () => self.hide(), options.delay, toastString);\n }\n};\n\n/**\n * Executes after the toast is hidden to the user.\n *\n * @param self the `Toast` instance\n */\nconst hideToastComplete = (self: Toast) => {\n const { element } = self;\n removeClass(element, showingClass);\n removeClass(element, showClass);\n addClass(element, hideClass); // B/C\n Timer.clear(element, toastString);\n dispatchEvent(element, hiddenToastEvent);\n};\n\n/**\n * Executes before hiding the toast.\n *\n * @param self the `Toast` instance\n */\nconst hideToast = (self: Toast) => {\n const { element, options } = self;\n addClass(element, showingClass);\n\n if (options.animation) {\n reflow(element as HTMLElement);\n emulateTransitionEnd(element, () => hideToastComplete(self));\n } else {\n hideToastComplete(self);\n }\n};\n\n/**\n * Executes before showing the toast.\n *\n * @param self the `Toast` instance\n */\nconst showToast = (self: Toast) => {\n const { element, options } = self;\n Timer.set(\n element,\n () => {\n removeClass(element, hideClass); // B/C\n reflow(element as HTMLElement);\n addClass(element, showClass);\n addClass(element, showingClass);\n\n if (options.animation) {\n emulateTransitionEnd(element, () => showToastComplete(self));\n } else {\n showToastComplete(self);\n }\n },\n 17,\n showingClass,\n );\n};\n\n// TOAST EVENT HANDLERS\n// ====================\n/**\n * Handles the `click` event listener for toast.\n *\n * @param e the `Event` object\n */\nconst toastClickHandler = (e: Event) => {\n const { target } = e;\n\n const trigger = target && closest(target as HTMLElement, toastToggleSelector);\n const element = trigger && getTargetElement(trigger);\n const self = element && getToastInstance(element);\n\n // istanbul ignore if @preserve\n if (!self) return;\n // istanbul ignore else @preserve\n if (trigger && trigger.tagName === \"A\") e.preventDefault();\n self.relatedTarget = trigger;\n self.show();\n};\n\n/**\n * Executes when user interacts with the toast without closing it,\n * usually by hovering or focusing it.\n *\n * @param e the `Toast` instance\n */\nconst interactiveToastHandler = (e: MouseEvent) => {\n const element = e.target;\n const self = getToastInstance(element);\n const { type, relatedTarget } = e;\n\n // istanbul ignore if @preserve: a solid filter is required\n if (\n !self || element === relatedTarget ||\n element.contains(relatedTarget as Node)\n ) return;\n\n if ([mouseenterEvent, focusinEvent].includes(type)) {\n Timer.clear(element, toastString);\n } else {\n Timer.set(element, () => self.hide(), self.options.delay, toastString);\n }\n};\n\n// TOAST DEFINITION\n// ================\n/** Creates a new `Toast` instance. */\nexport default class Toast extends BaseComponent {\n static selector = toastSelector;\n static init = toastInitCallback;\n static getInstance = getToastInstance;\n declare element: HTMLElement;\n declare options: ToastOptions;\n declare dismiss: HTMLElement | null;\n declare triggers: HTMLElement[];\n declare relatedTarget: HTMLElement | null;\n\n /**\n * @param target the target `.toast` element\n * @param config the instance options\n */\n constructor(target: Element | string, config?: Partial) {\n super(target, config);\n const { element, options } = this;\n\n // set fadeClass, the options.animation will override the markup\n if (options.animation && !hasClass(element, fadeClass)) {\n addClass(element, fadeClass);\n } else if (!options.animation && hasClass(element, fadeClass)) {\n removeClass(element, fadeClass);\n }\n\n // dismiss button\n this.dismiss = querySelector(toastDismissSelector, element);\n\n // toast can have multiple triggering elements\n this.triggers = [\n ...querySelectorAll(\n toastToggleSelector,\n getDocument(element),\n ),\n ].filter(\n (btn) => getTargetElement(btn) === element,\n );\n\n // add event listener\n this._toggleEventListeners(true);\n }\n /**\n * Returns component name string.\n */\n get name() {\n return toastComponent;\n }\n /**\n * Returns component default options.\n */\n get defaults() {\n return toastDefaults;\n }\n /**\n * Returns *true* when toast is visible.\n */\n get isShown() {\n return hasClass(this.element, showClass);\n }\n\n // TOAST PUBLIC METHODS\n // ====================\n /** Shows the toast. */\n show = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || isShown) return;\n\n dispatchEvent(element, showToastEvent);\n if (!showToastEvent.defaultPrevented) showToast(this);\n };\n\n /** Hides the toast. */\n hide = () => {\n const { element, isShown } = this;\n\n // istanbul ignore if @preserve\n if (!element || !isShown) return;\n\n dispatchEvent(element, hideToastEvent);\n if (!hideToastEvent.defaultPrevented) hideToast(this);\n };\n\n /**\n * Toggles on/off the `click` event listener.\n *\n * @param add when `true`, it will add the listener\n */\n _toggleEventListeners = (add?: boolean) => {\n const action = add ? addListener : removeListener;\n const { element, triggers, dismiss, options, hide } = this;\n\n // istanbul ignore else @preserve\n if (dismiss) {\n action(dismiss, mouseclickEvent, hide);\n }\n\n // istanbul ignore else @preserve\n if (options.autohide) {\n [focusinEvent, focusoutEvent, mouseenterEvent, mouseleaveEvent].forEach(\n (e) => action(element, e, interactiveToastHandler),\n );\n }\n // istanbul ignore else @preserve\n if (triggers.length) {\n triggers.forEach((btn) =>\n action(btn, mouseclickEvent, toastClickHandler)\n );\n }\n };\n\n /** Removes the `Toast` component from the target element. */\n dispose() {\n const { element, isShown } = this;\n this._toggleEventListeners();\n Timer.clear(element, toastString);\n\n if (isShown) removeClass(element, showClass);\n\n super.dispose();\n }\n}\n","import { Data, getElementsByTagName, matches } from \"@thednp/shorty\";\n\nimport { addListener } from \"@thednp/event-listener\";\n\nimport Alert from \"../components/alert\";\nimport Button from \"../components/button\";\nimport Carousel from \"../components/carousel\";\nimport Collapse from \"../components/collapse\";\nimport Dropdown from \"../components/dropdown\";\nimport Modal from \"../components/modal\";\nimport Offcanvas from \"../components/offcanvas\";\nimport Popover from \"../components/popover\";\nimport ScrollSpy from \"../components/scrollspy\";\nimport Tab from \"../components/tab\";\nimport Toast from \"../components/toast\";\nimport Tooltip from \"../components/tooltip\";\n\nconst componentsList = new Map<\n string,\n | typeof Alert\n | typeof Button\n | typeof Carousel\n | typeof Collapse\n | typeof Dropdown\n | typeof Modal\n | typeof Offcanvas\n | typeof Popover\n | typeof ScrollSpy\n | typeof Tab\n | typeof Toast\n | typeof Tooltip\n>();\n\ntype Component =\n | Alert\n | Button\n | Carousel\n | Collapse\n | Dropdown\n | Modal\n | Offcanvas\n | Popover\n | ScrollSpy\n | Tab\n | Toast\n | Tooltip;\n\n[\n Alert,\n Button,\n Carousel,\n Collapse,\n Dropdown,\n Modal,\n Offcanvas,\n Popover,\n ScrollSpy,\n Tab,\n Toast,\n Tooltip,\n].forEach((c) => componentsList.set(c.prototype.name, c));\n\n/**\n * Initialize all matched `Element`s for one component.\n *\n * @param callback\n * @param collection\n */\nconst initComponentDataAPI = (\n callback: (el: Element) => Component,\n collection: HTMLCollectionOf | Element[],\n) => {\n [...collection].forEach((x) => callback(x));\n};\n\n/**\n * Remove one component from a target container element or all in the page.\n *\n * @param component the component name\n * @param context parent `Node`\n */\nconst removeComponentDataAPI = (component: string, context: ParentNode) => {\n const compData = Data.getAllFor(component) as Map;\n\n if (compData) {\n [...compData].forEach(([element, instance]) => {\n if (context.contains(element)) {\n (instance as T & { dispose: () => void }).dispose();\n }\n });\n }\n};\n\n/**\n * Initialize all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const initCallback = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n const elemCollection = [...getElementsByTagName(\"*\", lookUp)];\n\n componentsList.forEach((cs) => {\n const { init, selector } = cs;\n initComponentDataAPI(\n init,\n elemCollection.filter((item) => matches(item, selector)),\n );\n });\n};\n\n/**\n * Remove all BSN components for a target container.\n *\n * @param context parent `Node`\n */\nexport const removeDataAPI = (context?: ParentNode) => {\n const lookUp = context && context.nodeName ? context : document;\n\n componentsList.forEach((comp) => {\n removeComponentDataAPI(comp.prototype.name, lookUp);\n });\n};\n\n// Bulk initialize all components\nif (document.body) initCallback();\nelse {\n addListener(document, \"DOMContentLoaded\", () => initCallback(), {\n once: true,\n });\n}\n"],"names":["De","Oe","$","Pe","Be","Fe","rt","ct","at","dt","pt","mt","bt","ht","yt","wt","Dt","xt","zt","Rt","je","qt","on","sn","rn","cn","gn","_t","$t","M","W","zn","t","e","te","R","n","o","s","Q","j","ne","Qn","Gn","qn","Zn","Yn","b","l","u","h","O","to","k","G","K","d","N","oe","q","g","ae","ie","ro","r","a","i","io","P","T","ue","lo","f","c","p","E","C","po","vo","bo","Eo","ho","x","le","v","yo","de","z","fe","pe","Ao","m","w","So","S","ko","me","A","ve","be","Ee","we","Co","F","H","y","Ae","Se","Do","zo","Vo","Uo","ke","Ro","Ne","Go","fadeClass","showClass","dataBsDismiss","alertString","alertComponent","Version","BaseComponent","target","config","element","isElement","isString","querySelector","prevInstance","Data","ObjectKeys","normalizeOptions","prop","alertSelector","alertDismissSelector","getAlertInstance","getInstance","alertInitCallback","Alert","closeAlertEvent","createCustomEvent","closedAlertEvent","alertTransitionEnd","self","dispatchEvent","hasClass","removeClass","emulateTransitionEnd","add","action","addListener","removeListener","dismiss","close","mouseclickEvent","activeClass","dataBsToggle","buttonString","buttonComponent","buttonSelector","getButtonInstance","buttonInitCallback","Button","setAttribute","ariaPressed","isActive","getAttribute","addClass","dataBsTarget","carouselString","carouselComponent","dataBsParent","dataBsContainer","getTargetElement","targetAttr","doc","getDocument","att","attValue","closest","carouselSelector","carouselItem","dataBsSlideTo","dataBsSlide","pausedClass","carouselDefaults","getCarouselInstance","carouselInitCallback","Carousel","startX","currentX","endX","carouselSlideEvent","carouselSlidEvent","carouselTransitionEndHandler","index","direction","slides","options","activeItem","getActiveIndex","orientation","directionClass","Timer","carouselPauseHandler","carouselResumeHandler","carouselIndicatorHandler","newIndex","carouselControlsHandler","carouselKeyHandler","code","querySelectorAll","isElementInScrollRange","RTL","isRTL","keyArrowRight","keyArrowLeft","carouselDragHandler","carouselPointerDownHandler","controls","indicators","el","toggleCarouselTouchHandlers","carouselPointerMoveHandler","carouselPointerUpHandler","activateCarouselIndicator","pointermoveEvent","passiveHandler","pointerupEvent","isHTMLElement","getElementsByClassName","activeIndex","transitionItem","matches","ar","isPaused","idx","next","eventProperties","ObjectAssign","getElementTransitionDuration","reflow","touch","pause","interval","keyboard","mouseenterEvent","mouseleaveEvent","pointerdownEvent","touchstartEvent","dragstartEvent","arrow","indicator","keydownEvent","isAnimating","clone","collapsingClass","collapseString","collapseComponent","collapseSelector","collapseToggleSelector","collapseDefaults","getCollapseInstance","collapseInitCallback","Collapse","showCollapseEvent","shownCollapseEvent","hideCollapseEvent","hiddenCollapseEvent","expandCollapse","parent","triggers","noop","setElementStyle","btn","ariaExpanded","collapseContent","collapseClickHandler","trigger","activeCollapse","activeCollapseInstance","dropdownMenuClasses","dropdownComponent","dropdownMenuClass","isEmptyAnchor","parentAnchor","hasAttribute","dropdownString","dropupString","dropstartString","dropendString","dropdownClasses","dropdownSelector","getDropdownInstance","dropdownInitCallback","Dropdown","dropdownMenuEndClass","verticalClass","horizontalClass","menuFocusTags","dropdownDefaults","showDropdownEvent","shownDropdownEvent","hideDropdownEvent","hiddenDropdownEvent","updatedDropdownEvent","styleDropdown","menu","parentElement","offset","getElementStyle","menuEnd","style","positionClass","dropdownMargin","dropdownPosition","menuWidth","menuHeight","clientWidth","clientHeight","getDocumentElement","targetLeft","targetTop","targetWidth","targetHeight","getBoundingClientRect","leftFullExceed","rightFullExceed","bottomExceed","bottomFullExceed","topExceed","leftExceed","rightExceed","posAjust","margins","getMenuItems","firstElementChild","toggleDropdownDismiss","dropdownDismissHandler","focusEvent","dropdownPreventScroll","keyupEvent","dropdownKeyHandler","getCurrentOpenDropdown","currentParent","type","isForm","mousedownEvent","dropdownClickHandler","keyArrowDown","keyArrowUp","activeElement","open","menuItems","focus","keyEscape","dropdownIntersectionHandler","entry","currentElement","currentInstance","modalString","modalComponent","offcanvasComponent","fixedTopClass","fixedBottomClass","stickyTopClass","positionStickyClass","getFixedItems","resetScrollbar","bd","getDocumentBody","fixedItems","fixed","measureScrollbar","innerWidth","getWindow","setScrollbar","overflow","bodyPad","sbWidth","itemPadValue","itemMValue","offcanvasString","popupContainer","createElement","appendPopup","customContainer","containerIsBody","isNode","lookup","BODY","removePopup","hasPopup","backdropString","modalBackdropClass","offcanvasBackdropClass","modalActiveSelector","offcanvasActiveSelector","overlay","getCurrentOpen","toggleOverlayType","isModal","targetClass","appendOverlay","hasFade","showOverlay","hideOverlay","removeOverlay","isVisible","modalSelector","modalToggleSelector","modalDismissSelector","modalStaticClass","modalDefaults","getModalInstance","modalInitCallback","Modal","showModalEvent","shownModalEvent","hideModalEvent","hiddenModalEvent","setModalScrollbar","scrollbarWidth","scrollHeight","modalHeight","modalScrollHeight","modalOverflow","padStyle","toggleModalDismiss","modalDismissHandler","modalKeyHandler","afterModalHide","relatedTarget","focusElement","toggleFocusTrap","afterModalShow","beforeModalShow","removeAttribute","ariaHidden","ariaModal","beforeModalHide","modalClickHandler","currentTarget","isStatic","modalDialog","backdrop","selectedText","targetInsideDialog","staticTransitionEnd","duration","overlayDelay","currentOpen","that","callback","offcanvasSelector","offcanvasToggleSelector","offcanvasDismissSelector","offcanvasTogglingClass","offcanvasDefaults","getOffcanvasInstance","offcanvasInitCallback","Offcanvas","showOffcanvasEvent","shownOffcanvasEvent","hideOffcanvasEvent","hiddenOffcanvasEvent","setOffCanvasScrollbar","toggleOffCanvasDismiss","offcanvasKeyDismissHandler","offcanvasDismissHandler","beforeOffcanvasShow","showOffcanvasComplete","beforeOffcanvasHide","hideOffcanvasComplete","offcanvasTriggerHandler","offCanvasDismiss","selection","visibleTrigger","isOpen","popoverString","popoverComponent","tooltipString","getTipTemplate","tipType","isTooltip","bodyClass","header","body","tipClassPositions","styleTip","tipClasses","tooltip","container","offsetParent","scrollLeft","scrollTop","getNodeScroll","tipWidth","tipHeight","htmlcw","htmlch","htmlow","placement","parentCWidth","parentOWidth","fixedParent","leftBoundry","rightBoundry","observerEntry","elemWidth","elemHeight","elemRectLeft","elemRectRight","elemRectTop","elemOffsetLeft","elemOffsetTop","getRectRelativeToOffsetParent","topPosition","bottomPosition","leftPosition","rightPosition","arrowTop","arrowLeft","arrowRight","arrowWidth","arrowHeight","arrowAdjust","horizontals","verticals","updatedTooltipEvent","toLowerCase","tooltipDefaults","_","dataOriginalTitle","tooltipComponent","setHtml","content","sanitizeFn","dirty","isFunction","tempDocument","isNodeList","isArray","createTip","id","title","template","animation","customClass","dismissible","btnClose","tipString","tipPositions","titleParts","contentParts","placementClass","tooltipTemplate","htmlMarkup","tooltipHeader","tooltipBody","tempTitle","tempContent","tempBtn","getElementContainer","majorBlockTags","containers","parentNode","getParentNode","isShadowRoot","isTableElement","tooltipSelector","titleAttr","getTooltipInstance","tooltipInitCallback","Tooltip","removeTooltip","ariaDescribedBy","hasTip","disposeTooltipComplete","toggleTooltipTitle","toggleTooltipAction","tooltipShownAction","shownTooltipEvent","tooltipHiddenAction","hiddenTooltipEvent","toggleTooltipOpenHandlers","parentModal","parentOffcanvas","titleAtt","tipComponent","elem","getUID","position","PositionObserver","entries","outTimer","showTooltipEvent","delay","hideTooltipEvent","enabled","tr","mousehoverEvent","focusinEvent","focusoutEvent","isApple","popoverSelector","popoverDefaults","getPopoverInstance","popoverInitCallback","Popover","scrollspyString","scrollspyComponent","scrollspySelector","scrollspyDefaults","getScrollSpyInstance","scrollspyInitCallback","ScrollSpy","activateScrollSpy","updateSpyTargets","scrollTarget","itemsLength","_observer","isRoot","links","getElementsByTagName","scrollHEIGHT","href","ref","targetItem","rect","getOffsetHeight","link","toggleObservers","targets","getScrollHeight","clear","item","activate","parents","parentItem","menuItem","parentLink","spyTarget","maxScroll","items","newActiveItem","offsets","tabString","tabComponent","tabSelector","getTabInstance","tabInitCallback","Tab","showTabEvent","shownTabEvent","hideTabEvent","hiddenTabEvent","tabPrivate","triggerTabEnd","tabContent","nav","triggerTabShow","nextContent","tab","currentHeight","nextHeight","triggerTabHide","getActiveTab","activeTabs","getParentDropdown","dropdown","tabClickHandler","firstTab","firstTabContent","ariaSelected","activeDropdown","toggleTab","toastString","toastComponent","toastSelector","toastDismissSelector","toastToggleSelector","showingClass","hideClass","toastDefaults","getToastInstance","toastInitCallback","Toast","showToastEvent","shownToastEvent","hideToastEvent","hiddenToastEvent","showToastComplete","hideToastComplete","hideToast","showToast","toastClickHandler","interactiveToastHandler","isShown","hide","componentsList","initComponentDataAPI","collection","removeComponentDataAPI","component","context","compData","instance","initCallback","lookUp","elemCollection","cs","init","selector","removeDataAPI","comp"],"mappings":"iCAAK,MAA6DA,GAAK,mBAAoBC,GAAK,gBAAuCC,GAAI,cAA0DC,GAAK,aAAcC,GAAK,eAAgBC,GAAK,gBAAwPC,GAAK,QAASC,GAAK,UAAWC,GAAK,WAA0EC,GAAK,UAA4BC,GAAK,QAAsBC,EAAK,QAA0BC,GAAK,YAA6BC,GAAK,QAASC,GAAK,aAAcC,GAAK,aAAmKC,GAAK,cAAoCC,GAAK,cAAeC,GAAK,YAAsJC,GAAK,aAmD1mCC,GAAK,YAUuBC,GAAK,oFAoBlCC,GAAK,YAAaC,GAAK,UAAWC,GAAK,YAAaC,GAAK,aAAkHC,GAAK,SAAyMC,GAAK,qBAAsBC,GAAK,kBAAmBC,GAAI,gBAAiBC,GAAI,qBA+BjdC,GAAK,IAAM,CACZ,MAAMC,EAAI,qBACV,OAAO,WAAW,eAAe,OAAO,KACrCC,GAAMD,EAAE,KAAKC,EAAE,KAAK,CACtB,GAAID,EAAE,KACL,WAAW,SACZ,GAAI,EACP,EAA2PE,GAA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,CACnD,CACH,EAGA,OAAI,SAAS,KAAmBD,GAAA,EAE9B9iB,EAAY,SAAU,mBAAoB,IAAM8iB,GAAA,EAAgB,CAC9D,KAAM,EAAA,CACP","x_google_ignoreList":[0,1,52]} \ No newline at end of file diff --git a/docs/index-dev.html b/docs/index-dev.html index 27c0b992..25eea9cd 100644 --- a/docs/index-dev.html +++ b/docs/index-dev.html @@ -75,7 +75,7 @@

A What Bootstrap?

The lighter and more compact set of JavaScript components for Bootstrap, sourced with Typescript codebase.
- At less than half the size of the original and around 15kb gZipped, this library does most of Bootstrap & Popper combined.

+ At half the size of the original and around 21kb gZipped, this library does it all.

Download NPM @@ -784,7 +784,6 @@

This is another caption

-

Collapse

The Collapse component covers the original events and methods of the jQuery plugin counterpart. This @@ -1106,12 +1105,14 @@

Dropdown

The Dropdown component covers most of the functionality from the original plugin in terms of original events, instance methods and options, but also offers some additional functionality without using any third party library.

-

To get on par with the original plugin, our component now sports automatic repositioning but without the use of Popper.js.

+

To get on par with the original plugin, our component now features automatic repositioning but without the use of Popper.js, + but with IntersectionObserver + to update the menu's position.

Here's how it works:

  • when showing the dropdown menu to the user, the component will calculate all possible positions and update the menu position so that the it's always displayed fully into the viewport;
  • -
  • while the dropdown menu is visible to the user, event listeners will update the position for the dropdown menu, +
  • while the dropdown menu is visible to the user, the observer will trigger the update of dropdown menu position, just like when showing it again to the user.
@@ -1427,6 +1428,9 @@

Modal

<nav class="navbar fixed-top"> are also adjusted in the same manner to get the smoothest possible transition. Like all components of the library, the component grants access to the initialization object even if your modal is automatically initialized via DATA API.

+

While shown to the user, the component makes use of ResizeObserver + to trigger the update of these elements and not rely on the obsolete implementation of resize + event listeners.

Modal Options

@@ -1690,11 +1694,6 @@ SVG @@ -3858,7 +3867,7 @@

Tooltip Examples

Demo Tooltip for IMG
- diff --git a/docs/index.html b/docs/index.html index d4201840..dd846523 100644 --- a/docs/index.html +++ b/docs/index.html @@ -74,8 +74,8 @@

A What Bootstrap?

-

The lighter and more compact set of JavaScript components for Bootstrap, sourced with Typescript codebase.
- At less than half the size of the original and around 15kb gZipped, this library does most of Bootstrap & Popper combined.

+

The lighter and more compact set of JavaScript components for Bootstrap, written in Typescript.
+ At half the size of the original and around 21kb gZipped, this library does it all.

Download NPM @@ -784,7 +784,6 @@

This is another caption

-

Collapse

The Collapse component covers the original events and methods of the jQuery plugin counterpart. This @@ -1106,12 +1105,14 @@

Dropdown

The Dropdown component covers most of the functionality from the original plugin in terms of original events, instance methods and options, but also offers some additional functionality without using any third party library.

-

To get on par with the original plugin, our component now sports automatic repositioning but without the use of Popper.js.

+

To get on par with the original plugin, our component now features automatic repositioning but without the use of Popper.js, + but with IntersectionObserver + to update the menu's position.

Here's how it works:

  • when showing the dropdown menu to the user, the component will calculate all possible positions and update the menu position so that the it's always displayed fully into the viewport;
  • -
  • while the dropdown menu is visible to the user, event listeners will update the position for the dropdown menu, +
  • while the dropdown menu is visible to the user, the observer will trigger the update of dropdown menu position, just like when showing it again to the user.
@@ -1427,6 +1428,9 @@

Modal

<nav class="navbar fixed-top"> are also adjusted in the same manner to get the smoothest possible transition. Like all components of the library, the component grants access to the initialization object even if your modal is automatically initialized via DATA API.

+

While shown to the user, the component makes use of ResizeObserver + to trigger the update of these elements and not rely on the obsolete implementation of resize + event listeners.

Modal Options

@@ -1690,11 +1694,6 @@ +

This iframe is intentionally larger.

diff --git a/package.json b/package.json index 0f50b171..c7185a86 100644 --- a/package.json +++ b/package.json @@ -83,7 +83,7 @@ "clean-coverage": "rm -rf coverage .nyc_output", "badges": "npx -p dependency-version-badge update-badge typescript vitest vite", "build": "pnpm build-vite && pnpm build-components && pnpm copy-docs", - "build-vite": "vite build && pnpm copy-docs", + "build-vite": "vite build", "build-components": "vite build --config vite.config.components.mts", "copy-docs": "cp dist/bootstrap-native.js docs/assets/js/bootstrap-native.js && cp dist/bootstrap-native.js.map docs/assets/js/bootstrap-native.js.map", "lint": "deno lint src && pnpm check:ts", @@ -108,12 +108,12 @@ "typescript" ], "dependencies": { - "@thednp/event-listener": "^2.0.6", - "@thednp/position-observer": "^0.0.3", - "@thednp/shorty": "^2.0.7" + "@thednp/event-listener": "^2.0.8", + "@thednp/position-observer": "github:thednp/position-observer", + "@thednp/shorty": "github:thednp/shorty" }, "devDependencies": { - "@types/node": "^20.17.1", + "@types/node": "^20.17.6", "@vitest/browser": "^2.1.4", "@vitest/coverage-istanbul": "^2.1.4", "@vitest/ui": "^2.1.4", @@ -121,6 +121,7 @@ "typescript": "^5.6.3", "vite": "^5.4.10", "vite-plugin-dts": "^4.3.0", + "vite-plugin-strip-comments": "^0.0.1", "vitest": "^2.1.4" }, "packageManager": "pnpm@8.6.12", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index af14e73d..7691a883 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,24 +9,24 @@ importers: .: dependencies: '@thednp/event-listener': - specifier: ^2.0.6 - version: 2.0.6 + specifier: ^2.0.8 + version: 2.0.8 '@thednp/position-observer': - specifier: ^0.0.3 - version: 0.0.3 + specifier: github:thednp/position-observer + version: https://codeload.github.com/thednp/position-observer/tar.gz/d693d5387bed0966c0954c6c5a0e5dbc8e5cb67f '@thednp/shorty': - specifier: ^2.0.7 - version: 2.0.7 + specifier: github:thednp/shorty + version: https://codeload.github.com/thednp/shorty/tar.gz/309d581b370f747cb15531ca6c201def3827e05c devDependencies: '@types/node': - specifier: ^20.17.1 - version: 20.17.1 + specifier: ^20.17.6 + version: 20.17.6 '@vitest/browser': specifier: ^2.1.4 - version: 2.1.4(@types/node@20.17.1)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0))(vitest@2.1.4) + version: 2.1.4(@types/node@20.17.6)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0))(vitest@2.1.4) '@vitest/coverage-istanbul': specifier: ^2.1.4 - version: 2.1.4(vitest@2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0)) + version: 2.1.4(vitest@2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0)) '@vitest/ui': specifier: ^2.1.4 version: 2.1.4(vitest@2.1.4) @@ -38,13 +38,16 @@ importers: version: 5.6.3 vite: specifier: ^5.4.10 - version: 5.4.10(@types/node@20.17.1)(terser@5.33.0) + version: 5.4.10(@types/node@20.17.6)(terser@5.33.0) vite-plugin-dts: specifier: ^4.3.0 - version: 4.3.0(@types/node@20.17.1)(rollup@4.24.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0)) + version: 4.3.0(@types/node@20.17.6)(rollup@4.24.4)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0)) + vite-plugin-strip-comments: + specifier: ^0.0.1 + version: 0.0.1 vitest: specifier: ^2.1.4 - version: 2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0) + version: 2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0) packages: @@ -52,20 +55,20 @@ packages: resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} engines: {node: '>=6.0.0'} - '@babel/code-frame@7.26.0': - resolution: {integrity: sha512-INCKxTtbXtcNbUZ3YXutwMpEleqttcswhAdee7dhuoVrD2cnuc3PqtERBtxkX5nziX9vnBL8WXmSGwv8CuPV6g==} + '@babel/code-frame@7.26.2': + resolution: {integrity: sha512-RJlIHRueQgwWitWgF8OdFYGZX328Ax5BCemNGlqHfplnRT9ESi8JkFlvaVYbS+UubVY6dpv87Fs2u5M29iNFVQ==} engines: {node: '>=6.9.0'} - '@babel/compat-data@7.26.0': - resolution: {integrity: sha512-qETICbZSLe7uXv9VE8T/RWOdIE5qqyTucOt4zLYMafj2MRO271VGgLd4RACJMeBO37UPWhXiKMBk7YlJ0fOzQA==} + '@babel/compat-data@7.26.2': + resolution: {integrity: sha512-Z0WgzSEa+aUcdiJuCIqgujCshpMWgUpgOxXotrYPSA53hA3qopNaqcJpyr0hVb1FeWdnqFA35/fUtXgBK8srQg==} engines: {node: '>=6.9.0'} '@babel/core@7.26.0': resolution: {integrity: sha512-i1SLeK+DzNnQ3LL/CswPCa/E5u4lh1k6IAEphON8F+cXt0t9euTshDru0q7/IqMa1PMPz5RnHuHscF8/ZJsStg==} engines: {node: '>=6.9.0'} - '@babel/generator@7.26.0': - resolution: {integrity: sha512-/AIkAmInnWwgEAJGQr9vY0c66Mj6kjkE2ZPB1PurTRaRAh3U+J45sAQMjQDJdh4WbR3l0x5xkimXBKyBXXAu2w==} + '@babel/generator@7.26.2': + resolution: {integrity: sha512-zevQbhbau95nkoxSq3f/DC/SC+EEOUZd3DYqfSkMhY2/wfSeaHV1Ew4vk8e+x8lja31IbyuUa2uQ3JONqKbysw==} engines: {node: '>=6.9.0'} '@babel/helper-compilation-targets@7.25.9': @@ -98,8 +101,8 @@ packages: resolution: {integrity: sha512-tbhNuIxNcVb21pInl3ZSjksLCvgdZy9KwJ8brv993QtIVKJBBkYXz4q4ZbAv31GdnC+R90np23L5FbEBlthAEw==} engines: {node: '>=6.9.0'} - '@babel/parser@7.26.1': - resolution: {integrity: sha512-reoQYNiAJreZNsJzyrDNzFQ+IQ5JFiIzAHJg9bn94S3l+4++J7RsIhNMoB+lgP/9tpmiAQqspv+xfdxTSzREOw==} + '@babel/parser@7.26.2': + resolution: {integrity: sha512-DWMCZH9WA4Maitz2q21SRKHo9QXZxkDsbNZoVD62gusNtNBBqDg9i7uOhASfTfIGNzW+O+r7+jAlM8dwphcJKQ==} engines: {node: '>=6.0.0'} hasBin: true @@ -119,8 +122,8 @@ packages: resolution: {integrity: sha512-Z/yiTPj+lDVnF7lWeKCIJzaIkI0vYO87dMpZ4bg4TDrFe4XXLFWL1TbXU27gBP3QccxV9mZICCrnjnYlJjXHOA==} engines: {node: '>=6.9.0'} - '@bundled-es-modules/cookie@2.0.0': - resolution: {integrity: sha512-Or6YHg/kamKHpxULAdSqhGqnWFneIXu1NKvvfBBzKGwpVsYuFIQ5aBPHDnnoR3ghW1nvSkALd+EF9iMtY7Vjxw==} + '@bundled-es-modules/cookie@2.0.1': + resolution: {integrity: sha512-8o+5fRPLNbjbdGRRmJj3h6Hh1AQJf2dk3qQ/5ZFb+PXkRNiSoMGGUKlsgLfrxneb72axVJyIYji64E2+nNfYyw==} '@bundled-es-modules/statuses@1.0.1': resolution: {integrity: sha512-yn7BklA5acgcBr+7w064fGV+SGIFySjCKpqjcWgBAIfrAkY+4GQTJJHQMeT3V/sgz23VTEVV8TtOmkvJAhFVfg==} @@ -328,8 +331,8 @@ packages: '@microsoft/tsdoc@0.15.0': resolution: {integrity: sha512-HZpPoABogPvjeJOdzCOSJsXeL/SMCBgBZMVC3X3d7YYp2gf31MfxhUoYUNwf1ERPJOnQc0wkFn9trqI6ZEdZuA==} - '@mswjs/interceptors@0.36.6': - resolution: {integrity: sha512-issnYydStyH0wPEeU7CMwfO7kI668ffVtzKRMRS7H7BliOYuPuwEZxh9dwiXV+oeHBxT5SXT0wPwV8T7V2PJUA==} + '@mswjs/interceptors@0.36.10': + resolution: {integrity: sha512-GXrJgakgJW3DWKueebkvtYgGKkxA7s0u5B0P5syJM5rvQUnrpLPigvci8Hukl7yEM+sU06l+er2Fgvx/gmiRgg==} engines: {node: '>=18'} '@open-draft/deferred-promise@2.2.0': @@ -357,93 +360,93 @@ packages: rollup: optional: true - '@rollup/rollup-android-arm-eabi@4.24.2': - resolution: {integrity: sha512-ufoveNTKDg9t/b7nqI3lwbCG/9IJMhADBNjjz/Jn6LxIZxD7T5L8l2uO/wD99945F1Oo8FvgbbZJRguyk/BdzA==} + '@rollup/rollup-android-arm-eabi@4.24.4': + resolution: {integrity: sha512-jfUJrFct/hTA0XDM5p/htWKoNNTbDLY0KRwEt6pyOA6k2fmk0WVwl65PdUdJZgzGEHWx+49LilkcSaumQRyNQw==} cpu: [arm] os: [android] - '@rollup/rollup-android-arm64@4.24.2': - resolution: {integrity: sha512-iZoYCiJz3Uek4NI0J06/ZxUgwAfNzqltK0MptPDO4OR0a88R4h0DSELMsflS6ibMCJ4PnLvq8f7O1d7WexUvIA==} + '@rollup/rollup-android-arm64@4.24.4': + resolution: {integrity: sha512-j4nrEO6nHU1nZUuCfRKoCcvh7PIywQPUCBa2UsootTHvTHIoIu2BzueInGJhhvQO/2FTRdNYpf63xsgEqH9IhA==} cpu: [arm64] os: [android] - '@rollup/rollup-darwin-arm64@4.24.2': - resolution: {integrity: sha512-/UhrIxobHYCBfhi5paTkUDQ0w+jckjRZDZ1kcBL132WeHZQ6+S5v9jQPVGLVrLbNUebdIRpIt00lQ+4Z7ys4Rg==} + '@rollup/rollup-darwin-arm64@4.24.4': + resolution: {integrity: sha512-GmU/QgGtBTeraKyldC7cDVVvAJEOr3dFLKneez/n7BvX57UdhOqDsVwzU7UOnYA7AAOt+Xb26lk79PldDHgMIQ==} cpu: [arm64] os: [darwin] - '@rollup/rollup-darwin-x64@4.24.2': - resolution: {integrity: sha512-1F/jrfhxJtWILusgx63WeTvGTwE4vmsT9+e/z7cZLKU8sBMddwqw3UV5ERfOV+H1FuRK3YREZ46J4Gy0aP3qDA==} + '@rollup/rollup-darwin-x64@4.24.4': + resolution: {integrity: sha512-N6oDBiZCBKlwYcsEPXGDE4g9RoxZLK6vT98M8111cW7VsVJFpNEqvJeIPfsCzbf0XEakPslh72X0gnlMi4Ddgg==} cpu: [x64] os: [darwin] - '@rollup/rollup-freebsd-arm64@4.24.2': - resolution: {integrity: sha512-1YWOpFcGuC6iGAS4EI+o3BV2/6S0H+m9kFOIlyFtp4xIX5rjSnL3AwbTBxROX0c8yWtiWM7ZI6mEPTI7VkSpZw==} + '@rollup/rollup-freebsd-arm64@4.24.4': + resolution: {integrity: sha512-py5oNShCCjCyjWXCZNrRGRpjWsF0ic8f4ieBNra5buQz0O/U6mMXCpC1LvrHuhJsNPgRt36tSYMidGzZiJF6mw==} cpu: [arm64] os: [freebsd] - '@rollup/rollup-freebsd-x64@4.24.2': - resolution: {integrity: sha512-3qAqTewYrCdnOD9Gl9yvPoAoFAVmPJsBvleabvx4bnu1Kt6DrB2OALeRVag7BdWGWLhP1yooeMLEi6r2nYSOjg==} + '@rollup/rollup-freebsd-x64@4.24.4': + resolution: {integrity: sha512-L7VVVW9FCnTTp4i7KrmHeDsDvjB4++KOBENYtNYAiYl96jeBThFfhP6HVxL74v4SiZEVDH/1ILscR5U9S4ms4g==} cpu: [x64] os: [freebsd] - '@rollup/rollup-linux-arm-gnueabihf@4.24.2': - resolution: {integrity: sha512-ArdGtPHjLqWkqQuoVQ6a5UC5ebdX8INPuJuJNWRe0RGa/YNhVvxeWmCTFQ7LdmNCSUzVZzxAvUznKaYx645Rig==} + '@rollup/rollup-linux-arm-gnueabihf@4.24.4': + resolution: {integrity: sha512-10ICosOwYChROdQoQo589N5idQIisxjaFE/PAnX2i0Zr84mY0k9zul1ArH0rnJ/fpgiqfu13TFZR5A5YJLOYZA==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm-musleabihf@4.24.2': - resolution: {integrity: sha512-B6UHHeNnnih8xH6wRKB0mOcJGvjZTww1FV59HqJoTJ5da9LCG6R4SEBt6uPqzlawv1LoEXSS0d4fBlHNWl6iYw==} + '@rollup/rollup-linux-arm-musleabihf@4.24.4': + resolution: {integrity: sha512-ySAfWs69LYC7QhRDZNKqNhz2UKN8LDfbKSMAEtoEI0jitwfAG2iZwVqGACJT+kfYvvz3/JgsLlcBP+WWoKCLcw==} cpu: [arm] os: [linux] - '@rollup/rollup-linux-arm64-gnu@4.24.2': - resolution: {integrity: sha512-kr3gqzczJjSAncwOS6i7fpb4dlqcvLidqrX5hpGBIM1wtt0QEVtf4wFaAwVv8QygFU8iWUMYEoJZWuWxyua4GQ==} + '@rollup/rollup-linux-arm64-gnu@4.24.4': + resolution: {integrity: sha512-uHYJ0HNOI6pGEeZ/5mgm5arNVTI0nLlmrbdph+pGXpC9tFHFDQmDMOEqkmUObRfosJqpU8RliYoGz06qSdtcjg==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-arm64-musl@4.24.2': - resolution: {integrity: sha512-TDdHLKCWgPuq9vQcmyLrhg/bgbOvIQ8rtWQK7MRxJ9nvaxKx38NvY7/Lo6cYuEnNHqf6rMqnivOIPIQt6H2AoA==} + '@rollup/rollup-linux-arm64-musl@4.24.4': + resolution: {integrity: sha512-38yiWLemQf7aLHDgTg85fh3hW9stJ0Muk7+s6tIkSUOMmi4Xbv5pH/5Bofnsb6spIwD5FJiR+jg71f0CH5OzoA==} cpu: [arm64] os: [linux] - '@rollup/rollup-linux-powerpc64le-gnu@4.24.2': - resolution: {integrity: sha512-xv9vS648T3X4AxFFZGWeB5Dou8ilsv4VVqJ0+loOIgDO20zIhYfDLkk5xoQiej2RiSQkld9ijF/fhLeonrz2mw==} + '@rollup/rollup-linux-powerpc64le-gnu@4.24.4': + resolution: {integrity: sha512-q73XUPnkwt9ZNF2xRS4fvneSuaHw2BXuV5rI4cw0fWYVIWIBeDZX7c7FWhFQPNTnE24172K30I+dViWRVD9TwA==} cpu: [ppc64] os: [linux] - '@rollup/rollup-linux-riscv64-gnu@4.24.2': - resolution: {integrity: sha512-tbtXwnofRoTt223WUZYiUnbxhGAOVul/3StZ947U4A5NNjnQJV5irKMm76G0LGItWs6y+SCjUn/Q0WaMLkEskg==} + '@rollup/rollup-linux-riscv64-gnu@4.24.4': + resolution: {integrity: sha512-Aie/TbmQi6UXokJqDZdmTJuZBCU3QBDA8oTKRGtd4ABi/nHgXICulfg1KI6n9/koDsiDbvHAiQO3YAUNa/7BCw==} cpu: [riscv64] os: [linux] - '@rollup/rollup-linux-s390x-gnu@4.24.2': - resolution: {integrity: sha512-gc97UebApwdsSNT3q79glOSPdfwgwj5ELuiyuiMY3pEWMxeVqLGKfpDFoum4ujivzxn6veUPzkGuSYoh5deQ2Q==} + '@rollup/rollup-linux-s390x-gnu@4.24.4': + resolution: {integrity: sha512-P8MPErVO/y8ohWSP9JY7lLQ8+YMHfTI4bAdtCi3pC2hTeqFJco2jYspzOzTUB8hwUWIIu1xwOrJE11nP+0JFAQ==} cpu: [s390x] os: [linux] - '@rollup/rollup-linux-x64-gnu@4.24.2': - resolution: {integrity: sha512-jOG/0nXb3z+EM6SioY8RofqqmZ+9NKYvJ6QQaa9Mvd3RQxlH68/jcB/lpyVt4lCiqr04IyaC34NzhUqcXbB5FQ==} + '@rollup/rollup-linux-x64-gnu@4.24.4': + resolution: {integrity: sha512-K03TljaaoPK5FOyNMZAAEmhlyO49LaE4qCsr0lYHUKyb6QacTNF9pnfPpXnFlFD3TXuFbFbz7tJ51FujUXkXYA==} cpu: [x64] os: [linux] - '@rollup/rollup-linux-x64-musl@4.24.2': - resolution: {integrity: sha512-XAo7cJec80NWx9LlZFEJQxqKOMz/lX3geWs2iNT5CHIERLFfd90f3RYLLjiCBm1IMaQ4VOX/lTC9lWfzzQm14Q==} + '@rollup/rollup-linux-x64-musl@4.24.4': + resolution: {integrity: sha512-VJYl4xSl/wqG2D5xTYncVWW+26ICV4wubwN9Gs5NrqhJtayikwCXzPL8GDsLnaLU3WwhQ8W02IinYSFJfyo34Q==} cpu: [x64] os: [linux] - '@rollup/rollup-win32-arm64-msvc@4.24.2': - resolution: {integrity: sha512-A+JAs4+EhsTjnPQvo9XY/DC0ztaws3vfqzrMNMKlwQXuniBKOIIvAAI8M0fBYiTCxQnElYu7mLk7JrhlQ+HeOw==} + '@rollup/rollup-win32-arm64-msvc@4.24.4': + resolution: {integrity: sha512-ku2GvtPwQfCqoPFIJCqZ8o7bJcj+Y54cZSr43hHca6jLwAiCbZdBUOrqE6y29QFajNAzzpIOwsckaTFmN6/8TA==} cpu: [arm64] os: [win32] - '@rollup/rollup-win32-ia32-msvc@4.24.2': - resolution: {integrity: sha512-ZhcrakbqA1SCiJRMKSU64AZcYzlZ/9M5LaYil9QWxx9vLnkQ9Vnkve17Qn4SjlipqIIBFKjBES6Zxhnvh0EAEw==} + '@rollup/rollup-win32-ia32-msvc@4.24.4': + resolution: {integrity: sha512-V3nCe+eTt/W6UYNr/wGvO1fLpHUrnlirlypZfKCT1fG6hWfqhPgQV/K/mRBXBpxc0eKLIF18pIOFVPh0mqHjlg==} cpu: [ia32] os: [win32] - '@rollup/rollup-win32-x64-msvc@4.24.2': - resolution: {integrity: sha512-2mLH46K1u3r6uwc95hU+OR9q/ggYMpnS7pSp83Ece1HUQgF9Nh/QwTK5rcgbFnV9j+08yBrU5sA/P0RK2MSBNA==} + '@rollup/rollup-win32-x64-msvc@4.24.4': + resolution: {integrity: sha512-LTw1Dfd0mBIEqUVCxbvTE/LLo+9ZxVC9k99v1v4ahg9Aak6FpqOfNu5kRkeTAn0wphoC4JU7No1/rL+bBCEwhg==} cpu: [x64] os: [win32] @@ -479,16 +482,18 @@ packages: peerDependencies: '@testing-library/dom': '>=7.21.4' - '@thednp/event-listener@2.0.6': - resolution: {integrity: sha512-6u55ydv4+2VHwHU8EJaJXa40QzZ7XOXVo74MMPnGCSzbl0q3yqHfQh8r0Sw/50rutHxecLVQBM/C9Fr0c+m+ew==} + '@thednp/event-listener@2.0.8': + resolution: {integrity: sha512-bZY04sWSn2YWAqcuY/fYy03ynARYHwn8xzYgdqqcHBXsBXhOc+bbWwHyLwW28XAA2NjzjMPZZAM3N5D09i+zEQ==} engines: {node: '>=16', pnpm: '>=8.6.0'} - '@thednp/position-observer@0.0.3': - resolution: {integrity: sha512-O2ukulmlcPhqo0alSn2lvKg9V4k2D/6HpXtD5qYbZyYCEBG1Nd2m97oqRfw5+ivIAh7DxC+wmkWGBkybknU2aA==} + '@thednp/position-observer@https://codeload.github.com/thednp/position-observer/tar.gz/d693d5387bed0966c0954c6c5a0e5dbc8e5cb67f': + resolution: {tarball: https://codeload.github.com/thednp/position-observer/tar.gz/d693d5387bed0966c0954c6c5a0e5dbc8e5cb67f} + version: 1.0.2 engines: {node: '>=16', pnpm: '>=8.6.0'} - '@thednp/shorty@2.0.7': - resolution: {integrity: sha512-PQ388ZznrgnkikwkDCqqFfkGAYWXS2ijFmXD63Ej47Md6VrV5WJqhgQilhu3tSkzddtbDJlz4tQTj4RYVrWUoA==} + '@thednp/shorty@https://codeload.github.com/thednp/shorty/tar.gz/309d581b370f747cb15531ca6c201def3827e05c': + resolution: {tarball: https://codeload.github.com/thednp/shorty/tar.gz/309d581b370f747cb15531ca6c201def3827e05c} + version: 2.0.8 engines: {node: '>=16', pnpm: '>=8.6.0'} '@types/argparse@1.0.38': @@ -503,8 +508,8 @@ packages: '@types/estree@1.0.6': resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} - '@types/node@20.17.1': - resolution: {integrity: sha512-j2VlPv1NnwPJbaCNv69FO/1z4lId0QmGvpT41YxitRtWlg96g/j8qcv2RKsLKe2F6OJgyXhupN1Xo17b2m139Q==} + '@types/node@20.17.6': + resolution: {integrity: sha512-VEI7OdvK2wP7XHnsuXbAJnEpEkF6NjSN45QJlL4VGqZSXsnicpesdTWsg9RISeSdYd3yeRj/y3k5KGjUXYnFwQ==} '@types/statuses@2.0.5': resolution: {integrity: sha512-jmIUGWrAiwu3dZpxntxieC+1n/5c3mjrImkmOSQ2NC5uP6cYO4aAZDdSmRcI5C1oiTmqlZGHC+/NmJrKogbP5A==} @@ -566,14 +571,14 @@ packages: '@vitest/utils@2.1.4': resolution: {integrity: sha512-MXDnZn0Awl2S86PSNIim5PWXgIAx8CIkzu35mBdSApUip6RFOGXBCf3YFyeEu8n1IHk4bWD46DeYFu9mQlFIRg==} - '@volar/language-core@2.4.8': - resolution: {integrity: sha512-K/GxMOXGq997bO00cdFhTNuR85xPxj0BEEAy+BaqqayTmy9Tmhfgmq2wpJcVspRhcwfgPoE2/mEJa26emUhG/g==} + '@volar/language-core@2.4.9': + resolution: {integrity: sha512-t++GIrUeQnKCieZdY9e+Uar2VmTqOE4Z9KcEcdSHKmKZPuqpbbWow1YKe1i3HpU2s1JqLRVM8y/n87WKXyxJAg==} - '@volar/source-map@2.4.8': - resolution: {integrity: sha512-jeWJBkC/WivdelMwxKkpFL811uH/jJ1kVxa+c7OvG48DXc3VrP7pplSWPP2W1dLMqBxD+awRlg55FQQfiup4cA==} + '@volar/source-map@2.4.9': + resolution: {integrity: sha512-UGE+WgJwk64OcfBwBOBKIzmF+uNx4dC5GzOvaVsHbTBp/IVqeTVsGiO5CwBAt6l3vVXYbMuddG2DU8FEnBRxTg==} - '@volar/typescript@2.4.8': - resolution: {integrity: sha512-6xkIYJ5xxghVBhVywMoPMidDDAFT1OoQeXwa27HSgJ6AiIKRe61RXLoik+14Z7r0JvnblXVsjsRLmCr42SGzqg==} + '@volar/typescript@2.4.9': + resolution: {integrity: sha512-Zmh3Bq8CFD6OANKYsi4vs/l7togwfjFH0kgrT12uAsDff2AJQjbEUKTVUnxmHbnbH2B9ja7Lb6Mu/Wj9wBuJlg==} '@vue/compiler-core@3.5.12': resolution: {integrity: sha512-ISyBTRMmMYagUxhcpyEH0hpXRd/KqDU4ymofPgl2XAkY9ZhQ+h0ovEZJIiPop13UmR/54oA2cgMDjgroRelaEw==} @@ -677,8 +682,8 @@ packages: resolution: {integrity: sha512-b6Ilus+c3RrdDk+JhLKUAQfzzgLEPy6wcXqS7f/xe1EETvsDP6GORG7SFuOs6cID5YkqchW/LXZbX5bc8j7ZcQ==} engines: {node: '>=8'} - caniuse-lite@1.0.30001673: - resolution: {integrity: sha512-WTrjUCSMp3LYX0nE12ECkV0a+e6LC85E0Auz75555/qr78Oc8YWhEPNfDd6SHdtlCMSzqtuXY0uyEMNRcsKpKw==} + caniuse-lite@1.0.30001678: + resolution: {integrity: sha512-RR+4U/05gNtps58PEBDZcPWTgEO2MBeoPZ96aQcjmfkBWRIDfN451fW2qyDA9/+HohLLIL5GqiMwA+IB1pWarw==} chai@5.1.2: resolution: {integrity: sha512-aGtmf24DW6MLHHG5gCx4zaI3uBq3KRtxeVs0DjFH6Z0rDNbsvTxFASFvdj79pxjxZ8/5u3PIiN3IwEIQkiiuPw==} @@ -725,12 +730,12 @@ packages: convert-source-map@2.0.0: resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} - cookie@0.5.0: - resolution: {integrity: sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==} + cookie@0.7.2: + resolution: {integrity: sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==} engines: {node: '>= 0.6'} - cross-spawn@7.0.3: - resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} + cross-spawn@7.0.5: + resolution: {integrity: sha512-ZVJrKKYunU38/76t0RMOulHOnUcbU9GbpWKAOZ0mhjr7CX6FVrH+4FrAapSOekrgFQ3f/8gwMEuIft0aKq6Hug==} engines: {node: '>= 8'} de-indent@1.0.2: @@ -759,8 +764,8 @@ packages: eastasianwidth@0.2.0: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} - electron-to-chromium@1.5.47: - resolution: {integrity: sha512-zS5Yer0MOYw4rtK2iq43cJagHZ8sXN0jDHDKzB+86gSBSAI4v07S97mcq+Gs2vclAxSh1j7vOAHxSVgduiiuVQ==} + electron-to-chromium@1.5.52: + resolution: {integrity: sha512-xtoijJTZ+qeucLBDNztDOuQBE1ksqjvNjvqFoST3nGC7fSpqJ+X6BdTBaY5BHG+IhWWmpc6b/KfpeuEDupEPOQ==} emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} @@ -991,8 +996,8 @@ packages: ms@2.1.3: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} - msw@2.5.2: - resolution: {integrity: sha512-eBsFgU30NYtrfC62XzS1rdAzFK+Br0zKU4ORqD9Qliq86362DWZyPiD6FLfMgy0Ktik83DPTXmqPMz2bqwmJdA==} + msw@2.6.2: + resolution: {integrity: sha512-RdRgPvjfuzMIACkWv7VOVAeSRYMU3ofokLv1w0RsbFX960qnj/tFEyOFXY0G2GTUd9trA6rHuHciM/FKpBp6/A==} engines: {node: '>=18'} hasBin: true peerDependencies: @@ -1105,8 +1110,8 @@ packages: resolution: {integrity: sha512-oKWePCxqpd6FlLvGV1VU0x7bkPmmCNolxzjMf4NczoDnQcIWrAF+cPtZn5i6n+RfD2d9i0tzpKnG6Yk168yIyw==} hasBin: true - rollup@4.24.2: - resolution: {integrity: sha512-do/DFGq5g6rdDhdpPq5qb2ecoczeK6y+2UAjdJ5trjQJj5f1AiVdLRWRc9A9/fFukfvJRgM0UXzxBIYMovm5ww==} + rollup@4.24.4: + resolution: {integrity: sha512-vGorVWIsWfX3xbcyAS+I047kFKapHYivmkaT63Smj77XwvLSJos6M1xGqZnBPFQFBRZDOcG1QnYEIxAvTr/HjA==} engines: {node: '>=18.0.0', npm: '>=8.0.0'} hasBin: true @@ -1304,6 +1309,10 @@ packages: vite: optional: true + vite-plugin-strip-comments@0.0.1: + resolution: {integrity: sha512-P7EzXmL6uoCynzuEVknKI9YR+JnF9gHouPI88cz7QwYVCEnZlmX5rUXxW88+UDiieRt0MoBAUrYR5Chd9w9wtw==} + engines: {deno: '>=2.0.4', node: '>=20', pnpm: '>=9.10.0'} + vite@5.4.10: resolution: {integrity: sha512-1hvaPshuPUtxeQ0hsVH3Mud0ZanOLwVTneA1EgbAM5LhaZEqyPWGRQ7BtaMvUrTDeEaC8pxtj6a6jku3x4z6SQ==} engines: {node: ^18.0.0 || >=20.0.0} @@ -1426,23 +1435,23 @@ snapshots: '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 - '@babel/code-frame@7.26.0': + '@babel/code-frame@7.26.2': dependencies: '@babel/helper-validator-identifier': 7.25.9 js-tokens: 4.0.0 picocolors: 1.1.1 - '@babel/compat-data@7.26.0': {} + '@babel/compat-data@7.26.2': {} '@babel/core@7.26.0': dependencies: '@ampproject/remapping': 2.3.0 - '@babel/code-frame': 7.26.0 - '@babel/generator': 7.26.0 + '@babel/code-frame': 7.26.2 + '@babel/generator': 7.26.2 '@babel/helper-compilation-targets': 7.25.9 '@babel/helper-module-transforms': 7.26.0(@babel/core@7.26.0) '@babel/helpers': 7.26.0 - '@babel/parser': 7.26.1 + '@babel/parser': 7.26.2 '@babel/template': 7.25.9 '@babel/traverse': 7.25.9 '@babel/types': 7.26.0 @@ -1454,9 +1463,9 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/generator@7.26.0': + '@babel/generator@7.26.2': dependencies: - '@babel/parser': 7.26.1 + '@babel/parser': 7.26.2 '@babel/types': 7.26.0 '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 @@ -1464,7 +1473,7 @@ snapshots: '@babel/helper-compilation-targets@7.25.9': dependencies: - '@babel/compat-data': 7.26.0 + '@babel/compat-data': 7.26.2 '@babel/helper-validator-option': 7.25.9 browserslist: 4.24.2 lru-cache: 5.1.1 @@ -1497,7 +1506,7 @@ snapshots: '@babel/template': 7.25.9 '@babel/types': 7.26.0 - '@babel/parser@7.26.1': + '@babel/parser@7.26.2': dependencies: '@babel/types': 7.26.0 @@ -1507,15 +1516,15 @@ snapshots: '@babel/template@7.25.9': dependencies: - '@babel/code-frame': 7.26.0 - '@babel/parser': 7.26.1 + '@babel/code-frame': 7.26.2 + '@babel/parser': 7.26.2 '@babel/types': 7.26.0 '@babel/traverse@7.25.9': dependencies: - '@babel/code-frame': 7.26.0 - '@babel/generator': 7.26.0 - '@babel/parser': 7.26.1 + '@babel/code-frame': 7.26.2 + '@babel/generator': 7.26.2 + '@babel/parser': 7.26.2 '@babel/template': 7.25.9 '@babel/types': 7.26.0 debug: 4.3.7 @@ -1528,9 +1537,9 @@ snapshots: '@babel/helper-string-parser': 7.25.9 '@babel/helper-validator-identifier': 7.25.9 - '@bundled-es-modules/cookie@2.0.0': + '@bundled-es-modules/cookie@2.0.1': dependencies: - cookie: 0.5.0 + cookie: 0.7.2 '@bundled-es-modules/statuses@1.0.1': dependencies: @@ -1610,16 +1619,16 @@ snapshots: '@esbuild/win32-x64@0.21.5': optional: true - '@inquirer/confirm@5.0.1(@types/node@20.17.1)': + '@inquirer/confirm@5.0.1(@types/node@20.17.6)': dependencies: - '@inquirer/core': 10.0.1(@types/node@20.17.1) - '@inquirer/type': 3.0.0(@types/node@20.17.1) - '@types/node': 20.17.1 + '@inquirer/core': 10.0.1(@types/node@20.17.6) + '@inquirer/type': 3.0.0(@types/node@20.17.6) + '@types/node': 20.17.6 - '@inquirer/core@10.0.1(@types/node@20.17.1)': + '@inquirer/core@10.0.1(@types/node@20.17.6)': dependencies: '@inquirer/figures': 1.0.7 - '@inquirer/type': 3.0.0(@types/node@20.17.1) + '@inquirer/type': 3.0.0(@types/node@20.17.6) ansi-escapes: 4.3.2 cli-width: 4.1.0 mute-stream: 2.0.0 @@ -1632,9 +1641,9 @@ snapshots: '@inquirer/figures@1.0.7': {} - '@inquirer/type@3.0.0(@types/node@20.17.1)': + '@inquirer/type@3.0.0(@types/node@20.17.6)': dependencies: - '@types/node': 20.17.1 + '@types/node': 20.17.6 '@isaacs/cliui@8.0.2': dependencies: @@ -1670,23 +1679,23 @@ snapshots: '@jridgewell/resolve-uri': 3.1.2 '@jridgewell/sourcemap-codec': 1.5.0 - '@microsoft/api-extractor-model@7.29.8(@types/node@20.17.1)': + '@microsoft/api-extractor-model@7.29.8(@types/node@20.17.6)': dependencies: '@microsoft/tsdoc': 0.15.0 '@microsoft/tsdoc-config': 0.17.0 - '@rushstack/node-core-library': 5.9.0(@types/node@20.17.1) + '@rushstack/node-core-library': 5.9.0(@types/node@20.17.6) transitivePeerDependencies: - '@types/node' - '@microsoft/api-extractor@7.47.11(@types/node@20.17.1)': + '@microsoft/api-extractor@7.47.11(@types/node@20.17.6)': dependencies: - '@microsoft/api-extractor-model': 7.29.8(@types/node@20.17.1) + '@microsoft/api-extractor-model': 7.29.8(@types/node@20.17.6) '@microsoft/tsdoc': 0.15.0 '@microsoft/tsdoc-config': 0.17.0 - '@rushstack/node-core-library': 5.9.0(@types/node@20.17.1) + '@rushstack/node-core-library': 5.9.0(@types/node@20.17.6) '@rushstack/rig-package': 0.5.3 - '@rushstack/terminal': 0.14.2(@types/node@20.17.1) - '@rushstack/ts-command-line': 4.23.0(@types/node@20.17.1) + '@rushstack/terminal': 0.14.2(@types/node@20.17.6) + '@rushstack/ts-command-line': 4.23.0(@types/node@20.17.6) lodash: 4.17.21 minimatch: 3.0.8 resolve: 1.22.8 @@ -1705,7 +1714,7 @@ snapshots: '@microsoft/tsdoc@0.15.0': {} - '@mswjs/interceptors@0.36.6': + '@mswjs/interceptors@0.36.10': dependencies: '@open-draft/deferred-promise': 2.2.0 '@open-draft/logger': 0.3.0 @@ -1728,69 +1737,69 @@ snapshots: '@polka/url@1.0.0-next.28': {} - '@rollup/pluginutils@5.1.3(rollup@4.24.2)': + '@rollup/pluginutils@5.1.3(rollup@4.24.4)': dependencies: '@types/estree': 1.0.6 estree-walker: 2.0.2 picomatch: 4.0.2 optionalDependencies: - rollup: 4.24.2 + rollup: 4.24.4 - '@rollup/rollup-android-arm-eabi@4.24.2': + '@rollup/rollup-android-arm-eabi@4.24.4': optional: true - '@rollup/rollup-android-arm64@4.24.2': + '@rollup/rollup-android-arm64@4.24.4': optional: true - '@rollup/rollup-darwin-arm64@4.24.2': + '@rollup/rollup-darwin-arm64@4.24.4': optional: true - '@rollup/rollup-darwin-x64@4.24.2': + '@rollup/rollup-darwin-x64@4.24.4': optional: true - '@rollup/rollup-freebsd-arm64@4.24.2': + '@rollup/rollup-freebsd-arm64@4.24.4': optional: true - '@rollup/rollup-freebsd-x64@4.24.2': + '@rollup/rollup-freebsd-x64@4.24.4': optional: true - '@rollup/rollup-linux-arm-gnueabihf@4.24.2': + '@rollup/rollup-linux-arm-gnueabihf@4.24.4': optional: true - '@rollup/rollup-linux-arm-musleabihf@4.24.2': + '@rollup/rollup-linux-arm-musleabihf@4.24.4': optional: true - '@rollup/rollup-linux-arm64-gnu@4.24.2': + '@rollup/rollup-linux-arm64-gnu@4.24.4': optional: true - '@rollup/rollup-linux-arm64-musl@4.24.2': + '@rollup/rollup-linux-arm64-musl@4.24.4': optional: true - '@rollup/rollup-linux-powerpc64le-gnu@4.24.2': + '@rollup/rollup-linux-powerpc64le-gnu@4.24.4': optional: true - '@rollup/rollup-linux-riscv64-gnu@4.24.2': + '@rollup/rollup-linux-riscv64-gnu@4.24.4': optional: true - '@rollup/rollup-linux-s390x-gnu@4.24.2': + '@rollup/rollup-linux-s390x-gnu@4.24.4': optional: true - '@rollup/rollup-linux-x64-gnu@4.24.2': + '@rollup/rollup-linux-x64-gnu@4.24.4': optional: true - '@rollup/rollup-linux-x64-musl@4.24.2': + '@rollup/rollup-linux-x64-musl@4.24.4': optional: true - '@rollup/rollup-win32-arm64-msvc@4.24.2': + '@rollup/rollup-win32-arm64-msvc@4.24.4': optional: true - '@rollup/rollup-win32-ia32-msvc@4.24.2': + '@rollup/rollup-win32-ia32-msvc@4.24.4': optional: true - '@rollup/rollup-win32-x64-msvc@4.24.2': + '@rollup/rollup-win32-x64-msvc@4.24.4': optional: true - '@rushstack/node-core-library@5.9.0(@types/node@20.17.1)': + '@rushstack/node-core-library@5.9.0(@types/node@20.17.6)': dependencies: ajv: 8.13.0 ajv-draft-04: 1.0.0(ajv@8.13.0) @@ -1801,23 +1810,23 @@ snapshots: resolve: 1.22.8 semver: 7.5.4 optionalDependencies: - '@types/node': 20.17.1 + '@types/node': 20.17.6 '@rushstack/rig-package@0.5.3': dependencies: resolve: 1.22.8 strip-json-comments: 3.1.1 - '@rushstack/terminal@0.14.2(@types/node@20.17.1)': + '@rushstack/terminal@0.14.2(@types/node@20.17.6)': dependencies: - '@rushstack/node-core-library': 5.9.0(@types/node@20.17.1) + '@rushstack/node-core-library': 5.9.0(@types/node@20.17.6) supports-color: 8.1.1 optionalDependencies: - '@types/node': 20.17.1 + '@types/node': 20.17.6 - '@rushstack/ts-command-line@4.23.0(@types/node@20.17.1)': + '@rushstack/ts-command-line@4.23.0(@types/node@20.17.6)': dependencies: - '@rushstack/terminal': 0.14.2(@types/node@20.17.1) + '@rushstack/terminal': 0.14.2(@types/node@20.17.6) '@types/argparse': 1.0.38 argparse: 1.0.10 string-argv: 0.3.2 @@ -1826,7 +1835,7 @@ snapshots: '@testing-library/dom@10.4.0': dependencies: - '@babel/code-frame': 7.26.0 + '@babel/code-frame': 7.26.2 '@babel/runtime': 7.26.0 '@types/aria-query': 5.0.4 aria-query: 5.3.0 @@ -1839,13 +1848,13 @@ snapshots: dependencies: '@testing-library/dom': 10.4.0 - '@thednp/event-listener@2.0.6': {} + '@thednp/event-listener@2.0.8': {} - '@thednp/position-observer@0.0.3': + '@thednp/position-observer@https://codeload.github.com/thednp/position-observer/tar.gz/d693d5387bed0966c0954c6c5a0e5dbc8e5cb67f': dependencies: - '@thednp/shorty': 2.0.7 + '@thednp/shorty': https://codeload.github.com/thednp/shorty/tar.gz/309d581b370f747cb15531ca6c201def3827e05c - '@thednp/shorty@2.0.7': {} + '@thednp/shorty@https://codeload.github.com/thednp/shorty/tar.gz/309d581b370f747cb15531ca6c201def3827e05c': {} '@types/argparse@1.0.38': {} @@ -1855,7 +1864,7 @@ snapshots: '@types/estree@1.0.6': {} - '@types/node@20.17.1': + '@types/node@20.17.6': dependencies: undici-types: 6.19.8 @@ -1863,17 +1872,17 @@ snapshots: '@types/tough-cookie@4.0.5': {} - '@vitest/browser@2.1.4(@types/node@20.17.1)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0))(vitest@2.1.4)': + '@vitest/browser@2.1.4(@types/node@20.17.6)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0))(vitest@2.1.4)': dependencies: '@testing-library/dom': 10.4.0 '@testing-library/user-event': 14.5.2(@testing-library/dom@10.4.0) - '@vitest/mocker': 2.1.4(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0)) + '@vitest/mocker': 2.1.4(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0)) '@vitest/utils': 2.1.4 magic-string: 0.30.12 - msw: 2.5.2(@types/node@20.17.1)(typescript@5.6.3) + msw: 2.6.2(@types/node@20.17.6)(typescript@5.6.3) sirv: 3.0.0 tinyrainbow: 1.2.0 - vitest: 2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0) + vitest: 2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0) ws: 8.18.0 optionalDependencies: playwright: 1.48.2 @@ -1884,7 +1893,7 @@ snapshots: - utf-8-validate - vite - '@vitest/coverage-istanbul@2.1.4(vitest@2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0))': + '@vitest/coverage-istanbul@2.1.4(vitest@2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0))': dependencies: '@istanbuljs/schema': 0.1.3 debug: 4.3.7 @@ -1896,7 +1905,7 @@ snapshots: magicast: 0.3.5 test-exclude: 7.0.1 tinyrainbow: 1.2.0 - vitest: 2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0) + vitest: 2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0) transitivePeerDependencies: - supports-color @@ -1907,14 +1916,14 @@ snapshots: chai: 5.1.2 tinyrainbow: 1.2.0 - '@vitest/mocker@2.1.4(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0))': + '@vitest/mocker@2.1.4(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0))': dependencies: '@vitest/spy': 2.1.4 estree-walker: 3.0.3 magic-string: 0.30.12 optionalDependencies: - msw: 2.5.2(@types/node@20.17.1)(typescript@5.6.3) - vite: 5.4.10(@types/node@20.17.1)(terser@5.33.0) + msw: 2.6.2(@types/node@20.17.6)(typescript@5.6.3) + vite: 5.4.10(@types/node@20.17.6)(terser@5.33.0) '@vitest/pretty-format@2.1.4': dependencies: @@ -1944,7 +1953,7 @@ snapshots: sirv: 3.0.0 tinyglobby: 0.2.10 tinyrainbow: 1.2.0 - vitest: 2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0) + vitest: 2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0) '@vitest/utils@2.1.4': dependencies: @@ -1952,21 +1961,21 @@ snapshots: loupe: 3.1.2 tinyrainbow: 1.2.0 - '@volar/language-core@2.4.8': + '@volar/language-core@2.4.9': dependencies: - '@volar/source-map': 2.4.8 + '@volar/source-map': 2.4.9 - '@volar/source-map@2.4.8': {} + '@volar/source-map@2.4.9': {} - '@volar/typescript@2.4.8': + '@volar/typescript@2.4.9': dependencies: - '@volar/language-core': 2.4.8 + '@volar/language-core': 2.4.9 path-browserify: 1.0.1 vscode-uri: 3.0.8 '@vue/compiler-core@3.5.12': dependencies: - '@babel/parser': 7.26.1 + '@babel/parser': 7.26.2 '@vue/shared': 3.5.12 entities: 4.5.0 estree-walker: 2.0.2 @@ -1984,7 +1993,7 @@ snapshots: '@vue/language-core@2.1.6(typescript@5.6.3)': dependencies: - '@volar/language-core': 2.4.8 + '@volar/language-core': 2.4.9 '@vue/compiler-dom': 3.5.12 '@vue/compiler-vue2': 2.7.16 '@vue/shared': 3.5.12 @@ -2060,8 +2069,8 @@ snapshots: browserslist@4.24.2: dependencies: - caniuse-lite: 1.0.30001673 - electron-to-chromium: 1.5.47 + caniuse-lite: 1.0.30001678 + electron-to-chromium: 1.5.52 node-releases: 2.0.18 update-browserslist-db: 1.1.1(browserslist@4.24.2) @@ -2070,7 +2079,7 @@ snapshots: cac@6.7.14: {} - caniuse-lite@1.0.30001673: {} + caniuse-lite@1.0.30001678: {} chai@5.1.2: dependencies: @@ -2114,9 +2123,9 @@ snapshots: convert-source-map@2.0.0: {} - cookie@0.5.0: {} + cookie@0.7.2: {} - cross-spawn@7.0.3: + cross-spawn@7.0.5: dependencies: path-key: 3.1.1 shebang-command: 2.0.0 @@ -2136,7 +2145,7 @@ snapshots: eastasianwidth@0.2.0: {} - electron-to-chromium@1.5.47: {} + electron-to-chromium@1.5.52: {} emoji-regex@8.0.0: {} @@ -2192,7 +2201,7 @@ snapshots: foreground-child@3.3.0: dependencies: - cross-spawn: 7.0.3 + cross-spawn: 7.0.5 signal-exit: 4.1.0 fs-extra@7.0.1: @@ -2257,7 +2266,7 @@ snapshots: istanbul-lib-instrument@6.0.3: dependencies: '@babel/core': 7.26.0 - '@babel/parser': 7.26.1 + '@babel/parser': 7.26.2 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.2 semver: 7.6.3 @@ -2332,7 +2341,7 @@ snapshots: magicast@0.3.5: dependencies: - '@babel/parser': 7.26.1 + '@babel/parser': 7.26.2 '@babel/types': 7.26.0 source-map-js: 1.2.1 @@ -2361,13 +2370,14 @@ snapshots: ms@2.1.3: {} - msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3): + msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3): dependencies: - '@bundled-es-modules/cookie': 2.0.0 + '@bundled-es-modules/cookie': 2.0.1 '@bundled-es-modules/statuses': 1.0.1 '@bundled-es-modules/tough-cookie': 0.1.6 - '@inquirer/confirm': 5.0.1(@types/node@20.17.1) - '@mswjs/interceptors': 0.36.6 + '@inquirer/confirm': 5.0.1(@types/node@20.17.6) + '@mswjs/interceptors': 0.36.10 + '@open-draft/deferred-promise': 2.2.0 '@open-draft/until': 2.1.0 '@types/cookie': 0.6.0 '@types/statuses': 2.0.5 @@ -2466,28 +2476,28 @@ snapshots: path-parse: 1.0.7 supports-preserve-symlinks-flag: 1.0.0 - rollup@4.24.2: + rollup@4.24.4: dependencies: '@types/estree': 1.0.6 optionalDependencies: - '@rollup/rollup-android-arm-eabi': 4.24.2 - '@rollup/rollup-android-arm64': 4.24.2 - '@rollup/rollup-darwin-arm64': 4.24.2 - '@rollup/rollup-darwin-x64': 4.24.2 - '@rollup/rollup-freebsd-arm64': 4.24.2 - '@rollup/rollup-freebsd-x64': 4.24.2 - '@rollup/rollup-linux-arm-gnueabihf': 4.24.2 - '@rollup/rollup-linux-arm-musleabihf': 4.24.2 - '@rollup/rollup-linux-arm64-gnu': 4.24.2 - '@rollup/rollup-linux-arm64-musl': 4.24.2 - '@rollup/rollup-linux-powerpc64le-gnu': 4.24.2 - '@rollup/rollup-linux-riscv64-gnu': 4.24.2 - '@rollup/rollup-linux-s390x-gnu': 4.24.2 - '@rollup/rollup-linux-x64-gnu': 4.24.2 - '@rollup/rollup-linux-x64-musl': 4.24.2 - '@rollup/rollup-win32-arm64-msvc': 4.24.2 - '@rollup/rollup-win32-ia32-msvc': 4.24.2 - '@rollup/rollup-win32-x64-msvc': 4.24.2 + '@rollup/rollup-android-arm-eabi': 4.24.4 + '@rollup/rollup-android-arm64': 4.24.4 + '@rollup/rollup-darwin-arm64': 4.24.4 + '@rollup/rollup-darwin-x64': 4.24.4 + '@rollup/rollup-freebsd-arm64': 4.24.4 + '@rollup/rollup-freebsd-x64': 4.24.4 + '@rollup/rollup-linux-arm-gnueabihf': 4.24.4 + '@rollup/rollup-linux-arm-musleabihf': 4.24.4 + '@rollup/rollup-linux-arm64-gnu': 4.24.4 + '@rollup/rollup-linux-arm64-musl': 4.24.4 + '@rollup/rollup-linux-powerpc64le-gnu': 4.24.4 + '@rollup/rollup-linux-riscv64-gnu': 4.24.4 + '@rollup/rollup-linux-s390x-gnu': 4.24.4 + '@rollup/rollup-linux-x64-gnu': 4.24.4 + '@rollup/rollup-linux-x64-musl': 4.24.4 + '@rollup/rollup-win32-arm64-msvc': 4.24.4 + '@rollup/rollup-win32-ia32-msvc': 4.24.4 + '@rollup/rollup-win32-x64-msvc': 4.24.4 fsevents: 2.3.3 semver@6.3.1: {} @@ -2637,12 +2647,12 @@ snapshots: querystringify: 2.2.0 requires-port: 1.0.0 - vite-node@2.1.4(@types/node@20.17.1)(terser@5.33.0): + vite-node@2.1.4(@types/node@20.17.6)(terser@5.33.0): dependencies: cac: 6.7.14 debug: 4.3.7 pathe: 1.1.2 - vite: 5.4.10(@types/node@20.17.1)(terser@5.33.0) + vite: 5.4.10(@types/node@20.17.6)(terser@5.33.0) transitivePeerDependencies: - '@types/node' - less @@ -2654,11 +2664,11 @@ snapshots: - supports-color - terser - vite-plugin-dts@4.3.0(@types/node@20.17.1)(rollup@4.24.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0)): + vite-plugin-dts@4.3.0(@types/node@20.17.6)(rollup@4.24.4)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0)): dependencies: - '@microsoft/api-extractor': 7.47.11(@types/node@20.17.1) - '@rollup/pluginutils': 5.1.3(rollup@4.24.2) - '@volar/typescript': 2.4.8 + '@microsoft/api-extractor': 7.47.11(@types/node@20.17.6) + '@rollup/pluginutils': 5.1.3(rollup@4.24.4) + '@volar/typescript': 2.4.9 '@vue/language-core': 2.1.6(typescript@5.6.3) compare-versions: 6.1.1 debug: 4.3.7 @@ -2667,26 +2677,28 @@ snapshots: magic-string: 0.30.12 typescript: 5.6.3 optionalDependencies: - vite: 5.4.10(@types/node@20.17.1)(terser@5.33.0) + vite: 5.4.10(@types/node@20.17.6)(terser@5.33.0) transitivePeerDependencies: - '@types/node' - rollup - supports-color - vite@5.4.10(@types/node@20.17.1)(terser@5.33.0): + vite-plugin-strip-comments@0.0.1: {} + + vite@5.4.10(@types/node@20.17.6)(terser@5.33.0): dependencies: esbuild: 0.21.5 postcss: 8.4.47 - rollup: 4.24.2 + rollup: 4.24.4 optionalDependencies: - '@types/node': 20.17.1 + '@types/node': 20.17.6 fsevents: 2.3.3 terser: 5.33.0 - vitest@2.1.4(@types/node@20.17.1)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(terser@5.33.0): + vitest@2.1.4(@types/node@20.17.6)(@vitest/browser@2.1.4)(@vitest/ui@2.1.4)(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(terser@5.33.0): dependencies: '@vitest/expect': 2.1.4 - '@vitest/mocker': 2.1.4(msw@2.5.2(@types/node@20.17.1)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0)) + '@vitest/mocker': 2.1.4(msw@2.6.2(@types/node@20.17.6)(typescript@5.6.3))(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0)) '@vitest/pretty-format': 2.1.4 '@vitest/runner': 2.1.4 '@vitest/snapshot': 2.1.4 @@ -2702,12 +2714,12 @@ snapshots: tinyexec: 0.3.1 tinypool: 1.0.1 tinyrainbow: 1.2.0 - vite: 5.4.10(@types/node@20.17.1)(terser@5.33.0) - vite-node: 2.1.4(@types/node@20.17.1)(terser@5.33.0) + vite: 5.4.10(@types/node@20.17.6)(terser@5.33.0) + vite-node: 2.1.4(@types/node@20.17.6)(terser@5.33.0) why-is-node-running: 2.3.0 optionalDependencies: - '@types/node': 20.17.1 - '@vitest/browser': 2.1.4(@types/node@20.17.1)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.1)(terser@5.33.0))(vitest@2.1.4) + '@types/node': 20.17.6 + '@vitest/browser': 2.1.4(@types/node@20.17.6)(playwright@1.48.2)(typescript@5.6.3)(vite@5.4.10(@types/node@20.17.6)(terser@5.33.0))(vitest@2.1.4) '@vitest/ui': 2.1.4(vitest@2.1.4) transitivePeerDependencies: - less diff --git a/src/components/alert.ts b/src/components/alert.ts index 258c18de..160df872 100644 --- a/src/components/alert.ts +++ b/src/components/alert.ts @@ -31,13 +31,13 @@ const alertDismissSelector = `[${dataBsDismiss}="${alertString}"]`; * Static method which returns an existing `Alert` instance associated * to a target `Element`. */ -const getAlertInstance = (element: HTMLElement) => +const getAlertInstance = (element: Element) => getInstance(element, alertComponent); /** * An `Alert` initialization callback. */ -const alertInitCallback = (element: HTMLElement) => new Alert(element); +const alertInitCallback = (element: Element) => new Alert(element); // ALERT CUSTOM EVENTS // =================== @@ -73,11 +73,14 @@ export default class Alert extends BaseComponent { static getInstance = getAlertInstance; dismiss: HTMLElement | null; - constructor(target: HTMLElement | string) { + constructor(target: Element | string) { super(target); // the dismiss button - this.dismiss = querySelector(alertDismissSelector, this.element); + this.dismiss = querySelector( + alertDismissSelector, + this.element, + ); // add event listener this._toggleEventListeners(true); diff --git a/src/components/base-component.ts b/src/components/base-component.ts index dd337324..9d81e962 100644 --- a/src/components/base-component.ts +++ b/src/components/base-component.ts @@ -2,7 +2,7 @@ ----------------------------------------------------- */ import { Data, - isHTMLElement, + isElement, isString, normalizeOptions, ObjectKeys, @@ -14,21 +14,21 @@ import Version from "../version"; /** Returns a new `BaseComponent` instance. */ export default class BaseComponent { - declare element: HTMLElement; + declare element: Element; declare options?: BaseOptions; /** - * @param target `HTMLElement` or selector string + * @param target `Element` or selector string * @param config component instance options */ - constructor(target: HTMLElement | string, config?: BaseOptions) { - let element: HTMLElement | null; + constructor(target: Element | string, config?: BaseOptions) { + let element: Element | null; try { - if (isHTMLElement(target)) { - element = target; + if (isElement(target)) { + element = target as Element; } else if (isString(target)) { - element = querySelector(target); + element = querySelector(target); // istanbul ignore else @preserve if (!element) throw Error(`"${target}" is not a valid selector.`); } else { @@ -39,7 +39,7 @@ export default class BaseComponent { } const prevInstance = Data.get(element, this.name); - // istanbul ignore else @preserve + /* istanbul ignore else @preserve */ if (prevInstance) { // remove previously attached event listeners // to avoid memory leaks diff --git a/src/components/button.ts b/src/components/button.ts index 080fab51..887ca8b1 100644 --- a/src/components/button.ts +++ b/src/components/button.ts @@ -28,11 +28,11 @@ const buttonSelector = `[${dataBsToggle}="${buttonString}"]`; * Static method which returns an existing `Button` instance associated * to a target `Element`. */ -const getButtonInstance = (element: HTMLElement) => +const getButtonInstance = (element: Element) => getInstance @@ -344,9 +343,9 @@ const markup = {