Files
PIbd-23_Sheymuhov_A.I._Inte…/dist/assets/page3-K_pi1AMQ.js

6 lines
85 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import{g as Oe,d as gi}from"./client-HTyyrb_U.js";/* empty css */const Cn=(n,t)=>{localStorage.setItem(n,JSON.stringify(t))},Ei=n=>JSON.parse(localStorage.getItem(n))||[],vi="video",Ne="video-stars";class bi{constructor(){this.data=[],this.stars=Ei(Ne)}async getAll(){try{const t=await Oe("video"),e=await Oe("playlist"),s=await Oe("category");this.data=t.map(i=>{var r,o;return{...i,playlistName:((r=e.find(a=>a.id===i.playlistId))==null?void 0:r.name)||"Не указан",categoryName:((o=s.find(a=>a.id===i.categoryId))==null?void 0:o.name)||"Не указан"}})}catch(t){console.error("Failed to load videos:",t),this.data=[]}}async delete(t){await gi(vi,t.id),this.stars=this.stars.filter(e=>e!==t.id),Cn(Ne,this.stars)}toggleStar(t){const e=t;e.star=!e.star,e.star?this.stars.push(e.id):this.stars=this.stars.filter(s=>s!==e.id),Cn(Ne,this.stars)}}var $="top",M="bottom",R="right",I="left",pe="auto",It=[$,M,R,I],pt="start",Ot="end",us="clippingParents",Qe="viewport",Tt="popper",ds="reference",Ke=It.reduce(function(n,t){return n.concat([t+"-"+pt,t+"-"+Ot])},[]),Je=[].concat(It,[pe]).reduce(function(n,t){return n.concat([t,t+"-"+pt,t+"-"+Ot])},[]),hs="beforeRead",fs="read",ps="afterRead",_s="beforeMain",ms="main",gs="afterMain",Es="beforeWrite",vs="write",bs="afterWrite",As=[hs,fs,ps,_s,ms,gs,Es,vs,bs];function z(n){return n?(n.nodeName||"").toLowerCase():null}function k(n){if(n==null)return window;if(n.toString()!=="[object Window]"){var t=n.ownerDocument;return t&&t.defaultView||window}return n}function _t(n){var t=k(n).Element;return n instanceof t||n instanceof Element}function V(n){var t=k(n).HTMLElement;return n instanceof t||n instanceof HTMLElement}function Ze(n){if(typeof ShadowRoot>"u")return!1;var t=k(n).ShadowRoot;return n instanceof t||n instanceof ShadowRoot}function Ai(n){var t=n.state;Object.keys(t.elements).forEach(function(e){var s=t.styles[e]||{},i=t.attributes[e]||{},r=t.elements[e];!V(r)||!z(r)||(Object.assign(r.style,s),Object.keys(i).forEach(function(o){var a=i[o];a===!1?r.removeAttribute(o):r.setAttribute(o,a===!0?"":a)}))})}function Ti(n){var t=n.state,e={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,e.popper),t.styles=e,t.elements.arrow&&Object.assign(t.elements.arrow.style,e.arrow),function(){Object.keys(t.elements).forEach(function(s){var i=t.elements[s],r=t.attributes[s]||{},o=Object.keys(t.styles.hasOwnProperty(s)?t.styles[s]:e[s]),a=o.reduce(function(c,d){return c[d]="",c},{});!V(i)||!z(i)||(Object.assign(i.style,a),Object.keys(r).forEach(function(c){i.removeAttribute(c)}))})}}const tn={name:"applyStyles",enabled:!0,phase:"write",fn:Ai,effect:Ti,requires:["computeStyles"]};function Y(n){return n.split("-")[0]}var ft=Math.max,ue=Math.min,Nt=Math.round;function Ye(){var n=navigator.userAgentData;return n!=null&&n.brands&&Array.isArray(n.brands)?n.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function Ts(){return!/^((?!chrome|android).)*safari/i.test(Ye())}function St(n,t,e){t===void 0&&(t=!1),e===void 0&&(e=!1);var s=n.getBoundingClientRect(),i=1,r=1;t&&V(n)&&(i=n.offsetWidth>0&&Nt(s.width)/n.offsetWidth||1,r=n.offsetHeight>0&&Nt(s.height)/n.offsetHeight||1);var o=_t(n)?k(n):window,a=o.visualViewport,c=!Ts()&&e,d=(s.left+(c&&a?a.offsetLeft:0))/i,u=(s.top+(c&&a?a.offsetTop:0))/r,p=s.width/i,_=s.height/r;return{width:p,height:_,top:u,right:d+p,bottom:u+_,left:d,x:d,y:u}}function en(n){var t=St(n),e=n.offsetWidth,s=n.offsetHeight;return Math.abs(t.width-e)<=1&&(e=t.width),Math.abs(t.height-s)<=1&&(s=t.height),{x:n.offsetLeft,y:n.offsetTop,width:e,height:s}}function ys(n,t){var e=t.getRootNode&&t.getRootNode();if(n.contains(t))return!0;if(e&&Ze(e)){var s=t;do{if(s&&n.isSameNode(s))return!0;s=s.parentNode||s.host}while(s)}return!1}function X(n){return k(n).getComputedStyle(n)}function yi(n){return["table","td","th"].indexOf(z(n))>=0}function st(n){return((_t(n)?n.ownerDocument:n.document)||window.document).documentElement}function _e(n){return z(n)==="html"?n:n.assignedSlot||n.parentNode||(Ze(n)?n.host:null)||st(n)}function On(n){return!V(n)||X(n).position==="fixed"?null:n.offsetParent}function wi(n){var t=/firefox/i.test(Ye()),e=/Trident/i.test(Ye());if(e&&V(n)){var s=X(n);if(s.position==="fixed")return null}var i=_e(n);for(Ze(i)&&(i=i.host);V(i)&&["html","body"].indexOf(z(i))<0;){var r=X(i);if(r.transform!=="none"||r.perspective!=="none"||r.contain==="paint"||["transform","perspective"].indexOf(r.willChange)!==-1||t&&r.willChange==="filter"||t&&r.filter&&r.filter!=="none")return i;i=i.parentNode}return null}function Kt(n){for(var t=k(n),e=On(n);e&&yi(e)&&X(e).position==="static";)e=On(e);return e&&(z(e)==="html"||z(e)==="body"&&X(e).position==="static")?t:e||wi(n)||t}function nn(n){return["top","bottom"].indexOf(n)>=0?"x":"y"}function Wt(n,t,e){return ft(n,ue(t,e))}function Ci(n,t,e){var s=Wt(n,t,e);return s>e?e:s}function ws(){return{top:0,right:0,bottom:0,left:0}}function Cs(n){return Object.assign({},ws(),n)}function Os(n,t){return t.reduce(function(e,s){return e[s]=n,e},{})}var Oi=function(t,e){return t=typeof t=="function"?t(Object.assign({},e.rects,{placement:e.placement})):t,Cs(typeof t!="number"?t:Os(t,It))};function Ni(n){var t,e=n.state,s=n.name,i=n.options,r=e.elements.arrow,o=e.modifiersData.popperOffsets,a=Y(e.placement),c=nn(a),d=[I,R].indexOf(a)>=0,u=d?"height":"width";if(!(!r||!o)){var p=Oi(i.padding,e),_=en(r),f=c==="y"?$:I,A=c==="y"?M:R,m=e.rects.reference[u]+e.rects.reference[c]-o[c]-e.rects.popper[u],E=o[c]-e.rects.reference[c],T=Kt(r),w=T?c==="y"?T.clientHeight||0:T.clientWidth||0:0,C=m/2-E/2,g=p[f],v=w-_[u]-p[A],b=w/2-_[u]/2+C,y=Wt(g,b,v),S=c;e.modifiersData[s]=(t={},t[S]=y,t.centerOffset=y-b,t)}}function Si(n){var t=n.state,e=n.options,s=e.element,i=s===void 0?"[data-popper-arrow]":s;i!=null&&(typeof i=="string"&&(i=t.elements.popper.querySelector(i),!i)||ys(t.elements.popper,i)&&(t.elements.arrow=i))}const Ns={name:"arrow",enabled:!0,phase:"main",fn:Ni,effect:Si,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Dt(n){return n.split("-")[1]}var Di={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Li(n,t){var e=n.x,s=n.y,i=t.devicePixelRatio||1;return{x:Nt(e*i)/i||0,y:Nt(s*i)/i||0}}function Nn(n){var t,e=n.popper,s=n.popperRect,i=n.placement,r=n.variation,o=n.offsets,a=n.position,c=n.gpuAcceleration,d=n.adaptive,u=n.roundOffsets,p=n.isFixed,_=o.x,f=_===void 0?0:_,A=o.y,m=A===void 0?0:A,E=typeof u=="function"?u({x:f,y:m}):{x:f,y:m};f=E.x,m=E.y;var T=o.hasOwnProperty("x"),w=o.hasOwnProperty("y"),C=I,g=$,v=window;if(d){var b=Kt(e),y="clientHeight",S="clientWidth";if(b===k(e)&&(b=st(e),X(b).position!=="static"&&a==="absolute"&&(y="scrollHeight",S="scrollWidth")),b=b,i===$||(i===I||i===R)&&r===Ot){g=M;var N=p&&b===v&&v.visualViewport?v.visualViewport.height:b[y];m-=N-s.height,m*=c?1:-1}if(i===I||(i===$||i===M)&&r===Ot){C=R;var O=p&&b===v&&v.visualViewport?v.visualViewport.width:b[S];f-=O-s.width,f*=c?1:-1}}var D=Object.assign({position:a},d&&Di),j=u===!0?Li({x:f,y:m},k(e)):{x:f,y:m};if(f=j.x,m=j.y,c){var L;return Object.assign({},D,(L={},L[g]=w?"0":"",L[C]=T?"0":"",L.transform=(v.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",L))}return Object.assign({},D,(t={},t[g]=w?m+"px":"",t[C]=T?f+"px":"",t.transform="",t))}function $i(n){var t=n.state,e=n.options,s=e.gpuAcceleration,i=s===void 0?!0:s,r=e.adaptive,o=r===void 0?!0:r,a=e.roundOffsets,c=a===void 0?!0:a,d={placement:Y(t.placement),variation:Dt(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,Nn(Object.assign({},d,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:c})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,Nn(Object.assign({},d,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const sn={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:$i,data:{}};var te={passive:!0};function Ii(n){var t=n.state,e=n.instance,s=n.options,i=s.scroll,r=i===void 0?!0:i,o=s.resize,a=o===void 0?!0:o,c=k(t.elements.popper),d=[].concat(t.scrollParents.reference,t.scrollParents.popper);return r&&d.forEach(function(u){u.addEventListener("scroll",e.update,te)}),a&&c.addEventListener("resize",e.update,te),function(){r&&d.forEach(function(u){u.removeEventListener("scroll",e.update,te)}),a&&c.removeEventListener("resize",e.update,te)}}const rn={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Ii,data:{}};var Pi={left:"right",right:"left",bottom:"top",top:"bottom"};function ae(n){return n.replace(/left|right|bottom|top/g,function(t){return Pi[t]})}var xi={start:"end",end:"start"};function Sn(n){return n.replace(/start|end/g,function(t){return xi[t]})}function on(n){var t=k(n),e=t.pageXOffset,s=t.pageYOffset;return{scrollLeft:e,scrollTop:s}}function an(n){return St(st(n)).left+on(n).scrollLeft}function Mi(n,t){var e=k(n),s=st(n),i=e.visualViewport,r=s.clientWidth,o=s.clientHeight,a=0,c=0;if(i){r=i.width,o=i.height;var d=Ts();(d||!d&&t==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}return{width:r,height:o,x:a+an(n),y:c}}function Ri(n){var t,e=st(n),s=on(n),i=(t=n.ownerDocument)==null?void 0:t.body,r=ft(e.scrollWidth,e.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),o=ft(e.scrollHeight,e.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),a=-s.scrollLeft+an(n),c=-s.scrollTop;return X(i||e).direction==="rtl"&&(a+=ft(e.clientWidth,i?i.clientWidth:0)-r),{width:r,height:o,x:a,y:c}}function ln(n){var t=X(n),e=t.overflow,s=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(e+i+s)}function Ss(n){return["html","body","#document"].indexOf(z(n))>=0?n.ownerDocument.body:V(n)&&ln(n)?n:Ss(_e(n))}function Bt(n,t){var e;t===void 0&&(t=[]);var s=Ss(n),i=s===((e=n.ownerDocument)==null?void 0:e.body),r=k(s),o=i?[r].concat(r.visualViewport||[],ln(s)?s:[]):s,a=t.concat(o);return i?a:a.concat(Bt(_e(o)))}function Ue(n){return Object.assign({},n,{left:n.x,top:n.y,right:n.x+n.width,bottom:n.y+n.height})}function ki(n,t){var e=St(n,!1,t==="fixed");return e.top=e.top+n.clientTop,e.left=e.left+n.clientLeft,e.bottom=e.top+n.clientHeight,e.right=e.left+n.clientWidth,e.width=n.clientWidth,e.height=n.clientHeight,e.x=e.left,e.y=e.top,e}function Dn(n,t,e){return t===Qe?Ue(Mi(n,e)):_t(t)?ki(t,e):Ue(Ri(st(n)))}function Vi(n){var t=Bt(_e(n)),e=["absolute","fixed"].indexOf(X(n).position)>=0,s=e&&V(n)?Kt(n):n;return _t(s)?t.filter(function(i){return _t(i)&&ys(i,s)&&z(i)!=="body"}):[]}function Hi(n,t,e,s){var i=t==="clippingParents"?Vi(n):[].concat(t),r=[].concat(i,[e]),o=r[0],a=r.reduce(function(c,d){var u=Dn(n,d,s);return c.top=ft(u.top,c.top),c.right=ue(u.right,c.right),c.bottom=ue(u.bottom,c.bottom),c.left=ft(u.left,c.left),c},Dn(n,o,s));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function Ds(n){var t=n.reference,e=n.element,s=n.placement,i=s?Y(s):null,r=s?Dt(s):null,o=t.x+t.width/2-e.width/2,a=t.y+t.height/2-e.height/2,c;switch(i){case $:c={x:o,y:t.y-e.height};break;case M:c={x:o,y:t.y+t.height};break;case R:c={x:t.x+t.width,y:a};break;case I:c={x:t.x-e.width,y:a};break;default:c={x:t.x,y:t.y}}var d=i?nn(i):null;if(d!=null){var u=d==="y"?"height":"width";switch(r){case pt:c[d]=c[d]-(t[u]/2-e[u]/2);break;case Ot:c[d]=c[d]+(t[u]/2-e[u]/2);break}}return c}function Lt(n,t){t===void 0&&(t={});var e=t,s=e.placement,i=s===void 0?n.placement:s,r=e.strategy,o=r===void 0?n.strategy:r,a=e.boundary,c=a===void 0?us:a,d=e.rootBoundary,u=d===void 0?Qe:d,p=e.elementContext,_=p===void 0?Tt:p,f=e.altBoundary,A=f===void 0?!1:f,m=e.padding,E=m===void 0?0:m,T=Cs(typeof E!="number"?E:Os(E,It)),w=_===Tt?ds:Tt,C=n.rects.popper,g=n.elements[A?w:_],v=Hi(_t(g)?g:g.contextElement||st(n.elements.popper),c,u,o),b=St(n.elements.reference),y=Ds({reference:b,element:C,placement:i}),S=Ue(Object.assign({},C,y)),N=_===Tt?S:b,O={top:v.top-N.top+T.top,bottom:N.bottom-v.bottom+T.bottom,left:v.left-N.left+T.left,right:N.right-v.right+T.right},D=n.modifiersData.offset;if(_===Tt&&D){var j=D[i];Object.keys(O).forEach(function(L){var ot=[R,M].indexOf(L)>=0?1:-1,at=[$,M].indexOf(L)>=0?"y":"x";O[L]+=j[at]*ot})}return O}function Wi(n,t){t===void 0&&(t={});var e=t,s=e.placement,i=e.boundary,r=e.rootBoundary,o=e.padding,a=e.flipVariations,c=e.allowedAutoPlacements,d=c===void 0?Je:c,u=Dt(s),p=u?a?Ke:Ke.filter(function(A){return Dt(A)===u}):It,_=p.filter(function(A){return d.indexOf(A)>=0});_.length===0&&(_=p);var f=_.reduce(function(A,m){return A[m]=Lt(n,{placement:m,boundary:i,rootBoundary:r,padding:o})[Y(m)],A},{});return Object.keys(f).sort(function(A,m){return f[A]-f[m]})}function Bi(n){if(Y(n)===pe)return[];var t=ae(n);return[Sn(n),t,Sn(t)]}function ji(n){var t=n.state,e=n.options,s=n.name;if(!t.modifiersData[s]._skip){for(var i=e.mainAxis,r=i===void 0?!0:i,o=e.altAxis,a=o===void 0?!0:o,c=e.fallbackPlacements,d=e.padding,u=e.boundary,p=e.rootBoundary,_=e.altBoundary,f=e.flipVariations,A=f===void 0?!0:f,m=e.allowedAutoPlacements,E=t.options.placement,T=Y(E),w=T===E,C=c||(w||!A?[ae(E)]:Bi(E)),g=[E].concat(C).reduce(function(vt,J){return vt.concat(Y(J)===pe?Wi(t,{placement:J,boundary:u,rootBoundary:p,padding:d,flipVariations:A,allowedAutoPlacements:m}):J)},[]),v=t.rects.reference,b=t.rects.popper,y=new Map,S=!0,N=g[0],O=0;O<g.length;O++){var D=g[O],j=Y(D),L=Dt(D)===pt,ot=[$,M].indexOf(j)>=0,at=ot?"width":"height",x=Lt(t,{placement:D,boundary:u,rootBoundary:p,altBoundary:_,padding:d}),F=ot?L?R:I:L?M:$;v[at]>b[at]&&(F=ae(F));var qt=ae(F),lt=[];if(r&&lt.push(x[j]<=0),a&&lt.push(x[F]<=0,x[qt]<=0),lt.every(function(vt){return vt})){N=D,S=!1;break}y.set(D,lt)}if(S)for(var Xt=A?3:1,Te=function(J){var kt=g.find(function(Jt){var ct=y.get(Jt);if(ct)return ct.slice(0,J).every(function(ye){return ye})});if(kt)return N=kt,"break"},Rt=Xt;Rt>0;Rt--){var Qt=Te(Rt);if(Qt==="break")break}t.placement!==N&&(t.modifiersData[s]._skip=!0,t.placement=N,t.reset=!0)}}const Ls={name:"flip",enabled:!0,phase:"main",fn:ji,requiresIfExists:["offset"],data:{_skip:!1}};function Ln(n,t,e){return e===void 0&&(e={x:0,y:0}),{top:n.top-t.height-e.y,right:n.right-t.width+e.x,bottom:n.bottom-t.height+e.y,left:n.left-t.width-e.x}}function $n(n){return[$,R,M,I].some(function(t){return n[t]>=0})}function Fi(n){var t=n.state,e=n.name,s=t.rects.reference,i=t.rects.popper,r=t.modifiersData.preventOverflow,o=Lt(t,{elementContext:"reference"}),a=Lt(t,{altBoundary:!0}),c=Ln(o,s),d=Ln(a,i,r),u=$n(c),p=$n(d);t.modifiersData[e]={referenceClippingOffsets:c,popperEscapeOffsets:d,isReferenceHidden:u,hasPopperEscaped:p},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":p})}const $s={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Fi};function Ki(n,t,e){var s=Y(n),i=[I,$].indexOf(s)>=0?-1:1,r=typeof e=="function"?e(Object.assign({},t,{placement:n})):e,o=r[0],a=r[1];return o=o||0,a=(a||0)*i,[I,R].indexOf(s)>=0?{x:a,y:o}:{x:o,y:a}}function Yi(n){var t=n.state,e=n.options,s=n.name,i=e.offset,r=i===void 0?[0,0]:i,o=Je.reduce(function(u,p){return u[p]=Ki(p,t.rects,r),u},{}),a=o[t.placement],c=a.x,d=a.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=d),t.modifiersData[s]=o}const Is={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Yi};function Ui(n){var t=n.state,e=n.name;t.modifiersData[e]=Ds({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const cn={name:"popperOffsets",enabled:!0,phase:"read",fn:Ui,data:{}};function zi(n){return n==="x"?"y":"x"}function Gi(n){var t=n.state,e=n.options,s=n.name,i=e.mainAxis,r=i===void 0?!0:i,o=e.altAxis,a=o===void 0?!1:o,c=e.boundary,d=e.rootBoundary,u=e.altBoundary,p=e.padding,_=e.tether,f=_===void 0?!0:_,A=e.tetherOffset,m=A===void 0?0:A,E=Lt(t,{boundary:c,rootBoundary:d,padding:p,altBoundary:u}),T=Y(t.placement),w=Dt(t.placement),C=!w,g=nn(T),v=zi(g),b=t.modifiersData.popperOffsets,y=t.rects.reference,S=t.rects.popper,N=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,O=typeof N=="number"?{mainAxis:N,altAxis:N}:Object.assign({mainAxis:0,altAxis:0},N),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,j={x:0,y:0};if(b){if(r){var L,ot=g==="y"?$:I,at=g==="y"?M:R,x=g==="y"?"height":"width",F=b[g],qt=F+E[ot],lt=F-E[at],Xt=f?-S[x]/2:0,Te=w===pt?y[x]:S[x],Rt=w===pt?-S[x]:-y[x],Qt=t.elements.arrow,vt=f&&Qt?en(Qt):{width:0,height:0},J=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:ws(),kt=J[ot],Jt=J[at],ct=Wt(0,y[x],vt[x]),ye=C?y[x]/2-Xt-ct-kt-O.mainAxis:Te-ct-kt-O.mainAxis,di=C?-y[x]/2+Xt+ct+Jt+O.mainAxis:Rt+ct+Jt+O.mainAxis,we=t.elements.arrow&&Kt(t.elements.arrow),hi=we?g==="y"?we.clientTop||0:we.clientLeft||0:0,mn=(L=D==null?void 0:D[g])!=null?L:0,fi=F+ye-mn-hi,pi=F+di-mn,gn=Wt(f?ue(qt,fi):qt,F,f?ft(lt,pi):lt);b[g]=gn,j[g]=gn-F}if(a){var En,_i=g==="x"?$:I,mi=g==="x"?M:R,ut=b[v],Zt=v==="y"?"height":"width",vn=ut+E[_i],bn=ut-E[mi],Ce=[$,I].indexOf(T)!==-1,An=(En=D==null?void 0:D[v])!=null?En:0,Tn=Ce?vn:ut-y[Zt]-S[Zt]-An+O.altAxis,yn=Ce?ut+y[Zt]+S[Zt]-An-O.altAxis:bn,wn=f&&Ce?Ci(Tn,ut,yn):Wt(f?Tn:vn,ut,f?yn:bn);b[v]=wn,j[v]=wn-ut}t.modifiersData[s]=j}}const Ps={name:"preventOverflow",enabled:!0,phase:"main",fn:Gi,requiresIfExists:["offset"]};function qi(n){return{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}}function Xi(n){return n===k(n)||!V(n)?on(n):qi(n)}function Qi(n){var t=n.getBoundingClientRect(),e=Nt(t.width)/n.offsetWidth||1,s=Nt(t.height)/n.offsetHeight||1;return e!==1||s!==1}function Ji(n,t,e){e===void 0&&(e=!1);var s=V(t),i=V(t)&&Qi(t),r=st(t),o=St(n,i,e),a={scrollLeft:0,scrollTop:0},c={x:0,y:0};return(s||!s&&!e)&&((z(t)!=="body"||ln(r))&&(a=Xi(t)),V(t)?(c=St(t,!0),c.x+=t.clientLeft,c.y+=t.clientTop):r&&(c.x=an(r))),{x:o.left+a.scrollLeft-c.x,y:o.top+a.scrollTop-c.y,width:o.width,height:o.height}}function Zi(n){var t=new Map,e=new Set,s=[];n.forEach(function(r){t.set(r.name,r)});function i(r){e.add(r.name);var o=[].concat(r.requires||[],r.requiresIfExists||[]);o.forEach(function(a){if(!e.has(a)){var c=t.get(a);c&&i(c)}}),s.push(r)}return n.forEach(function(r){e.has(r.name)||i(r)}),s}function tr(n){var t=Zi(n);return As.reduce(function(e,s){return e.concat(t.filter(function(i){return i.phase===s}))},[])}function er(n){var t;return function(){return t||(t=new Promise(function(e){Promise.resolve().then(function(){t=void 0,e(n())})})),t}}function nr(n){var t=n.reduce(function(e,s){var i=e[s.name];return e[s.name]=i?Object.assign({},i,s,{options:Object.assign({},i.options,s.options),data:Object.assign({},i.data,s.data)}):s,e},{});return Object.keys(t).map(function(e){return t[e]})}var In={placement:"bottom",modifiers:[],strategy:"absolute"};function Pn(){for(var n=arguments.length,t=new Array(n),e=0;e<n;e++)t[e]=arguments[e];return!t.some(function(s){return!(s&&typeof s.getBoundingClientRect=="function")})}function me(n){n===void 0&&(n={});var t=n,e=t.defaultModifiers,s=e===void 0?[]:e,i=t.defaultOptions,r=i===void 0?In:i;return function(a,c,d){d===void 0&&(d=r);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},In,r),modifiersData:{},elements:{reference:a,popper:c},attributes:{},styles:{}},p=[],_=!1,f={state:u,setOptions:function(T){var w=typeof T=="function"?T(u.options):T;m(),u.options=Object.assign({},r,u.options,w),u.scrollParents={reference:_t(a)?Bt(a):a.contextElement?Bt(a.contextElement):[],popper:Bt(c)};var C=tr(nr([].concat(s,u.options.modifiers)));return u.orderedModifiers=C.filter(function(g){return g.enabled}),A(),f.update()},forceUpdate:function(){if(!_){var T=u.elements,w=T.reference,C=T.popper;if(Pn(w,C)){u.rects={reference:Ji(w,Kt(C),u.options.strategy==="fixed"),popper:en(C)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(O){return u.modifiersData[O.name]=Object.assign({},O.data)});for(var g=0;g<u.orderedModifiers.length;g++){if(u.reset===!0){u.reset=!1,g=-1;continue}var v=u.orderedModifiers[g],b=v.fn,y=v.options,S=y===void 0?{}:y,N=v.name;typeof b=="function"&&(u=b({state:u,options:S,name:N,instance:f})||u)}}}},update:er(function(){return new Promise(function(E){f.forceUpdate(),E(u)})}),destroy:function(){m(),_=!0}};if(!Pn(a,c))return f;f.setOptions(d).then(function(E){!_&&d.onFirstUpdate&&d.onFirstUpdate(E)});function A(){u.orderedModifiers.forEach(function(E){var T=E.name,w=E.options,C=w===void 0?{}:w,g=E.effect;if(typeof g=="function"){var v=g({state:u,name:T,instance:f,options:C}),b=function(){};p.push(v||b)}})}function m(){p.forEach(function(E){return E()}),p=[]}return f}}var sr=me(),ir=[rn,cn,sn,tn],rr=me({defaultModifiers:ir}),or=[rn,cn,sn,tn,Is,Ls,Ps,Ns,$s],un=me({defaultModifiers:or});const xs=Object.freeze(Object.defineProperty({__proto__:null,afterMain:gs,afterRead:ps,afterWrite:bs,applyStyles:tn,arrow:Ns,auto:pe,basePlacements:It,beforeMain:_s,beforeRead:hs,beforeWrite:Es,bottom:M,clippingParents:us,computeStyles:sn,createPopper:un,createPopperBase:sr,createPopperLite:rr,detectOverflow:Lt,end:Ot,eventListeners:rn,flip:Ls,hide:$s,left:I,main:ms,modifierPhases:As,offset:Is,placements:Je,popper:Tt,popperGenerator:me,popperOffsets:cn,preventOverflow:Ps,read:fs,reference:ds,right:R,start:pt,top:$,variationPlacements:Ke,viewport:Qe,write:vs},Symbol.toStringTag,{value:"Module"}));/*!
* Bootstrap v5.3.3 (https://getbootstrap.com/)
* Copyright 2011-2024 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
*/const Z=new Map,Se={set(n,t,e){Z.has(n)||Z.set(n,new Map);const s=Z.get(n);if(!s.has(t)&&s.size!==0){console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`);return}s.set(t,e)},get(n,t){return Z.has(n)&&Z.get(n).get(t)||null},remove(n,t){if(!Z.has(n))return;const e=Z.get(n);e.delete(t),e.size===0&&Z.delete(n)}},ar=1e6,lr=1e3,ze="transitionend",Ms=n=>(n&&window.CSS&&window.CSS.escape&&(n=n.replace(/#([^\s"#']+)/g,(t,e)=>`#${CSS.escape(e)}`)),n),cr=n=>n==null?`${n}`:Object.prototype.toString.call(n).match(/\s([a-z]+)/i)[1].toLowerCase(),ur=n=>{do n+=Math.floor(Math.random()*ar);while(document.getElementById(n));return n},dr=n=>{if(!n)return 0;let{transitionDuration:t,transitionDelay:e}=window.getComputedStyle(n);const s=Number.parseFloat(t),i=Number.parseFloat(e);return!s&&!i?0:(t=t.split(",")[0],e=e.split(",")[0],(Number.parseFloat(t)+Number.parseFloat(e))*lr)},Rs=n=>{n.dispatchEvent(new Event(ze))},G=n=>!n||typeof n!="object"?!1:(typeof n.jquery<"u"&&(n=n[0]),typeof n.nodeType<"u"),tt=n=>G(n)?n.jquery?n[0]:n:typeof n=="string"&&n.length>0?document.querySelector(Ms(n)):null,Pt=n=>{if(!G(n)||n.getClientRects().length===0)return!1;const t=getComputedStyle(n).getPropertyValue("visibility")==="visible",e=n.closest("details:not([open])");if(!e)return t;if(e!==n){const s=n.closest("summary");if(s&&s.parentNode!==e||s===null)return!1}return t},et=n=>!n||n.nodeType!==Node.ELEMENT_NODE||n.classList.contains("disabled")?!0:typeof n.disabled<"u"?n.disabled:n.hasAttribute("disabled")&&n.getAttribute("disabled")!=="false",ks=n=>{if(!document.documentElement.attachShadow)return null;if(typeof n.getRootNode=="function"){const t=n.getRootNode();return t instanceof ShadowRoot?t:null}return n instanceof ShadowRoot?n:n.parentNode?ks(n.parentNode):null},de=()=>{},Yt=n=>{n.offsetHeight},Vs=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,De=[],hr=n=>{document.readyState==="loading"?(De.length||document.addEventListener("DOMContentLoaded",()=>{for(const t of De)t()}),De.push(n)):n()},H=()=>document.documentElement.dir==="rtl",B=n=>{hr(()=>{const t=Vs();if(t){const e=n.NAME,s=t.fn[e];t.fn[e]=n.jQueryInterface,t.fn[e].Constructor=n,t.fn[e].noConflict=()=>(t.fn[e]=s,n.jQueryInterface)}})},P=(n,t=[],e=n)=>typeof n=="function"?n(...t):e,Hs=(n,t,e=!0)=>{if(!e){P(n);return}const i=dr(t)+5;let r=!1;const o=({target:a})=>{a===t&&(r=!0,t.removeEventListener(ze,o),P(n))};t.addEventListener(ze,o),setTimeout(()=>{r||Rs(t)},i)},dn=(n,t,e,s)=>{const i=n.length;let r=n.indexOf(t);return r===-1?!e&&s?n[i-1]:n[0]:(r+=e?1:-1,s&&(r=(r+i)%i),n[Math.max(0,Math.min(r,i-1))])},fr=/[^.]*(?=\..*)\.|.*/,pr=/\..*/,_r=/::\d+$/,Le={};let xn=1;const Ws={mouseenter:"mouseover",mouseleave:"mouseout"},mr=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function Bs(n,t){return t&&`${t}::${xn++}`||n.uidEvent||xn++}function js(n){const t=Bs(n);return n.uidEvent=t,Le[t]=Le[t]||{},Le[t]}function gr(n,t){return function e(s){return hn(s,{delegateTarget:n}),e.oneOff&&l.off(n,s.type,t),t.apply(n,[s])}}function Er(n,t,e){return function s(i){const r=n.querySelectorAll(t);for(let{target:o}=i;o&&o!==this;o=o.parentNode)for(const a of r)if(a===o)return hn(i,{delegateTarget:o}),s.oneOff&&l.off(n,i.type,t,e),e.apply(o,[i])}}function Fs(n,t,e=null){return Object.values(n).find(s=>s.callable===t&&s.delegationSelector===e)}function Ks(n,t,e){const s=typeof t=="string",i=s?e:t||e;let r=Ys(n);return mr.has(r)||(r=n),[s,i,r]}function Mn(n,t,e,s,i){if(typeof t!="string"||!n)return;let[r,o,a]=Ks(t,e,s);t in Ws&&(o=(A=>function(m){if(!m.relatedTarget||m.relatedTarget!==m.delegateTarget&&!m.delegateTarget.contains(m.relatedTarget))return A.call(this,m)})(o));const c=js(n),d=c[a]||(c[a]={}),u=Fs(d,o,r?e:null);if(u){u.oneOff=u.oneOff&&i;return}const p=Bs(o,t.replace(fr,"")),_=r?Er(n,e,o):gr(n,o);_.delegationSelector=r?e:null,_.callable=o,_.oneOff=i,_.uidEvent=p,d[p]=_,n.addEventListener(a,_,r)}function Ge(n,t,e,s,i){const r=Fs(t[e],s,i);r&&(n.removeEventListener(e,r,!!i),delete t[e][r.uidEvent])}function vr(n,t,e,s){const i=t[e]||{};for(const[r,o]of Object.entries(i))r.includes(s)&&Ge(n,t,e,o.callable,o.delegationSelector)}function Ys(n){return n=n.replace(pr,""),Ws[n]||n}const l={on(n,t,e,s){Mn(n,t,e,s,!1)},one(n,t,e,s){Mn(n,t,e,s,!0)},off(n,t,e,s){if(typeof t!="string"||!n)return;const[i,r,o]=Ks(t,e,s),a=o!==t,c=js(n),d=c[o]||{},u=t.startsWith(".");if(typeof r<"u"){if(!Object.keys(d).length)return;Ge(n,c,o,r,i?e:null);return}if(u)for(const p of Object.keys(c))vr(n,c,p,t.slice(1));for(const[p,_]of Object.entries(d)){const f=p.replace(_r,"");(!a||t.includes(f))&&Ge(n,c,o,_.callable,_.delegationSelector)}},trigger(n,t,e){if(typeof t!="string"||!n)return null;const s=Vs(),i=Ys(t),r=t!==i;let o=null,a=!0,c=!0,d=!1;r&&s&&(o=s.Event(t,e),s(n).trigger(o),a=!o.isPropagationStopped(),c=!o.isImmediatePropagationStopped(),d=o.isDefaultPrevented());const u=hn(new Event(t,{bubbles:a,cancelable:!0}),e);return d&&u.preventDefault(),c&&n.dispatchEvent(u),u.defaultPrevented&&o&&o.preventDefault(),u}};function hn(n,t={}){for(const[e,s]of Object.entries(t))try{n[e]=s}catch{Object.defineProperty(n,e,{configurable:!0,get(){return s}})}return n}function Rn(n){if(n==="true")return!0;if(n==="false")return!1;if(n===Number(n).toString())return Number(n);if(n===""||n==="null")return null;if(typeof n!="string")return n;try{return JSON.parse(decodeURIComponent(n))}catch{return n}}function $e(n){return n.replace(/[A-Z]/g,t=>`-${t.toLowerCase()}`)}const q={setDataAttribute(n,t,e){n.setAttribute(`data-bs-${$e(t)}`,e)},removeDataAttribute(n,t){n.removeAttribute(`data-bs-${$e(t)}`)},getDataAttributes(n){if(!n)return{};const t={},e=Object.keys(n.dataset).filter(s=>s.startsWith("bs")&&!s.startsWith("bsConfig"));for(const s of e){let i=s.replace(/^bs/,"");i=i.charAt(0).toLowerCase()+i.slice(1,i.length),t[i]=Rn(n.dataset[s])}return t},getDataAttribute(n,t){return Rn(n.getAttribute(`data-bs-${$e(t)}`))}};class Ut{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(t){return t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t}_mergeConfigObj(t,e){const s=G(e)?q.getDataAttribute(e,"config"):{};return{...this.constructor.Default,...typeof s=="object"?s:{},...G(e)?q.getDataAttributes(e):{},...typeof t=="object"?t:{}}}_typeCheckConfig(t,e=this.constructor.DefaultType){for(const[s,i]of Object.entries(e)){const r=t[s],o=G(r)?"element":cr(r);if(!new RegExp(i).test(o))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${s}" provided type "${o}" but expected type "${i}".`)}}}const br="5.3.3";class K extends Ut{constructor(t,e){super(),t=tt(t),t&&(this._element=t,this._config=this._getConfig(e),Se.set(this._element,this.constructor.DATA_KEY,this))}dispose(){Se.remove(this._element,this.constructor.DATA_KEY),l.off(this._element,this.constructor.EVENT_KEY);for(const t of Object.getOwnPropertyNames(this))this[t]=null}_queueCallback(t,e,s=!0){Hs(t,e,s)}_getConfig(t){return t=this._mergeConfigObj(t,this._element),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}static getInstance(t){return Se.get(tt(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,typeof e=="object"?e:null)}static get VERSION(){return br}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(t){return`${t}${this.EVENT_KEY}`}}const Ie=n=>{let t=n.getAttribute("data-bs-target");if(!t||t==="#"){let e=n.getAttribute("href");if(!e||!e.includes("#")&&!e.startsWith("."))return null;e.includes("#")&&!e.startsWith("#")&&(e=`#${e.split("#")[1]}`),t=e&&e!=="#"?e.trim():null}return t?t.split(",").map(e=>Ms(e)).join(","):null},h={find(n,t=document.documentElement){return[].concat(...Element.prototype.querySelectorAll.call(t,n))},findOne(n,t=document.documentElement){return Element.prototype.querySelector.call(t,n)},children(n,t){return[].concat(...n.children).filter(e=>e.matches(t))},parents(n,t){const e=[];let s=n.parentNode.closest(t);for(;s;)e.push(s),s=s.parentNode.closest(t);return e},prev(n,t){let e=n.previousElementSibling;for(;e;){if(e.matches(t))return[e];e=e.previousElementSibling}return[]},next(n,t){let e=n.nextElementSibling;for(;e;){if(e.matches(t))return[e];e=e.nextElementSibling}return[]},focusableChildren(n){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(e=>`${e}:not([tabindex^="-"])`).join(",");return this.find(t,n).filter(e=>!et(e)&&Pt(e))},getSelectorFromElement(n){const t=Ie(n);return t&&h.findOne(t)?t:null},getElementFromSelector(n){const t=Ie(n);return t?h.findOne(t):null},getMultipleElementsFromSelector(n){const t=Ie(n);return t?h.find(t):[]}},ge=(n,t="hide")=>{const e=`click.dismiss${n.EVENT_KEY}`,s=n.NAME;l.on(document,e,`[data-bs-dismiss="${s}"]`,function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),et(this))return;const r=h.getElementFromSelector(this)||this.closest(`.${s}`);n.getOrCreateInstance(r)[t]()})},Ar="alert",Tr="bs.alert",Us=`.${Tr}`,yr=`close${Us}`,wr=`closed${Us}`,Cr="fade",Or="show";class Ee extends K{static get NAME(){return Ar}close(){if(l.trigger(this._element,yr).defaultPrevented)return;this._element.classList.remove(Or);const e=this._element.classList.contains(Cr);this._queueCallback(()=>this._destroyElement(),this._element,e)}_destroyElement(){this._element.remove(),l.trigger(this._element,wr),this.dispose()}static jQueryInterface(t){return this.each(function(){const e=Ee.getOrCreateInstance(this);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}ge(Ee,"close");B(Ee);const Nr="button",Sr="bs.button",Dr=`.${Sr}`,Lr=".data-api",$r="active",kn='[data-bs-toggle="button"]',Ir=`click${Dr}${Lr}`;class ve extends K{static get NAME(){return Nr}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle($r))}static jQueryInterface(t){return this.each(function(){const e=ve.getOrCreateInstance(this);t==="toggle"&&e[t]()})}}l.on(document,Ir,kn,n=>{n.preventDefault();const t=n.target.closest(kn);ve.getOrCreateInstance(t).toggle()});B(ve);const Pr="swipe",xt=".bs.swipe",xr=`touchstart${xt}`,Mr=`touchmove${xt}`,Rr=`touchend${xt}`,kr=`pointerdown${xt}`,Vr=`pointerup${xt}`,Hr="touch",Wr="pen",Br="pointer-event",jr=40,Fr={endCallback:null,leftCallback:null,rightCallback:null},Kr={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class he extends Ut{constructor(t,e){super(),this._element=t,!(!t||!he.isSupported())&&(this._config=this._getConfig(e),this._deltaX=0,this._supportPointerEvents=!!window.PointerEvent,this._initEvents())}static get Default(){return Fr}static get DefaultType(){return Kr}static get NAME(){return Pr}dispose(){l.off(this._element,xt)}_start(t){if(!this._supportPointerEvents){this._deltaX=t.touches[0].clientX;return}this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX)}_end(t){this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX-this._deltaX),this._handleSwipe(),P(this._config.endCallback)}_move(t){this._deltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this._deltaX}_handleSwipe(){const t=Math.abs(this._deltaX);if(t<=jr)return;const e=t/this._deltaX;this._deltaX=0,e&&P(e>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(l.on(this._element,kr,t=>this._start(t)),l.on(this._element,Vr,t=>this._end(t)),this._element.classList.add(Br)):(l.on(this._element,xr,t=>this._start(t)),l.on(this._element,Mr,t=>this._move(t)),l.on(this._element,Rr,t=>this._end(t)))}_eventIsPointerPenTouch(t){return this._supportPointerEvents&&(t.pointerType===Wr||t.pointerType===Hr)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const Yr="carousel",Ur="bs.carousel",it=`.${Ur}`,zs=".data-api",zr="ArrowLeft",Gr="ArrowRight",qr=500,Vt="next",bt="prev",yt="left",le="right",Xr=`slide${it}`,Pe=`slid${it}`,Qr=`keydown${it}`,Jr=`mouseenter${it}`,Zr=`mouseleave${it}`,to=`dragstart${it}`,eo=`load${it}${zs}`,no=`click${it}${zs}`,Gs="carousel",ee="active",so="slide",io="carousel-item-end",ro="carousel-item-start",oo="carousel-item-next",ao="carousel-item-prev",qs=".active",Xs=".carousel-item",lo=qs+Xs,co=".carousel-item img",uo=".carousel-indicators",ho="[data-bs-slide], [data-bs-slide-to]",fo='[data-bs-ride="carousel"]',po={[zr]:le,[Gr]:yt},_o={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},mo={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class zt extends K{constructor(t,e){super(t,e),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=h.findOne(uo,this._element),this._addEventListeners(),this._config.ride===Gs&&this.cycle()}static get Default(){return _o}static get DefaultType(){return mo}static get NAME(){return Yr}next(){this._slide(Vt)}nextWhenVisible(){!document.hidden&&Pt(this._element)&&this.next()}prev(){this._slide(bt)}pause(){this._isSliding&&Rs(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval(()=>this.nextWhenVisible(),this._config.interval)}_maybeEnableCycle(){if(this._config.ride){if(this._isSliding){l.one(this._element,Pe,()=>this.cycle());return}this.cycle()}}to(t){const e=this._getItems();if(t>e.length-1||t<0)return;if(this._isSliding){l.one(this._element,Pe,()=>this.to(t));return}const s=this._getItemIndex(this._getActive());if(s===t)return;const i=t>s?Vt:bt;this._slide(i,e[t])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(t){return t.defaultInterval=t.interval,t}_addEventListeners(){this._config.keyboard&&l.on(this._element,Qr,t=>this._keydown(t)),this._config.pause==="hover"&&(l.on(this._element,Jr,()=>this.pause()),l.on(this._element,Zr,()=>this._maybeEnableCycle())),this._config.touch&&he.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const s of h.find(co,this._element))l.on(s,to,i=>i.preventDefault());const e={leftCallback:()=>this._slide(this._directionToOrder(yt)),rightCallback:()=>this._slide(this._directionToOrder(le)),endCallback:()=>{this._config.pause==="hover"&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(()=>this._maybeEnableCycle(),qr+this._config.interval))}};this._swipeHelper=new he(this._element,e)}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=po[t.key];e&&(t.preventDefault(),this._slide(this._directionToOrder(e)))}_getItemIndex(t){return this._getItems().indexOf(t)}_setActiveIndicatorElement(t){if(!this._indicatorsElement)return;const e=h.findOne(qs,this._indicatorsElement);e.classList.remove(ee),e.removeAttribute("aria-current");const s=h.findOne(`[data-bs-slide-to="${t}"]`,this._indicatorsElement);s&&(s.classList.add(ee),s.setAttribute("aria-current","true"))}_updateInterval(){const t=this._activeElement||this._getActive();if(!t)return;const e=Number.parseInt(t.getAttribute("data-bs-interval"),10);this._config.interval=e||this._config.defaultInterval}_slide(t,e=null){if(this._isSliding)return;const s=this._getActive(),i=t===Vt,r=e||dn(this._getItems(),s,i,this._config.wrap);if(r===s)return;const o=this._getItemIndex(r),a=f=>l.trigger(this._element,f,{relatedTarget:r,direction:this._orderToDirection(t),from:this._getItemIndex(s),to:o});if(a(Xr).defaultPrevented||!s||!r)return;const d=!!this._interval;this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=r;const u=i?ro:io,p=i?oo:ao;r.classList.add(p),Yt(r),s.classList.add(u),r.classList.add(u);const _=()=>{r.classList.remove(u,p),r.classList.add(ee),s.classList.remove(ee,p,u),this._isSliding=!1,a(Pe)};this._queueCallback(_,s,this._isAnimated()),d&&this.cycle()}_isAnimated(){return this._element.classList.contains(so)}_getActive(){return h.findOne(lo,this._element)}_getItems(){return h.find(Xs,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(t){return H()?t===yt?bt:Vt:t===yt?Vt:bt}_orderToDirection(t){return H()?t===bt?yt:le:t===bt?le:yt}static jQueryInterface(t){return this.each(function(){const e=zt.getOrCreateInstance(this,t);if(typeof t=="number"){e.to(t);return}if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}l.on(document,no,ho,function(n){const t=h.getElementFromSelector(this);if(!t||!t.classList.contains(Gs))return;n.preventDefault();const e=zt.getOrCreateInstance(t),s=this.getAttribute("data-bs-slide-to");if(s){e.to(s),e._maybeEnableCycle();return}if(q.getDataAttribute(this,"slide")==="next"){e.next(),e._maybeEnableCycle();return}e.prev(),e._maybeEnableCycle()});l.on(window,eo,()=>{const n=h.find(fo);for(const t of n)zt.getOrCreateInstance(t)});B(zt);const go="collapse",Eo="bs.collapse",Gt=`.${Eo}`,vo=".data-api",bo=`show${Gt}`,Ao=`shown${Gt}`,To=`hide${Gt}`,yo=`hidden${Gt}`,wo=`click${Gt}${vo}`,xe="show",Ct="collapse",ne="collapsing",Co="collapsed",Oo=`:scope .${Ct} .${Ct}`,No="collapse-horizontal",So="width",Do="height",Lo=".collapse.show, .collapse.collapsing",qe='[data-bs-toggle="collapse"]',$o={parent:null,toggle:!0},Io={parent:"(null|element)",toggle:"boolean"};class Ft extends K{constructor(t,e){super(t,e),this._isTransitioning=!1,this._triggerArray=[];const s=h.find(qe);for(const i of s){const r=h.getSelectorFromElement(i),o=h.find(r).filter(a=>a===this._element);r!==null&&o.length&&this._triggerArray.push(i)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return $o}static get DefaultType(){return Io}static get NAME(){return go}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t=[];if(this._config.parent&&(t=this._getFirstLevelChildren(Lo).filter(a=>a!==this._element).map(a=>Ft.getOrCreateInstance(a,{toggle:!1}))),t.length&&t[0]._isTransitioning||l.trigger(this._element,bo).defaultPrevented)return;for(const a of t)a.hide();const s=this._getDimension();this._element.classList.remove(Ct),this._element.classList.add(ne),this._element.style[s]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=()=>{this._isTransitioning=!1,this._element.classList.remove(ne),this._element.classList.add(Ct,xe),this._element.style[s]="",l.trigger(this._element,Ao)},o=`scroll${s[0].toUpperCase()+s.slice(1)}`;this._queueCallback(i,this._element,!0),this._element.style[s]=`${this._element[o]}px`}hide(){if(this._isTransitioning||!this._isShown()||l.trigger(this._element,To).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,Yt(this._element),this._element.classList.add(ne),this._element.classList.remove(Ct,xe);for(const i of this._triggerArray){const r=h.getElementFromSelector(i);r&&!this._isShown(r)&&this._addAriaAndCollapsedClass([i],!1)}this._isTransitioning=!0;const s=()=>{this._isTransitioning=!1,this._element.classList.remove(ne),this._element.classList.add(Ct),l.trigger(this._element,yo)};this._element.style[e]="",this._queueCallback(s,this._element,!0)}_isShown(t=this._element){return t.classList.contains(xe)}_configAfterMerge(t){return t.toggle=!!t.toggle,t.parent=tt(t.parent),t}_getDimension(){return this._element.classList.contains(No)?So:Do}_initializeChildren(){if(!this._config.parent)return;const t=this._getFirstLevelChildren(qe);for(const e of t){const s=h.getElementFromSelector(e);s&&this._addAriaAndCollapsedClass([e],this._isShown(s))}}_getFirstLevelChildren(t){const e=h.find(Oo,this._config.parent);return h.find(t,this._config.parent).filter(s=>!e.includes(s))}_addAriaAndCollapsedClass(t,e){if(t.length)for(const s of t)s.classList.toggle(Co,!e),s.setAttribute("aria-expanded",e)}static jQueryInterface(t){const e={};return typeof t=="string"&&/show|hide/.test(t)&&(e.toggle=!1),this.each(function(){const s=Ft.getOrCreateInstance(this,e);if(typeof t=="string"){if(typeof s[t]>"u")throw new TypeError(`No method named "${t}"`);s[t]()}})}}l.on(document,wo,qe,function(n){(n.target.tagName==="A"||n.delegateTarget&&n.delegateTarget.tagName==="A")&&n.preventDefault();for(const t of h.getMultipleElementsFromSelector(this))Ft.getOrCreateInstance(t,{toggle:!1}).toggle()});B(Ft);const Vn="dropdown",Po="bs.dropdown",gt=`.${Po}`,fn=".data-api",xo="Escape",Hn="Tab",Mo="ArrowUp",Wn="ArrowDown",Ro=2,ko=`hide${gt}`,Vo=`hidden${gt}`,Ho=`show${gt}`,Wo=`shown${gt}`,Qs=`click${gt}${fn}`,Js=`keydown${gt}${fn}`,Bo=`keyup${gt}${fn}`,wt="show",jo="dropup",Fo="dropend",Ko="dropstart",Yo="dropup-center",Uo="dropdown-center",dt='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',zo=`${dt}.${wt}`,ce=".dropdown-menu",Go=".navbar",qo=".navbar-nav",Xo=".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",Qo=H()?"top-end":"top-start",Jo=H()?"top-start":"top-end",Zo=H()?"bottom-end":"bottom-start",ta=H()?"bottom-start":"bottom-end",ea=H()?"left-start":"right-start",na=H()?"right-start":"left-start",sa="top",ia="bottom",ra={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},oa={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class U extends K{constructor(t,e){super(t,e),this._popper=null,this._parent=this._element.parentNode,this._menu=h.next(this._element,ce)[0]||h.prev(this._element,ce)[0]||h.findOne(ce,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return ra}static get DefaultType(){return oa}static get NAME(){return Vn}toggle(){return this._isShown()?this.hide():this.show()}show(){if(et(this._element)||this._isShown())return;const t={relatedTarget:this._element};if(!l.trigger(this._element,Ho,t).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(qo))for(const s of[].concat(...document.body.children))l.on(s,"mouseover",de);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(wt),this._element.classList.add(wt),l.trigger(this._element,Wo,t)}}hide(){if(et(this._element)||!this._isShown())return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){if(!l.trigger(this._element,ko,t).defaultPrevented){if("ontouchstart"in document.documentElement)for(const s of[].concat(...document.body.children))l.off(s,"mouseover",de);this._popper&&this._popper.destroy(),this._menu.classList.remove(wt),this._element.classList.remove(wt),this._element.setAttribute("aria-expanded","false"),q.removeDataAttribute(this._menu,"popper"),l.trigger(this._element,Vo,t)}}_getConfig(t){if(t=super._getConfig(t),typeof t.reference=="object"&&!G(t.reference)&&typeof t.reference.getBoundingClientRect!="function")throw new TypeError(`${Vn.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(){if(typeof xs>"u")throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let t=this._element;this._config.reference==="parent"?t=this._parent:G(this._config.reference)?t=tt(this._config.reference):typeof this._config.reference=="object"&&(t=this._config.reference);const e=this._getPopperConfig();this._popper=un(t,this._menu,e)}_isShown(){return this._menu.classList.contains(wt)}_getPlacement(){const t=this._parent;if(t.classList.contains(Fo))return ea;if(t.classList.contains(Ko))return na;if(t.classList.contains(Yo))return sa;if(t.classList.contains(Uo))return ia;const e=getComputedStyle(this._menu).getPropertyValue("--bs-position").trim()==="end";return t.classList.contains(jo)?e?Jo:Qo:e?ta:Zo}_detectNavbar(){return this._element.closest(Go)!==null}_getOffset(){const{offset:t}=this._config;return typeof t=="string"?t.split(",").map(e=>Number.parseInt(e,10)):typeof t=="function"?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||this._config.display==="static")&&(q.setDataAttribute(this._menu,"popper","static"),t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,...P(this._config.popperConfig,[t])}}_selectMenuItem({key:t,target:e}){const s=h.find(Xo,this._menu).filter(i=>Pt(i));s.length&&dn(s,e,t===Wn,!s.includes(e)).focus()}static jQueryInterface(t){return this.each(function(){const e=U.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}static clearMenus(t){if(t.button===Ro||t.type==="keyup"&&t.key!==Hn)return;const e=h.find(zo);for(const s of e){const i=U.getInstance(s);if(!i||i._config.autoClose===!1)continue;const r=t.composedPath(),o=r.includes(i._menu);if(r.includes(i._element)||i._config.autoClose==="inside"&&!o||i._config.autoClose==="outside"&&o||i._menu.contains(t.target)&&(t.type==="keyup"&&t.key===Hn||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;const a={relatedTarget:i._element};t.type==="click"&&(a.clickEvent=t),i._completeHide(a)}}static dataApiKeydownHandler(t){const e=/input|textarea/i.test(t.target.tagName),s=t.key===xo,i=[Mo,Wn].includes(t.key);if(!i&&!s||e&&!s)return;t.preventDefault();const r=this.matches(dt)?this:h.prev(this,dt)[0]||h.next(this,dt)[0]||h.findOne(dt,t.delegateTarget.parentNode),o=U.getOrCreateInstance(r);if(i){t.stopPropagation(),o.show(),o._selectMenuItem(t);return}o._isShown()&&(t.stopPropagation(),o.hide(),r.focus())}}l.on(document,Js,dt,U.dataApiKeydownHandler);l.on(document,Js,ce,U.dataApiKeydownHandler);l.on(document,Qs,U.clearMenus);l.on(document,Bo,U.clearMenus);l.on(document,Qs,dt,function(n){n.preventDefault(),U.getOrCreateInstance(this).toggle()});B(U);const Zs="backdrop",aa="fade",Bn="show",jn=`mousedown.bs.${Zs}`,la={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},ca={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class ti extends Ut{constructor(t){super(),this._config=this._getConfig(t),this._isAppended=!1,this._element=null}static get Default(){return la}static get DefaultType(){return ca}static get NAME(){return Zs}show(t){if(!this._config.isVisible){P(t);return}this._append();const e=this._getElement();this._config.isAnimated&&Yt(e),e.classList.add(Bn),this._emulateAnimation(()=>{P(t)})}hide(t){if(!this._config.isVisible){P(t);return}this._getElement().classList.remove(Bn),this._emulateAnimation(()=>{this.dispose(),P(t)})}dispose(){this._isAppended&&(l.off(this._element,jn),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add(aa),this._element=t}return this._element}_configAfterMerge(t){return t.rootElement=tt(t.rootElement),t}_append(){if(this._isAppended)return;const t=this._getElement();this._config.rootElement.append(t),l.on(t,jn,()=>{P(this._config.clickCallback)}),this._isAppended=!0}_emulateAnimation(t){Hs(t,this._getElement(),this._config.isAnimated)}}const ua="focustrap",da="bs.focustrap",fe=`.${da}`,ha=`focusin${fe}`,fa=`keydown.tab${fe}`,pa="Tab",_a="forward",Fn="backward",ma={autofocus:!0,trapElement:null},ga={autofocus:"boolean",trapElement:"element"};class ei extends Ut{constructor(t){super(),this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return ma}static get DefaultType(){return ga}static get NAME(){return ua}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),l.off(document,fe),l.on(document,ha,t=>this._handleFocusin(t)),l.on(document,fa,t=>this._handleKeydown(t)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,l.off(document,fe))}_handleFocusin(t){const{trapElement:e}=this._config;if(t.target===document||t.target===e||e.contains(t.target))return;const s=h.focusableChildren(e);s.length===0?e.focus():this._lastTabNavDirection===Fn?s[s.length-1].focus():s[0].focus()}_handleKeydown(t){t.key===pa&&(this._lastTabNavDirection=t.shiftKey?Fn:_a)}}const Kn=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",Yn=".sticky-top",se="padding-right",Un="margin-right";class Xe{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,se,e=>e+t),this._setElementAttributes(Kn,se,e=>e+t),this._setElementAttributes(Yn,Un,e=>e-t)}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,se),this._resetElementAttributes(Kn,se),this._resetElementAttributes(Yn,Un)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,s){const i=this.getWidth(),r=o=>{if(o!==this._element&&window.innerWidth>o.clientWidth+i)return;this._saveInitialAttribute(o,e);const a=window.getComputedStyle(o).getPropertyValue(e);o.style.setProperty(e,`${s(Number.parseFloat(a))}px`)};this._applyManipulationCallback(t,r)}_saveInitialAttribute(t,e){const s=t.style.getPropertyValue(e);s&&q.setDataAttribute(t,e,s)}_resetElementAttributes(t,e){const s=i=>{const r=q.getDataAttribute(i,e);if(r===null){i.style.removeProperty(e);return}q.removeDataAttribute(i,e),i.style.setProperty(e,r)};this._applyManipulationCallback(t,s)}_applyManipulationCallback(t,e){if(G(t)){e(t);return}for(const s of h.find(t,this._element))e(s)}}const Ea="modal",va="bs.modal",W=`.${va}`,ba=".data-api",Aa="Escape",Ta=`hide${W}`,ya=`hidePrevented${W}`,ni=`hidden${W}`,si=`show${W}`,wa=`shown${W}`,Ca=`resize${W}`,Oa=`click.dismiss${W}`,Na=`mousedown.dismiss${W}`,Sa=`keydown.dismiss${W}`,Da=`click${W}${ba}`,zn="modal-open",La="fade",Gn="show",Me="modal-static",$a=".modal.show",Ia=".modal-dialog",Pa=".modal-body",xa='[data-bs-toggle="modal"]',Ma={backdrop:!0,focus:!0,keyboard:!0},Ra={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class mt extends K{constructor(t,e){super(t,e),this._dialog=h.findOne(Ia,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new Xe,this._addEventListeners()}static get Default(){return Ma}static get DefaultType(){return Ra}static get NAME(){return Ea}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||l.trigger(this._element,si,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(zn),this._adjustDialog(),this._backdrop.show(()=>this._showElement(t)))}hide(){!this._isShown||this._isTransitioning||l.trigger(this._element,Ta).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Gn),this._queueCallback(()=>this._hideModal(),this._element,this._isAnimated()))}dispose(){l.off(window,W),l.off(this._dialog,W),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new ti({isVisible:!!this._config.backdrop,isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new ei({trapElement:this._element})}_showElement(t){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const e=h.findOne(Pa,this._dialog);e&&(e.scrollTop=0),Yt(this._element),this._element.classList.add(Gn);const s=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,l.trigger(this._element,wa,{relatedTarget:t})};this._queueCallback(s,this._dialog,this._isAnimated())}_addEventListeners(){l.on(this._element,Sa,t=>{if(t.key===Aa){if(this._config.keyboard){this.hide();return}this._triggerBackdropTransition()}}),l.on(window,Ca,()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()}),l.on(this._element,Na,t=>{l.one(this._element,Oa,e=>{if(!(this._element!==t.target||this._element!==e.target)){if(this._config.backdrop==="static"){this._triggerBackdropTransition();return}this._config.backdrop&&this.hide()}})})}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove(zn),this._resetAdjustments(),this._scrollBar.reset(),l.trigger(this._element,ni)})}_isAnimated(){return this._element.classList.contains(La)}_triggerBackdropTransition(){if(l.trigger(this._element,ya).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,s=this._element.style.overflowY;s==="hidden"||this._element.classList.contains(Me)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(Me),this._queueCallback(()=>{this._element.classList.remove(Me),this._queueCallback(()=>{this._element.style.overflowY=s},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),s=e>0;if(s&&!t){const i=H()?"paddingLeft":"paddingRight";this._element.style[i]=`${e}px`}if(!s&&t){const i=H()?"paddingRight":"paddingLeft";this._element.style[i]=`${e}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each(function(){const s=mt.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof s[t]>"u")throw new TypeError(`No method named "${t}"`);s[t](e)}})}}l.on(document,Da,xa,function(n){const t=h.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&n.preventDefault(),l.one(t,si,i=>{i.defaultPrevented||l.one(t,ni,()=>{Pt(this)&&this.focus()})});const e=h.findOne($a);e&&mt.getInstance(e).hide(),mt.getOrCreateInstance(t).toggle(this)});ge(mt);B(mt);const ka="offcanvas",Va="bs.offcanvas",Q=`.${Va}`,ii=".data-api",Ha=`load${Q}${ii}`,Wa="Escape",qn="show",Xn="showing",Qn="hiding",Ba="offcanvas-backdrop",ri=".offcanvas.show",ja=`show${Q}`,Fa=`shown${Q}`,Ka=`hide${Q}`,Jn=`hidePrevented${Q}`,oi=`hidden${Q}`,Ya=`resize${Q}`,Ua=`click${Q}${ii}`,za=`keydown.dismiss${Q}`,Ga='[data-bs-toggle="offcanvas"]',qa={backdrop:!0,keyboard:!0,scroll:!1},Xa={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class nt extends K{constructor(t,e){super(t,e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return qa}static get DefaultType(){return Xa}static get NAME(){return ka}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){if(this._isShown||l.trigger(this._element,ja,{relatedTarget:t}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||new Xe().hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Xn);const s=()=>{(!this._config.scroll||this._config.backdrop)&&this._focustrap.activate(),this._element.classList.add(qn),this._element.classList.remove(Xn),l.trigger(this._element,Fa,{relatedTarget:t})};this._queueCallback(s,this._element,!0)}hide(){if(!this._isShown||l.trigger(this._element,Ka).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Qn),this._backdrop.hide();const e=()=>{this._element.classList.remove(qn,Qn),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||new Xe().reset(),l.trigger(this._element,oi)};this._queueCallback(e,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const t=()=>{if(this._config.backdrop==="static"){l.trigger(this._element,Jn);return}this.hide()},e=!!this._config.backdrop;return new ti({className:Ba,isVisible:e,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:e?t:null})}_initializeFocusTrap(){return new ei({trapElement:this._element})}_addEventListeners(){l.on(this._element,za,t=>{if(t.key===Wa){if(this._config.keyboard){this.hide();return}l.trigger(this._element,Jn)}})}static jQueryInterface(t){return this.each(function(){const e=nt.getOrCreateInstance(this,t);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}l.on(document,Ua,Ga,function(n){const t=h.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&n.preventDefault(),et(this))return;l.one(t,oi,()=>{Pt(this)&&this.focus()});const e=h.findOne(ri);e&&e!==t&&nt.getInstance(e).hide(),nt.getOrCreateInstance(t).toggle(this)});l.on(window,Ha,()=>{for(const n of h.find(ri))nt.getOrCreateInstance(n).show()});l.on(window,Ya,()=>{for(const n of h.find("[aria-modal][class*=show][class*=offcanvas-]"))getComputedStyle(n).position!=="fixed"&&nt.getOrCreateInstance(n).hide()});ge(nt);B(nt);const Qa=/^aria-[\w-]*$/i,ai={"*":["class","dir","id","lang","role",Qa],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],dd:[],div:[],dl:[],dt:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},Ja=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Za=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,tl=(n,t)=>{const e=n.nodeName.toLowerCase();return t.includes(e)?Ja.has(e)?!!Za.test(n.nodeValue):!0:t.filter(s=>s instanceof RegExp).some(s=>s.test(e))};function el(n,t,e){if(!n.length)return n;if(e&&typeof e=="function")return e(n);const i=new window.DOMParser().parseFromString(n,"text/html"),r=[].concat(...i.body.querySelectorAll("*"));for(const o of r){const a=o.nodeName.toLowerCase();if(!Object.keys(t).includes(a)){o.remove();continue}const c=[].concat(...o.attributes),d=[].concat(t["*"]||[],t[a]||[]);for(const u of c)tl(u,d)||o.removeAttribute(u.nodeName)}return i.body.innerHTML}const nl="TemplateFactory",sl={allowList:ai,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},il={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},rl={entry:"(string|element|function|null)",selector:"(string|element)"};class ol extends Ut{constructor(t){super(),this._config=this._getConfig(t)}static get Default(){return sl}static get DefaultType(){return il}static get NAME(){return nl}getContent(){return Object.values(this._config.content).map(t=>this._resolvePossibleFunction(t)).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(t){return this._checkContent(t),this._config.content={...this._config.content,...t},this}toHtml(){const t=document.createElement("div");t.innerHTML=this._maybeSanitize(this._config.template);for(const[i,r]of Object.entries(this._config.content))this._setContent(t,r,i);const e=t.children[0],s=this._resolvePossibleFunction(this._config.extraClass);return s&&e.classList.add(...s.split(" ")),e}_typeCheckConfig(t){super._typeCheckConfig(t),this._checkContent(t.content)}_checkContent(t){for(const[e,s]of Object.entries(t))super._typeCheckConfig({selector:e,entry:s},rl)}_setContent(t,e,s){const i=h.findOne(s,t);if(i){if(e=this._resolvePossibleFunction(e),!e){i.remove();return}if(G(e)){this._putElementInTemplate(tt(e),i);return}if(this._config.html){i.innerHTML=this._maybeSanitize(e);return}i.textContent=e}}_maybeSanitize(t){return this._config.sanitize?el(t,this._config.allowList,this._config.sanitizeFn):t}_resolvePossibleFunction(t){return P(t,[this])}_putElementInTemplate(t,e){if(this._config.html){e.innerHTML="",e.append(t);return}e.textContent=t.textContent}}const al="tooltip",ll=new Set(["sanitize","allowList","sanitizeFn"]),Re="fade",cl="modal",ie="show",ul=".tooltip-inner",Zn=`.${cl}`,ts="hide.bs.modal",Ht="hover",ke="focus",dl="click",hl="manual",fl="hide",pl="hidden",_l="show",ml="shown",gl="inserted",El="click",vl="focusin",bl="focusout",Al="mouseenter",Tl="mouseleave",yl={AUTO:"auto",TOP:"top",RIGHT:H()?"left":"right",BOTTOM:"bottom",LEFT:H()?"right":"left"},wl={allowList:ai,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',title:"",trigger:"hover focus"},Cl={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class Mt extends K{constructor(t,e){if(typeof xs>"u")throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t,e),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return wl}static get DefaultType(){return Cl}static get NAME(){return al}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){if(this._isEnabled){if(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()){this._leave();return}this._enter()}}dispose(){clearTimeout(this._timeout),l.off(this._element.closest(Zn),ts,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if(this._element.style.display==="none")throw new Error("Please use show on visible elements");if(!(this._isWithContent()&&this._isEnabled))return;const t=l.trigger(this._element,this.constructor.eventName(_l)),s=(ks(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(t.defaultPrevented||!s)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:r}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(r.append(i),l.trigger(this._element,this.constructor.eventName(gl))),this._popper=this._createPopper(i),i.classList.add(ie),"ontouchstart"in document.documentElement)for(const a of[].concat(...document.body.children))l.on(a,"mouseover",de);const o=()=>{l.trigger(this._element,this.constructor.eventName(ml)),this._isHovered===!1&&this._leave(),this._isHovered=!1};this._queueCallback(o,this.tip,this._isAnimated())}hide(){if(!this._isShown()||l.trigger(this._element,this.constructor.eventName(fl)).defaultPrevented)return;if(this._getTipElement().classList.remove(ie),"ontouchstart"in document.documentElement)for(const i of[].concat(...document.body.children))l.off(i,"mouseover",de);this._activeTrigger[dl]=!1,this._activeTrigger[ke]=!1,this._activeTrigger[Ht]=!1,this._isHovered=null;const s=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),l.trigger(this._element,this.constructor.eventName(pl)))};this._queueCallback(s,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return!!this._getTitle()}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(t){const e=this._getTemplateFactory(t).toHtml();if(!e)return null;e.classList.remove(Re,ie),e.classList.add(`bs-${this.constructor.NAME}-auto`);const s=ur(this.constructor.NAME).toString();return e.setAttribute("id",s),this._isAnimated()&&e.classList.add(Re),e}setContent(t){this._newContent=t,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(t){return this._templateFactory?this._templateFactory.changeContent(t):this._templateFactory=new ol({...this._config,content:t,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[ul]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(t){return this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(Re)}_isShown(){return this.tip&&this.tip.classList.contains(ie)}_createPopper(t){const e=P(this._config.placement,[this,t,this._element]),s=yl[e.toUpperCase()];return un(this._element,t,this._getPopperConfig(s))}_getOffset(){const{offset:t}=this._config;return typeof t=="string"?t.split(",").map(e=>Number.parseInt(e,10)):typeof t=="function"?e=>t(e,this._element):t}_resolvePossibleFunction(t){return P(t,[this._element])}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:s=>{this._getTipElement().setAttribute("data-popper-placement",s.state.placement)}}]};return{...e,...P(this._config.popperConfig,[e])}}_setListeners(){const t=this._config.trigger.split(" ");for(const e of t)if(e==="click")l.on(this._element,this.constructor.eventName(El),this._config.selector,s=>{this._initializeOnDelegatedTarget(s).toggle()});else if(e!==hl){const s=e===Ht?this.constructor.eventName(Al):this.constructor.eventName(vl),i=e===Ht?this.constructor.eventName(Tl):this.constructor.eventName(bl);l.on(this._element,s,this._config.selector,r=>{const o=this._initializeOnDelegatedTarget(r);o._activeTrigger[r.type==="focusin"?ke:Ht]=!0,o._enter()}),l.on(this._element,i,this._config.selector,r=>{const o=this._initializeOnDelegatedTarget(r);o._activeTrigger[r.type==="focusout"?ke:Ht]=o._element.contains(r.relatedTarget),o._leave()})}this._hideModalHandler=()=>{this._element&&this.hide()},l.on(this._element.closest(Zn),ts,this._hideModalHandler)}_fixTitle(){const t=this._element.getAttribute("title");t&&(!this._element.getAttribute("aria-label")&&!this._element.textContent.trim()&&this._element.setAttribute("aria-label",t),this._element.setAttribute("data-bs-original-title",t),this._element.removeAttribute("title"))}_enter(){if(this._isShown()||this._isHovered){this._isHovered=!0;return}this._isHovered=!0,this._setTimeout(()=>{this._isHovered&&this.show()},this._config.delay.show)}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout(()=>{this._isHovered||this.hide()},this._config.delay.hide))}_setTimeout(t,e){clearTimeout(this._timeout),this._timeout=setTimeout(t,e)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(t){const e=q.getDataAttributes(this._element);for(const s of Object.keys(e))ll.has(s)&&delete e[s];return t={...e,...typeof t=="object"&&t?t:{}},t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t.container=t.container===!1?document.body:tt(t.container),typeof t.delay=="number"&&(t.delay={show:t.delay,hide:t.delay}),typeof t.title=="number"&&(t.title=t.title.toString()),typeof t.content=="number"&&(t.content=t.content.toString()),t}_getDelegateConfig(){const t={};for(const[e,s]of Object.entries(this._config))this.constructor.Default[e]!==s&&(t[e]=s);return t.selector=!1,t.trigger="manual",t}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(t){return this.each(function(){const e=Mt.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}}B(Mt);const Ol="popover",Nl=".popover-header",Sl=".popover-body",Dl={...Mt.Default,content:"",offset:[0,8],placement:"right",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',trigger:"click"},Ll={...Mt.DefaultType,content:"(null|string|element|function)"};class pn extends Mt{static get Default(){return Dl}static get DefaultType(){return Ll}static get NAME(){return Ol}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[Nl]:this._getTitle(),[Sl]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(t){return this.each(function(){const e=pn.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t]()}})}}B(pn);const $l="scrollspy",Il="bs.scrollspy",_n=`.${Il}`,Pl=".data-api",xl=`activate${_n}`,es=`click${_n}`,Ml=`load${_n}${Pl}`,Rl="dropdown-item",At="active",kl='[data-bs-spy="scroll"]',Ve="[href]",Vl=".nav, .list-group",ns=".nav-link",Hl=".nav-item",Wl=".list-group-item",Bl=`${ns}, ${Hl} > ${ns}, ${Wl}`,jl=".dropdown",Fl=".dropdown-toggle",Kl={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Yl={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class be extends K{constructor(t,e){super(t,e),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement=getComputedStyle(this._element).overflowY==="visible"?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return Kl}static get DefaultType(){return Yl}static get NAME(){return $l}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const t of this._observableSections.values())this._observer.observe(t)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(t){return t.target=tt(t.target)||document.body,t.rootMargin=t.offset?`${t.offset}px 0px -30%`:t.rootMargin,typeof t.threshold=="string"&&(t.threshold=t.threshold.split(",").map(e=>Number.parseFloat(e))),t}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(l.off(this._config.target,es),l.on(this._config.target,es,Ve,t=>{const e=this._observableSections.get(t.target.hash);if(e){t.preventDefault();const s=this._rootElement||window,i=e.offsetTop-this._element.offsetTop;if(s.scrollTo){s.scrollTo({top:i,behavior:"smooth"});return}s.scrollTop=i}}))}_getNewObserver(){const t={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver(e=>this._observerCallback(e),t)}_observerCallback(t){const e=o=>this._targetLinks.get(`#${o.target.id}`),s=o=>{this._previousScrollData.visibleEntryTop=o.target.offsetTop,this._process(e(o))},i=(this._rootElement||document.documentElement).scrollTop,r=i>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=i;for(const o of t){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(e(o));continue}const a=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(r&&a){if(s(o),!i)return;continue}!r&&!a&&s(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const t=h.find(Ve,this._config.target);for(const e of t){if(!e.hash||et(e))continue;const s=h.findOne(decodeURI(e.hash),this._element);Pt(s)&&(this._targetLinks.set(decodeURI(e.hash),e),this._observableSections.set(e.hash,s))}}_process(t){this._activeTarget!==t&&(this._clearActiveClass(this._config.target),this._activeTarget=t,t.classList.add(At),this._activateParents(t),l.trigger(this._element,xl,{relatedTarget:t}))}_activateParents(t){if(t.classList.contains(Rl)){h.findOne(Fl,t.closest(jl)).classList.add(At);return}for(const e of h.parents(t,Vl))for(const s of h.prev(e,Bl))s.classList.add(At)}_clearActiveClass(t){t.classList.remove(At);const e=h.find(`${Ve}.${At}`,t);for(const s of e)s.classList.remove(At)}static jQueryInterface(t){return this.each(function(){const e=be.getOrCreateInstance(this,t);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}l.on(window,Ml,()=>{for(const n of h.find(kl))be.getOrCreateInstance(n)});B(be);const Ul="tab",zl="bs.tab",Et=`.${zl}`,Gl=`hide${Et}`,ql=`hidden${Et}`,Xl=`show${Et}`,Ql=`shown${Et}`,Jl=`click${Et}`,Zl=`keydown${Et}`,tc=`load${Et}`,ec="ArrowLeft",ss="ArrowRight",nc="ArrowUp",is="ArrowDown",He="Home",rs="End",ht="active",os="fade",We="show",sc="dropdown",li=".dropdown-toggle",ic=".dropdown-menu",Be=`:not(${li})`,rc='.list-group, .nav, [role="tablist"]',oc=".nav-item, .list-group-item",ac=`.nav-link${Be}, .list-group-item${Be}, [role="tab"]${Be}`,ci='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',je=`${ac}, ${ci}`,lc=`.${ht}[data-bs-toggle="tab"], .${ht}[data-bs-toggle="pill"], .${ht}[data-bs-toggle="list"]`;class $t extends K{constructor(t){super(t),this._parent=this._element.closest(rc),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),l.on(this._element,Zl,e=>this._keydown(e)))}static get NAME(){return Ul}show(){const t=this._element;if(this._elemIsActive(t))return;const e=this._getActiveElem(),s=e?l.trigger(e,Gl,{relatedTarget:t}):null;l.trigger(t,Xl,{relatedTarget:e}).defaultPrevented||s&&s.defaultPrevented||(this._deactivate(e,t),this._activate(t,e))}_activate(t,e){if(!t)return;t.classList.add(ht),this._activate(h.getElementFromSelector(t));const s=()=>{if(t.getAttribute("role")!=="tab"){t.classList.add(We);return}t.removeAttribute("tabindex"),t.setAttribute("aria-selected",!0),this._toggleDropDown(t,!0),l.trigger(t,Ql,{relatedTarget:e})};this._queueCallback(s,t,t.classList.contains(os))}_deactivate(t,e){if(!t)return;t.classList.remove(ht),t.blur(),this._deactivate(h.getElementFromSelector(t));const s=()=>{if(t.getAttribute("role")!=="tab"){t.classList.remove(We);return}t.setAttribute("aria-selected",!1),t.setAttribute("tabindex","-1"),this._toggleDropDown(t,!1),l.trigger(t,ql,{relatedTarget:e})};this._queueCallback(s,t,t.classList.contains(os))}_keydown(t){if(![ec,ss,nc,is,He,rs].includes(t.key))return;t.stopPropagation(),t.preventDefault();const e=this._getChildren().filter(i=>!et(i));let s;if([He,rs].includes(t.key))s=e[t.key===He?0:e.length-1];else{const i=[ss,is].includes(t.key);s=dn(e,t.target,i,!0)}s&&(s.focus({preventScroll:!0}),$t.getOrCreateInstance(s).show())}_getChildren(){return h.find(je,this._parent)}_getActiveElem(){return this._getChildren().find(t=>this._elemIsActive(t))||null}_setInitialAttributes(t,e){this._setAttributeIfNotExists(t,"role","tablist");for(const s of e)this._setInitialAttributesOnChild(s)}_setInitialAttributesOnChild(t){t=this._getInnerElement(t);const e=this._elemIsActive(t),s=this._getOuterElement(t);t.setAttribute("aria-selected",e),s!==t&&this._setAttributeIfNotExists(s,"role","presentation"),e||t.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(t,"role","tab"),this._setInitialAttributesOnTargetPanel(t)}_setInitialAttributesOnTargetPanel(t){const e=h.getElementFromSelector(t);e&&(this._setAttributeIfNotExists(e,"role","tabpanel"),t.id&&this._setAttributeIfNotExists(e,"aria-labelledby",`${t.id}`))}_toggleDropDown(t,e){const s=this._getOuterElement(t);if(!s.classList.contains(sc))return;const i=(r,o)=>{const a=h.findOne(r,s);a&&a.classList.toggle(o,e)};i(li,ht),i(ic,We),s.setAttribute("aria-expanded",e)}_setAttributeIfNotExists(t,e,s){t.hasAttribute(e)||t.setAttribute(e,s)}_elemIsActive(t){return t.classList.contains(ht)}_getInnerElement(t){return t.matches(je)?t:h.findOne(je,t)}_getOuterElement(t){return t.closest(oc)||t}static jQueryInterface(t){return this.each(function(){const e=$t.getOrCreateInstance(this);if(typeof t=="string"){if(e[t]===void 0||t.startsWith("_")||t==="constructor")throw new TypeError(`No method named "${t}"`);e[t]()}})}}l.on(document,Jl,ci,function(n){["A","AREA"].includes(this.tagName)&&n.preventDefault(),!et(this)&&$t.getOrCreateInstance(this).show()});l.on(window,tc,()=>{for(const n of h.find(lc))$t.getOrCreateInstance(n)});B($t);const cc="toast",uc="bs.toast",rt=`.${uc}`,dc=`mouseover${rt}`,hc=`mouseout${rt}`,fc=`focusin${rt}`,pc=`focusout${rt}`,_c=`hide${rt}`,mc=`hidden${rt}`,gc=`show${rt}`,Ec=`shown${rt}`,vc="fade",as="hide",re="show",oe="showing",bc={animation:"boolean",autohide:"boolean",delay:"number"},Ac={animation:!0,autohide:!0,delay:5e3};class Ae extends K{constructor(t,e){super(t,e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return Ac}static get DefaultType(){return bc}static get NAME(){return cc}show(){if(l.trigger(this._element,gc).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(vc);const e=()=>{this._element.classList.remove(oe),l.trigger(this._element,Ec),this._maybeScheduleHide()};this._element.classList.remove(as),Yt(this._element),this._element.classList.add(re,oe),this._queueCallback(e,this._element,this._config.animation)}hide(){if(!this.isShown()||l.trigger(this._element,_c).defaultPrevented)return;const e=()=>{this._element.classList.add(as),this._element.classList.remove(oe,re),l.trigger(this._element,mc)};this._element.classList.add(oe),this._queueCallback(e,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(re),super.dispose()}isShown(){return this._element.classList.contains(re)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":{this._hasMouseInteraction=e;break}case"focusin":case"focusout":{this._hasKeyboardInteraction=e;break}}if(e){this._clearTimeout();return}const s=t.relatedTarget;this._element===s||this._element.contains(s)||this._maybeScheduleHide()}_setListeners(){l.on(this._element,dc,t=>this._onInteraction(t,!0)),l.on(this._element,hc,t=>this._onInteraction(t,!1)),l.on(this._element,fc,t=>this._onInteraction(t,!0)),l.on(this._element,pc,t=>this._onInteraction(t,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each(function(){const e=Ae.getOrCreateInstance(this,t);if(typeof t=="string"){if(typeof e[t]>"u")throw new TypeError(`No method named "${t}"`);e[t](this)}})}}ge(Ae);B(Ae);const Tc=()=>{const n=document.createElement("div");return n.classList.add("modal"),n.setAttribute("tabindex",-1),n},jt=n=>{const t=document.createElement("div");return t.classList.add(n),t},ui=n=>{const t=document.createElement("button");return t.setAttribute("type","button"),t.addEventListener("click",()=>n()),t},yc=(n,t)=>{const e=jt("modal-header"),s=document.createElement("h5");s.innerText=n,e.appendChild(s);const i=ui(t);return i.classList.add("btn-close"),e.appendChild(i),e},wc=(n,t,e)=>{const s=jt("modal-footer"),i=document.createElement("button");i.classList.add("btn","btn-primary"),i.setAttribute("type","button"),i.innerText=n,i.addEventListener("click",()=>t()),s.appendChild(i);const r=ui(e);return r.classList.add("btn","btn-secondary"),r.innerText="Отмена",s.appendChild(r),s},Cc=(n,t,e,s,i)=>{const r=Tc(),o=jt("modal-dialog"),a=jt("modal-content"),c=yc(n,i);a.appendChild(c);const d=jt("modal-body");d.appendChild(e),a.appendChild(d);const u=wc(t,s,i);return a.appendChild(u),o.appendChild(a),r.appendChild(o),r},Oc=(n,t,e)=>{const s=document.createElement("p");return s.innerText=e,new Promise(i=>{let r;const c=Cc(n,t,s,()=>{r.hide(),i(!0)},()=>{r.hide(),i(!1)});r=new mt(c),r.show()})},ls=n=>{const t=document.createElement("i");return t.classList.add("bi",`bi-${n}`),t},Nc=(n,t,e="primary")=>{const s=document.createElement("button");return s.classList.add("btn",`btn-${e}`),s.setAttribute("type","button"),ls&&s.appendChild(ls(t)),s},Sc=(n,t)=>Nc(null,n,t),Dc=(n,t)=>{const e=t.split(".");let s=n;for(const i of e){if(!s)break;s=s[i]}return s||""},Lc=n=>{const t=document.createElement("th");return t.setAttribute("scope","col"),t.innerText=n,t},$c=n=>{if(!n||!Array.isArray(n)||n.length===0)throw new Error("Columns are not defined");const t=document.createElement("thead"),e=document.createElement("tr");return n.forEach(s=>e.appendChild(Lc(s))),t.appendChild(e),t},cs=n=>{const t=document.createElement("td");return t.innerText=n,t},Fe=(n,t,e,s)=>{const i=Sc(t,e);i.addEventListener("click",()=>s(n));const r=document.createElement("td");return r.appendChild(i),r},Ic=(n,t,e)=>{const s=document.createElement("tr");if(e!=null&&e.star){const i=n.star?"star-fill":"star";s.appendChild(Fe(n,i,"null",e.star))}return!t||!Array.isArray(t)?Object.values(n).forEach(i=>s.appendChild(cs(i))):t.forEach(i=>s.appendChild(cs(Dc(n,i)))),e&&(e.edit&&s.appendChild(Fe(n,"pencil-fill","warning",e.edit)),e.delete&&s.appendChild(Fe(n,"trash-fill","danger",e.delete))),s},Pc=(n,t,e)=>{if(!n||!Array.isArray(n))throw new Error("Data is not defined");const s=document.createElement("tbody");return n.forEach(i=>s.appendChild(Ic(i,t,e))),s},xc=n=>{const t=document.createElement("table");return t.classList.add("table","table-hover","table-sm"),t.appendChild($c(n)),t},Mc=(n,t,e,s)=>{const i=n.querySelector("tbody");i&&n.removeChild(i),n.appendChild(Pc(t,e,s))};class Rc{constructor(t,e,s,i){this.root=t,this.toggleStarCallback=e,this.editCallback=s,this.deleteCallback=i}render(){const t=["","№","Название","Превью","Описание","Плейлист","Категория","Группа","",""];this.keys=["id","name","image","description","playlistName","categoryName"],this.callbacks={star:this.toggleStarCallback,edit:this.editCallback,delete:this.deleteCallback},this.tableElement=xc(t);const e=document.createElement("div");e.classList.add("table-responsive"),e.appendChild(this.tableElement),this.root.appendChild(e)}update(t){const e=t.data.length>0?t.data:[{id:"Нет данных",name:"",playlistName:"",categoryName:""}];Mc(this.tableElement,e,this.keys,this.callbacks)}deleteQuestion(t=null){return Oc("Удаление","Удалить",`Удалить элемент '${t.id}'?`)}}class kc extends HTMLElement{constructor(){super();const t=this.toggleStar.bind(this),e=this.editVideo.bind(this),s=this.deleteVideo.bind(this);this.view=new Rc(this,t,e,s),this.model=new bi}connectedCallback(){this.view.render(),this.getAllVideos()}async getAllVideos(){await this.model.getAll(),this.view.update(this.model)}editVideo(t){window.location.href=`/pageForm?id=${t.id}`}toggleStar(t){this.model.toggleStar(t),this.view.update(this.model)}async deleteVideo(t){await this.view.deleteQuestion(t)&&(await this.model.delete(t),this.getAllVideos())}}customElements.define("videos-table",kc);