diff --git a/assets/js/app.js b/assets/js/app.js index 6c792ed339..d7502e8dd3 100644 --- a/assets/js/app.js +++ b/assets/js/app.js @@ -32,6 +32,7 @@ class App { this.#createModalWindowsForDeleteActions(); this.#createPopovers(); this.#createTooltips(); + this.#createPaginator(); document.addEventListener('ea.collection.item-added', () => this.#createAutoCompleteFields()); } @@ -456,4 +457,18 @@ class App { }); }); } + + #createPaginator() { + document + .querySelectorAll('.list-pagination-counter select[data-ea-paginator-list-size-per-page]') + .forEach((element) => { + element.addEventListener('change', (event) => { + const url = new URL(window.location.href); + url.searchParams.set('size', event.currentTarget.value); + url.searchParams.set('page', '1'); + + window.location.replace(url.toString()); + }); + }); + } } diff --git a/public/app.09038c6d.js b/public/app.b25cfb59.js similarity index 94% rename from public/app.09038c6d.js rename to public/app.b25cfb59.js index 1281919bff..aeb3091f7a 100644 --- a/public/app.09038c6d.js +++ b/public/app.b25cfb59.js @@ -1,2 +1,2 @@ -/*! For license information please see app.09038c6d.js.LICENSE.txt */ -(()=>{var e={414:function(e){e.exports=function(){"use strict";const e=new Map,t={set(t,i,n){e.has(t)||e.set(t,new Map);const s=e.get(t);s.has(i)||0===s.size?s.set(i,n):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(t,i)=>e.has(t)&&e.get(t).get(i)||null,remove(t,i){if(!e.has(t))return;const n=e.get(t);n.delete(i),0===n.size&&e.delete(t)}},i=1e6,n=1e3,s="transitionend",o=e=>(e&&window.CSS&&window.CSS.escape&&(e=e.replace(/#([^\s"#']+)/g,((e,t)=>`#${CSS.escape(t)}`))),e),r=e=>null==e?`${e}`:Object.prototype.toString.call(e).match(/\s([a-z]+)/i)[1].toLowerCase(),a=e=>{do{e+=Math.floor(Math.random()*i)}while(document.getElementById(e));return e},l=e=>{if(!e)return 0;let{transitionDuration:t,transitionDelay:i}=window.getComputedStyle(e);const s=Number.parseFloat(t),o=Number.parseFloat(i);return s||o?(t=t.split(",")[0],i=i.split(",")[0],(Number.parseFloat(t)+Number.parseFloat(i))*n):0},c=e=>{e.dispatchEvent(new Event(s))},d=e=>!(!e||"object"!=typeof e)&&(void 0!==e.jquery&&(e=e[0]),void 0!==e.nodeType),u=e=>d(e)?e.jquery?e[0]:e:"string"==typeof e&&e.length>0?document.querySelector(o(e)):null,h=e=>{if(!d(e)||0===e.getClientRects().length)return!1;const t="visible"===getComputedStyle(e).getPropertyValue("visibility"),i=e.closest("details:not([open])");if(!i)return t;if(i!==e){const t=e.closest("summary");if(t&&t.parentNode!==i)return!1;if(null===t)return!1}return t},p=e=>!e||e.nodeType!==Node.ELEMENT_NODE||!!e.classList.contains("disabled")||(void 0!==e.disabled?e.disabled:e.hasAttribute("disabled")&&"false"!==e.getAttribute("disabled")),f=e=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){const t=e.getRootNode();return t instanceof ShadowRoot?t:null}return e instanceof ShadowRoot?e:e.parentNode?f(e.parentNode):null},g=()=>{},m=e=>{e.offsetHeight},v=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,_=[],b=e=>{"loading"===document.readyState?(_.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of _)e()})),_.push(e)):e()},y=()=>"rtl"===document.documentElement.dir,w=e=>{b((()=>{const t=v();if(t){const i=e.NAME,n=t.fn[i];t.fn[i]=e.jQueryInterface,t.fn[i].Constructor=e,t.fn[i].noConflict=()=>(t.fn[i]=n,e.jQueryInterface)}}))},O=(e,t=[],i=e)=>"function"==typeof e?e(...t):i,E=(e,t,i=!0)=>{if(!i)return void O(e);const n=5,o=l(t)+n;let r=!1;const a=({target:i})=>{i===t&&(r=!0,t.removeEventListener(s,a),O(e))};t.addEventListener(s,a),setTimeout((()=>{r||c(t)}),o)},A=(e,t,i,n)=>{const s=e.length;let o=e.indexOf(t);return-1===o?!i&&n?e[s-1]:e[0]:(o+=i?1:-1,n&&(o=(o+s)%s),e[Math.max(0,Math.min(o,s-1))])},x=/[^.]*(?=\..*)\.|.*/,S=/\..*/,C=/::\d+$/,k={};let I=1;const T={mouseenter:"mouseover",mouseleave:"mouseout"},L=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 N(e,t){return t&&`${t}::${I++}`||e.uidEvent||I++}function P(e){const t=N(e);return e.uidEvent=t,k[t]=k[t]||{},k[t]}function $(e,t){return function i(n){return B(n,{delegateTarget:e}),i.oneOff&&z.off(e,n.type,t),t.apply(e,[n])}}function D(e,t,i){return function n(s){const o=e.querySelectorAll(t);for(let{target:r}=s;r&&r!==this;r=r.parentNode)for(const a of o)if(a===r)return B(s,{delegateTarget:r}),n.oneOff&&z.off(e,s.type,t,i),i.apply(r,[s])}}function j(e,t,i=null){return Object.values(e).find((e=>e.callable===t&&e.delegationSelector===i))}function F(e,t,i){const n="string"==typeof t,s=n?i:t||i;let o=H(e);return L.has(o)||(o=e),[n,s,o]}function M(e,t,i,n,s){if("string"!=typeof t||!e)return;let[o,r,a]=F(t,i,n);if(t in T){const e=e=>function(t){if(!t.relatedTarget||t.relatedTarget!==t.delegateTarget&&!t.delegateTarget.contains(t.relatedTarget))return e.call(this,t)};r=e(r)}const l=P(e),c=l[a]||(l[a]={}),d=j(c,r,o?i:null);if(d)return void(d.oneOff=d.oneOff&&s);const u=N(r,t.replace(x,"")),h=o?D(e,i,r):$(e,r);h.delegationSelector=o?i:null,h.callable=r,h.oneOff=s,h.uidEvent=u,c[u]=h,e.addEventListener(a,h,o)}function q(e,t,i,n,s){const o=j(t[i],n,s);o&&(e.removeEventListener(i,o,Boolean(s)),delete t[i][o.uidEvent])}function R(e,t,i,n){const s=t[i]||{};for(const[o,r]of Object.entries(s))o.includes(n)&&q(e,t,i,r.callable,r.delegationSelector)}function H(e){return e=e.replace(S,""),T[e]||e}const z={on(e,t,i,n){M(e,t,i,n,!1)},one(e,t,i,n){M(e,t,i,n,!0)},off(e,t,i,n){if("string"!=typeof t||!e)return;const[s,o,r]=F(t,i,n),a=r!==t,l=P(e),c=l[r]||{},d=t.startsWith(".");if(void 0===o){if(d)for(const i of Object.keys(l))R(e,l,i,t.slice(1));for(const[i,n]of Object.entries(c)){const s=i.replace(C,"");a&&!t.includes(s)||q(e,l,r,n.callable,n.delegationSelector)}}else{if(!Object.keys(c).length)return;q(e,l,r,o,s?i:null)}},trigger(e,t,i){if("string"!=typeof t||!e)return null;const n=v();let s=null,o=!0,r=!0,a=!1;t!==H(t)&&n&&(s=n.Event(t,i),n(e).trigger(s),o=!s.isPropagationStopped(),r=!s.isImmediatePropagationStopped(),a=s.isDefaultPrevented());const l=B(new Event(t,{bubbles:o,cancelable:!0}),i);return a&&l.preventDefault(),r&&e.dispatchEvent(l),l.defaultPrevented&&s&&s.preventDefault(),l}};function B(e,t={}){for(const[i,n]of Object.entries(t))try{e[i]=n}catch(t){Object.defineProperty(e,i,{configurable:!0,get:()=>n})}return e}function V(e){if("true"===e)return!0;if("false"===e)return!1;if(e===Number(e).toString())return Number(e);if(""===e||"null"===e)return null;if("string"!=typeof e)return e;try{return JSON.parse(decodeURIComponent(e))}catch(t){return e}}function W(e){return e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`))}const K={setDataAttribute(e,t,i){e.setAttribute(`data-bs-${W(t)}`,i)},removeDataAttribute(e,t){e.removeAttribute(`data-bs-${W(t)}`)},getDataAttributes(e){if(!e)return{};const t={},i=Object.keys(e.dataset).filter((e=>e.startsWith("bs")&&!e.startsWith("bsConfig")));for(const n of i){let i=n.replace(/^bs/,"");i=i.charAt(0).toLowerCase()+i.slice(1,i.length),t[i]=V(e.dataset[n])}return t},getDataAttribute:(e,t)=>V(e.getAttribute(`data-bs-${W(t)}`))};class U{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(e){return e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e}_mergeConfigObj(e,t){const i=d(t)?K.getDataAttribute(t,"config"):{};return{...this.constructor.Default,..."object"==typeof i?i:{},...d(t)?K.getDataAttributes(t):{},..."object"==typeof e?e:{}}}_typeCheckConfig(e,t=this.constructor.DefaultType){for(const[i,n]of Object.entries(t)){const t=e[i],s=d(t)?"element":r(t);if(!new RegExp(n).test(s))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${i}" provided type "${s}" but expected type "${n}".`)}}}const Q="5.3.3";class J extends U{constructor(e,i){super(),(e=u(e))&&(this._element=e,this._config=this._getConfig(i),t.set(this._element,this.constructor.DATA_KEY,this))}dispose(){t.remove(this._element,this.constructor.DATA_KEY),z.off(this._element,this.constructor.EVENT_KEY);for(const e of Object.getOwnPropertyNames(this))this[e]=null}_queueCallback(e,t,i=!0){E(e,t,i)}_getConfig(e){return e=this._mergeConfigObj(e,this._element),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static getInstance(e){return t.get(u(e),this.DATA_KEY)}static getOrCreateInstance(e,t={}){return this.getInstance(e)||new this(e,"object"==typeof t?t:null)}static get VERSION(){return Q}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(e){return`${e}${this.EVENT_KEY}`}}const Y=e=>{let t=e.getAttribute("data-bs-target");if(!t||"#"===t){let i=e.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),t=i&&"#"!==i?i.trim():null}return t?t.split(",").map((e=>o(e))).join(","):null},X={find:(e,t=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(t,e)),findOne:(e,t=document.documentElement)=>Element.prototype.querySelector.call(t,e),children:(e,t)=>[].concat(...e.children).filter((e=>e.matches(t))),parents(e,t){const i=[];let n=e.parentNode.closest(t);for(;n;)i.push(n),n=n.parentNode.closest(t);return i},prev(e,t){let i=e.previousElementSibling;for(;i;){if(i.matches(t))return[i];i=i.previousElementSibling}return[]},next(e,t){let i=e.nextElementSibling;for(;i;){if(i.matches(t))return[i];i=i.nextElementSibling}return[]},focusableChildren(e){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((e=>`${e}:not([tabindex^="-"])`)).join(",");return this.find(t,e).filter((e=>!p(e)&&h(e)))},getSelectorFromElement(e){const t=Y(e);return t&&X.findOne(t)?t:null},getElementFromSelector(e){const t=Y(e);return t?X.findOne(t):null},getMultipleElementsFromSelector(e){const t=Y(e);return t?X.find(t):[]}},G=(e,t="hide")=>{const i=`click.dismiss${e.EVENT_KEY}`,n=e.NAME;z.on(document,i,`[data-bs-dismiss="${n}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),p(this))return;const s=X.getElementFromSelector(this)||this.closest(`.${n}`);e.getOrCreateInstance(s)[t]()}))},Z="alert",ee=".bs.alert",te=`close${ee}`,ie=`closed${ee}`,ne="fade",se="show";class oe extends J{static get NAME(){return Z}close(){if(z.trigger(this._element,te).defaultPrevented)return;this._element.classList.remove(se);const e=this._element.classList.contains(ne);this._queueCallback((()=>this._destroyElement()),this._element,e)}_destroyElement(){this._element.remove(),z.trigger(this._element,ie),this.dispose()}static jQueryInterface(e){return this.each((function(){const t=oe.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}G(oe,"close"),w(oe);const re="button",ae="active",le='[data-bs-toggle="button"]',ce="click.bs.button.data-api";class de extends J{static get NAME(){return re}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle(ae))}static jQueryInterface(e){return this.each((function(){const t=de.getOrCreateInstance(this);"toggle"===e&&t[e]()}))}}z.on(document,ce,le,(e=>{e.preventDefault();const t=e.target.closest(le);de.getOrCreateInstance(t).toggle()})),w(de);const ue="swipe",he=".bs.swipe",pe=`touchstart${he}`,fe=`touchmove${he}`,ge=`touchend${he}`,me=`pointerdown${he}`,ve=`pointerup${he}`,_e="touch",be="pen",ye="pointer-event",we=40,Oe={endCallback:null,leftCallback:null,rightCallback:null},Ee={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class Ae extends U{constructor(e,t){super(),this._element=e,e&&Ae.isSupported()&&(this._config=this._getConfig(t),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return Oe}static get DefaultType(){return Ee}static get NAME(){return ue}dispose(){z.off(this._element,he)}_start(e){this._supportPointerEvents?this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX):this._deltaX=e.touches[0].clientX}_end(e){this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX-this._deltaX),this._handleSwipe(),O(this._config.endCallback)}_move(e){this._deltaX=e.touches&&e.touches.length>1?0:e.touches[0].clientX-this._deltaX}_handleSwipe(){const e=Math.abs(this._deltaX);if(e<=we)return;const t=e/this._deltaX;this._deltaX=0,t&&O(t>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(z.on(this._element,me,(e=>this._start(e))),z.on(this._element,ve,(e=>this._end(e))),this._element.classList.add(ye)):(z.on(this._element,pe,(e=>this._start(e))),z.on(this._element,fe,(e=>this._move(e))),z.on(this._element,ge,(e=>this._end(e))))}_eventIsPointerPenTouch(e){return this._supportPointerEvents&&(e.pointerType===be||e.pointerType===_e)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const xe="carousel",Se=".bs.carousel",Ce=".data-api",ke="ArrowLeft",Ie="ArrowRight",Te=500,Le="next",Ne="prev",Pe="left",$e="right",De=`slide${Se}`,je=`slid${Se}`,Fe=`keydown${Se}`,Me=`mouseenter${Se}`,qe=`mouseleave${Se}`,Re=`dragstart${Se}`,He=`load${Se}${Ce}`,ze=`click${Se}${Ce}`,Be="carousel",Ve="active",We="slide",Ke="carousel-item-end",Ue="carousel-item-start",Qe="carousel-item-next",Je="carousel-item-prev",Ye=".active",Xe=".carousel-item",Ge=Ye+Xe,Ze=".carousel-item img",et=".carousel-indicators",tt="[data-bs-slide], [data-bs-slide-to]",it='[data-bs-ride="carousel"]',nt={[ke]:$e,[Ie]:Pe},st={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},ot={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class rt extends J{constructor(e,t){super(e,t),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=X.findOne(et,this._element),this._addEventListeners(),this._config.ride===Be&&this.cycle()}static get Default(){return st}static get DefaultType(){return ot}static get NAME(){return xe}next(){this._slide(Le)}nextWhenVisible(){!document.hidden&&h(this._element)&&this.next()}prev(){this._slide(Ne)}pause(){this._isSliding&&c(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval((()=>this.nextWhenVisible()),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?z.one(this._element,je,(()=>this.cycle())):this.cycle())}to(e){const t=this._getItems();if(e>t.length-1||e<0)return;if(this._isSliding)return void z.one(this._element,je,(()=>this.to(e)));const i=this._getItemIndex(this._getActive());if(i===e)return;const n=e>i?Le:Ne;this._slide(n,t[e])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(e){return e.defaultInterval=e.interval,e}_addEventListeners(){this._config.keyboard&&z.on(this._element,Fe,(e=>this._keydown(e))),"hover"===this._config.pause&&(z.on(this._element,Me,(()=>this.pause())),z.on(this._element,qe,(()=>this._maybeEnableCycle()))),this._config.touch&&Ae.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const e of X.find(Ze,this._element))z.on(e,Re,(e=>e.preventDefault()));const e={leftCallback:()=>this._slide(this._directionToOrder(Pe)),rightCallback:()=>this._slide(this._directionToOrder($e)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),Te+this._config.interval))}};this._swipeHelper=new Ae(this._element,e)}_keydown(e){if(/input|textarea/i.test(e.target.tagName))return;const t=nt[e.key];t&&(e.preventDefault(),this._slide(this._directionToOrder(t)))}_getItemIndex(e){return this._getItems().indexOf(e)}_setActiveIndicatorElement(e){if(!this._indicatorsElement)return;const t=X.findOne(Ye,this._indicatorsElement);t.classList.remove(Ve),t.removeAttribute("aria-current");const i=X.findOne(`[data-bs-slide-to="${e}"]`,this._indicatorsElement);i&&(i.classList.add(Ve),i.setAttribute("aria-current","true"))}_updateInterval(){const e=this._activeElement||this._getActive();if(!e)return;const t=Number.parseInt(e.getAttribute("data-bs-interval"),10);this._config.interval=t||this._config.defaultInterval}_slide(e,t=null){if(this._isSliding)return;const i=this._getActive(),n=e===Le,s=t||A(this._getItems(),i,n,this._config.wrap);if(s===i)return;const o=this._getItemIndex(s),r=t=>z.trigger(this._element,t,{relatedTarget:s,direction:this._orderToDirection(e),from:this._getItemIndex(i),to:o});if(r(De).defaultPrevented)return;if(!i||!s)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=s;const l=n?Ue:Ke,c=n?Qe:Je;s.classList.add(c),m(s),i.classList.add(l),s.classList.add(l);const d=()=>{s.classList.remove(l,c),s.classList.add(Ve),i.classList.remove(Ve,c,l),this._isSliding=!1,r(je)};this._queueCallback(d,i,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains(We)}_getActive(){return X.findOne(Ge,this._element)}_getItems(){return X.find(Xe,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(e){return y()?e===Pe?Ne:Le:e===Pe?Le:Ne}_orderToDirection(e){return y()?e===Ne?Pe:$e:e===Ne?$e:Pe}static jQueryInterface(e){return this.each((function(){const t=rt.getOrCreateInstance(this,e);if("number"!=typeof e){if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}else t.to(e)}))}}z.on(document,ze,tt,(function(e){const t=X.getElementFromSelector(this);if(!t||!t.classList.contains(Be))return;e.preventDefault();const i=rt.getOrCreateInstance(t),n=this.getAttribute("data-bs-slide-to");return n?(i.to(n),void i._maybeEnableCycle()):"next"===K.getDataAttribute(this,"slide")?(i.next(),void i._maybeEnableCycle()):(i.prev(),void i._maybeEnableCycle())})),z.on(window,He,(()=>{const e=X.find(it);for(const t of e)rt.getOrCreateInstance(t)})),w(rt);const at="collapse",lt=".bs.collapse",ct=`show${lt}`,dt=`shown${lt}`,ut=`hide${lt}`,ht=`hidden${lt}`,pt=`click${lt}.data-api`,ft="show",gt="collapse",mt="collapsing",vt="collapsed",_t=`:scope .${gt} .${gt}`,bt="collapse-horizontal",yt="width",wt="height",Ot=".collapse.show, .collapse.collapsing",Et='[data-bs-toggle="collapse"]',At={parent:null,toggle:!0},xt={parent:"(null|element)",toggle:"boolean"};class St extends J{constructor(e,t){super(e,t),this._isTransitioning=!1,this._triggerArray=[];const i=X.find(Et);for(const e of i){const t=X.getSelectorFromElement(e),i=X.find(t).filter((e=>e===this._element));null!==t&&i.length&&this._triggerArray.push(e)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return At}static get DefaultType(){return xt}static get NAME(){return at}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let e=[];if(this._config.parent&&(e=this._getFirstLevelChildren(Ot).filter((e=>e!==this._element)).map((e=>St.getOrCreateInstance(e,{toggle:!1})))),e.length&&e[0]._isTransitioning)return;if(z.trigger(this._element,ct).defaultPrevented)return;for(const t of e)t.hide();const t=this._getDimension();this._element.classList.remove(gt),this._element.classList.add(mt),this._element.style[t]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=()=>{this._isTransitioning=!1,this._element.classList.remove(mt),this._element.classList.add(gt,ft),this._element.style[t]="",z.trigger(this._element,dt)},n=`scroll${t[0].toUpperCase()+t.slice(1)}`;this._queueCallback(i,this._element,!0),this._element.style[t]=`${this._element[n]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(z.trigger(this._element,ut).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,m(this._element),this._element.classList.add(mt),this._element.classList.remove(gt,ft);for(const e of this._triggerArray){const t=X.getElementFromSelector(e);t&&!this._isShown(t)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0;const t=()=>{this._isTransitioning=!1,this._element.classList.remove(mt),this._element.classList.add(gt),z.trigger(this._element,ht)};this._element.style[e]="",this._queueCallback(t,this._element,!0)}_isShown(e=this._element){return e.classList.contains(ft)}_configAfterMerge(e){return e.toggle=Boolean(e.toggle),e.parent=u(e.parent),e}_getDimension(){return this._element.classList.contains(bt)?yt:wt}_initializeChildren(){if(!this._config.parent)return;const e=this._getFirstLevelChildren(Et);for(const t of e){const e=X.getElementFromSelector(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}}_getFirstLevelChildren(e){const t=X.find(_t,this._config.parent);return X.find(e,this._config.parent).filter((e=>!t.includes(e)))}_addAriaAndCollapsedClass(e,t){if(e.length)for(const i of e)i.classList.toggle(vt,!t),i.setAttribute("aria-expanded",t)}static jQueryInterface(e){const t={};return"string"==typeof e&&/show|hide/.test(e)&&(t.toggle=!1),this.each((function(){const i=St.getOrCreateInstance(this,t);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}))}}z.on(document,pt,Et,(function(e){("A"===e.target.tagName||e.delegateTarget&&"A"===e.delegateTarget.tagName)&&e.preventDefault();for(const e of X.getMultipleElementsFromSelector(this))St.getOrCreateInstance(e,{toggle:!1}).toggle()})),w(St);var Ct="top",kt="bottom",It="right",Tt="left",Lt="auto",Nt=[Ct,kt,It,Tt],Pt="start",$t="end",Dt="clippingParents",jt="viewport",Ft="popper",Mt="reference",qt=Nt.reduce((function(e,t){return e.concat([t+"-"+Pt,t+"-"+$t])}),[]),Rt=[].concat(Nt,[Lt]).reduce((function(e,t){return e.concat([t,t+"-"+Pt,t+"-"+$t])}),[]),Ht="beforeRead",zt="read",Bt="afterRead",Vt="beforeMain",Wt="main",Kt="afterMain",Ut="beforeWrite",Qt="write",Jt="afterWrite",Yt=[Ht,zt,Bt,Vt,Wt,Kt,Ut,Qt,Jt];function Xt(e){return e?(e.nodeName||"").toLowerCase():null}function Gt(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Zt(e){return e instanceof Gt(e).Element||e instanceof Element}function ei(e){return e instanceof Gt(e).HTMLElement||e instanceof HTMLElement}function ti(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Gt(e).ShadowRoot||e instanceof ShadowRoot)}function ii(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var i=t.styles[e]||{},n=t.attributes[e]||{},s=t.elements[e];ei(s)&&Xt(s)&&(Object.assign(s.style,i),Object.keys(n).forEach((function(e){var t=n[e];!1===t?s.removeAttribute(e):s.setAttribute(e,!0===t?"":t)})))}))}function ni(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],s=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce((function(e,t){return e[t]="",e}),{});ei(n)&&Xt(n)&&(Object.assign(n.style,o),Object.keys(s).forEach((function(e){n.removeAttribute(e)})))}))}}const si={name:"applyStyles",enabled:!0,phase:"write",fn:ii,effect:ni,requires:["computeStyles"]};function oi(e){return e.split("-")[0]}var ri=Math.max,ai=Math.min,li=Math.round;function ci(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function di(){return!/^((?!chrome|android).)*safari/i.test(ci())}function ui(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);var n=e.getBoundingClientRect(),s=1,o=1;t&&ei(e)&&(s=e.offsetWidth>0&&li(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&li(n.height)/e.offsetHeight||1);var r=(Zt(e)?Gt(e):window).visualViewport,a=!di()&&i,l=(n.left+(a&&r?r.offsetLeft:0))/s,c=(n.top+(a&&r?r.offsetTop:0))/o,d=n.width/s,u=n.height/o;return{width:d,height:u,top:c,right:l+d,bottom:c+u,left:l,x:l,y:c}}function hi(e){var t=ui(e),i=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-i)<=1&&(i=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:n}}function pi(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&ti(i)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function fi(e){return Gt(e).getComputedStyle(e)}function gi(e){return["table","td","th"].indexOf(Xt(e))>=0}function mi(e){return((Zt(e)?e.ownerDocument:e.document)||window.document).documentElement}function vi(e){return"html"===Xt(e)?e:e.assignedSlot||e.parentNode||(ti(e)?e.host:null)||mi(e)}function _i(e){return ei(e)&&"fixed"!==fi(e).position?e.offsetParent:null}function bi(e){var t=/firefox/i.test(ci());if(/Trident/i.test(ci())&&ei(e)&&"fixed"===fi(e).position)return null;var i=vi(e);for(ti(i)&&(i=i.host);ei(i)&&["html","body"].indexOf(Xt(i))<0;){var n=fi(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}function yi(e){for(var t=Gt(e),i=_i(e);i&&gi(i)&&"static"===fi(i).position;)i=_i(i);return i&&("html"===Xt(i)||"body"===Xt(i)&&"static"===fi(i).position)?t:i||bi(e)||t}function wi(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Oi(e,t,i){return ri(e,ai(t,i))}function Ei(e,t,i){var n=Oi(e,t,i);return n>i?i:n}function Ai(){return{top:0,right:0,bottom:0,left:0}}function xi(e){return Object.assign({},Ai(),e)}function Si(e,t){return t.reduce((function(t,i){return t[i]=e,t}),{})}var Ci=function(e,t){return xi("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:Si(e,Nt))};function ki(e){var t,i=e.state,n=e.name,s=e.options,o=i.elements.arrow,r=i.modifiersData.popperOffsets,a=oi(i.placement),l=wi(a),c=[Tt,It].indexOf(a)>=0?"height":"width";if(o&&r){var d=Ci(s.padding,i),u=hi(o),h="y"===l?Ct:Tt,p="y"===l?kt:It,f=i.rects.reference[c]+i.rects.reference[l]-r[l]-i.rects.popper[c],g=r[l]-i.rects.reference[l],m=yi(o),v=m?"y"===l?m.clientHeight||0:m.clientWidth||0:0,_=f/2-g/2,b=d[h],y=v-u[c]-d[p],w=v/2-u[c]/2+_,O=Oi(b,w,y),E=l;i.modifiersData[n]=((t={})[E]=O,t.centerOffset=O-w,t)}}function Ii(e){var t=e.state,i=e.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&pi(t.elements.popper,n)&&(t.elements.arrow=n)}const Ti={name:"arrow",enabled:!0,phase:"main",fn:ki,effect:Ii,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Li(e){return e.split("-")[1]}var Ni={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Pi(e,t){var i=e.x,n=e.y,s=t.devicePixelRatio||1;return{x:li(i*s)/s||0,y:li(n*s)/s||0}}function $i(e){var t,i=e.popper,n=e.popperRect,s=e.placement,o=e.variation,r=e.offsets,a=e.position,l=e.gpuAcceleration,c=e.adaptive,d=e.roundOffsets,u=e.isFixed,h=r.x,p=void 0===h?0:h,f=r.y,g=void 0===f?0:f,m="function"==typeof d?d({x:p,y:g}):{x:p,y:g};p=m.x,g=m.y;var v=r.hasOwnProperty("x"),_=r.hasOwnProperty("y"),b=Tt,y=Ct,w=window;if(c){var O=yi(i),E="clientHeight",A="clientWidth";O===Gt(i)&&"static"!==fi(O=mi(i)).position&&"absolute"===a&&(E="scrollHeight",A="scrollWidth"),(s===Ct||(s===Tt||s===It)&&o===$t)&&(y=kt,g-=(u&&O===w&&w.visualViewport?w.visualViewport.height:O[E])-n.height,g*=l?1:-1),s!==Tt&&(s!==Ct&&s!==kt||o!==$t)||(b=It,p-=(u&&O===w&&w.visualViewport?w.visualViewport.width:O[A])-n.width,p*=l?1:-1)}var x,S=Object.assign({position:a},c&&Ni),C=!0===d?Pi({x:p,y:g},Gt(i)):{x:p,y:g};return p=C.x,g=C.y,l?Object.assign({},S,((x={})[y]=_?"0":"",x[b]=v?"0":"",x.transform=(w.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",x)):Object.assign({},S,((t={})[y]=_?g+"px":"",t[b]=v?p+"px":"",t.transform="",t))}function Di(e){var t=e.state,i=e.options,n=i.gpuAcceleration,s=void 0===n||n,o=i.adaptive,r=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:oi(t.placement),variation:Li(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,$i(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:r,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,$i(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const ji={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Di,data:{}};var Fi={passive:!0};function Mi(e){var t=e.state,i=e.instance,n=e.options,s=n.scroll,o=void 0===s||s,r=n.resize,a=void 0===r||r,l=Gt(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach((function(e){e.addEventListener("scroll",i.update,Fi)})),a&&l.addEventListener("resize",i.update,Fi),function(){o&&c.forEach((function(e){e.removeEventListener("scroll",i.update,Fi)})),a&&l.removeEventListener("resize",i.update,Fi)}}const qi={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Mi,data:{}};var Ri={left:"right",right:"left",bottom:"top",top:"bottom"};function Hi(e){return e.replace(/left|right|bottom|top/g,(function(e){return Ri[e]}))}var zi={start:"end",end:"start"};function Bi(e){return e.replace(/start|end/g,(function(e){return zi[e]}))}function Vi(e){var t=Gt(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Wi(e){return ui(mi(e)).left+Vi(e).scrollLeft}function Ki(e,t){var i=Gt(e),n=mi(e),s=i.visualViewport,o=n.clientWidth,r=n.clientHeight,a=0,l=0;if(s){o=s.width,r=s.height;var c=di();(c||!c&&"fixed"===t)&&(a=s.offsetLeft,l=s.offsetTop)}return{width:o,height:r,x:a+Wi(e),y:l}}function Ui(e){var t,i=mi(e),n=Vi(e),s=null==(t=e.ownerDocument)?void 0:t.body,o=ri(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),r=ri(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-n.scrollLeft+Wi(e),l=-n.scrollTop;return"rtl"===fi(s||i).direction&&(a+=ri(i.clientWidth,s?s.clientWidth:0)-o),{width:o,height:r,x:a,y:l}}function Qi(e){var t=fi(e),i=t.overflow,n=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function Ji(e){return["html","body","#document"].indexOf(Xt(e))>=0?e.ownerDocument.body:ei(e)&&Qi(e)?e:Ji(vi(e))}function Yi(e,t){var i;void 0===t&&(t=[]);var n=Ji(e),s=n===(null==(i=e.ownerDocument)?void 0:i.body),o=Gt(n),r=s?[o].concat(o.visualViewport||[],Qi(n)?n:[]):n,a=t.concat(r);return s?a:a.concat(Yi(vi(r)))}function Xi(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Gi(e,t){var i=ui(e,!1,"fixed"===t);return i.top=i.top+e.clientTop,i.left=i.left+e.clientLeft,i.bottom=i.top+e.clientHeight,i.right=i.left+e.clientWidth,i.width=e.clientWidth,i.height=e.clientHeight,i.x=i.left,i.y=i.top,i}function Zi(e,t,i){return t===jt?Xi(Ki(e,i)):Zt(t)?Gi(t,i):Xi(Ui(mi(e)))}function en(e){var t=Yi(vi(e)),i=["absolute","fixed"].indexOf(fi(e).position)>=0&&ei(e)?yi(e):e;return Zt(i)?t.filter((function(e){return Zt(e)&&pi(e,i)&&"body"!==Xt(e)})):[]}function tn(e,t,i,n){var s="clippingParents"===t?en(e):[].concat(t),o=[].concat(s,[i]),r=o[0],a=o.reduce((function(t,i){var s=Zi(e,i,n);return t.top=ri(s.top,t.top),t.right=ai(s.right,t.right),t.bottom=ai(s.bottom,t.bottom),t.left=ri(s.left,t.left),t}),Zi(e,r,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function nn(e){var t,i=e.reference,n=e.element,s=e.placement,o=s?oi(s):null,r=s?Li(s):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case Ct:t={x:a,y:i.y-n.height};break;case kt:t={x:a,y:i.y+i.height};break;case It:t={x:i.x+i.width,y:l};break;case Tt:t={x:i.x-n.width,y:l};break;default:t={x:i.x,y:i.y}}var c=o?wi(o):null;if(null!=c){var d="y"===c?"height":"width";switch(r){case Pt:t[c]=t[c]-(i[d]/2-n[d]/2);break;case $t:t[c]=t[c]+(i[d]/2-n[d]/2)}}return t}function sn(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=void 0===n?e.placement:n,o=i.strategy,r=void 0===o?e.strategy:o,a=i.boundary,l=void 0===a?Dt:a,c=i.rootBoundary,d=void 0===c?jt:c,u=i.elementContext,h=void 0===u?Ft:u,p=i.altBoundary,f=void 0!==p&&p,g=i.padding,m=void 0===g?0:g,v=xi("number"!=typeof m?m:Si(m,Nt)),_=h===Ft?Mt:Ft,b=e.rects.popper,y=e.elements[f?_:h],w=tn(Zt(y)?y:y.contextElement||mi(e.elements.popper),l,d,r),O=ui(e.elements.reference),E=nn({reference:O,element:b,strategy:"absolute",placement:s}),A=Xi(Object.assign({},b,E)),x=h===Ft?A:O,S={top:w.top-x.top+v.top,bottom:x.bottom-w.bottom+v.bottom,left:w.left-x.left+v.left,right:x.right-w.right+v.right},C=e.modifiersData.offset;if(h===Ft&&C){var k=C[s];Object.keys(S).forEach((function(e){var t=[It,kt].indexOf(e)>=0?1:-1,i=[Ct,kt].indexOf(e)>=0?"y":"x";S[e]+=k[i]*t}))}return S}function on(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=i.boundary,o=i.rootBoundary,r=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?Rt:l,d=Li(n),u=d?a?qt:qt.filter((function(e){return Li(e)===d})):Nt,h=u.filter((function(e){return c.indexOf(e)>=0}));0===h.length&&(h=u);var p=h.reduce((function(t,i){return t[i]=sn(e,{placement:i,boundary:s,rootBoundary:o,padding:r})[oi(i)],t}),{});return Object.keys(p).sort((function(e,t){return p[e]-p[t]}))}function rn(e){if(oi(e)===Lt)return[];var t=Hi(e);return[Bi(e),t,Bi(t)]}function an(e){var t=e.state,i=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0===r||r,l=i.fallbackPlacements,c=i.padding,d=i.boundary,u=i.rootBoundary,h=i.altBoundary,p=i.flipVariations,f=void 0===p||p,g=i.allowedAutoPlacements,m=t.options.placement,v=oi(m),_=l||(v!==m&&f?rn(m):[Hi(m)]),b=[m].concat(_).reduce((function(e,i){return e.concat(oi(i)===Lt?on(t,{placement:i,boundary:d,rootBoundary:u,padding:c,flipVariations:f,allowedAutoPlacements:g}):i)}),[]),y=t.rects.reference,w=t.rects.popper,O=new Map,E=!0,A=b[0],x=0;x=0,T=I?"width":"height",L=sn(t,{placement:S,boundary:d,rootBoundary:u,altBoundary:h,padding:c}),N=I?k?It:Tt:k?kt:Ct;y[T]>w[T]&&(N=Hi(N));var P=Hi(N),$=[];if(o&&$.push(L[C]<=0),a&&$.push(L[N]<=0,L[P]<=0),$.every((function(e){return e}))){A=S,E=!1;break}O.set(S,$)}if(E)for(var D=function(e){var t=b.find((function(t){var i=O.get(t);if(i)return i.slice(0,e).every((function(e){return e}))}));if(t)return A=t,"break"},j=f?3:1;j>0&&"break"!==D(j);j--);t.placement!==A&&(t.modifiersData[n]._skip=!0,t.placement=A,t.reset=!0)}}const ln={name:"flip",enabled:!0,phase:"main",fn:an,requiresIfExists:["offset"],data:{_skip:!1}};function cn(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function dn(e){return[Ct,It,kt,Tt].some((function(t){return e[t]>=0}))}function un(e){var t=e.state,i=e.name,n=t.rects.reference,s=t.rects.popper,o=t.modifiersData.preventOverflow,r=sn(t,{elementContext:"reference"}),a=sn(t,{altBoundary:!0}),l=cn(r,n),c=cn(a,s,o),d=dn(l),u=dn(c);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:d,hasPopperEscaped:u},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":u})}const hn={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:un};function pn(e,t,i){var n=oi(e),s=[Tt,Ct].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},t,{placement:e})):i,r=o[0],a=o[1];return r=r||0,a=(a||0)*s,[Tt,It].indexOf(n)>=0?{x:a,y:r}:{x:r,y:a}}function fn(e){var t=e.state,i=e.options,n=e.name,s=i.offset,o=void 0===s?[0,0]:s,r=Rt.reduce((function(e,i){return e[i]=pn(i,t.rects,o),e}),{}),a=r[t.placement],l=a.x,c=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=r}const gn={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn};function mn(e){var t=e.state,i=e.name;t.modifiersData[i]=nn({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const vn={name:"popperOffsets",enabled:!0,phase:"read",fn:mn,data:{}};function _n(e){return"x"===e?"y":"x"}function bn(e){var t=e.state,i=e.options,n=e.name,s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0!==r&&r,l=i.boundary,c=i.rootBoundary,d=i.altBoundary,u=i.padding,h=i.tether,p=void 0===h||h,f=i.tetherOffset,g=void 0===f?0:f,m=sn(t,{boundary:l,rootBoundary:c,padding:u,altBoundary:d}),v=oi(t.placement),_=Li(t.placement),b=!_,y=wi(v),w=_n(y),O=t.modifiersData.popperOffsets,E=t.rects.reference,A=t.rects.popper,x="function"==typeof g?g(Object.assign({},t.rects,{placement:t.placement})):g,S="number"==typeof x?{mainAxis:x,altAxis:x}:Object.assign({mainAxis:0,altAxis:0},x),C=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,k={x:0,y:0};if(O){if(o){var I,T="y"===y?Ct:Tt,L="y"===y?kt:It,N="y"===y?"height":"width",P=O[y],$=P+m[T],D=P-m[L],j=p?-A[N]/2:0,F=_===Pt?E[N]:A[N],M=_===Pt?-A[N]:-E[N],q=t.elements.arrow,R=p&&q?hi(q):{width:0,height:0},H=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Ai(),z=H[T],B=H[L],V=Oi(0,E[N],R[N]),W=b?E[N]/2-j-V-z-S.mainAxis:F-V-z-S.mainAxis,K=b?-E[N]/2+j+V+B+S.mainAxis:M+V+B+S.mainAxis,U=t.elements.arrow&&yi(t.elements.arrow),Q=U?"y"===y?U.clientTop||0:U.clientLeft||0:0,J=null!=(I=null==C?void 0:C[y])?I:0,Y=P+K-J,X=Oi(p?ai($,P+W-J-Q):$,P,p?ri(D,Y):D);O[y]=X,k[y]=X-P}if(a){var G,Z="x"===y?Ct:Tt,ee="x"===y?kt:It,te=O[w],ie="y"===w?"height":"width",ne=te+m[Z],se=te-m[ee],oe=-1!==[Ct,Tt].indexOf(v),re=null!=(G=null==C?void 0:C[w])?G:0,ae=oe?ne:te-E[ie]-A[ie]-re+S.altAxis,le=oe?te+E[ie]+A[ie]-re-S.altAxis:se,ce=p&&oe?Ei(ae,te,le):Oi(p?ae:ne,te,p?le:se);O[w]=ce,k[w]=ce-te}t.modifiersData[n]=k}}const yn={name:"preventOverflow",enabled:!0,phase:"main",fn:bn,requiresIfExists:["offset"]};function wn(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function On(e){return e!==Gt(e)&&ei(e)?wn(e):Vi(e)}function En(e){var t=e.getBoundingClientRect(),i=li(t.width)/e.offsetWidth||1,n=li(t.height)/e.offsetHeight||1;return 1!==i||1!==n}function An(e,t,i){void 0===i&&(i=!1);var n=ei(t),s=ei(t)&&En(t),o=mi(t),r=ui(e,s,i),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(n||!n&&!i)&&(("body"!==Xt(t)||Qi(o))&&(a=On(t)),ei(t)?((l=ui(t,!0)).x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=Wi(o))),{x:r.left+a.scrollLeft-l.x,y:r.top+a.scrollTop-l.y,width:r.width,height:r.height}}function xn(e){var t=new Map,i=new Set,n=[];function s(e){i.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!i.has(e)){var n=t.get(e);n&&s(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){i.has(e.name)||s(e)})),n}function Sn(e){var t=xn(e);return Yt.reduce((function(e,i){return e.concat(t.filter((function(e){return e.phase===i})))}),[])}function Cn(e){var t;return function(){return t||(t=new Promise((function(i){Promise.resolve().then((function(){t=void 0,i(e())}))}))),t}}function kn(e){var t=e.reduce((function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e}),{});return Object.keys(t).map((function(e){return t[e]}))}var In={placement:"bottom",modifiers:[],strategy:"absolute"};function Tn(){for(var e=arguments.length,t=new Array(e),i=0;iNumber.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_getPopperConfig(){const e={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(K.setDataAttribute(this._menu,"popper","static"),e.modifiers=[{name:"applyStyles",enabled:!1}]),{...e,...O(this._config.popperConfig,[e])}}_selectMenuItem({key:e,target:t}){const i=X.find(ls,this._menu).filter((e=>h(e)));i.length&&A(i,t,e===zn,!i.includes(t)).focus()}static jQueryInterface(e){return this.each((function(){const t=bs.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}static clearMenus(e){if(e.button===Bn||"keyup"===e.type&&e.key!==Rn)return;const t=X.find(ss);for(const i of t){const t=bs.getInstance(i);if(!t||!1===t._config.autoClose)continue;const n=e.composedPath(),s=n.includes(t._menu);if(n.includes(t._element)||"inside"===t._config.autoClose&&!s||"outside"===t._config.autoClose&&s)continue;if(t._menu.contains(e.target)&&("keyup"===e.type&&e.key===Rn||/input|select|option|textarea|form/i.test(e.target.tagName)))continue;const o={relatedTarget:t._element};"click"===e.type&&(o.clickEvent=e),t._completeHide(o)}}static dataApiKeydownHandler(e){const t=/input|textarea/i.test(e.target.tagName),i=e.key===qn,n=[Hn,zn].includes(e.key);if(!n&&!i)return;if(t&&!i)return;e.preventDefault();const s=this.matches(ns)?this:X.prev(this,ns)[0]||X.next(this,ns)[0]||X.findOne(ns,e.delegateTarget.parentNode),o=bs.getOrCreateInstance(s);if(n)return e.stopPropagation(),o.show(),void o._selectMenuItem(e);o._isShown()&&(e.stopPropagation(),o.hide(),s.focus())}}z.on(document,Jn,ns,bs.dataApiKeydownHandler),z.on(document,Jn,os,bs.dataApiKeydownHandler),z.on(document,Qn,bs.clearMenus),z.on(document,Yn,bs.clearMenus),z.on(document,Qn,ns,(function(e){e.preventDefault(),bs.getOrCreateInstance(this).toggle()})),w(bs);const ys="backdrop",ws="fade",Os="show",Es=`mousedown.bs.${ys}`,As={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},xs={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Ss extends U{constructor(e){super(),this._config=this._getConfig(e),this._isAppended=!1,this._element=null}static get Default(){return As}static get DefaultType(){return xs}static get NAME(){return ys}show(e){if(!this._config.isVisible)return void O(e);this._append();const t=this._getElement();this._config.isAnimated&&m(t),t.classList.add(Os),this._emulateAnimation((()=>{O(e)}))}hide(e){this._config.isVisible?(this._getElement().classList.remove(Os),this._emulateAnimation((()=>{this.dispose(),O(e)}))):O(e)}dispose(){this._isAppended&&(z.off(this._element,Es),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const e=document.createElement("div");e.className=this._config.className,this._config.isAnimated&&e.classList.add(ws),this._element=e}return this._element}_configAfterMerge(e){return e.rootElement=u(e.rootElement),e}_append(){if(this._isAppended)return;const e=this._getElement();this._config.rootElement.append(e),z.on(e,Es,(()=>{O(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(e){E(e,this._getElement(),this._config.isAnimated)}}const Cs="focustrap",ks=".bs.focustrap",Is=`focusin${ks}`,Ts=`keydown.tab${ks}`,Ls="Tab",Ns="forward",Ps="backward",$s={autofocus:!0,trapElement:null},Ds={autofocus:"boolean",trapElement:"element"};class js extends U{constructor(e){super(),this._config=this._getConfig(e),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return $s}static get DefaultType(){return Ds}static get NAME(){return Cs}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),z.off(document,ks),z.on(document,Is,(e=>this._handleFocusin(e))),z.on(document,Ts,(e=>this._handleKeydown(e))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,z.off(document,ks))}_handleFocusin(e){const{trapElement:t}=this._config;if(e.target===document||e.target===t||t.contains(e.target))return;const i=X.focusableChildren(t);0===i.length?t.focus():this._lastTabNavDirection===Ps?i[i.length-1].focus():i[0].focus()}_handleKeydown(e){e.key===Ls&&(this._lastTabNavDirection=e.shiftKey?Ps:Ns)}}const Fs=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",Ms=".sticky-top",qs="padding-right",Rs="margin-right";class Hs{constructor(){this._element=document.body}getWidth(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}hide(){const e=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,qs,(t=>t+e)),this._setElementAttributes(Fs,qs,(t=>t+e)),this._setElementAttributes(Ms,Rs,(t=>t-e))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,qs),this._resetElementAttributes(Fs,qs),this._resetElementAttributes(Ms,Rs)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(e,t,i){const n=this.getWidth(),s=e=>{if(e!==this._element&&window.innerWidth>e.clientWidth+n)return;this._saveInitialAttribute(e,t);const s=window.getComputedStyle(e).getPropertyValue(t);e.style.setProperty(t,`${i(Number.parseFloat(s))}px`)};this._applyManipulationCallback(e,s)}_saveInitialAttribute(e,t){const i=e.style.getPropertyValue(t);i&&K.setDataAttribute(e,t,i)}_resetElementAttributes(e,t){const i=e=>{const i=K.getDataAttribute(e,t);null!==i?(K.removeDataAttribute(e,t),e.style.setProperty(t,i)):e.style.removeProperty(t)};this._applyManipulationCallback(e,i)}_applyManipulationCallback(e,t){if(d(e))t(e);else for(const i of X.find(e,this._element))t(i)}}const zs="modal",Bs=".bs.modal",Vs="Escape",Ws=`hide${Bs}`,Ks=`hidePrevented${Bs}`,Us=`hidden${Bs}`,Qs=`show${Bs}`,Js=`shown${Bs}`,Ys=`resize${Bs}`,Xs=`click.dismiss${Bs}`,Gs=`mousedown.dismiss${Bs}`,Zs=`keydown.dismiss${Bs}`,eo=`click${Bs}.data-api`,to="modal-open",io="fade",no="show",so="modal-static",oo=".modal.show",ro=".modal-dialog",ao=".modal-body",lo='[data-bs-toggle="modal"]',co={backdrop:!0,focus:!0,keyboard:!0},uo={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class ho extends J{constructor(e,t){super(e,t),this._dialog=X.findOne(ro,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new Hs,this._addEventListeners()}static get Default(){return co}static get DefaultType(){return uo}static get NAME(){return zs}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){this._isShown||this._isTransitioning||z.trigger(this._element,Qs,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(to),this._adjustDialog(),this._backdrop.show((()=>this._showElement(e))))}hide(){this._isShown&&!this._isTransitioning&&(z.trigger(this._element,Ws).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(no),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated())))}dispose(){z.off(window,Bs),z.off(this._dialog,Bs),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Ss({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new js({trapElement:this._element})}_showElement(e){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 t=X.findOne(ao,this._dialog);t&&(t.scrollTop=0),m(this._element),this._element.classList.add(no);const i=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,z.trigger(this._element,Js,{relatedTarget:e})};this._queueCallback(i,this._dialog,this._isAnimated())}_addEventListeners(){z.on(this._element,Zs,(e=>{e.key===Vs&&(this._config.keyboard?this.hide():this._triggerBackdropTransition())})),z.on(window,Ys,(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),z.on(this._element,Gs,(e=>{z.one(this._element,Xs,(t=>{this._element===e.target&&this._element===t.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())}))}))}_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(to),this._resetAdjustments(),this._scrollBar.reset(),z.trigger(this._element,Us)}))}_isAnimated(){return this._element.classList.contains(io)}_triggerBackdropTransition(){if(z.trigger(this._element,Ks).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._element.style.overflowY;"hidden"===t||this._element.classList.contains(so)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(so),this._queueCallback((()=>{this._element.classList.remove(so),this._queueCallback((()=>{this._element.style.overflowY=t}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._scrollBar.getWidth(),i=t>0;if(i&&!e){const e=y()?"paddingLeft":"paddingRight";this._element.style[e]=`${t}px`}if(!i&&e){const e=y()?"paddingRight":"paddingLeft";this._element.style[e]=`${t}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(e,t){return this.each((function(){const i=ho.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e](t)}}))}}z.on(document,eo,lo,(function(e){const t=X.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&e.preventDefault(),z.one(t,Qs,(e=>{e.defaultPrevented||z.one(t,Us,(()=>{h(this)&&this.focus()}))}));const i=X.findOne(oo);i&&ho.getInstance(i).hide(),ho.getOrCreateInstance(t).toggle(this)})),G(ho),w(ho);const po="offcanvas",fo=".bs.offcanvas",go=".data-api",mo=`load${fo}${go}`,vo="Escape",_o="show",bo="showing",yo="hiding",wo="offcanvas-backdrop",Oo=".offcanvas.show",Eo=`show${fo}`,Ao=`shown${fo}`,xo=`hide${fo}`,So=`hidePrevented${fo}`,Co=`hidden${fo}`,ko=`resize${fo}`,Io=`click${fo}${go}`,To=`keydown.dismiss${fo}`,Lo='[data-bs-toggle="offcanvas"]',No={backdrop:!0,keyboard:!0,scroll:!1},Po={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class $o extends J{constructor(e,t){super(e,t),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return No}static get DefaultType(){return Po}static get NAME(){return po}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown)return;if(z.trigger(this._element,Eo,{relatedTarget:e}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||(new Hs).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(bo);const t=()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add(_o),this._element.classList.remove(bo),z.trigger(this._element,Ao,{relatedTarget:e})};this._queueCallback(t,this._element,!0)}hide(){if(!this._isShown)return;if(z.trigger(this._element,xo).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(yo),this._backdrop.hide();const e=()=>{this._element.classList.remove(_o,yo),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new Hs).reset(),z.trigger(this._element,Co)};this._queueCallback(e,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const e=()=>{"static"!==this._config.backdrop?this.hide():z.trigger(this._element,So)},t=Boolean(this._config.backdrop);return new Ss({className:wo,isVisible:t,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:t?e:null})}_initializeFocusTrap(){return new js({trapElement:this._element})}_addEventListeners(){z.on(this._element,To,(e=>{e.key===vo&&(this._config.keyboard?this.hide():z.trigger(this._element,So))}))}static jQueryInterface(e){return this.each((function(){const t=$o.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}z.on(document,Io,Lo,(function(e){const t=X.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&e.preventDefault(),p(this))return;z.one(t,Co,(()=>{h(this)&&this.focus()}));const i=X.findOne(Oo);i&&i!==t&&$o.getInstance(i).hide(),$o.getOrCreateInstance(t).toggle(this)})),z.on(window,mo,(()=>{for(const e of X.find(Oo))$o.getOrCreateInstance(e).show()})),z.on(window,ko,(()=>{for(const e of X.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(e).position&&$o.getOrCreateInstance(e).hide()})),G($o),w($o);const Do={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],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:[]},jo=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Fo=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,Mo=(e,t)=>{const i=e.nodeName.toLowerCase();return t.includes(i)?!jo.has(i)||Boolean(Fo.test(e.nodeValue)):t.filter((e=>e instanceof RegExp)).some((e=>e.test(i)))};function qo(e,t,i){if(!e.length)return e;if(i&&"function"==typeof i)return i(e);const n=(new window.DOMParser).parseFromString(e,"text/html"),s=[].concat(...n.body.querySelectorAll("*"));for(const e of s){const i=e.nodeName.toLowerCase();if(!Object.keys(t).includes(i)){e.remove();continue}const n=[].concat(...e.attributes),s=[].concat(t["*"]||[],t[i]||[]);for(const t of n)Mo(t,s)||e.removeAttribute(t.nodeName)}return n.body.innerHTML}const Ro="TemplateFactory",Ho={allowList:Do,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"
"},zo={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},Bo={entry:"(string|element|function|null)",selector:"(string|element)"};class Vo extends U{constructor(e){super(),this._config=this._getConfig(e)}static get Default(){return Ho}static get DefaultType(){return zo}static get NAME(){return Ro}getContent(){return Object.values(this._config.content).map((e=>this._resolvePossibleFunction(e))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(e){return this._checkContent(e),this._config.content={...this._config.content,...e},this}toHtml(){const e=document.createElement("div");e.innerHTML=this._maybeSanitize(this._config.template);for(const[t,i]of Object.entries(this._config.content))this._setContent(e,i,t);const t=e.children[0],i=this._resolvePossibleFunction(this._config.extraClass);return i&&t.classList.add(...i.split(" ")),t}_typeCheckConfig(e){super._typeCheckConfig(e),this._checkContent(e.content)}_checkContent(e){for(const[t,i]of Object.entries(e))super._typeCheckConfig({selector:t,entry:i},Bo)}_setContent(e,t,i){const n=X.findOne(i,e);n&&((t=this._resolvePossibleFunction(t))?d(t)?this._putElementInTemplate(u(t),n):this._config.html?n.innerHTML=this._maybeSanitize(t):n.textContent=t:n.remove())}_maybeSanitize(e){return this._config.sanitize?qo(e,this._config.allowList,this._config.sanitizeFn):e}_resolvePossibleFunction(e){return O(e,[this])}_putElementInTemplate(e,t){if(this._config.html)return t.innerHTML="",void t.append(e);t.textContent=e.textContent}}const Wo="tooltip",Ko=new Set(["sanitize","allowList","sanitizeFn"]),Uo="fade",Qo="show",Jo=".tooltip-inner",Yo=".modal",Xo="hide.bs.modal",Go="hover",Zo="focus",er="click",tr="manual",ir="hide",nr="hidden",sr="show",or="shown",rr="inserted",ar="click",lr="focusin",cr="focusout",dr="mouseenter",ur="mouseleave",hr={AUTO:"auto",TOP:"top",RIGHT:y()?"left":"right",BOTTOM:"bottom",LEFT:y()?"right":"left"},pr={allowList:Do,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:'',title:"",trigger:"hover focus"},fr={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 gr extends J{constructor(e,t){if(void 0===Dn)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(e,t),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 pr}static get DefaultType(){return fr}static get NAME(){return Wo}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),z.off(this._element.closest(Yo),Xo,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("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const e=z.trigger(this._element,this.constructor.eventName(sr)),t=(f(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(e.defaultPrevented||!t)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:n}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(n.append(i),z.trigger(this._element,this.constructor.eventName(rr))),this._popper=this._createPopper(i),i.classList.add(Qo),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))z.on(e,"mouseover",g);const s=()=>{z.trigger(this._element,this.constructor.eventName(or)),!1===this._isHovered&&this._leave(),this._isHovered=!1};this._queueCallback(s,this.tip,this._isAnimated())}hide(){if(!this._isShown())return;if(z.trigger(this._element,this.constructor.eventName(ir)).defaultPrevented)return;if(this._getTipElement().classList.remove(Qo),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))z.off(e,"mouseover",g);this._activeTrigger[er]=!1,this._activeTrigger[Zo]=!1,this._activeTrigger[Go]=!1,this._isHovered=null;const e=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),z.trigger(this._element,this.constructor.eventName(nr)))};this._queueCallback(e,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(e){const t=this._getTemplateFactory(e).toHtml();if(!t)return null;t.classList.remove(Uo,Qo),t.classList.add(`bs-${this.constructor.NAME}-auto`);const i=a(this.constructor.NAME).toString();return t.setAttribute("id",i),this._isAnimated()&&t.classList.add(Uo),t}setContent(e){this._newContent=e,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(e){return this._templateFactory?this._templateFactory.changeContent(e):this._templateFactory=new Vo({...this._config,content:e,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[Jo]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(e){return this.constructor.getOrCreateInstance(e.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(Uo)}_isShown(){return this.tip&&this.tip.classList.contains(Qo)}_createPopper(e){const t=O(this._config.placement,[this,e,this._element]),i=hr[t.toUpperCase()];return $n(this._element,e,this._getPopperConfig(i))}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_resolvePossibleFunction(e){return O(e,[this._element])}_getPopperConfig(e){const t={placement:e,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:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...t,...O(this._config.popperConfig,[t])}}_setListeners(){const e=this._config.trigger.split(" ");for(const t of e)if("click"===t)z.on(this._element,this.constructor.eventName(ar),this._config.selector,(e=>{this._initializeOnDelegatedTarget(e).toggle()}));else if(t!==tr){const e=t===Go?this.constructor.eventName(dr):this.constructor.eventName(lr),i=t===Go?this.constructor.eventName(ur):this.constructor.eventName(cr);z.on(this._element,e,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusin"===e.type?Zo:Go]=!0,t._enter()})),z.on(this._element,i,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusout"===e.type?Zo:Go]=t._element.contains(e.relatedTarget),t._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},z.on(this._element.closest(Yo),Xo,this._hideModalHandler)}_fixTitle(){const e=this._element.getAttribute("title");e&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",e),this._element.setAttribute("data-bs-original-title",e),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(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(e,t){clearTimeout(this._timeout),this._timeout=setTimeout(e,t)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(e){const t=K.getDataAttributes(this._element);for(const e of Object.keys(t))Ko.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e.container=!1===e.container?document.body:u(e.container),"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),e}_getDelegateConfig(){const e={};for(const[t,i]of Object.entries(this._config))this.constructor.Default[t]!==i&&(e[t]=i);return e.selector=!1,e.trigger="manual",e}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(e){return this.each((function(){const t=gr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}w(gr);const mr="popover",vr=".popover-header",_r=".popover-body",br={...gr.Default,content:"",offset:[0,8],placement:"right",template:'',trigger:"click"},yr={...gr.DefaultType,content:"(null|string|element|function)"};class wr extends gr{static get Default(){return br}static get DefaultType(){return yr}static get NAME(){return mr}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[vr]:this._getTitle(),[_r]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(e){return this.each((function(){const t=wr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}w(wr);const Or="scrollspy",Er=".bs.scrollspy",Ar=`activate${Er}`,xr=`click${Er}`,Sr=`load${Er}.data-api`,Cr="dropdown-item",kr="active",Ir='[data-bs-spy="scroll"]',Tr="[href]",Lr=".nav, .list-group",Nr=".nav-link",Pr=`${Nr}, .nav-item > ${Nr}, .list-group-item`,$r=".dropdown",Dr=".dropdown-toggle",jr={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Fr={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class Mr extends J{constructor(e,t){super(e,t),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return jr}static get DefaultType(){return Fr}static get NAME(){return Or}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const e of this._observableSections.values())this._observer.observe(e)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(e){return e.target=u(e.target)||document.body,e.rootMargin=e.offset?`${e.offset}px 0px -30%`:e.rootMargin,"string"==typeof e.threshold&&(e.threshold=e.threshold.split(",").map((e=>Number.parseFloat(e)))),e}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(z.off(this._config.target,xr),z.on(this._config.target,xr,Tr,(e=>{const t=this._observableSections.get(e.target.hash);if(t){e.preventDefault();const i=this._rootElement||window,n=t.offsetTop-this._element.offsetTop;if(i.scrollTo)return void i.scrollTo({top:n,behavior:"smooth"});i.scrollTop=n}})))}_getNewObserver(){const e={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver((e=>this._observerCallback(e)),e)}_observerCallback(e){const t=e=>this._targetLinks.get(`#${e.target.id}`),i=e=>{this._previousScrollData.visibleEntryTop=e.target.offsetTop,this._process(t(e))},n=(this._rootElement||document.documentElement).scrollTop,s=n>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=n;for(const o of e){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(t(o));continue}const e=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(s&&e){if(i(o),!n)return}else s||e||i(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const e=X.find(Tr,this._config.target);for(const t of e){if(!t.hash||p(t))continue;const e=X.findOne(decodeURI(t.hash),this._element);h(e)&&(this._targetLinks.set(decodeURI(t.hash),t),this._observableSections.set(t.hash,e))}}_process(e){this._activeTarget!==e&&(this._clearActiveClass(this._config.target),this._activeTarget=e,e.classList.add(kr),this._activateParents(e),z.trigger(this._element,Ar,{relatedTarget:e}))}_activateParents(e){if(e.classList.contains(Cr))X.findOne(Dr,e.closest($r)).classList.add(kr);else for(const t of X.parents(e,Lr))for(const e of X.prev(t,Pr))e.classList.add(kr)}_clearActiveClass(e){e.classList.remove(kr);const t=X.find(`${Tr}.${kr}`,e);for(const e of t)e.classList.remove(kr)}static jQueryInterface(e){return this.each((function(){const t=Mr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}z.on(window,Sr,(()=>{for(const e of X.find(Ir))Mr.getOrCreateInstance(e)})),w(Mr);const qr="tab",Rr=".bs.tab",Hr=`hide${Rr}`,zr=`hidden${Rr}`,Br=`show${Rr}`,Vr=`shown${Rr}`,Wr=`click${Rr}`,Kr=`keydown${Rr}`,Ur=`load${Rr}`,Qr="ArrowLeft",Jr="ArrowRight",Yr="ArrowUp",Xr="ArrowDown",Gr="Home",Zr="End",ea="active",ta="fade",ia="show",na="dropdown",sa=".dropdown-toggle",oa=".dropdown-menu",ra=`:not(${sa})`,aa='.list-group, .nav, [role="tablist"]',la=".nav-item, .list-group-item",ca='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',da=`.nav-link${ra}, .list-group-item${ra}, [role="tab"]${ra}, ${ca}`,ua=`.${ea}[data-bs-toggle="tab"], .${ea}[data-bs-toggle="pill"], .${ea}[data-bs-toggle="list"]`;class ha extends J{constructor(e){super(e),this._parent=this._element.closest(aa),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),z.on(this._element,Kr,(e=>this._keydown(e))))}static get NAME(){return qr}show(){const e=this._element;if(this._elemIsActive(e))return;const t=this._getActiveElem(),i=t?z.trigger(t,Hr,{relatedTarget:e}):null;z.trigger(e,Br,{relatedTarget:t}).defaultPrevented||i&&i.defaultPrevented||(this._deactivate(t,e),this._activate(e,t))}_activate(e,t){if(!e)return;e.classList.add(ea),this._activate(X.getElementFromSelector(e));const i=()=>{"tab"===e.getAttribute("role")?(e.removeAttribute("tabindex"),e.setAttribute("aria-selected",!0),this._toggleDropDown(e,!0),z.trigger(e,Vr,{relatedTarget:t})):e.classList.add(ia)};this._queueCallback(i,e,e.classList.contains(ta))}_deactivate(e,t){if(!e)return;e.classList.remove(ea),e.blur(),this._deactivate(X.getElementFromSelector(e));const i=()=>{"tab"===e.getAttribute("role")?(e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1"),this._toggleDropDown(e,!1),z.trigger(e,zr,{relatedTarget:t})):e.classList.remove(ia)};this._queueCallback(i,e,e.classList.contains(ta))}_keydown(e){if(![Qr,Jr,Yr,Xr,Gr,Zr].includes(e.key))return;e.stopPropagation(),e.preventDefault();const t=this._getChildren().filter((e=>!p(e)));let i;if([Gr,Zr].includes(e.key))i=t[e.key===Gr?0:t.length-1];else{const n=[Jr,Xr].includes(e.key);i=A(t,e.target,n,!0)}i&&(i.focus({preventScroll:!0}),ha.getOrCreateInstance(i).show())}_getChildren(){return X.find(da,this._parent)}_getActiveElem(){return this._getChildren().find((e=>this._elemIsActive(e)))||null}_setInitialAttributes(e,t){this._setAttributeIfNotExists(e,"role","tablist");for(const e of t)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(e){e=this._getInnerElement(e);const t=this._elemIsActive(e),i=this._getOuterElement(e);e.setAttribute("aria-selected",t),i!==e&&this._setAttributeIfNotExists(i,"role","presentation"),t||e.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(e,"role","tab"),this._setInitialAttributesOnTargetPanel(e)}_setInitialAttributesOnTargetPanel(e){const t=X.getElementFromSelector(e);t&&(this._setAttributeIfNotExists(t,"role","tabpanel"),e.id&&this._setAttributeIfNotExists(t,"aria-labelledby",`${e.id}`))}_toggleDropDown(e,t){const i=this._getOuterElement(e);if(!i.classList.contains(na))return;const n=(e,n)=>{const s=X.findOne(e,i);s&&s.classList.toggle(n,t)};n(sa,ea),n(oa,ia),i.setAttribute("aria-expanded",t)}_setAttributeIfNotExists(e,t,i){e.hasAttribute(t)||e.setAttribute(t,i)}_elemIsActive(e){return e.classList.contains(ea)}_getInnerElement(e){return e.matches(da)?e:X.findOne(da,e)}_getOuterElement(e){return e.closest(la)||e}static jQueryInterface(e){return this.each((function(){const t=ha.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}z.on(document,Wr,ca,(function(e){["A","AREA"].includes(this.tagName)&&e.preventDefault(),p(this)||ha.getOrCreateInstance(this).show()})),z.on(window,Ur,(()=>{for(const e of X.find(ua))ha.getOrCreateInstance(e)})),w(ha);const pa="toast",fa=".bs.toast",ga=`mouseover${fa}`,ma=`mouseout${fa}`,va=`focusin${fa}`,_a=`focusout${fa}`,ba=`hide${fa}`,ya=`hidden${fa}`,wa=`show${fa}`,Oa=`shown${fa}`,Ea="fade",Aa="hide",xa="show",Sa="showing",Ca={animation:"boolean",autohide:"boolean",delay:"number"},ka={animation:!0,autohide:!0,delay:5e3};class Ia extends J{constructor(e,t){super(e,t),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return ka}static get DefaultType(){return Ca}static get NAME(){return pa}show(){if(z.trigger(this._element,wa).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(Ea);const e=()=>{this._element.classList.remove(Sa),z.trigger(this._element,Oa),this._maybeScheduleHide()};this._element.classList.remove(Aa),m(this._element),this._element.classList.add(xa,Sa),this._queueCallback(e,this._element,this._config.animation)}hide(){if(!this.isShown())return;if(z.trigger(this._element,ba).defaultPrevented)return;const e=()=>{this._element.classList.add(Aa),this._element.classList.remove(Sa,xa),z.trigger(this._element,ya)};this._element.classList.add(Sa),this._queueCallback(e,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(xa),super.dispose()}isShown(){return this._element.classList.contains(xa)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(e,t){switch(e.type){case"mouseover":case"mouseout":this._hasMouseInteraction=t;break;case"focusin":case"focusout":this._hasKeyboardInteraction=t}if(t)return void this._clearTimeout();const i=e.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){z.on(this._element,ga,(e=>this._onInteraction(e,!0))),z.on(this._element,ma,(e=>this._onInteraction(e,!1))),z.on(this._element,va,(e=>this._onInteraction(e,!0))),z.on(this._element,_a,(e=>this._onInteraction(e,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(e){return this.each((function(){const t=Ia.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}return G(Ia),w(Ia),{Alert:oe,Button:de,Carousel:rt,Collapse:St,Dropdown:bs,Modal:ho,Offcanvas:$o,Popover:wr,ScrollSpy:Mr,Tab:ha,Toast:Ia,Tooltip:gr}}()},538:(e,t,i)=>{"use strict";i.r(t)},766:function(e){e.exports=function(){"use strict";function e(e,t){e.split(/\s+/).forEach((e=>{t(e)}))}class t{constructor(){this._events={}}on(t,i){e(t,(e=>{const t=this._events[e]||[];t.push(i),this._events[e]=t}))}off(t,i){var n=arguments.length;0!==n?e(t,(e=>{if(1===n)return void delete this._events[e];const t=this._events[e];void 0!==t&&(t.splice(t.indexOf(i),1),this._events[e]=t)})):this._events={}}trigger(t,...i){var n=this;e(t,(e=>{const t=n._events[e];void 0!==t&&t.forEach((e=>{e.apply(n,i)}))}))}}const i=e=>(e=e.filter(Boolean)).length<2?e[0]||"":1==a(e)?"["+e.join("")+"]":"(?:"+e.join("|")+")",n=e=>{if(!o(e))return e.join("");let t="",i=0;const n=()=>{i>1&&(t+="{"+i+"}")};return e.forEach(((s,o)=>{s!==e[o-1]?(n(),t+=s,i=1):i++})),n(),t},s=e=>{let t=Array.from(e);return i(t)},o=e=>new Set(e).size!==e.length,r=e=>(e+"").replace(/([\$\(\)\*\+\.\?\[\]\^\{\|\}\\])/gu,"\\$1"),a=e=>e.reduce(((e,t)=>Math.max(e,l(t))),0),l=e=>Array.from(e).length,c=e=>{if(1===e.length)return[[e]];let t=[];const i=e.substring(1);return c(i).forEach((function(i){let n=i.slice(0);n[0]=e.charAt(0)+n[0],t.push(n),n=i.slice(0),n.unshift(e.charAt(0)),t.push(n)})),t},d=[[0,65535]];let u,h;const p={},f={"/":"⁄∕",0:"߀",a:"ⱥɐɑ",aa:"ꜳ",ae:"æǽǣ",ao:"ꜵ",au:"ꜷ",av:"ꜹꜻ",ay:"ꜽ",b:"ƀɓƃ",c:"ꜿƈȼↄ",d:"đɗɖᴅƌꮷԁɦ",e:"ɛǝᴇɇ",f:"ꝼƒ",g:"ǥɠꞡᵹꝿɢ",h:"ħⱨⱶɥ",i:"ɨı",j:"ɉȷ",k:"ƙⱪꝁꝃꝅꞣ",l:"łƚɫⱡꝉꝇꞁɭ",m:"ɱɯϻ",n:"ꞥƞɲꞑᴎлԉ",o:"øǿɔɵꝋꝍᴑ",oe:"œ",oi:"ƣ",oo:"ꝏ",ou:"ȣ",p:"ƥᵽꝑꝓꝕρ",q:"ꝗꝙɋ",r:"ɍɽꝛꞧꞃ",s:"ßȿꞩꞅʂ",t:"ŧƭʈⱦꞇ",th:"þ",tz:"ꜩ",u:"ʉ",v:"ʋꝟʌ",vy:"ꝡ",w:"ⱳ",y:"ƴɏỿ",z:"ƶȥɀⱬꝣ",hv:"ƕ"};for(let e in f){let t=f[e]||"";for(let i=0;ie.normalize(t),v=e=>Array.from(e).reduce(((e,t)=>e+_(t)),""),_=e=>(e=m(e).toLowerCase().replace(g,(e=>p[e]||"")),m(e,"NFC")),b=e=>{const t={},i=(e,i)=>{const n=t[e]||new Set,o=new RegExp("^"+s(n)+"$","iu");i.match(o)||(n.add(r(i)),t[e]=n)};for(let t of function*(e){for(const[t,i]of e)for(let e=t;e<=i;e++){let t=String.fromCharCode(e),i=v(t);i!=t.toLowerCase()&&(i.length>3||0!=i.length&&(yield{folded:i,composed:t,code_point:e}))}}(e))i(t.folded,t.folded),i(t.folded,t.composed);return t},y=e=>{const t=b(e),n={};let o=[];for(let e in t){let i=t[e];i&&(n[e]=s(i)),e.length>1&&o.push(r(e))}o.sort(((e,t)=>t.length-e.length));const a=i(o);return h=new RegExp("^"+a,"u"),n},w=(e,t=1)=>(t=Math.max(t,e.length-1),i(c(e).map((e=>((e,t=1)=>{let i=0;return e=e.map((e=>(u[e]&&(i+=e.length),u[e]||e))),i>=t?n(e):""})(e,t))))),O=(e,t=!0)=>{let s=e.length>1?1:0;return i(e.map((e=>{let i=[];const o=t?e.length():e.length()-1;for(let t=0;t{for(const i of t){if(i.start!=e.start||i.end!=e.end)continue;if(i.substrs.join("")!==e.substrs.join(""))continue;let t=e.parts;const n=e=>{for(const i of t){if(i.start===e.start&&i.substr===e.substr)return!1;if(1!=e.length&&1!=i.length){if(e.starti.start)return!0;if(i.starte.start)return!0}}return!1};if(!(i.parts.filter(n).length>0))return!0}return!1};class A{parts;substrs;start;end;constructor(){this.parts=[],this.substrs=[],this.start=0,this.end=0}add(e){e&&(this.parts.push(e),this.substrs.push(e.substr),this.start=Math.min(e.start,this.start),this.end=Math.max(e.end,this.end))}last(){return this.parts[this.parts.length-1]}length(){return this.parts.length}clone(e,t){let i=new A,n=JSON.parse(JSON.stringify(this.parts)),s=n.pop();for(const e of n)i.add(e);let o=t.substr.substring(0,e-s.start),r=o.length;return i.add({start:s.start,end:s.start+r,length:r,substr:o}),i}}const x=e=>{void 0===u&&(u=y(d)),e=v(e);let t="",i=[new A];for(let n=0;n0){a=a.sort(((e,t)=>e.length()-t.length()));for(let e of a)E(e,i)||i.push(e)}else if(n>0&&1==l.size&&!l.has("3")){t+=O(i,!1);let e=new A;const n=i[0];n&&e.add(n.last()),i=[e]}}return t+=O(i,!0),t},S=(e,t)=>{if(e)return e[t]},C=(e,t)=>{if(e){for(var i,n=t.split(".");(i=n.shift())&&(e=e[i]););return e}},k=(e,t,i)=>{var n,s;return e?(e+="",null==t.regex||-1===(s=e.search(t.regex))?0:(n=t.string.length/e.length,0===s&&(n+=.5),n*i)):0},I=(e,t)=>{var i=e[t];if("function"==typeof i)return i;i&&!Array.isArray(i)&&(e[t]=[i])},T=(e,t)=>{if(Array.isArray(e))e.forEach(t);else for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},L=(e,t)=>"number"==typeof e&&"number"==typeof t?e>t?1:e(t=v(t+"").toLowerCase())?1:t>e?-1:0;class N{items;settings;constructor(e,t){this.items=e,this.settings=t||{diacritics:!0}}tokenize(e,t,i){if(!e||!e.length)return[];const n=[],s=e.split(/\s+/);var o;return i&&(o=new RegExp("^("+Object.keys(i).map(r).join("|")+"):(.*)$")),s.forEach((e=>{let i,s=null,a=null;o&&(i=e.match(o))&&(s=i[1],e=i[2]),e.length>0&&(a=this.settings.diacritics?x(e)||null:r(e),a&&t&&(a="\\b"+a)),n.push({string:e,regex:a?new RegExp(a,"iu"):null,field:s})})),n}getScoreFunction(e,t){var i=this.prepareSearch(e,t);return this._getScoreFunction(i)}_getScoreFunction(e){const t=e.tokens,i=t.length;if(!i)return function(){return 0};const n=e.options.fields,s=e.weights,o=n.length,r=e.getAttrFn;if(!o)return function(){return 1};const a=1===o?function(e,t){const i=n[0].field;return k(r(t,i),e,s[i]||1)}:function(e,t){var i=0;if(e.field){const n=r(t,e.field);!e.regex&&n?i+=1/o:i+=k(n,e,1)}else T(s,((n,s)=>{i+=k(r(t,s),e,n)}));return i/o};return 1===i?function(e){return a(t[0],e)}:"and"===e.options.conjunction?function(e){var n,s=0;for(let i of t){if((n=a(i,e))<=0)return 0;s+=n}return s/i}:function(e){var n=0;return T(t,(t=>{n+=a(t,e)})),n/i}}getSortFunction(e,t){var i=this.prepareSearch(e,t);return this._getSortFunction(i)}_getSortFunction(e){var t,i=[];const n=this,s=e.options,o=!e.query&&s.sort_empty?s.sort_empty:s.sort;if("function"==typeof o)return o.bind(this);const r=function(t,i){return"$score"===t?i.score:e.getAttrFn(n.items[i.id],t)};if(o)for(let t of o)(e.query||"$score"!==t.field)&&i.push(t);if(e.query){t=!0;for(let e of i)if("$score"===e.field){t=!1;break}t&&i.unshift({field:"$score",direction:"desc"})}else i=i.filter((e=>"$score"!==e.field));return i.length?function(e,t){var n,s;for(let o of i)if(s=o.field,n=("desc"===o.direction?-1:1)*L(r(s,e),r(s,t)))return n;return 0}:null}prepareSearch(e,t){const i={};var n=Object.assign({},t);if(I(n,"sort"),I(n,"sort_empty"),n.fields){I(n,"fields");const e=[];n.fields.forEach((t=>{"string"==typeof t&&(t={field:t,weight:1}),e.push(t),i[t.field]="weight"in t?t.weight:1})),n.fields=e}return{options:n,query:e.toLowerCase().trim(),tokens:this.tokenize(e,n.respect_word_boundaries,i),total:0,items:[],weights:i,getAttrFn:n.nesting?C:S}}search(e,t){var i,n,s=this;n=this.prepareSearch(e,t),t=n.options,e=n.query;const o=t.score||s._getScoreFunction(n);e.length?T(s.items,((e,s)=>{i=o(e),(!1===t.filter||i>0)&&n.items.push({score:i,id:s})})):T(s.items,((e,t)=>{n.items.push({score:1,id:t})}));const r=s._getSortFunction(n);return r&&n.items.sort(r),n.total=n.items.length,"number"==typeof t.limit&&(n.items=n.items.slice(0,t.limit)),n}}const P=e=>null==e?null:$(e),$=e=>"boolean"==typeof e?e?"1":"0":e+"",D=e=>(e+"").replace(/&/g,"&").replace(//g,">").replace(/"/g,"""),j=(e,t)=>{var i;return function(n,s){var o=this;i&&(o.loading=Math.max(o.loading-1,0),clearTimeout(i)),i=setTimeout((function(){i=null,o.loadedSearches[n]=!0,e.call(o,n,s)}),t)}},F=(e,t,i)=>{var n,s=e.trigger,o={};for(n of(e.trigger=function(){var i=arguments[0];if(-1===t.indexOf(i))return s.apply(e,arguments);o[i]=arguments},i.apply(e,[]),e.trigger=s,t))n in o&&s.apply(e,o[n])},M=(e,t=!1)=>{e&&(e.preventDefault(),t&&e.stopPropagation())},q=(e,t,i,n)=>{e.addEventListener(t,i,n)},R=(e,t)=>!!t&&!!t[e]&&1==(t.altKey?1:0)+(t.ctrlKey?1:0)+(t.shiftKey?1:0)+(t.metaKey?1:0),H=(e,t)=>e.getAttribute("id")||(e.setAttribute("id",t),t),z=e=>e.replace(/[\\"']/g,"\\$&"),B=(e,t)=>{t&&e.append(t)},V=(e,t)=>{if(Array.isArray(e))e.forEach(t);else for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},W=e=>{if(e.jquery)return e[0];if(e instanceof HTMLElement)return e;if(K(e)){var t=document.createElement("template");return t.innerHTML=e.trim(),t.content.firstChild}return document.querySelector(e)},K=e=>"string"==typeof e&&e.indexOf("<")>-1,U=(e,t)=>{var i=document.createEvent("HTMLEvents");i.initEvent(t,!0,!1),e.dispatchEvent(i)},Q=(e,t)=>{Object.assign(e.style,t)},J=(e,...t)=>{var i=X(t);(e=G(e)).map((e=>{i.map((t=>{e.classList.add(t)}))}))},Y=(e,...t)=>{var i=X(t);(e=G(e)).map((e=>{i.map((t=>{e.classList.remove(t)}))}))},X=e=>{var t=[];return V(e,(e=>{"string"==typeof e&&(e=e.trim().split(/[\t\n\f\r\s]/)),Array.isArray(e)&&(t=t.concat(e))})),t.filter(Boolean)},G=e=>(Array.isArray(e)||(e=[e]),e),Z=(e,t,i)=>{if(!i||i.contains(e))for(;e&&e.matches;){if(e.matches(t))return e;e=e.parentNode}},ee=(e,t=0)=>t>0?e[e.length-1]:e[0],te=(e,t)=>{if(!e)return-1;t=t||e.nodeName;for(var i=0;e=e.previousElementSibling;)e.matches(t)&&i++;return i},ie=(e,t)=>{V(t,((t,i)=>{null==t?e.removeAttribute(i):e.setAttribute(i,""+t)}))},ne=(e,t)=>{e.parentNode&&e.parentNode.replaceChild(t,e)},se=(e,t)=>{if(null===t)return;if("string"==typeof t){if(!t.length)return;t=new RegExp(t,"i")}const i=e=>3===e.nodeType?(e=>{var i=e.data.match(t);if(i&&e.data.length>0){var n=document.createElement("span");n.className="highlight";var s=e.splitText(i.index);s.splitText(i[0].length);var o=s.cloneNode(!0);return n.appendChild(o),ne(s,n),1}return 0})(e):((e=>{1!==e.nodeType||!e.childNodes||/(script|style)/i.test(e.tagName)||"highlight"===e.className&&"SPAN"===e.tagName||Array.from(e.childNodes).forEach((e=>{i(e)}))})(e),0);i(e)},oe="undefined"!=typeof navigator&&/Mac/.test(navigator.userAgent)?"metaKey":"ctrlKey";var re={options:[],optgroups:[],plugins:[],delimiter:",",splitOn:null,persist:!0,diacritics:!0,create:null,createOnBlur:!1,createFilter:null,highlight:!0,openOnFocus:!0,shouldOpen:null,maxOptions:50,maxItems:null,hideSelected:null,duplicates:!1,addPrecedence:!1,selectOnTab:!1,preload:null,allowEmptyOption:!1,refreshThrottle:300,loadThrottle:300,loadingClass:"loading",dataAttr:null,optgroupField:"optgroup",valueField:"value",labelField:"text",disabledField:"disabled",optgroupLabelField:"label",optgroupValueField:"value",lockOptgroupOrder:!1,sortField:"$order",searchField:["text"],searchConjunction:"and",mode:null,wrapperClass:"ts-wrapper",controlClass:"ts-control",dropdownClass:"ts-dropdown",dropdownContentClass:"ts-dropdown-content",itemClass:"item",optionClass:"option",dropdownParent:null,controlInput:'',copyClassesToDropdown:!1,placeholder:null,hidePlaceholder:null,shouldLoad:function(e){return e.length>0},render:{}};function ae(e,t){var i=Object.assign({},re,t),n=i.dataAttr,s=i.labelField,o=i.valueField,r=i.disabledField,a=i.optgroupField,l=i.optgroupLabelField,c=i.optgroupValueField,d=e.tagName.toLowerCase(),u=e.getAttribute("placeholder")||e.getAttribute("data-placeholder");if(!u&&!i.allowEmptyOption){let t=e.querySelector('option[value=""]');t&&(u=t.textContent)}var h={placeholder:u,options:[],optgroups:[],items:[],maxItems:null};return"select"===d?(()=>{var t,d=h.options,u={},p=1;let f=0;var g=e=>{var t=Object.assign({},e.dataset),i=n&&t[n];return"string"==typeof i&&i.length&&(t=Object.assign(t,JSON.parse(i))),t},m=(e,t)=>{var n=P(e.value);if(null!=n&&(n||i.allowEmptyOption)){if(u.hasOwnProperty(n)){if(t){var l=u[n][a];l?Array.isArray(l)?l.push(t):u[n][a]=[l,t]:u[n][a]=t}}else{var c=g(e);c[s]=c[s]||e.textContent,c[o]=c[o]||n,c[r]=c[r]||e.disabled,c[a]=c[a]||t,c.$option=e,c.$order=c.$order||++f,u[n]=c,d.push(c)}e.selected&&h.items.push(n)}};h.maxItems=e.hasAttribute("multiple")?null:1,V(e.children,(e=>{var i,n,s;"optgroup"===(t=e.tagName.toLowerCase())?((s=g(i=e))[l]=s[l]||i.getAttribute("label")||"",s[c]=s[c]||p++,s[r]=s[r]||i.disabled,s.$order=s.$order||++f,h.optgroups.push(s),n=s[c],V(i.children,(e=>{m(e,n)}))):"option"===t&&m(e)}))})():(()=>{const t=e.getAttribute(n);if(t)h.options=JSON.parse(t),V(h.options,(e=>{h.items.push(e[o])}));else{var r=e.value.trim()||"";if(!i.allowEmptyOption&&!r.length)return;const t=r.split(i.delimiter);V(t,(e=>{const t={};t[s]=e,t[o]=e,h.options.push(t)})),h.items=t}})(),Object.assign({},re,h,t)}var le=0;class ce extends(function(e){return e.plugins={},class extends e{constructor(...e){super(...e),this.plugins={names:[],settings:{},requested:{},loaded:{}}}static define(t,i){e.plugins[t]={name:t,fn:i}}initializePlugins(e){var t,i;const n=this,s=[];if(Array.isArray(e))e.forEach((e=>{"string"==typeof e?s.push(e):(n.plugins.settings[e.name]=e.options,s.push(e.name))}));else if(e)for(t in e)e.hasOwnProperty(t)&&(n.plugins.settings[t]=e[t],s.push(t));for(;i=s.shift();)n.require(i)}loadPlugin(t){var i=this,n=i.plugins,s=e.plugins[t];if(!e.plugins.hasOwnProperty(t))throw new Error('Unable to find "'+t+'" plugin');n.requested[t]=!0,n.loaded[t]=s.fn.apply(i,[i.plugins.settings[t]||{}]),n.names.push(t)}require(e){var t=this,i=t.plugins;if(!t.plugins.loaded.hasOwnProperty(e)){if(i.requested[e])throw new Error('Plugin has circular dependency ("'+e+'")');t.loadPlugin(e)}return i.loaded[e]}}}(t)){constructor(e,t){var i;super(),this.order=0,this.isOpen=!1,this.isDisabled=!1,this.isReadOnly=!1,this.isInvalid=!1,this.isValid=!0,this.isLocked=!1,this.isFocused=!1,this.isInputHidden=!1,this.isSetup=!1,this.ignoreFocus=!1,this.ignoreHover=!1,this.hasOptions=!1,this.lastValue="",this.caretPos=0,this.loading=0,this.loadedSearches={},this.activeOption=null,this.activeItems=[],this.optgroups={},this.options={},this.userOptions={},this.items=[],this.refreshTimeout=null,le++;var n=W(e);if(n.tomselect)throw new Error("Tom Select already initialized on this element");n.tomselect=this,i=(window.getComputedStyle&&window.getComputedStyle(n,null)).getPropertyValue("direction");const s=ae(n,t);this.settings=s,this.input=n,this.tabIndex=n.tabIndex||0,this.is_select_tag="select"===n.tagName.toLowerCase(),this.rtl=/rtl/i.test(i),this.inputId=H(n,"tomselect-"+le),this.isRequired=n.required,this.sifter=new N(this.options,{diacritics:s.diacritics}),s.mode=s.mode||(1===s.maxItems?"single":"multi"),"boolean"!=typeof s.hideSelected&&(s.hideSelected="multi"===s.mode),"boolean"!=typeof s.hidePlaceholder&&(s.hidePlaceholder="multi"!==s.mode);var o=s.createFilter;"function"!=typeof o&&("string"==typeof o&&(o=new RegExp(o)),o instanceof RegExp?s.createFilter=e=>o.test(e):s.createFilter=e=>this.settings.duplicates||!this.options[e]),this.initializePlugins(s.plugins),this.setupCallbacks(),this.setupTemplates();const r=W("
"),a=W("
"),l=this._render("dropdown"),c=W('
'),d=this.input.getAttribute("class")||"",u=s.mode;var h;J(r,s.wrapperClass,d,u),J(a,s.controlClass),B(r,a),J(l,s.dropdownClass,u),s.copyClassesToDropdown&&J(l,d),J(c,s.dropdownContentClass),B(l,c),W(s.dropdownParent||r).appendChild(l),K(s.controlInput)?(h=W(s.controlInput),V(["autocorrect","autocapitalize","autocomplete","spellcheck"],(e=>{n.getAttribute(e)&&ie(h,{[e]:n.getAttribute(e)})})),h.tabIndex=-1,a.appendChild(h),this.focus_node=h):s.controlInput?(h=W(s.controlInput),this.focus_node=h):(h=W(""),this.focus_node=a),this.wrapper=r,this.dropdown=l,this.dropdown_content=c,this.control=a,this.control_input=h,this.setup()}setup(){const e=this,t=e.settings,i=e.control_input,n=e.dropdown,s=e.dropdown_content,o=e.wrapper,a=e.control,l=e.input,c=e.focus_node,d={passive:!0},u=e.inputId+"-ts-dropdown";ie(s,{id:u}),ie(c,{role:"combobox","aria-haspopup":"listbox","aria-expanded":"false","aria-controls":u});const h=H(c,e.inputId+"-ts-control"),p="label[for='"+(e=>e.replace(/['"\\]/g,"\\$&"))(e.inputId)+"']",f=document.querySelector(p),g=e.focus.bind(e);if(f){q(f,"click",g),ie(f,{for:h});const t=H(f,e.inputId+"-ts-label");ie(c,{"aria-labelledby":t}),ie(s,{"aria-labelledby":t})}if(o.style.width=l.style.width,e.plugins.names.length){const t="plugin-"+e.plugins.names.join(" plugin-");J([o,n],t)}(null===t.maxItems||t.maxItems>1)&&e.is_select_tag&&ie(l,{multiple:"multiple"}),t.placeholder&&ie(i,{placeholder:t.placeholder}),!t.splitOn&&t.delimiter&&(t.splitOn=new RegExp("\\s*"+r(t.delimiter)+"+\\s*")),t.load&&t.loadThrottle&&(t.load=j(t.load,t.loadThrottle)),q(n,"mousemove",(()=>{e.ignoreHover=!1})),q(n,"mouseenter",(t=>{var i=Z(t.target,"[data-selectable]",n);i&&e.onOptionHover(t,i)}),{capture:!0}),q(n,"click",(t=>{const i=Z(t.target,"[data-selectable]");i&&(e.onOptionSelect(t,i),M(t,!0))})),q(a,"click",(t=>{var n=Z(t.target,"[data-ts-item]",a);n&&e.onItemSelect(t,n)?M(t,!0):""==i.value&&(e.onClick(),M(t,!0))})),q(c,"keydown",(t=>e.onKeyDown(t))),q(i,"keypress",(t=>e.onKeyPress(t))),q(i,"input",(t=>e.onInput(t))),q(c,"blur",(t=>e.onBlur(t))),q(c,"focus",(t=>e.onFocus(t))),q(i,"paste",(t=>e.onPaste(t)));const m=t=>{const s=t.composedPath()[0];if(!o.contains(s)&&!n.contains(s))return e.isFocused&&e.blur(),void e.inputState();s==i&&e.isOpen?t.stopPropagation():M(t,!0)},v=()=>{e.isOpen&&e.positionDropdown()};q(document,"mousedown",m),q(window,"scroll",v,d),q(window,"resize",v,d),this._destroy=()=>{document.removeEventListener("mousedown",m),window.removeEventListener("scroll",v),window.removeEventListener("resize",v),f&&f.removeEventListener("click",g)},this.revertSettings={innerHTML:l.innerHTML,tabIndex:l.tabIndex},l.tabIndex=-1,l.insertAdjacentElement("afterend",e.wrapper),e.sync(!1),t.items=[],delete t.optgroups,delete t.options,q(l,"invalid",(()=>{e.isValid&&(e.isValid=!1,e.isInvalid=!0,e.refreshState())})),e.updateOriginalInput(),e.refreshItems(),e.close(!1),e.inputState(),e.isSetup=!0,l.disabled?e.disable():l.readOnly?e.setReadOnly(!0):e.enable(),e.on("change",this.onChange),J(l,"tomselected","ts-hidden-accessible"),e.trigger("initialize"),!0===t.preload&&e.preload()}setupOptions(e=[],t=[]){this.addOptions(e),V(t,(e=>{this.registerOptionGroup(e)}))}setupTemplates(){var e=this,t=e.settings.labelField,i=e.settings.optgroupLabelField,n={optgroup:e=>{let t=document.createElement("div");return t.className="optgroup",t.appendChild(e.options),t},optgroup_header:(e,t)=>'
'+t(e[i])+"
",option:(e,i)=>"
"+i(e[t])+"
",item:(e,i)=>"
"+i(e[t])+"
",option_create:(e,t)=>'
Add '+t(e.input)+"
",no_results:()=>'
No results found
',loading:()=>'
',not_loading:()=>{},dropdown:()=>"
"};e.settings.render=Object.assign({},n,e.settings.render)}setupCallbacks(){var e,t,i={initialize:"onInitialize",change:"onChange",item_add:"onItemAdd",item_remove:"onItemRemove",item_select:"onItemSelect",clear:"onClear",option_add:"onOptionAdd",option_remove:"onOptionRemove",option_clear:"onOptionClear",optgroup_add:"onOptionGroupAdd",optgroup_remove:"onOptionGroupRemove",optgroup_clear:"onOptionGroupClear",dropdown_open:"onDropdownOpen",dropdown_close:"onDropdownClose",type:"onType",load:"onLoad",focus:"onFocus",blur:"onBlur"};for(e in i)(t=this.settings[i[e]])&&this.on(e,t)}sync(e=!0){const t=this,i=e?ae(t.input,{delimiter:t.settings.delimiter}):t.settings;t.setupOptions(i.options,i.optgroups),t.setValue(i.items||[],!0),t.lastQuery=null}onClick(){var e=this;if(e.activeItems.length>0)return e.clearActiveItems(),void e.focus();e.isFocused&&e.isOpen?e.blur():e.focus()}onMouseDown(){}onChange(){U(this.input,"input"),U(this.input,"change")}onPaste(e){var t=this;t.isInputHidden||t.isLocked?M(e):t.settings.splitOn&&setTimeout((()=>{var e=t.inputValue();if(e.match(t.settings.splitOn)){var i=e.trim().split(t.settings.splitOn);V(i,(e=>{P(e)&&(this.options[e]?t.addItem(e):t.createItem(e))}))}}),0)}onKeyPress(e){var t=this;if(!t.isLocked){var i=String.fromCharCode(e.keyCode||e.which);return t.settings.create&&"multi"===t.settings.mode&&i===t.settings.delimiter?(t.createItem(),void M(e)):void 0}M(e)}onKeyDown(e){var t=this;if(t.ignoreHover=!0,t.isLocked)9!==e.keyCode&&M(e);else{switch(e.keyCode){case 65:if(R(oe,e)&&""==t.control_input.value)return M(e),void t.selectAll();break;case 27:return t.isOpen&&(M(e,!0),t.close()),void t.clearActiveItems();case 40:if(!t.isOpen&&t.hasOptions)t.open();else if(t.activeOption){let e=t.getAdjacent(t.activeOption,1);e&&t.setActiveOption(e)}return void M(e);case 38:if(t.activeOption){let e=t.getAdjacent(t.activeOption,-1);e&&t.setActiveOption(e)}return void M(e);case 13:return void(t.canSelect(t.activeOption)?(t.onOptionSelect(e,t.activeOption),M(e)):(t.settings.create&&t.createItem()||document.activeElement==t.control_input&&t.isOpen)&&M(e));case 37:return void t.advanceSelection(-1,e);case 39:return void t.advanceSelection(1,e);case 9:return void(t.settings.selectOnTab&&(t.canSelect(t.activeOption)&&(t.onOptionSelect(e,t.activeOption),M(e)),t.settings.create&&t.createItem()&&M(e)));case 8:case 46:return void t.deleteSelection(e)}t.isInputHidden&&!R(oe,e)&&M(e)}}onInput(e){if(this.isLocked)return;const t=this.inputValue();this.lastValue!==t&&(this.lastValue=t,""!=t?(this.refreshTimeout&&window.clearTimeout(this.refreshTimeout),this.refreshTimeout=((e,t)=>t>0?window.setTimeout(e,t):(e.call(null),null))((()=>{this.refreshTimeout=null,this._onInput()}),this.settings.refreshThrottle)):this._onInput())}_onInput(){const e=this.lastValue;this.settings.shouldLoad.call(this,e)&&this.load(e),this.refreshOptions(),this.trigger("type",e)}onOptionHover(e,t){this.ignoreHover||this.setActiveOption(t,!1)}onFocus(e){var t=this,i=t.isFocused;if(t.isDisabled||t.isReadOnly)return t.blur(),void M(e);t.ignoreFocus||(t.isFocused=!0,"focus"===t.settings.preload&&t.preload(),i||t.trigger("focus"),t.activeItems.length||(t.inputState(),t.refreshOptions(!!t.settings.openOnFocus)),t.refreshState())}onBlur(e){if(!1!==document.hasFocus()){var t=this;if(t.isFocused){t.isFocused=!1,t.ignoreFocus=!1;var i=()=>{t.close(),t.setActiveItem(),t.setCaret(t.items.length),t.trigger("blur")};t.settings.create&&t.settings.createOnBlur?t.createItem(null,i):i()}}}onOptionSelect(e,t){var i,n=this;t.parentElement&&t.parentElement.matches("[data-disabled]")||(t.classList.contains("create")?n.createItem(null,(()=>{n.settings.closeAfterSelect&&n.close()})):void 0!==(i=t.dataset.value)&&(n.lastQuery=null,n.addItem(i),n.settings.closeAfterSelect&&n.close(),!n.settings.hideSelected&&e.type&&/click/.test(e.type)&&n.setActiveOption(t)))}canSelect(e){return!!(this.isOpen&&e&&this.dropdown_content.contains(e))}onItemSelect(e,t){var i=this;return!i.isLocked&&"multi"===i.settings.mode&&(M(e),i.setActiveItem(t,e),!0)}canLoad(e){return!!this.settings.load&&!this.loadedSearches.hasOwnProperty(e)}load(e){const t=this;if(!t.canLoad(e))return;J(t.wrapper,t.settings.loadingClass),t.loading++;const i=t.loadCallback.bind(t);t.settings.load.call(t,e,i)}loadCallback(e,t){const i=this;i.loading=Math.max(i.loading-1,0),i.lastQuery=null,i.clearActiveOption(),i.setupOptions(e,t),i.refreshOptions(i.isFocused&&!i.isInputHidden),i.loading||Y(i.wrapper,i.settings.loadingClass),i.trigger("load",e,t)}preload(){var e=this.wrapper.classList;e.contains("preloaded")||(e.add("preloaded"),this.load(""))}setTextboxValue(e=""){var t=this.control_input;t.value!==e&&(t.value=e,U(t,"update"),this.lastValue=e)}getValue(){return this.is_select_tag&&this.input.hasAttribute("multiple")?this.items:this.items.join(this.settings.delimiter)}setValue(e,t){F(this,t?[]:["change"],(()=>{this.clear(t),this.addItems(e,t)}))}setMaxItems(e){0===e&&(e=null),this.settings.maxItems=e,this.refreshState()}setActiveItem(e,t){var i,n,s,o,r,a,l=this;if("single"!==l.settings.mode){if(!e)return l.clearActiveItems(),void(l.isFocused&&l.inputState());if("click"===(i=t&&t.type.toLowerCase())&&R("shiftKey",t)&&l.activeItems.length){for(a=l.getLastActive(),(s=Array.prototype.indexOf.call(l.control.children,a))>(o=Array.prototype.indexOf.call(l.control.children,e))&&(r=s,s=o,o=r),n=s;n<=o;n++)e=l.control.children[n],-1===l.activeItems.indexOf(e)&&l.setActiveItemClass(e);M(t)}else"click"===i&&R(oe,t)||"keydown"===i&&R("shiftKey",t)?e.classList.contains("active")?l.removeActiveItem(e):l.setActiveItemClass(e):(l.clearActiveItems(),l.setActiveItemClass(e));l.inputState(),l.isFocused||l.focus()}}setActiveItemClass(e){const t=this,i=t.control.querySelector(".last-active");i&&Y(i,"last-active"),J(e,"active last-active"),t.trigger("item_select",e),-1==t.activeItems.indexOf(e)&&t.activeItems.push(e)}removeActiveItem(e){var t=this.activeItems.indexOf(e);this.activeItems.splice(t,1),Y(e,"active")}clearActiveItems(){Y(this.activeItems,"active"),this.activeItems=[]}setActiveOption(e,t=!0){e!==this.activeOption&&(this.clearActiveOption(),e&&(this.activeOption=e,ie(this.focus_node,{"aria-activedescendant":e.getAttribute("id")}),ie(e,{"aria-selected":"true"}),J(e,"active"),t&&this.scrollToOption(e)))}scrollToOption(e,t){if(!e)return;const i=this.dropdown_content,n=i.clientHeight,s=i.scrollTop||0,o=e.offsetHeight,r=e.getBoundingClientRect().top-i.getBoundingClientRect().top+s;r+o>n+s?this.scroll(r-n+o,t):r{e.setActiveItemClass(t)})))}inputState(){var e=this;e.control.contains(e.control_input)&&(ie(e.control_input,{placeholder:e.settings.placeholder}),e.activeItems.length>0||!e.isFocused&&e.settings.hidePlaceholder&&e.items.length>0?(e.setTextboxValue(),e.isInputHidden=!0):(e.settings.hidePlaceholder&&e.items.length>0&&ie(e.control_input,{placeholder:""}),e.isInputHidden=!1),e.wrapper.classList.toggle("input-hidden",e.isInputHidden))}inputValue(){return this.control_input.value.trim()}focus(){var e=this;e.isDisabled||e.isReadOnly||(e.ignoreFocus=!0,e.control_input.offsetWidth?e.control_input.focus():e.focus_node.focus(),setTimeout((()=>{e.ignoreFocus=!1,e.onFocus()}),0))}blur(){this.focus_node.blur(),this.onBlur()}getScoreFunction(e){return this.sifter.getScoreFunction(e,this.getSearchOptions())}getSearchOptions(){var e=this.settings,t=e.sortField;return"string"==typeof e.sortField&&(t=[{field:e.sortField}]),{fields:e.searchField,conjunction:e.searchConjunction,sort:t,nesting:e.nesting}}search(e){var t,i,n=this,s=this.getSearchOptions();if(n.settings.score&&"function"!=typeof(i=n.settings.score.call(n,e)))throw new Error('Tom Select "score" setting must be a function that returns a function');return e!==n.lastQuery?(n.lastQuery=e,t=n.sifter.search(e,Object.assign(s,{score:i})),n.currentResults=t):t=Object.assign({},n.currentResults),n.settings.hideSelected&&(t.items=t.items.filter((e=>{let t=P(e.id);return!(t&&-1!==n.items.indexOf(t))}))),t}refreshOptions(e=!0){var t,i,n,s,o,r,a,l,c,d;const u={},h=[];var p=this,f=p.inputValue();const g=f===p.lastQuery||""==f&&null==p.lastQuery;var m=p.search(f),v=null,_=p.settings.shouldOpen||!1,b=p.dropdown_content;g&&(v=p.activeOption)&&(c=v.closest("[data-group]")),s=m.items.length,"number"==typeof p.settings.maxOptions&&(s=Math.min(s,p.settings.maxOptions)),s>0&&(_=!0);const y=(e,t)=>{let i=u[e];if(void 0!==i){let e=h[i];if(void 0!==e)return[i,e.fragment]}let n=document.createDocumentFragment();return i=h.length,h.push({fragment:n,order:t,optgroup:e}),[i,n]};for(t=0;t0&&(d=d.cloneNode(!0),ie(d,{id:a.$id+"-clone-"+i,"aria-selected":null}),d.classList.add("ts-cloned"),Y(d,"active"),p.activeOption&&p.activeOption.dataset.value==s&&c&&c.dataset.group===o.toString()&&(v=d)),l.appendChild(d),""!=o&&(u[o]=n)}}var w;p.settings.lockOptgroupOrder&&h.sort(((e,t)=>e.order-t.order)),a=document.createDocumentFragment(),V(h,(e=>{let t=e.fragment,i=e.optgroup;if(!t||!t.children.length)return;let n=p.optgroups[i];if(void 0!==n){let e=document.createDocumentFragment(),i=p.render("optgroup_header",n);B(e,i),B(e,t);let s=p.render("optgroup",{group:n,options:e});B(a,s)}else B(a,t)})),b.innerHTML="",B(b,a),p.settings.highlight&&(w=b.querySelectorAll("span.highlight"),Array.prototype.forEach.call(w,(function(e){var t=e.parentNode;t.replaceChild(e.firstChild,e),t.normalize()})),m.query.length&&m.tokens.length&&V(m.tokens,(e=>{se(b,e.regex)})));var O=e=>{let t=p.render(e,{input:f});return t&&(_=!0,b.insertBefore(t,b.firstChild)),t};if(p.loading?O("loading"):p.settings.shouldLoad.call(p,f)?0===m.items.length&&O("no_results"):O("not_loading"),(l=p.canCreate(f))&&(d=O("option_create")),p.hasOptions=m.items.length>0||l,_){if(m.items.length>0){if(v||"single"!==p.settings.mode||null==p.items[0]||(v=p.getOption(p.items[0])),!b.contains(v)){let e=0;d&&!p.settings.addPrecedence&&(e=1),v=p.selectable()[e]}}else d&&(v=d);e&&!p.isOpen&&(p.open(),p.scrollToOption(v,"auto")),p.setActiveOption(v)}else p.clearActiveOption(),e&&p.isOpen&&p.close(!1)}selectable(){return this.dropdown_content.querySelectorAll("[data-selectable]")}addOption(e,t=!1){const i=this;if(Array.isArray(e))return i.addOptions(e,t),!1;const n=P(e[i.settings.valueField]);return null!==n&&!i.options.hasOwnProperty(n)&&(e.$order=e.$order||++i.order,e.$id=i.inputId+"-opt-"+e.$order,i.options[n]=e,i.lastQuery=null,t&&(i.userOptions[n]=t,i.trigger("option_add",n,e)),n)}addOptions(e,t=!1){V(e,(e=>{this.addOption(e,t)}))}registerOption(e){return this.addOption(e)}registerOptionGroup(e){var t=P(e[this.settings.optgroupValueField]);return null!==t&&(e.$order=e.$order||++this.order,this.optgroups[t]=e,t)}addOptionGroup(e,t){var i;t[this.settings.optgroupValueField]=e,(i=this.registerOptionGroup(t))&&this.trigger("optgroup_add",i,t)}removeOptionGroup(e){this.optgroups.hasOwnProperty(e)&&(delete this.optgroups[e],this.clearCache(),this.trigger("optgroup_remove",e))}clearOptionGroups(){this.optgroups={},this.clearCache(),this.trigger("optgroup_clear")}updateOption(e,t){const i=this;var n,s;const o=P(e),r=P(t[i.settings.valueField]);if(null===o)return;const a=i.options[o];if(null==a)return;if("string"!=typeof r)throw new Error("Value must be set in option data");const l=i.getOption(o),c=i.getItem(o);if(t.$order=t.$order||a.$order,delete i.options[o],i.uncacheValue(r),i.options[r]=t,l){if(i.dropdown_content.contains(l)){const e=i._render("option",t);ne(l,e),i.activeOption===l&&i.setActiveOption(e)}l.remove()}c&&(-1!==(s=i.items.indexOf(o))&&i.items.splice(s,1,r),n=i._render("item",t),c.classList.contains("active")&&J(n,"active"),ne(c,n)),i.lastQuery=null}removeOption(e,t){const i=this;e=$(e),i.uncacheValue(e),delete i.userOptions[e],delete i.options[e],i.lastQuery=null,i.trigger("option_remove",e),i.removeItem(e,t)}clearOptions(e){const t=(e||this.clearFilter).bind(this);this.loadedSearches={},this.userOptions={},this.clearCache();const i={};V(this.options,((e,n)=>{t(e,n)&&(i[n]=e)})),this.options=this.sifter.items=i,this.lastQuery=null,this.trigger("option_clear")}clearFilter(e,t){return this.items.indexOf(t)>=0}getOption(e,t=!1){const i=P(e);if(null===i)return null;const n=this.options[i];if(null!=n){if(n.$div)return n.$div;if(t)return this._render("option",n)}return null}getAdjacent(e,t,i="option"){var n;if(!e)return null;n="item"==i?this.controlChildren():this.dropdown_content.querySelectorAll("[data-selectable]");for(let i=0;i0?n[i+1]:n[i-1];return null}getItem(e){if("object"==typeof e)return e;var t=P(e);return null!==t?this.control.querySelector(`[data-value="${z(t)}"]`):null}addItems(e,t){var i=this,n=Array.isArray(e)?e:[e];const s=(n=n.filter((e=>-1===i.items.indexOf(e))))[n.length-1];n.forEach((e=>{i.isPending=e!==s,i.addItem(e,t)}))}addItem(e,t){F(this,t?[]:["change","dropdown_close"],(()=>{var i,n;const s=this,o=s.settings.mode,r=P(e);if((!r||-1===s.items.indexOf(r)||("single"===o&&s.close(),"single"!==o&&s.settings.duplicates))&&null!==r&&s.options.hasOwnProperty(r)&&("single"===o&&s.clear(t),"multi"!==o||!s.isFull())){if(i=s._render("item",s.options[r]),s.control.contains(i)&&(i=i.cloneNode(!0)),n=s.isFull(),s.items.splice(s.caretPos,0,r),s.insertAtCaret(i),s.isSetup){if(!s.isPending&&s.settings.hideSelected){let e=s.getOption(r),t=s.getAdjacent(e,1);t&&s.setActiveOption(t)}s.isPending||s.settings.closeAfterSelect||s.refreshOptions(s.isFocused&&"single"!==o),0!=s.settings.closeAfterSelect&&s.isFull()?s.close():s.isPending||s.positionDropdown(),s.trigger("item_add",r,i),s.isPending||s.updateOriginalInput({silent:t})}(!s.isPending||!n&&s.isFull())&&(s.inputState(),s.refreshState())}}))}removeItem(e=null,t){const i=this;if(!(e=i.getItem(e)))return;var n,s;const o=e.dataset.value;n=te(e),e.remove(),e.classList.contains("active")&&(s=i.activeItems.indexOf(e),i.activeItems.splice(s,1),Y(e,"active")),i.items.splice(n,1),i.lastQuery=null,!i.settings.persist&&i.userOptions.hasOwnProperty(o)&&i.removeOption(o,t),n{}){3===arguments.length&&(t=arguments[2]),"function"!=typeof t&&(t=()=>{});var i,n=this,s=n.caretPos;if(e=e||n.inputValue(),!n.canCreate(e))return t(),!1;n.lock();var o=!1,r=e=>{if(n.unlock(),!e||"object"!=typeof e)return t();var i=P(e[n.settings.valueField]);if("string"!=typeof i)return t();n.setTextboxValue(),n.addOption(e,!0),n.setCaret(s),n.addItem(i),t(e),o=!0};return i="function"==typeof n.settings.create?n.settings.create.call(this,e,r):{[n.settings.labelField]:e,[n.settings.valueField]:e},o||r(i),!0}refreshItems(){var e=this;e.lastQuery=null,e.isSetup&&e.addItems(e.items),e.updateOriginalInput(),e.refreshState()}refreshState(){const e=this;e.refreshValidityState();const t=e.isFull(),i=e.isLocked;e.wrapper.classList.toggle("rtl",e.rtl);const n=e.wrapper.classList;var s;n.toggle("focus",e.isFocused),n.toggle("disabled",e.isDisabled),n.toggle("readonly",e.isReadOnly),n.toggle("required",e.isRequired),n.toggle("invalid",!e.isValid),n.toggle("locked",i),n.toggle("full",t),n.toggle("input-active",e.isFocused&&!e.isInputHidden),n.toggle("dropdown-active",e.isOpen),n.toggle("has-options",(s=e.options,0===Object.keys(s).length)),n.toggle("has-items",e.items.length>0)}refreshValidityState(){var e=this;e.input.validity&&(e.isValid=e.input.validity.valid,e.isInvalid=!e.isValid)}isFull(){return null!==this.settings.maxItems&&this.items.length>=this.settings.maxItems}updateOriginalInput(e={}){const t=this;var i,n;const s=t.input.querySelector('option[value=""]');if(t.is_select_tag){const o=[],r=t.input.querySelectorAll("option:checked").length;function a(e,i,n){return e||(e=W('")),e!=s&&t.input.append(e),o.push(e),(e!=s||r>0)&&(e.selected=!0),e}t.input.querySelectorAll("option:checked").forEach((e=>{e.selected=!1})),0==t.items.length&&"single"==t.settings.mode?a(s,"",""):t.items.forEach((e=>{i=t.options[e],n=i[t.settings.labelField]||"",o.includes(i.$option)?a(t.input.querySelector(`option[value="${z(e)}"]:not(:checked)`),e,n):i.$option=a(i.$option,e,n)}))}else t.input.value=t.getValue();t.isSetup&&(e.silent||t.trigger("change",t.getValue()))}open(){var e=this;e.isLocked||e.isOpen||"multi"===e.settings.mode&&e.isFull()||(e.isOpen=!0,ie(e.focus_node,{"aria-expanded":"true"}),e.refreshState(),Q(e.dropdown,{visibility:"hidden",display:"block"}),e.positionDropdown(),Q(e.dropdown,{visibility:"visible",display:"block"}),e.focus(),e.trigger("dropdown_open",e.dropdown))}close(e=!0){var t=this,i=t.isOpen;e&&(t.setTextboxValue(),"single"===t.settings.mode&&t.items.length&&t.inputState()),t.isOpen=!1,ie(t.focus_node,{"aria-expanded":"false"}),Q(t.dropdown,{display:"none"}),t.settings.hideSelected&&t.clearActiveOption(),t.refreshState(),i&&t.trigger("dropdown_close",t.dropdown)}positionDropdown(){if("body"===this.settings.dropdownParent){var e=this.control,t=e.getBoundingClientRect(),i=e.offsetHeight+t.top+window.scrollY,n=t.left+window.scrollX;Q(this.dropdown,{width:t.width+"px",top:i+"px",left:n+"px"})}}clear(e){var t=this;if(t.items.length){var i=t.controlChildren();V(i,(e=>{t.removeItem(e,!0)})),t.inputState(),e||t.updateOriginalInput(),t.trigger("clear")}}insertAtCaret(e){const t=this,i=t.caretPos,n=t.control;n.insertBefore(e,n.children[i]||null),t.setCaret(i+1)}deleteSelection(e){var t,i,n,s,o,r=this;t=e&&8===e.keyCode?-1:1,i={start:(o=r.control_input).selectionStart||0,length:(o.selectionEnd||0)-(o.selectionStart||0)};const a=[];if(r.activeItems.length)s=ee(r.activeItems,t),n=te(s),t>0&&n++,V(r.activeItems,(e=>a.push(e)));else if((r.isFocused||"single"===r.settings.mode)&&r.items.length){const e=r.controlChildren();let n;t<0&&0===i.start&&0===i.length?n=e[r.caretPos-1]:t>0&&i.start===r.inputValue().length&&(n=e[r.caretPos]),void 0!==n&&a.push(n)}if(!r.shouldDelete(a,e))return!1;for(M(e,!0),void 0!==n&&r.setCaret(n);a.length;)r.removeItem(a.pop());return r.inputState(),r.positionDropdown(),r.refreshOptions(!1),!0}shouldDelete(e,t){const i=e.map((e=>e.dataset.value));return!(!i.length||"function"==typeof this.settings.onDelete&&!1===this.settings.onDelete(i,t))}advanceSelection(e,t){var i,n,s=this;s.rtl&&(e*=-1),s.inputValue().length||(R(oe,t)||R("shiftKey",t)?(n=(i=s.getLastActive(e))?i.classList.contains("active")?s.getAdjacent(i,e,"item"):i:e>0?s.control_input.nextElementSibling:s.control_input.previousElementSibling)&&(n.classList.contains("active")&&s.removeActiveItem(i),s.setActiveItemClass(n)):s.moveCaret(e))}moveCaret(e){}getLastActive(e){let t=this.control.querySelector(".last-active");if(t)return t;var i=this.control.querySelectorAll(".active");return i?ee(i,e):void 0}setCaret(e){this.caretPos=this.items.length}controlChildren(){return Array.from(this.control.querySelectorAll("[data-ts-item]"))}lock(){this.setLocked(!0)}unlock(){this.setLocked(!1)}setLocked(e=this.isReadOnly||this.isDisabled){this.isLocked=e,this.refreshState()}disable(){this.setDisabled(!0),this.close()}enable(){this.setDisabled(!1)}setDisabled(e){this.focus_node.tabIndex=e?-1:this.tabIndex,this.isDisabled=e,this.input.disabled=e,this.control_input.disabled=e,this.setLocked()}setReadOnly(e){this.isReadOnly=e,this.input.readOnly=e,this.control_input.readOnly=e,this.setLocked()}destroy(){var e=this,t=e.revertSettings;e.trigger("destroy"),e.off(),e.wrapper.remove(),e.dropdown.remove(),e.input.innerHTML=t.innerHTML,e.input.tabIndex=t.tabIndex,Y(e.input,"tomselected","ts-hidden-accessible"),e._destroy(),delete e.input.tomselect}render(e,t){var i,n;const s=this;if("function"!=typeof this.settings.render[e])return null;if(!(n=s.settings.render[e].call(this,t,D)))return null;if(n=W(n),"option"===e||"option_create"===e?t[s.settings.disabledField]?ie(n,{"aria-disabled":"true"}):ie(n,{"data-selectable":""}):"optgroup"===e&&(i=t.group[s.settings.optgroupValueField],ie(n,{"data-group":i}),t.group[s.settings.disabledField]&&ie(n,{"data-disabled":""})),"option"===e||"item"===e){const i=$(t[s.settings.valueField]);ie(n,{"data-value":i}),"item"===e?(J(n,s.settings.itemClass),ie(n,{"data-ts-item":""})):(J(n,s.settings.optionClass),ie(n,{role:"option",id:t.$id}),t.$div=n,s.options[i]=t)}return n}_render(e,t){const i=this.render(e,t);if(null==i)throw"HTMLElement expected";return i}clearCache(){V(this.options,(e=>{e.$div&&(e.$div.remove(),delete e.$div)}))}uncacheValue(e){const t=this.getOption(e);t&&t.remove()}canCreate(e){return this.settings.create&&e.length>0&&this.settings.createFilter.call(this,e)}hook(e,t,i){var n=this,s=n[t];n[t]=function(){var t,o;return"after"===e&&(t=s.apply(n,arguments)),o=i.apply(n,arguments),"instead"===e?o:("before"===e&&(t=s.apply(n,arguments)),t)}}}return ce.define("change_listener",(function(){q(this.input,"change",(()=>{this.sync()}))})),ce.define("checkbox_options",(function(e){var t=this,i=t.onOptionSelect;t.settings.hideSelected=!1;const n=Object.assign({className:"tomselect-checkbox",checkedClassNames:void 0,uncheckedClassNames:void 0},e);var s=function(e,t){t?(e.checked=!0,n.uncheckedClassNames&&e.classList.remove(...n.uncheckedClassNames),n.checkedClassNames&&e.classList.add(...n.checkedClassNames)):(e.checked=!1,n.checkedClassNames&&e.classList.remove(...n.checkedClassNames),n.uncheckedClassNames&&e.classList.add(...n.uncheckedClassNames))},o=function(e){setTimeout((()=>{var t=e.querySelector("input."+n.className);t instanceof HTMLInputElement&&s(t,e.classList.contains("selected"))}),1)};t.hook("after","setupTemplates",(()=>{var e=t.settings.render.option;t.settings.render.option=(i,o)=>{var r=W(e.call(t,i,o)),a=document.createElement("input");n.className&&a.classList.add(n.className),a.addEventListener("click",(function(e){M(e)})),a.type="checkbox";const l=P(i[t.settings.valueField]);return s(a,!!(l&&t.items.indexOf(l)>-1)),r.prepend(a),r}})),t.on("item_remove",(e=>{var i=t.getOption(e);i&&(i.classList.remove("selected"),o(i))})),t.on("item_add",(e=>{var i=t.getOption(e);i&&o(i)})),t.hook("instead","onOptionSelect",((e,n)=>{if(n.classList.contains("selected"))return n.classList.remove("selected"),t.removeItem(n.dataset.value),t.refreshOptions(),void M(e,!0);i.call(t,e,n),o(n)}))})),ce.define("clear_button",(function(e){const t=this,i=Object.assign({className:"clear-button",title:"Clear All",html:e=>`
`},e);t.on("initialize",(()=>{var e=W(i.html(i));e.addEventListener("click",(e=>{t.isLocked||(t.clear(),"single"===t.settings.mode&&t.settings.allowEmptyOption&&t.addItem(""),e.preventDefault(),e.stopPropagation())})),t.control.appendChild(e)}))})),ce.define("drag_drop",(function(){var e=this;if("multi"!==e.settings.mode)return;var t=e.lock,i=e.unlock;let n,s=!0;e.hook("after","setupTemplates",(()=>{var t=e.settings.render.item;e.settings.render.item=(i,o)=>{const r=W(t.call(e,i,o));ie(r,{draggable:"true"});const a=e=>{e.preventDefault(),r.classList.add("ts-drag-over"),l(r,n)},l=(e,t)=>{var i,n,s;void 0!==t&&(((e,t)=>{do{var i;if(e==(t=null==(i=t)?void 0:i.previousElementSibling))return!0}while(t&&t.previousElementSibling);return!1})(t,r)?(n=t,null==(s=(i=e).parentNode)||s.insertBefore(n,i.nextSibling)):((e,t)=>{var i;null==(i=e.parentNode)||i.insertBefore(t,e)})(e,t))};return q(r,"mousedown",(e=>{s||M(e),e.stopPropagation()})),q(r,"dragstart",(e=>{n=r,setTimeout((()=>{r.classList.add("ts-dragging")}),0)})),q(r,"dragenter",a),q(r,"dragover",a),q(r,"dragleave",(()=>{r.classList.remove("ts-drag-over")})),q(r,"dragend",(()=>{var t;document.querySelectorAll(".ts-drag-over").forEach((e=>e.classList.remove("ts-drag-over"))),null==(t=n)||t.classList.remove("ts-dragging"),n=void 0;var i=[];e.control.querySelectorAll("[data-value]").forEach((e=>{if(e.dataset.value){let t=e.dataset.value;t&&i.push(t)}})),e.setValue(i)})),r}})),e.hook("instead","lock",(()=>(s=!1,t.call(e)))),e.hook("instead","unlock",(()=>(s=!0,i.call(e))))})),ce.define("dropdown_header",(function(e){const t=this,i=Object.assign({title:"Untitled",headerClass:"dropdown-header",titleRowClass:"dropdown-header-title",labelClass:"dropdown-header-label",closeClass:"dropdown-header-close",html:e=>'
'+e.title+'×
'},e);t.on("initialize",(()=>{var e=W(i.html(i)),n=e.querySelector("."+i.closeClass);n&&n.addEventListener("click",(e=>{M(e,!0),t.close()})),t.dropdown.insertBefore(e,t.dropdown.firstChild)}))})),ce.define("caret_position",(function(){var e=this;e.hook("instead","setCaret",(t=>{"single"!==e.settings.mode&&e.control.contains(e.control_input)?(t=Math.max(0,Math.min(e.items.length,t)))==e.caretPos||e.isPending||e.controlChildren().forEach(((i,n)=>{n{if(!e.isFocused)return;const i=e.getLastActive(t);if(i){const n=te(i);e.setCaret(t>0?n+1:n),e.setActiveItem(),Y(i,"last-active")}else e.setCaret(e.caretPos+t)}))})),ce.define("dropdown_input",(function(){const e=this;e.settings.shouldOpen=!0,e.hook("before","setup",(()=>{e.focus_node=e.control,J(e.control_input,"dropdown-input");const t=W('")}},plugins:{dropdown_input:{}}};return null===e.getAttribute("required")&&null===e.getAttribute("disabled")&&(t.plugins.clear_button={title:""}),null!==e.getAttribute("multiple")&&(t.plugins.remove_button={title:""}),null!==e.getAttribute("data-ea-autocomplete-endpoint-url")&&(t.plugins.virtual_scroll={}),"true"===e.getAttribute("data-ea-autocomplete-allow-item-create")&&(t.create=!0),t}function b(e){var t=g(m,this,E).call(this,g(m,this,_).call(this,e),{maxOptions:null});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:t,prefix:"autocomplete"},bubbles:!0}));var i=new(a())(e,t);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:i,config:t,prefix:"autocomplete"},bubbles:!0})),i}function y(e){for(var t=[],i=0;i".concat(e.label_raw,"
")},option:function(e,t){return"
".concat(e.label_raw,"
")}}});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:o,prefix:"autocomplete"},bubbles:!0}));var r=new(a())(e,o);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:r,config:o,prefix:"autocomplete"},bubbles:!0})),r}function w(e,t){var i="true"===e.getAttribute("data-ea-autocomplete-render-items-as-html"),n=g(m,this,E).call(this,g(m,this,_).call(this,e),{valueField:"entityId",labelField:"entityAsString",searchField:["entityAsString"],firstUrl:function(e){return"".concat(t,"&query=").concat(encodeURIComponent(e))},load:function(e,t){var i=this,n=this.getUrl(e);fetch(n).then((function(e){return e.json()})).then((function(n){i.setNextUrl(e,n.next_page),t(n.results)})).catch((function(){return t()}))},preload:"focus",maxOptions:null,score:function(e){return function(e){return 1}},render:{option:function(e,t){return"
".concat(i?e.entityAsString:t(e.entityAsString),"
")},item:function(e,t){return"
".concat(i?e.entityAsString:t(e.entityAsString),"
")},loading_more:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-loading-more-results"),"
")},no_more_results:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-no-more-results"),"
")},no_results:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-no-results-found"),"
")}}});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:n,prefix:"autocomplete"},bubbles:!0}));var s=new(a())(e,n);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:s,config:n,prefix:"autocomplete"},bubbles:!0})),s}function O(e){return e.replace(/(<([^>]+)>)/gi,"")}function E(e,t){return d(d({},e),t)}function A(e,t){t?(e.classList.remove("d-block"),e.classList.add("d-none")):(e.classList.remove("d-none"),e.classList.add("d-block"))}function x(e){return x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},x(e)}function S(e,t){for(var i=0;i
',fetch(t.getAttribute("href")).then((function(e){return e.text()})).then((function(t){s.innerHTML=t,P(j,e,W).call(e),P(j,e,J).call(e)})).catch((function(e){console.error(e)})),n.preventDefault()}));var n=function(e){e.closest("form").querySelectorAll('input[name^="filters['.concat(e.dataset.filterProperty,']"]')).forEach((function(e){e.remove()})),e.remove()};document.querySelector("#modal-clear-button").addEventListener("click",(function(){i.querySelectorAll(".filter-field").forEach((function(e){n(e)})),i.querySelector("form").submit()})),document.querySelector("#modal-apply-button").addEventListener("click",(function(){i.querySelectorAll(".filter-checkbox:not(:checked)").forEach((function(e){n(e.closest(".filter-field"))})),i.querySelector("form").submit()}))}}function V(){var e=null,t=document.querySelector(".form-batch-checkbox-all");if(null!==t){var i=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox');t.addEventListener("change",(function(){i.forEach((function(e){e.checked=t.checked,e.dispatchEvent(new Event("change"))}))}));var n=document.querySelector(".deselect-batch-button");null!==n&&n.addEventListener("click",(function(){t.checked=!1,t.dispatchEvent(new Event("change"))})),i.forEach((function(n,s){n.dataset.rowIndex=s,n.addEventListener("click",(function(t){if(e&&t.shiftKey){var n=Number.parseInt(e.dataset.rowIndex),s=Number.parseInt(t.target.dataset.rowIndex),o=t.target.checked,r=Math.min(n,s),a=Math.max(n,s);i.forEach((function(e,t){r<=t&&t<=a&&(e.checked=o,e.dispatchEvent(new Event("change")))}))}e=t.target})),n.addEventListener("change",(function(){var e=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox:checked'),i=n.closest("tr"),s=n.closest(".content");n.checked?i.classList.add("selected-row"):(i.classList.remove("selected-row"),t.checked=!1);var o=0!==e.length,r=document.querySelector(".content-header-title > .title"),a=s.querySelector(".datagrid-filters"),l=s.querySelector(".global-actions"),c=s.querySelector(".batch-actions");null!==r&&A(r,o),null!==a&&A(a,o),null!==l&&A(l,o),null!==c&&A(c,!o)}))}));var s=document.querySelector("#batch-action-confirmation-title"),o=s.textContent;document.querySelectorAll("[data-action-batch]").forEach((function(e){e.addEventListener("click",(function(e){e.preventDefault();var t=e.currentTarget,i=t.textContent.trim()||t.getAttribute("title"),n=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox:checked');s.textContent=o.replace("%action_name%",i).replace("%num_items%",n.length.toString()),document.querySelector("#modal-batch-action-button").addEventListener("click",(function(){t.setAttribute("disabled","disabled");var e={batchActionName:t.getAttribute("data-action-name"),entityFqcn:t.getAttribute("data-entity-fqcn"),batchActionUrl:t.getAttribute("data-action-url"),batchActionCsrfToken:t.getAttribute("data-action-csrf-token")};n.forEach((function(t,i){e["batchActionEntityIds[".concat(i,"]")]=t.value}));var i=document.createElement("form");for(var s in i.setAttribute("method","POST"),i.setAttribute("action",t.getAttribute("data-action-url")),e){var o=document.createElement("input");o.setAttribute("type","hidden"),o.setAttribute("name",s),o.setAttribute("value",e[s]),i.appendChild(o)}document.body.appendChild(i),i.submit()}))}))}))}}function W(){var e=new v;document.querySelectorAll('[data-ea-widget="ea-autocomplete"]').forEach((function(t){e.create(t)}))}function K(){document.querySelectorAll('[data-action-name="delete"]').forEach((function(e){e.addEventListener("click",(function(t){t.preventDefault(),document.querySelector("#modal-delete-button").addEventListener("click",(function(){var t=e.getAttribute("formaction"),i=document.querySelector("#delete-form");i.setAttribute("action",t),i.submit()}))}))}))}function U(){document.querySelectorAll('[data-bs-toggle="popover"]').forEach((function(e){new(t().Popover)(e)}))}function Q(){document.querySelectorAll('[data-bs-toggle="tooltip"]').forEach((function(e){new(t().Tooltip)(e)}))}function J(){document.querySelectorAll(".filter-checkbox").forEach((function(e){e.addEventListener("change",(function(){var t=e.nextElementSibling,i=e.nextElementSibling.getAttribute("aria-expanded");(e.checked&&"false"===i||!e.checked&&"true"===i)&&t.click()}))})),document.querySelectorAll("form[data-ea-filters-form-id]").forEach((function(e){e.addEventListener("change",(function(e){if(!e.target.classList.contains("filter-checkbox")){var t=e.target.closest(".filter-field").querySelector(".filter-checkbox");t.checked||(t.checked=!0)}}))})),document.querySelectorAll("[data-ea-comparison-id]").forEach((function(e){e.addEventListener("change",(function(e){var t=e.currentTarget,i=t.dataset.eaComparisonId;if(void 0!==i){var n=document.querySelector('[data-ea-value2-of-comparison-id="'.concat(i,'"]'));null!==n&&A(n,"between"!==t.value)}}))}))}})()})(); \ No newline at end of file +/*! For license information please see app.b25cfb59.js.LICENSE.txt */ +(()=>{var e={414:function(e){e.exports=function(){"use strict";const e=new Map,t={set(t,i,n){e.has(t)||e.set(t,new Map);const s=e.get(t);s.has(i)||0===s.size?s.set(i,n):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(t,i)=>e.has(t)&&e.get(t).get(i)||null,remove(t,i){if(!e.has(t))return;const n=e.get(t);n.delete(i),0===n.size&&e.delete(t)}},i=1e6,n=1e3,s="transitionend",o=e=>(e&&window.CSS&&window.CSS.escape&&(e=e.replace(/#([^\s"#']+)/g,((e,t)=>`#${CSS.escape(t)}`))),e),r=e=>null==e?`${e}`:Object.prototype.toString.call(e).match(/\s([a-z]+)/i)[1].toLowerCase(),a=e=>{do{e+=Math.floor(Math.random()*i)}while(document.getElementById(e));return e},l=e=>{if(!e)return 0;let{transitionDuration:t,transitionDelay:i}=window.getComputedStyle(e);const s=Number.parseFloat(t),o=Number.parseFloat(i);return s||o?(t=t.split(",")[0],i=i.split(",")[0],(Number.parseFloat(t)+Number.parseFloat(i))*n):0},c=e=>{e.dispatchEvent(new Event(s))},d=e=>!(!e||"object"!=typeof e)&&(void 0!==e.jquery&&(e=e[0]),void 0!==e.nodeType),u=e=>d(e)?e.jquery?e[0]:e:"string"==typeof e&&e.length>0?document.querySelector(o(e)):null,h=e=>{if(!d(e)||0===e.getClientRects().length)return!1;const t="visible"===getComputedStyle(e).getPropertyValue("visibility"),i=e.closest("details:not([open])");if(!i)return t;if(i!==e){const t=e.closest("summary");if(t&&t.parentNode!==i)return!1;if(null===t)return!1}return t},p=e=>!e||e.nodeType!==Node.ELEMENT_NODE||!!e.classList.contains("disabled")||(void 0!==e.disabled?e.disabled:e.hasAttribute("disabled")&&"false"!==e.getAttribute("disabled")),f=e=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){const t=e.getRootNode();return t instanceof ShadowRoot?t:null}return e instanceof ShadowRoot?e:e.parentNode?f(e.parentNode):null},g=()=>{},m=e=>{e.offsetHeight},v=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,_=[],b=e=>{"loading"===document.readyState?(_.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of _)e()})),_.push(e)):e()},y=()=>"rtl"===document.documentElement.dir,w=e=>{b((()=>{const t=v();if(t){const i=e.NAME,n=t.fn[i];t.fn[i]=e.jQueryInterface,t.fn[i].Constructor=e,t.fn[i].noConflict=()=>(t.fn[i]=n,e.jQueryInterface)}}))},O=(e,t=[],i=e)=>"function"==typeof e?e(...t):i,E=(e,t,i=!0)=>{if(!i)return void O(e);const n=5,o=l(t)+n;let r=!1;const a=({target:i})=>{i===t&&(r=!0,t.removeEventListener(s,a),O(e))};t.addEventListener(s,a),setTimeout((()=>{r||c(t)}),o)},A=(e,t,i,n)=>{const s=e.length;let o=e.indexOf(t);return-1===o?!i&&n?e[s-1]:e[0]:(o+=i?1:-1,n&&(o=(o+s)%s),e[Math.max(0,Math.min(o,s-1))])},x=/[^.]*(?=\..*)\.|.*/,S=/\..*/,C=/::\d+$/,k={};let I=1;const T={mouseenter:"mouseover",mouseleave:"mouseout"},L=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 N(e,t){return t&&`${t}::${I++}`||e.uidEvent||I++}function P(e){const t=N(e);return e.uidEvent=t,k[t]=k[t]||{},k[t]}function $(e,t){return function i(n){return B(n,{delegateTarget:e}),i.oneOff&&z.off(e,n.type,t),t.apply(e,[n])}}function D(e,t,i){return function n(s){const o=e.querySelectorAll(t);for(let{target:r}=s;r&&r!==this;r=r.parentNode)for(const a of o)if(a===r)return B(s,{delegateTarget:r}),n.oneOff&&z.off(e,s.type,t,i),i.apply(r,[s])}}function j(e,t,i=null){return Object.values(e).find((e=>e.callable===t&&e.delegationSelector===i))}function F(e,t,i){const n="string"==typeof t,s=n?i:t||i;let o=H(e);return L.has(o)||(o=e),[n,s,o]}function M(e,t,i,n,s){if("string"!=typeof t||!e)return;let[o,r,a]=F(t,i,n);if(t in T){const e=e=>function(t){if(!t.relatedTarget||t.relatedTarget!==t.delegateTarget&&!t.delegateTarget.contains(t.relatedTarget))return e.call(this,t)};r=e(r)}const l=P(e),c=l[a]||(l[a]={}),d=j(c,r,o?i:null);if(d)return void(d.oneOff=d.oneOff&&s);const u=N(r,t.replace(x,"")),h=o?D(e,i,r):$(e,r);h.delegationSelector=o?i:null,h.callable=r,h.oneOff=s,h.uidEvent=u,c[u]=h,e.addEventListener(a,h,o)}function q(e,t,i,n,s){const o=j(t[i],n,s);o&&(e.removeEventListener(i,o,Boolean(s)),delete t[i][o.uidEvent])}function R(e,t,i,n){const s=t[i]||{};for(const[o,r]of Object.entries(s))o.includes(n)&&q(e,t,i,r.callable,r.delegationSelector)}function H(e){return e=e.replace(S,""),T[e]||e}const z={on(e,t,i,n){M(e,t,i,n,!1)},one(e,t,i,n){M(e,t,i,n,!0)},off(e,t,i,n){if("string"!=typeof t||!e)return;const[s,o,r]=F(t,i,n),a=r!==t,l=P(e),c=l[r]||{},d=t.startsWith(".");if(void 0===o){if(d)for(const i of Object.keys(l))R(e,l,i,t.slice(1));for(const[i,n]of Object.entries(c)){const s=i.replace(C,"");a&&!t.includes(s)||q(e,l,r,n.callable,n.delegationSelector)}}else{if(!Object.keys(c).length)return;q(e,l,r,o,s?i:null)}},trigger(e,t,i){if("string"!=typeof t||!e)return null;const n=v();let s=null,o=!0,r=!0,a=!1;t!==H(t)&&n&&(s=n.Event(t,i),n(e).trigger(s),o=!s.isPropagationStopped(),r=!s.isImmediatePropagationStopped(),a=s.isDefaultPrevented());const l=B(new Event(t,{bubbles:o,cancelable:!0}),i);return a&&l.preventDefault(),r&&e.dispatchEvent(l),l.defaultPrevented&&s&&s.preventDefault(),l}};function B(e,t={}){for(const[i,n]of Object.entries(t))try{e[i]=n}catch(t){Object.defineProperty(e,i,{configurable:!0,get:()=>n})}return e}function V(e){if("true"===e)return!0;if("false"===e)return!1;if(e===Number(e).toString())return Number(e);if(""===e||"null"===e)return null;if("string"!=typeof e)return e;try{return JSON.parse(decodeURIComponent(e))}catch(t){return e}}function W(e){return e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`))}const K={setDataAttribute(e,t,i){e.setAttribute(`data-bs-${W(t)}`,i)},removeDataAttribute(e,t){e.removeAttribute(`data-bs-${W(t)}`)},getDataAttributes(e){if(!e)return{};const t={},i=Object.keys(e.dataset).filter((e=>e.startsWith("bs")&&!e.startsWith("bsConfig")));for(const n of i){let i=n.replace(/^bs/,"");i=i.charAt(0).toLowerCase()+i.slice(1,i.length),t[i]=V(e.dataset[n])}return t},getDataAttribute:(e,t)=>V(e.getAttribute(`data-bs-${W(t)}`))};class U{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(e){return e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e}_mergeConfigObj(e,t){const i=d(t)?K.getDataAttribute(t,"config"):{};return{...this.constructor.Default,..."object"==typeof i?i:{},...d(t)?K.getDataAttributes(t):{},..."object"==typeof e?e:{}}}_typeCheckConfig(e,t=this.constructor.DefaultType){for(const[i,n]of Object.entries(t)){const t=e[i],s=d(t)?"element":r(t);if(!new RegExp(n).test(s))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${i}" provided type "${s}" but expected type "${n}".`)}}}const Q="5.3.3";class J extends U{constructor(e,i){super(),(e=u(e))&&(this._element=e,this._config=this._getConfig(i),t.set(this._element,this.constructor.DATA_KEY,this))}dispose(){t.remove(this._element,this.constructor.DATA_KEY),z.off(this._element,this.constructor.EVENT_KEY);for(const e of Object.getOwnPropertyNames(this))this[e]=null}_queueCallback(e,t,i=!0){E(e,t,i)}_getConfig(e){return e=this._mergeConfigObj(e,this._element),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static getInstance(e){return t.get(u(e),this.DATA_KEY)}static getOrCreateInstance(e,t={}){return this.getInstance(e)||new this(e,"object"==typeof t?t:null)}static get VERSION(){return Q}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(e){return`${e}${this.EVENT_KEY}`}}const Y=e=>{let t=e.getAttribute("data-bs-target");if(!t||"#"===t){let i=e.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),t=i&&"#"!==i?i.trim():null}return t?t.split(",").map((e=>o(e))).join(","):null},X={find:(e,t=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(t,e)),findOne:(e,t=document.documentElement)=>Element.prototype.querySelector.call(t,e),children:(e,t)=>[].concat(...e.children).filter((e=>e.matches(t))),parents(e,t){const i=[];let n=e.parentNode.closest(t);for(;n;)i.push(n),n=n.parentNode.closest(t);return i},prev(e,t){let i=e.previousElementSibling;for(;i;){if(i.matches(t))return[i];i=i.previousElementSibling}return[]},next(e,t){let i=e.nextElementSibling;for(;i;){if(i.matches(t))return[i];i=i.nextElementSibling}return[]},focusableChildren(e){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((e=>`${e}:not([tabindex^="-"])`)).join(",");return this.find(t,e).filter((e=>!p(e)&&h(e)))},getSelectorFromElement(e){const t=Y(e);return t&&X.findOne(t)?t:null},getElementFromSelector(e){const t=Y(e);return t?X.findOne(t):null},getMultipleElementsFromSelector(e){const t=Y(e);return t?X.find(t):[]}},G=(e,t="hide")=>{const i=`click.dismiss${e.EVENT_KEY}`,n=e.NAME;z.on(document,i,`[data-bs-dismiss="${n}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),p(this))return;const s=X.getElementFromSelector(this)||this.closest(`.${n}`);e.getOrCreateInstance(s)[t]()}))},Z="alert",ee=".bs.alert",te=`close${ee}`,ie=`closed${ee}`,ne="fade",se="show";class oe extends J{static get NAME(){return Z}close(){if(z.trigger(this._element,te).defaultPrevented)return;this._element.classList.remove(se);const e=this._element.classList.contains(ne);this._queueCallback((()=>this._destroyElement()),this._element,e)}_destroyElement(){this._element.remove(),z.trigger(this._element,ie),this.dispose()}static jQueryInterface(e){return this.each((function(){const t=oe.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}G(oe,"close"),w(oe);const re="button",ae="active",le='[data-bs-toggle="button"]',ce="click.bs.button.data-api";class de extends J{static get NAME(){return re}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle(ae))}static jQueryInterface(e){return this.each((function(){const t=de.getOrCreateInstance(this);"toggle"===e&&t[e]()}))}}z.on(document,ce,le,(e=>{e.preventDefault();const t=e.target.closest(le);de.getOrCreateInstance(t).toggle()})),w(de);const ue="swipe",he=".bs.swipe",pe=`touchstart${he}`,fe=`touchmove${he}`,ge=`touchend${he}`,me=`pointerdown${he}`,ve=`pointerup${he}`,_e="touch",be="pen",ye="pointer-event",we=40,Oe={endCallback:null,leftCallback:null,rightCallback:null},Ee={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class Ae extends U{constructor(e,t){super(),this._element=e,e&&Ae.isSupported()&&(this._config=this._getConfig(t),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return Oe}static get DefaultType(){return Ee}static get NAME(){return ue}dispose(){z.off(this._element,he)}_start(e){this._supportPointerEvents?this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX):this._deltaX=e.touches[0].clientX}_end(e){this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX-this._deltaX),this._handleSwipe(),O(this._config.endCallback)}_move(e){this._deltaX=e.touches&&e.touches.length>1?0:e.touches[0].clientX-this._deltaX}_handleSwipe(){const e=Math.abs(this._deltaX);if(e<=we)return;const t=e/this._deltaX;this._deltaX=0,t&&O(t>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(z.on(this._element,me,(e=>this._start(e))),z.on(this._element,ve,(e=>this._end(e))),this._element.classList.add(ye)):(z.on(this._element,pe,(e=>this._start(e))),z.on(this._element,fe,(e=>this._move(e))),z.on(this._element,ge,(e=>this._end(e))))}_eventIsPointerPenTouch(e){return this._supportPointerEvents&&(e.pointerType===be||e.pointerType===_e)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const xe="carousel",Se=".bs.carousel",Ce=".data-api",ke="ArrowLeft",Ie="ArrowRight",Te=500,Le="next",Ne="prev",Pe="left",$e="right",De=`slide${Se}`,je=`slid${Se}`,Fe=`keydown${Se}`,Me=`mouseenter${Se}`,qe=`mouseleave${Se}`,Re=`dragstart${Se}`,He=`load${Se}${Ce}`,ze=`click${Se}${Ce}`,Be="carousel",Ve="active",We="slide",Ke="carousel-item-end",Ue="carousel-item-start",Qe="carousel-item-next",Je="carousel-item-prev",Ye=".active",Xe=".carousel-item",Ge=Ye+Xe,Ze=".carousel-item img",et=".carousel-indicators",tt="[data-bs-slide], [data-bs-slide-to]",it='[data-bs-ride="carousel"]',nt={[ke]:$e,[Ie]:Pe},st={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},ot={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class rt extends J{constructor(e,t){super(e,t),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=X.findOne(et,this._element),this._addEventListeners(),this._config.ride===Be&&this.cycle()}static get Default(){return st}static get DefaultType(){return ot}static get NAME(){return xe}next(){this._slide(Le)}nextWhenVisible(){!document.hidden&&h(this._element)&&this.next()}prev(){this._slide(Ne)}pause(){this._isSliding&&c(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval((()=>this.nextWhenVisible()),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?z.one(this._element,je,(()=>this.cycle())):this.cycle())}to(e){const t=this._getItems();if(e>t.length-1||e<0)return;if(this._isSliding)return void z.one(this._element,je,(()=>this.to(e)));const i=this._getItemIndex(this._getActive());if(i===e)return;const n=e>i?Le:Ne;this._slide(n,t[e])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(e){return e.defaultInterval=e.interval,e}_addEventListeners(){this._config.keyboard&&z.on(this._element,Fe,(e=>this._keydown(e))),"hover"===this._config.pause&&(z.on(this._element,Me,(()=>this.pause())),z.on(this._element,qe,(()=>this._maybeEnableCycle()))),this._config.touch&&Ae.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const e of X.find(Ze,this._element))z.on(e,Re,(e=>e.preventDefault()));const e={leftCallback:()=>this._slide(this._directionToOrder(Pe)),rightCallback:()=>this._slide(this._directionToOrder($e)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),Te+this._config.interval))}};this._swipeHelper=new Ae(this._element,e)}_keydown(e){if(/input|textarea/i.test(e.target.tagName))return;const t=nt[e.key];t&&(e.preventDefault(),this._slide(this._directionToOrder(t)))}_getItemIndex(e){return this._getItems().indexOf(e)}_setActiveIndicatorElement(e){if(!this._indicatorsElement)return;const t=X.findOne(Ye,this._indicatorsElement);t.classList.remove(Ve),t.removeAttribute("aria-current");const i=X.findOne(`[data-bs-slide-to="${e}"]`,this._indicatorsElement);i&&(i.classList.add(Ve),i.setAttribute("aria-current","true"))}_updateInterval(){const e=this._activeElement||this._getActive();if(!e)return;const t=Number.parseInt(e.getAttribute("data-bs-interval"),10);this._config.interval=t||this._config.defaultInterval}_slide(e,t=null){if(this._isSliding)return;const i=this._getActive(),n=e===Le,s=t||A(this._getItems(),i,n,this._config.wrap);if(s===i)return;const o=this._getItemIndex(s),r=t=>z.trigger(this._element,t,{relatedTarget:s,direction:this._orderToDirection(e),from:this._getItemIndex(i),to:o});if(r(De).defaultPrevented)return;if(!i||!s)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=s;const l=n?Ue:Ke,c=n?Qe:Je;s.classList.add(c),m(s),i.classList.add(l),s.classList.add(l);const d=()=>{s.classList.remove(l,c),s.classList.add(Ve),i.classList.remove(Ve,c,l),this._isSliding=!1,r(je)};this._queueCallback(d,i,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains(We)}_getActive(){return X.findOne(Ge,this._element)}_getItems(){return X.find(Xe,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(e){return y()?e===Pe?Ne:Le:e===Pe?Le:Ne}_orderToDirection(e){return y()?e===Ne?Pe:$e:e===Ne?$e:Pe}static jQueryInterface(e){return this.each((function(){const t=rt.getOrCreateInstance(this,e);if("number"!=typeof e){if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}else t.to(e)}))}}z.on(document,ze,tt,(function(e){const t=X.getElementFromSelector(this);if(!t||!t.classList.contains(Be))return;e.preventDefault();const i=rt.getOrCreateInstance(t),n=this.getAttribute("data-bs-slide-to");return n?(i.to(n),void i._maybeEnableCycle()):"next"===K.getDataAttribute(this,"slide")?(i.next(),void i._maybeEnableCycle()):(i.prev(),void i._maybeEnableCycle())})),z.on(window,He,(()=>{const e=X.find(it);for(const t of e)rt.getOrCreateInstance(t)})),w(rt);const at="collapse",lt=".bs.collapse",ct=`show${lt}`,dt=`shown${lt}`,ut=`hide${lt}`,ht=`hidden${lt}`,pt=`click${lt}.data-api`,ft="show",gt="collapse",mt="collapsing",vt="collapsed",_t=`:scope .${gt} .${gt}`,bt="collapse-horizontal",yt="width",wt="height",Ot=".collapse.show, .collapse.collapsing",Et='[data-bs-toggle="collapse"]',At={parent:null,toggle:!0},xt={parent:"(null|element)",toggle:"boolean"};class St extends J{constructor(e,t){super(e,t),this._isTransitioning=!1,this._triggerArray=[];const i=X.find(Et);for(const e of i){const t=X.getSelectorFromElement(e),i=X.find(t).filter((e=>e===this._element));null!==t&&i.length&&this._triggerArray.push(e)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return At}static get DefaultType(){return xt}static get NAME(){return at}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let e=[];if(this._config.parent&&(e=this._getFirstLevelChildren(Ot).filter((e=>e!==this._element)).map((e=>St.getOrCreateInstance(e,{toggle:!1})))),e.length&&e[0]._isTransitioning)return;if(z.trigger(this._element,ct).defaultPrevented)return;for(const t of e)t.hide();const t=this._getDimension();this._element.classList.remove(gt),this._element.classList.add(mt),this._element.style[t]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=()=>{this._isTransitioning=!1,this._element.classList.remove(mt),this._element.classList.add(gt,ft),this._element.style[t]="",z.trigger(this._element,dt)},n=`scroll${t[0].toUpperCase()+t.slice(1)}`;this._queueCallback(i,this._element,!0),this._element.style[t]=`${this._element[n]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(z.trigger(this._element,ut).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,m(this._element),this._element.classList.add(mt),this._element.classList.remove(gt,ft);for(const e of this._triggerArray){const t=X.getElementFromSelector(e);t&&!this._isShown(t)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0;const t=()=>{this._isTransitioning=!1,this._element.classList.remove(mt),this._element.classList.add(gt),z.trigger(this._element,ht)};this._element.style[e]="",this._queueCallback(t,this._element,!0)}_isShown(e=this._element){return e.classList.contains(ft)}_configAfterMerge(e){return e.toggle=Boolean(e.toggle),e.parent=u(e.parent),e}_getDimension(){return this._element.classList.contains(bt)?yt:wt}_initializeChildren(){if(!this._config.parent)return;const e=this._getFirstLevelChildren(Et);for(const t of e){const e=X.getElementFromSelector(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}}_getFirstLevelChildren(e){const t=X.find(_t,this._config.parent);return X.find(e,this._config.parent).filter((e=>!t.includes(e)))}_addAriaAndCollapsedClass(e,t){if(e.length)for(const i of e)i.classList.toggle(vt,!t),i.setAttribute("aria-expanded",t)}static jQueryInterface(e){const t={};return"string"==typeof e&&/show|hide/.test(e)&&(t.toggle=!1),this.each((function(){const i=St.getOrCreateInstance(this,t);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}))}}z.on(document,pt,Et,(function(e){("A"===e.target.tagName||e.delegateTarget&&"A"===e.delegateTarget.tagName)&&e.preventDefault();for(const e of X.getMultipleElementsFromSelector(this))St.getOrCreateInstance(e,{toggle:!1}).toggle()})),w(St);var Ct="top",kt="bottom",It="right",Tt="left",Lt="auto",Nt=[Ct,kt,It,Tt],Pt="start",$t="end",Dt="clippingParents",jt="viewport",Ft="popper",Mt="reference",qt=Nt.reduce((function(e,t){return e.concat([t+"-"+Pt,t+"-"+$t])}),[]),Rt=[].concat(Nt,[Lt]).reduce((function(e,t){return e.concat([t,t+"-"+Pt,t+"-"+$t])}),[]),Ht="beforeRead",zt="read",Bt="afterRead",Vt="beforeMain",Wt="main",Kt="afterMain",Ut="beforeWrite",Qt="write",Jt="afterWrite",Yt=[Ht,zt,Bt,Vt,Wt,Kt,Ut,Qt,Jt];function Xt(e){return e?(e.nodeName||"").toLowerCase():null}function Gt(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Zt(e){return e instanceof Gt(e).Element||e instanceof Element}function ei(e){return e instanceof Gt(e).HTMLElement||e instanceof HTMLElement}function ti(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Gt(e).ShadowRoot||e instanceof ShadowRoot)}function ii(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var i=t.styles[e]||{},n=t.attributes[e]||{},s=t.elements[e];ei(s)&&Xt(s)&&(Object.assign(s.style,i),Object.keys(n).forEach((function(e){var t=n[e];!1===t?s.removeAttribute(e):s.setAttribute(e,!0===t?"":t)})))}))}function ni(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],s=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce((function(e,t){return e[t]="",e}),{});ei(n)&&Xt(n)&&(Object.assign(n.style,o),Object.keys(s).forEach((function(e){n.removeAttribute(e)})))}))}}const si={name:"applyStyles",enabled:!0,phase:"write",fn:ii,effect:ni,requires:["computeStyles"]};function oi(e){return e.split("-")[0]}var ri=Math.max,ai=Math.min,li=Math.round;function ci(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function di(){return!/^((?!chrome|android).)*safari/i.test(ci())}function ui(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);var n=e.getBoundingClientRect(),s=1,o=1;t&&ei(e)&&(s=e.offsetWidth>0&&li(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&li(n.height)/e.offsetHeight||1);var r=(Zt(e)?Gt(e):window).visualViewport,a=!di()&&i,l=(n.left+(a&&r?r.offsetLeft:0))/s,c=(n.top+(a&&r?r.offsetTop:0))/o,d=n.width/s,u=n.height/o;return{width:d,height:u,top:c,right:l+d,bottom:c+u,left:l,x:l,y:c}}function hi(e){var t=ui(e),i=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-i)<=1&&(i=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:n}}function pi(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&ti(i)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function fi(e){return Gt(e).getComputedStyle(e)}function gi(e){return["table","td","th"].indexOf(Xt(e))>=0}function mi(e){return((Zt(e)?e.ownerDocument:e.document)||window.document).documentElement}function vi(e){return"html"===Xt(e)?e:e.assignedSlot||e.parentNode||(ti(e)?e.host:null)||mi(e)}function _i(e){return ei(e)&&"fixed"!==fi(e).position?e.offsetParent:null}function bi(e){var t=/firefox/i.test(ci());if(/Trident/i.test(ci())&&ei(e)&&"fixed"===fi(e).position)return null;var i=vi(e);for(ti(i)&&(i=i.host);ei(i)&&["html","body"].indexOf(Xt(i))<0;){var n=fi(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}function yi(e){for(var t=Gt(e),i=_i(e);i&&gi(i)&&"static"===fi(i).position;)i=_i(i);return i&&("html"===Xt(i)||"body"===Xt(i)&&"static"===fi(i).position)?t:i||bi(e)||t}function wi(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Oi(e,t,i){return ri(e,ai(t,i))}function Ei(e,t,i){var n=Oi(e,t,i);return n>i?i:n}function Ai(){return{top:0,right:0,bottom:0,left:0}}function xi(e){return Object.assign({},Ai(),e)}function Si(e,t){return t.reduce((function(t,i){return t[i]=e,t}),{})}var Ci=function(e,t){return xi("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:Si(e,Nt))};function ki(e){var t,i=e.state,n=e.name,s=e.options,o=i.elements.arrow,r=i.modifiersData.popperOffsets,a=oi(i.placement),l=wi(a),c=[Tt,It].indexOf(a)>=0?"height":"width";if(o&&r){var d=Ci(s.padding,i),u=hi(o),h="y"===l?Ct:Tt,p="y"===l?kt:It,f=i.rects.reference[c]+i.rects.reference[l]-r[l]-i.rects.popper[c],g=r[l]-i.rects.reference[l],m=yi(o),v=m?"y"===l?m.clientHeight||0:m.clientWidth||0:0,_=f/2-g/2,b=d[h],y=v-u[c]-d[p],w=v/2-u[c]/2+_,O=Oi(b,w,y),E=l;i.modifiersData[n]=((t={})[E]=O,t.centerOffset=O-w,t)}}function Ii(e){var t=e.state,i=e.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&pi(t.elements.popper,n)&&(t.elements.arrow=n)}const Ti={name:"arrow",enabled:!0,phase:"main",fn:ki,effect:Ii,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Li(e){return e.split("-")[1]}var Ni={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Pi(e,t){var i=e.x,n=e.y,s=t.devicePixelRatio||1;return{x:li(i*s)/s||0,y:li(n*s)/s||0}}function $i(e){var t,i=e.popper,n=e.popperRect,s=e.placement,o=e.variation,r=e.offsets,a=e.position,l=e.gpuAcceleration,c=e.adaptive,d=e.roundOffsets,u=e.isFixed,h=r.x,p=void 0===h?0:h,f=r.y,g=void 0===f?0:f,m="function"==typeof d?d({x:p,y:g}):{x:p,y:g};p=m.x,g=m.y;var v=r.hasOwnProperty("x"),_=r.hasOwnProperty("y"),b=Tt,y=Ct,w=window;if(c){var O=yi(i),E="clientHeight",A="clientWidth";O===Gt(i)&&"static"!==fi(O=mi(i)).position&&"absolute"===a&&(E="scrollHeight",A="scrollWidth"),(s===Ct||(s===Tt||s===It)&&o===$t)&&(y=kt,g-=(u&&O===w&&w.visualViewport?w.visualViewport.height:O[E])-n.height,g*=l?1:-1),s!==Tt&&(s!==Ct&&s!==kt||o!==$t)||(b=It,p-=(u&&O===w&&w.visualViewport?w.visualViewport.width:O[A])-n.width,p*=l?1:-1)}var x,S=Object.assign({position:a},c&&Ni),C=!0===d?Pi({x:p,y:g},Gt(i)):{x:p,y:g};return p=C.x,g=C.y,l?Object.assign({},S,((x={})[y]=_?"0":"",x[b]=v?"0":"",x.transform=(w.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",x)):Object.assign({},S,((t={})[y]=_?g+"px":"",t[b]=v?p+"px":"",t.transform="",t))}function Di(e){var t=e.state,i=e.options,n=i.gpuAcceleration,s=void 0===n||n,o=i.adaptive,r=void 0===o||o,a=i.roundOffsets,l=void 0===a||a,c={placement:oi(t.placement),variation:Li(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,$i(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:r,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,$i(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const ji={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Di,data:{}};var Fi={passive:!0};function Mi(e){var t=e.state,i=e.instance,n=e.options,s=n.scroll,o=void 0===s||s,r=n.resize,a=void 0===r||r,l=Gt(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&c.forEach((function(e){e.addEventListener("scroll",i.update,Fi)})),a&&l.addEventListener("resize",i.update,Fi),function(){o&&c.forEach((function(e){e.removeEventListener("scroll",i.update,Fi)})),a&&l.removeEventListener("resize",i.update,Fi)}}const qi={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Mi,data:{}};var Ri={left:"right",right:"left",bottom:"top",top:"bottom"};function Hi(e){return e.replace(/left|right|bottom|top/g,(function(e){return Ri[e]}))}var zi={start:"end",end:"start"};function Bi(e){return e.replace(/start|end/g,(function(e){return zi[e]}))}function Vi(e){var t=Gt(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Wi(e){return ui(mi(e)).left+Vi(e).scrollLeft}function Ki(e,t){var i=Gt(e),n=mi(e),s=i.visualViewport,o=n.clientWidth,r=n.clientHeight,a=0,l=0;if(s){o=s.width,r=s.height;var c=di();(c||!c&&"fixed"===t)&&(a=s.offsetLeft,l=s.offsetTop)}return{width:o,height:r,x:a+Wi(e),y:l}}function Ui(e){var t,i=mi(e),n=Vi(e),s=null==(t=e.ownerDocument)?void 0:t.body,o=ri(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),r=ri(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),a=-n.scrollLeft+Wi(e),l=-n.scrollTop;return"rtl"===fi(s||i).direction&&(a+=ri(i.clientWidth,s?s.clientWidth:0)-o),{width:o,height:r,x:a,y:l}}function Qi(e){var t=fi(e),i=t.overflow,n=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function Ji(e){return["html","body","#document"].indexOf(Xt(e))>=0?e.ownerDocument.body:ei(e)&&Qi(e)?e:Ji(vi(e))}function Yi(e,t){var i;void 0===t&&(t=[]);var n=Ji(e),s=n===(null==(i=e.ownerDocument)?void 0:i.body),o=Gt(n),r=s?[o].concat(o.visualViewport||[],Qi(n)?n:[]):n,a=t.concat(r);return s?a:a.concat(Yi(vi(r)))}function Xi(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Gi(e,t){var i=ui(e,!1,"fixed"===t);return i.top=i.top+e.clientTop,i.left=i.left+e.clientLeft,i.bottom=i.top+e.clientHeight,i.right=i.left+e.clientWidth,i.width=e.clientWidth,i.height=e.clientHeight,i.x=i.left,i.y=i.top,i}function Zi(e,t,i){return t===jt?Xi(Ki(e,i)):Zt(t)?Gi(t,i):Xi(Ui(mi(e)))}function en(e){var t=Yi(vi(e)),i=["absolute","fixed"].indexOf(fi(e).position)>=0&&ei(e)?yi(e):e;return Zt(i)?t.filter((function(e){return Zt(e)&&pi(e,i)&&"body"!==Xt(e)})):[]}function tn(e,t,i,n){var s="clippingParents"===t?en(e):[].concat(t),o=[].concat(s,[i]),r=o[0],a=o.reduce((function(t,i){var s=Zi(e,i,n);return t.top=ri(s.top,t.top),t.right=ai(s.right,t.right),t.bottom=ai(s.bottom,t.bottom),t.left=ri(s.left,t.left),t}),Zi(e,r,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function nn(e){var t,i=e.reference,n=e.element,s=e.placement,o=s?oi(s):null,r=s?Li(s):null,a=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(o){case Ct:t={x:a,y:i.y-n.height};break;case kt:t={x:a,y:i.y+i.height};break;case It:t={x:i.x+i.width,y:l};break;case Tt:t={x:i.x-n.width,y:l};break;default:t={x:i.x,y:i.y}}var c=o?wi(o):null;if(null!=c){var d="y"===c?"height":"width";switch(r){case Pt:t[c]=t[c]-(i[d]/2-n[d]/2);break;case $t:t[c]=t[c]+(i[d]/2-n[d]/2)}}return t}function sn(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=void 0===n?e.placement:n,o=i.strategy,r=void 0===o?e.strategy:o,a=i.boundary,l=void 0===a?Dt:a,c=i.rootBoundary,d=void 0===c?jt:c,u=i.elementContext,h=void 0===u?Ft:u,p=i.altBoundary,f=void 0!==p&&p,g=i.padding,m=void 0===g?0:g,v=xi("number"!=typeof m?m:Si(m,Nt)),_=h===Ft?Mt:Ft,b=e.rects.popper,y=e.elements[f?_:h],w=tn(Zt(y)?y:y.contextElement||mi(e.elements.popper),l,d,r),O=ui(e.elements.reference),E=nn({reference:O,element:b,strategy:"absolute",placement:s}),A=Xi(Object.assign({},b,E)),x=h===Ft?A:O,S={top:w.top-x.top+v.top,bottom:x.bottom-w.bottom+v.bottom,left:w.left-x.left+v.left,right:x.right-w.right+v.right},C=e.modifiersData.offset;if(h===Ft&&C){var k=C[s];Object.keys(S).forEach((function(e){var t=[It,kt].indexOf(e)>=0?1:-1,i=[Ct,kt].indexOf(e)>=0?"y":"x";S[e]+=k[i]*t}))}return S}function on(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=i.boundary,o=i.rootBoundary,r=i.padding,a=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?Rt:l,d=Li(n),u=d?a?qt:qt.filter((function(e){return Li(e)===d})):Nt,h=u.filter((function(e){return c.indexOf(e)>=0}));0===h.length&&(h=u);var p=h.reduce((function(t,i){return t[i]=sn(e,{placement:i,boundary:s,rootBoundary:o,padding:r})[oi(i)],t}),{});return Object.keys(p).sort((function(e,t){return p[e]-p[t]}))}function rn(e){if(oi(e)===Lt)return[];var t=Hi(e);return[Bi(e),t,Bi(t)]}function an(e){var t=e.state,i=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0===r||r,l=i.fallbackPlacements,c=i.padding,d=i.boundary,u=i.rootBoundary,h=i.altBoundary,p=i.flipVariations,f=void 0===p||p,g=i.allowedAutoPlacements,m=t.options.placement,v=oi(m),_=l||(v!==m&&f?rn(m):[Hi(m)]),b=[m].concat(_).reduce((function(e,i){return e.concat(oi(i)===Lt?on(t,{placement:i,boundary:d,rootBoundary:u,padding:c,flipVariations:f,allowedAutoPlacements:g}):i)}),[]),y=t.rects.reference,w=t.rects.popper,O=new Map,E=!0,A=b[0],x=0;x=0,T=I?"width":"height",L=sn(t,{placement:S,boundary:d,rootBoundary:u,altBoundary:h,padding:c}),N=I?k?It:Tt:k?kt:Ct;y[T]>w[T]&&(N=Hi(N));var P=Hi(N),$=[];if(o&&$.push(L[C]<=0),a&&$.push(L[N]<=0,L[P]<=0),$.every((function(e){return e}))){A=S,E=!1;break}O.set(S,$)}if(E)for(var D=function(e){var t=b.find((function(t){var i=O.get(t);if(i)return i.slice(0,e).every((function(e){return e}))}));if(t)return A=t,"break"},j=f?3:1;j>0&&"break"!==D(j);j--);t.placement!==A&&(t.modifiersData[n]._skip=!0,t.placement=A,t.reset=!0)}}const ln={name:"flip",enabled:!0,phase:"main",fn:an,requiresIfExists:["offset"],data:{_skip:!1}};function cn(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function dn(e){return[Ct,It,kt,Tt].some((function(t){return e[t]>=0}))}function un(e){var t=e.state,i=e.name,n=t.rects.reference,s=t.rects.popper,o=t.modifiersData.preventOverflow,r=sn(t,{elementContext:"reference"}),a=sn(t,{altBoundary:!0}),l=cn(r,n),c=cn(a,s,o),d=dn(l),u=dn(c);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:d,hasPopperEscaped:u},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":d,"data-popper-escaped":u})}const hn={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:un};function pn(e,t,i){var n=oi(e),s=[Tt,Ct].indexOf(n)>=0?-1:1,o="function"==typeof i?i(Object.assign({},t,{placement:e})):i,r=o[0],a=o[1];return r=r||0,a=(a||0)*s,[Tt,It].indexOf(n)>=0?{x:a,y:r}:{x:r,y:a}}function fn(e){var t=e.state,i=e.options,n=e.name,s=i.offset,o=void 0===s?[0,0]:s,r=Rt.reduce((function(e,i){return e[i]=pn(i,t.rects,o),e}),{}),a=r[t.placement],l=a.x,c=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=r}const gn={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn};function mn(e){var t=e.state,i=e.name;t.modifiersData[i]=nn({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const vn={name:"popperOffsets",enabled:!0,phase:"read",fn:mn,data:{}};function _n(e){return"x"===e?"y":"x"}function bn(e){var t=e.state,i=e.options,n=e.name,s=i.mainAxis,o=void 0===s||s,r=i.altAxis,a=void 0!==r&&r,l=i.boundary,c=i.rootBoundary,d=i.altBoundary,u=i.padding,h=i.tether,p=void 0===h||h,f=i.tetherOffset,g=void 0===f?0:f,m=sn(t,{boundary:l,rootBoundary:c,padding:u,altBoundary:d}),v=oi(t.placement),_=Li(t.placement),b=!_,y=wi(v),w=_n(y),O=t.modifiersData.popperOffsets,E=t.rects.reference,A=t.rects.popper,x="function"==typeof g?g(Object.assign({},t.rects,{placement:t.placement})):g,S="number"==typeof x?{mainAxis:x,altAxis:x}:Object.assign({mainAxis:0,altAxis:0},x),C=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,k={x:0,y:0};if(O){if(o){var I,T="y"===y?Ct:Tt,L="y"===y?kt:It,N="y"===y?"height":"width",P=O[y],$=P+m[T],D=P-m[L],j=p?-A[N]/2:0,F=_===Pt?E[N]:A[N],M=_===Pt?-A[N]:-E[N],q=t.elements.arrow,R=p&&q?hi(q):{width:0,height:0},H=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:Ai(),z=H[T],B=H[L],V=Oi(0,E[N],R[N]),W=b?E[N]/2-j-V-z-S.mainAxis:F-V-z-S.mainAxis,K=b?-E[N]/2+j+V+B+S.mainAxis:M+V+B+S.mainAxis,U=t.elements.arrow&&yi(t.elements.arrow),Q=U?"y"===y?U.clientTop||0:U.clientLeft||0:0,J=null!=(I=null==C?void 0:C[y])?I:0,Y=P+K-J,X=Oi(p?ai($,P+W-J-Q):$,P,p?ri(D,Y):D);O[y]=X,k[y]=X-P}if(a){var G,Z="x"===y?Ct:Tt,ee="x"===y?kt:It,te=O[w],ie="y"===w?"height":"width",ne=te+m[Z],se=te-m[ee],oe=-1!==[Ct,Tt].indexOf(v),re=null!=(G=null==C?void 0:C[w])?G:0,ae=oe?ne:te-E[ie]-A[ie]-re+S.altAxis,le=oe?te+E[ie]+A[ie]-re-S.altAxis:se,ce=p&&oe?Ei(ae,te,le):Oi(p?ae:ne,te,p?le:se);O[w]=ce,k[w]=ce-te}t.modifiersData[n]=k}}const yn={name:"preventOverflow",enabled:!0,phase:"main",fn:bn,requiresIfExists:["offset"]};function wn(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function On(e){return e!==Gt(e)&&ei(e)?wn(e):Vi(e)}function En(e){var t=e.getBoundingClientRect(),i=li(t.width)/e.offsetWidth||1,n=li(t.height)/e.offsetHeight||1;return 1!==i||1!==n}function An(e,t,i){void 0===i&&(i=!1);var n=ei(t),s=ei(t)&&En(t),o=mi(t),r=ui(e,s,i),a={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(n||!n&&!i)&&(("body"!==Xt(t)||Qi(o))&&(a=On(t)),ei(t)?((l=ui(t,!0)).x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=Wi(o))),{x:r.left+a.scrollLeft-l.x,y:r.top+a.scrollTop-l.y,width:r.width,height:r.height}}function xn(e){var t=new Map,i=new Set,n=[];function s(e){i.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!i.has(e)){var n=t.get(e);n&&s(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){i.has(e.name)||s(e)})),n}function Sn(e){var t=xn(e);return Yt.reduce((function(e,i){return e.concat(t.filter((function(e){return e.phase===i})))}),[])}function Cn(e){var t;return function(){return t||(t=new Promise((function(i){Promise.resolve().then((function(){t=void 0,i(e())}))}))),t}}function kn(e){var t=e.reduce((function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e}),{});return Object.keys(t).map((function(e){return t[e]}))}var In={placement:"bottom",modifiers:[],strategy:"absolute"};function Tn(){for(var e=arguments.length,t=new Array(e),i=0;iNumber.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_getPopperConfig(){const e={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(K.setDataAttribute(this._menu,"popper","static"),e.modifiers=[{name:"applyStyles",enabled:!1}]),{...e,...O(this._config.popperConfig,[e])}}_selectMenuItem({key:e,target:t}){const i=X.find(ls,this._menu).filter((e=>h(e)));i.length&&A(i,t,e===zn,!i.includes(t)).focus()}static jQueryInterface(e){return this.each((function(){const t=bs.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}static clearMenus(e){if(e.button===Bn||"keyup"===e.type&&e.key!==Rn)return;const t=X.find(ss);for(const i of t){const t=bs.getInstance(i);if(!t||!1===t._config.autoClose)continue;const n=e.composedPath(),s=n.includes(t._menu);if(n.includes(t._element)||"inside"===t._config.autoClose&&!s||"outside"===t._config.autoClose&&s)continue;if(t._menu.contains(e.target)&&("keyup"===e.type&&e.key===Rn||/input|select|option|textarea|form/i.test(e.target.tagName)))continue;const o={relatedTarget:t._element};"click"===e.type&&(o.clickEvent=e),t._completeHide(o)}}static dataApiKeydownHandler(e){const t=/input|textarea/i.test(e.target.tagName),i=e.key===qn,n=[Hn,zn].includes(e.key);if(!n&&!i)return;if(t&&!i)return;e.preventDefault();const s=this.matches(ns)?this:X.prev(this,ns)[0]||X.next(this,ns)[0]||X.findOne(ns,e.delegateTarget.parentNode),o=bs.getOrCreateInstance(s);if(n)return e.stopPropagation(),o.show(),void o._selectMenuItem(e);o._isShown()&&(e.stopPropagation(),o.hide(),s.focus())}}z.on(document,Jn,ns,bs.dataApiKeydownHandler),z.on(document,Jn,os,bs.dataApiKeydownHandler),z.on(document,Qn,bs.clearMenus),z.on(document,Yn,bs.clearMenus),z.on(document,Qn,ns,(function(e){e.preventDefault(),bs.getOrCreateInstance(this).toggle()})),w(bs);const ys="backdrop",ws="fade",Os="show",Es=`mousedown.bs.${ys}`,As={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},xs={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class Ss extends U{constructor(e){super(),this._config=this._getConfig(e),this._isAppended=!1,this._element=null}static get Default(){return As}static get DefaultType(){return xs}static get NAME(){return ys}show(e){if(!this._config.isVisible)return void O(e);this._append();const t=this._getElement();this._config.isAnimated&&m(t),t.classList.add(Os),this._emulateAnimation((()=>{O(e)}))}hide(e){this._config.isVisible?(this._getElement().classList.remove(Os),this._emulateAnimation((()=>{this.dispose(),O(e)}))):O(e)}dispose(){this._isAppended&&(z.off(this._element,Es),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const e=document.createElement("div");e.className=this._config.className,this._config.isAnimated&&e.classList.add(ws),this._element=e}return this._element}_configAfterMerge(e){return e.rootElement=u(e.rootElement),e}_append(){if(this._isAppended)return;const e=this._getElement();this._config.rootElement.append(e),z.on(e,Es,(()=>{O(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(e){E(e,this._getElement(),this._config.isAnimated)}}const Cs="focustrap",ks=".bs.focustrap",Is=`focusin${ks}`,Ts=`keydown.tab${ks}`,Ls="Tab",Ns="forward",Ps="backward",$s={autofocus:!0,trapElement:null},Ds={autofocus:"boolean",trapElement:"element"};class js extends U{constructor(e){super(),this._config=this._getConfig(e),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return $s}static get DefaultType(){return Ds}static get NAME(){return Cs}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),z.off(document,ks),z.on(document,Is,(e=>this._handleFocusin(e))),z.on(document,Ts,(e=>this._handleKeydown(e))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,z.off(document,ks))}_handleFocusin(e){const{trapElement:t}=this._config;if(e.target===document||e.target===t||t.contains(e.target))return;const i=X.focusableChildren(t);0===i.length?t.focus():this._lastTabNavDirection===Ps?i[i.length-1].focus():i[0].focus()}_handleKeydown(e){e.key===Ls&&(this._lastTabNavDirection=e.shiftKey?Ps:Ns)}}const Fs=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",Ms=".sticky-top",qs="padding-right",Rs="margin-right";class Hs{constructor(){this._element=document.body}getWidth(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}hide(){const e=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,qs,(t=>t+e)),this._setElementAttributes(Fs,qs,(t=>t+e)),this._setElementAttributes(Ms,Rs,(t=>t-e))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,qs),this._resetElementAttributes(Fs,qs),this._resetElementAttributes(Ms,Rs)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(e,t,i){const n=this.getWidth(),s=e=>{if(e!==this._element&&window.innerWidth>e.clientWidth+n)return;this._saveInitialAttribute(e,t);const s=window.getComputedStyle(e).getPropertyValue(t);e.style.setProperty(t,`${i(Number.parseFloat(s))}px`)};this._applyManipulationCallback(e,s)}_saveInitialAttribute(e,t){const i=e.style.getPropertyValue(t);i&&K.setDataAttribute(e,t,i)}_resetElementAttributes(e,t){const i=e=>{const i=K.getDataAttribute(e,t);null!==i?(K.removeDataAttribute(e,t),e.style.setProperty(t,i)):e.style.removeProperty(t)};this._applyManipulationCallback(e,i)}_applyManipulationCallback(e,t){if(d(e))t(e);else for(const i of X.find(e,this._element))t(i)}}const zs="modal",Bs=".bs.modal",Vs="Escape",Ws=`hide${Bs}`,Ks=`hidePrevented${Bs}`,Us=`hidden${Bs}`,Qs=`show${Bs}`,Js=`shown${Bs}`,Ys=`resize${Bs}`,Xs=`click.dismiss${Bs}`,Gs=`mousedown.dismiss${Bs}`,Zs=`keydown.dismiss${Bs}`,eo=`click${Bs}.data-api`,to="modal-open",io="fade",no="show",so="modal-static",oo=".modal.show",ro=".modal-dialog",ao=".modal-body",lo='[data-bs-toggle="modal"]',co={backdrop:!0,focus:!0,keyboard:!0},uo={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class ho extends J{constructor(e,t){super(e,t),this._dialog=X.findOne(ro,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new Hs,this._addEventListeners()}static get Default(){return co}static get DefaultType(){return uo}static get NAME(){return zs}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){this._isShown||this._isTransitioning||z.trigger(this._element,Qs,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(to),this._adjustDialog(),this._backdrop.show((()=>this._showElement(e))))}hide(){this._isShown&&!this._isTransitioning&&(z.trigger(this._element,Ws).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(no),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated())))}dispose(){z.off(window,Bs),z.off(this._dialog,Bs),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Ss({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new js({trapElement:this._element})}_showElement(e){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 t=X.findOne(ao,this._dialog);t&&(t.scrollTop=0),m(this._element),this._element.classList.add(no);const i=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,z.trigger(this._element,Js,{relatedTarget:e})};this._queueCallback(i,this._dialog,this._isAnimated())}_addEventListeners(){z.on(this._element,Zs,(e=>{e.key===Vs&&(this._config.keyboard?this.hide():this._triggerBackdropTransition())})),z.on(window,Ys,(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),z.on(this._element,Gs,(e=>{z.one(this._element,Xs,(t=>{this._element===e.target&&this._element===t.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())}))}))}_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(to),this._resetAdjustments(),this._scrollBar.reset(),z.trigger(this._element,Us)}))}_isAnimated(){return this._element.classList.contains(io)}_triggerBackdropTransition(){if(z.trigger(this._element,Ks).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._element.style.overflowY;"hidden"===t||this._element.classList.contains(so)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(so),this._queueCallback((()=>{this._element.classList.remove(so),this._queueCallback((()=>{this._element.style.overflowY=t}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._scrollBar.getWidth(),i=t>0;if(i&&!e){const e=y()?"paddingLeft":"paddingRight";this._element.style[e]=`${t}px`}if(!i&&e){const e=y()?"paddingRight":"paddingLeft";this._element.style[e]=`${t}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(e,t){return this.each((function(){const i=ho.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e](t)}}))}}z.on(document,eo,lo,(function(e){const t=X.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&e.preventDefault(),z.one(t,Qs,(e=>{e.defaultPrevented||z.one(t,Us,(()=>{h(this)&&this.focus()}))}));const i=X.findOne(oo);i&&ho.getInstance(i).hide(),ho.getOrCreateInstance(t).toggle(this)})),G(ho),w(ho);const po="offcanvas",fo=".bs.offcanvas",go=".data-api",mo=`load${fo}${go}`,vo="Escape",_o="show",bo="showing",yo="hiding",wo="offcanvas-backdrop",Oo=".offcanvas.show",Eo=`show${fo}`,Ao=`shown${fo}`,xo=`hide${fo}`,So=`hidePrevented${fo}`,Co=`hidden${fo}`,ko=`resize${fo}`,Io=`click${fo}${go}`,To=`keydown.dismiss${fo}`,Lo='[data-bs-toggle="offcanvas"]',No={backdrop:!0,keyboard:!0,scroll:!1},Po={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class $o extends J{constructor(e,t){super(e,t),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return No}static get DefaultType(){return Po}static get NAME(){return po}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){if(this._isShown)return;if(z.trigger(this._element,Eo,{relatedTarget:e}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||(new Hs).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(bo);const t=()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add(_o),this._element.classList.remove(bo),z.trigger(this._element,Ao,{relatedTarget:e})};this._queueCallback(t,this._element,!0)}hide(){if(!this._isShown)return;if(z.trigger(this._element,xo).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(yo),this._backdrop.hide();const e=()=>{this._element.classList.remove(_o,yo),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new Hs).reset(),z.trigger(this._element,Co)};this._queueCallback(e,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const e=()=>{"static"!==this._config.backdrop?this.hide():z.trigger(this._element,So)},t=Boolean(this._config.backdrop);return new Ss({className:wo,isVisible:t,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:t?e:null})}_initializeFocusTrap(){return new js({trapElement:this._element})}_addEventListeners(){z.on(this._element,To,(e=>{e.key===vo&&(this._config.keyboard?this.hide():z.trigger(this._element,So))}))}static jQueryInterface(e){return this.each((function(){const t=$o.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}z.on(document,Io,Lo,(function(e){const t=X.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&e.preventDefault(),p(this))return;z.one(t,Co,(()=>{h(this)&&this.focus()}));const i=X.findOne(Oo);i&&i!==t&&$o.getInstance(i).hide(),$o.getOrCreateInstance(t).toggle(this)})),z.on(window,mo,(()=>{for(const e of X.find(Oo))$o.getOrCreateInstance(e).show()})),z.on(window,ko,(()=>{for(const e of X.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(e).position&&$o.getOrCreateInstance(e).hide()})),G($o),w($o);const Do={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],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:[]},jo=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Fo=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,Mo=(e,t)=>{const i=e.nodeName.toLowerCase();return t.includes(i)?!jo.has(i)||Boolean(Fo.test(e.nodeValue)):t.filter((e=>e instanceof RegExp)).some((e=>e.test(i)))};function qo(e,t,i){if(!e.length)return e;if(i&&"function"==typeof i)return i(e);const n=(new window.DOMParser).parseFromString(e,"text/html"),s=[].concat(...n.body.querySelectorAll("*"));for(const e of s){const i=e.nodeName.toLowerCase();if(!Object.keys(t).includes(i)){e.remove();continue}const n=[].concat(...e.attributes),s=[].concat(t["*"]||[],t[i]||[]);for(const t of n)Mo(t,s)||e.removeAttribute(t.nodeName)}return n.body.innerHTML}const Ro="TemplateFactory",Ho={allowList:Do,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"
"},zo={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},Bo={entry:"(string|element|function|null)",selector:"(string|element)"};class Vo extends U{constructor(e){super(),this._config=this._getConfig(e)}static get Default(){return Ho}static get DefaultType(){return zo}static get NAME(){return Ro}getContent(){return Object.values(this._config.content).map((e=>this._resolvePossibleFunction(e))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(e){return this._checkContent(e),this._config.content={...this._config.content,...e},this}toHtml(){const e=document.createElement("div");e.innerHTML=this._maybeSanitize(this._config.template);for(const[t,i]of Object.entries(this._config.content))this._setContent(e,i,t);const t=e.children[0],i=this._resolvePossibleFunction(this._config.extraClass);return i&&t.classList.add(...i.split(" ")),t}_typeCheckConfig(e){super._typeCheckConfig(e),this._checkContent(e.content)}_checkContent(e){for(const[t,i]of Object.entries(e))super._typeCheckConfig({selector:t,entry:i},Bo)}_setContent(e,t,i){const n=X.findOne(i,e);n&&((t=this._resolvePossibleFunction(t))?d(t)?this._putElementInTemplate(u(t),n):this._config.html?n.innerHTML=this._maybeSanitize(t):n.textContent=t:n.remove())}_maybeSanitize(e){return this._config.sanitize?qo(e,this._config.allowList,this._config.sanitizeFn):e}_resolvePossibleFunction(e){return O(e,[this])}_putElementInTemplate(e,t){if(this._config.html)return t.innerHTML="",void t.append(e);t.textContent=e.textContent}}const Wo="tooltip",Ko=new Set(["sanitize","allowList","sanitizeFn"]),Uo="fade",Qo="show",Jo=".tooltip-inner",Yo=".modal",Xo="hide.bs.modal",Go="hover",Zo="focus",er="click",tr="manual",ir="hide",nr="hidden",sr="show",or="shown",rr="inserted",ar="click",lr="focusin",cr="focusout",dr="mouseenter",ur="mouseleave",hr={AUTO:"auto",TOP:"top",RIGHT:y()?"left":"right",BOTTOM:"bottom",LEFT:y()?"right":"left"},pr={allowList:Do,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:'',title:"",trigger:"hover focus"},fr={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 gr extends J{constructor(e,t){if(void 0===Dn)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(e,t),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 pr}static get DefaultType(){return fr}static get NAME(){return Wo}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),z.off(this._element.closest(Yo),Xo,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("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const e=z.trigger(this._element,this.constructor.eventName(sr)),t=(f(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(e.defaultPrevented||!t)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:n}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(n.append(i),z.trigger(this._element,this.constructor.eventName(rr))),this._popper=this._createPopper(i),i.classList.add(Qo),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))z.on(e,"mouseover",g);const s=()=>{z.trigger(this._element,this.constructor.eventName(or)),!1===this._isHovered&&this._leave(),this._isHovered=!1};this._queueCallback(s,this.tip,this._isAnimated())}hide(){if(!this._isShown())return;if(z.trigger(this._element,this.constructor.eventName(ir)).defaultPrevented)return;if(this._getTipElement().classList.remove(Qo),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))z.off(e,"mouseover",g);this._activeTrigger[er]=!1,this._activeTrigger[Zo]=!1,this._activeTrigger[Go]=!1,this._isHovered=null;const e=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),z.trigger(this._element,this.constructor.eventName(nr)))};this._queueCallback(e,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(e){const t=this._getTemplateFactory(e).toHtml();if(!t)return null;t.classList.remove(Uo,Qo),t.classList.add(`bs-${this.constructor.NAME}-auto`);const i=a(this.constructor.NAME).toString();return t.setAttribute("id",i),this._isAnimated()&&t.classList.add(Uo),t}setContent(e){this._newContent=e,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(e){return this._templateFactory?this._templateFactory.changeContent(e):this._templateFactory=new Vo({...this._config,content:e,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[Jo]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(e){return this.constructor.getOrCreateInstance(e.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(Uo)}_isShown(){return this.tip&&this.tip.classList.contains(Qo)}_createPopper(e){const t=O(this._config.placement,[this,e,this._element]),i=hr[t.toUpperCase()];return $n(this._element,e,this._getPopperConfig(i))}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_resolvePossibleFunction(e){return O(e,[this._element])}_getPopperConfig(e){const t={placement:e,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:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...t,...O(this._config.popperConfig,[t])}}_setListeners(){const e=this._config.trigger.split(" ");for(const t of e)if("click"===t)z.on(this._element,this.constructor.eventName(ar),this._config.selector,(e=>{this._initializeOnDelegatedTarget(e).toggle()}));else if(t!==tr){const e=t===Go?this.constructor.eventName(dr):this.constructor.eventName(lr),i=t===Go?this.constructor.eventName(ur):this.constructor.eventName(cr);z.on(this._element,e,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusin"===e.type?Zo:Go]=!0,t._enter()})),z.on(this._element,i,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusout"===e.type?Zo:Go]=t._element.contains(e.relatedTarget),t._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},z.on(this._element.closest(Yo),Xo,this._hideModalHandler)}_fixTitle(){const e=this._element.getAttribute("title");e&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",e),this._element.setAttribute("data-bs-original-title",e),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(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(e,t){clearTimeout(this._timeout),this._timeout=setTimeout(e,t)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(e){const t=K.getDataAttributes(this._element);for(const e of Object.keys(t))Ko.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e.container=!1===e.container?document.body:u(e.container),"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),e}_getDelegateConfig(){const e={};for(const[t,i]of Object.entries(this._config))this.constructor.Default[t]!==i&&(e[t]=i);return e.selector=!1,e.trigger="manual",e}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(e){return this.each((function(){const t=gr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}w(gr);const mr="popover",vr=".popover-header",_r=".popover-body",br={...gr.Default,content:"",offset:[0,8],placement:"right",template:'',trigger:"click"},yr={...gr.DefaultType,content:"(null|string|element|function)"};class wr extends gr{static get Default(){return br}static get DefaultType(){return yr}static get NAME(){return mr}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[vr]:this._getTitle(),[_r]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(e){return this.each((function(){const t=wr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}w(wr);const Or="scrollspy",Er=".bs.scrollspy",Ar=`activate${Er}`,xr=`click${Er}`,Sr=`load${Er}.data-api`,Cr="dropdown-item",kr="active",Ir='[data-bs-spy="scroll"]',Tr="[href]",Lr=".nav, .list-group",Nr=".nav-link",Pr=`${Nr}, .nav-item > ${Nr}, .list-group-item`,$r=".dropdown",Dr=".dropdown-toggle",jr={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},Fr={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class Mr extends J{constructor(e,t){super(e,t),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return jr}static get DefaultType(){return Fr}static get NAME(){return Or}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const e of this._observableSections.values())this._observer.observe(e)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(e){return e.target=u(e.target)||document.body,e.rootMargin=e.offset?`${e.offset}px 0px -30%`:e.rootMargin,"string"==typeof e.threshold&&(e.threshold=e.threshold.split(",").map((e=>Number.parseFloat(e)))),e}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(z.off(this._config.target,xr),z.on(this._config.target,xr,Tr,(e=>{const t=this._observableSections.get(e.target.hash);if(t){e.preventDefault();const i=this._rootElement||window,n=t.offsetTop-this._element.offsetTop;if(i.scrollTo)return void i.scrollTo({top:n,behavior:"smooth"});i.scrollTop=n}})))}_getNewObserver(){const e={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver((e=>this._observerCallback(e)),e)}_observerCallback(e){const t=e=>this._targetLinks.get(`#${e.target.id}`),i=e=>{this._previousScrollData.visibleEntryTop=e.target.offsetTop,this._process(t(e))},n=(this._rootElement||document.documentElement).scrollTop,s=n>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=n;for(const o of e){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(t(o));continue}const e=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(s&&e){if(i(o),!n)return}else s||e||i(o)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const e=X.find(Tr,this._config.target);for(const t of e){if(!t.hash||p(t))continue;const e=X.findOne(decodeURI(t.hash),this._element);h(e)&&(this._targetLinks.set(decodeURI(t.hash),t),this._observableSections.set(t.hash,e))}}_process(e){this._activeTarget!==e&&(this._clearActiveClass(this._config.target),this._activeTarget=e,e.classList.add(kr),this._activateParents(e),z.trigger(this._element,Ar,{relatedTarget:e}))}_activateParents(e){if(e.classList.contains(Cr))X.findOne(Dr,e.closest($r)).classList.add(kr);else for(const t of X.parents(e,Lr))for(const e of X.prev(t,Pr))e.classList.add(kr)}_clearActiveClass(e){e.classList.remove(kr);const t=X.find(`${Tr}.${kr}`,e);for(const e of t)e.classList.remove(kr)}static jQueryInterface(e){return this.each((function(){const t=Mr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}z.on(window,Sr,(()=>{for(const e of X.find(Ir))Mr.getOrCreateInstance(e)})),w(Mr);const qr="tab",Rr=".bs.tab",Hr=`hide${Rr}`,zr=`hidden${Rr}`,Br=`show${Rr}`,Vr=`shown${Rr}`,Wr=`click${Rr}`,Kr=`keydown${Rr}`,Ur=`load${Rr}`,Qr="ArrowLeft",Jr="ArrowRight",Yr="ArrowUp",Xr="ArrowDown",Gr="Home",Zr="End",ea="active",ta="fade",ia="show",na="dropdown",sa=".dropdown-toggle",oa=".dropdown-menu",ra=`:not(${sa})`,aa='.list-group, .nav, [role="tablist"]',la=".nav-item, .list-group-item",ca='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',da=`.nav-link${ra}, .list-group-item${ra}, [role="tab"]${ra}, ${ca}`,ua=`.${ea}[data-bs-toggle="tab"], .${ea}[data-bs-toggle="pill"], .${ea}[data-bs-toggle="list"]`;class ha extends J{constructor(e){super(e),this._parent=this._element.closest(aa),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),z.on(this._element,Kr,(e=>this._keydown(e))))}static get NAME(){return qr}show(){const e=this._element;if(this._elemIsActive(e))return;const t=this._getActiveElem(),i=t?z.trigger(t,Hr,{relatedTarget:e}):null;z.trigger(e,Br,{relatedTarget:t}).defaultPrevented||i&&i.defaultPrevented||(this._deactivate(t,e),this._activate(e,t))}_activate(e,t){if(!e)return;e.classList.add(ea),this._activate(X.getElementFromSelector(e));const i=()=>{"tab"===e.getAttribute("role")?(e.removeAttribute("tabindex"),e.setAttribute("aria-selected",!0),this._toggleDropDown(e,!0),z.trigger(e,Vr,{relatedTarget:t})):e.classList.add(ia)};this._queueCallback(i,e,e.classList.contains(ta))}_deactivate(e,t){if(!e)return;e.classList.remove(ea),e.blur(),this._deactivate(X.getElementFromSelector(e));const i=()=>{"tab"===e.getAttribute("role")?(e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1"),this._toggleDropDown(e,!1),z.trigger(e,zr,{relatedTarget:t})):e.classList.remove(ia)};this._queueCallback(i,e,e.classList.contains(ta))}_keydown(e){if(![Qr,Jr,Yr,Xr,Gr,Zr].includes(e.key))return;e.stopPropagation(),e.preventDefault();const t=this._getChildren().filter((e=>!p(e)));let i;if([Gr,Zr].includes(e.key))i=t[e.key===Gr?0:t.length-1];else{const n=[Jr,Xr].includes(e.key);i=A(t,e.target,n,!0)}i&&(i.focus({preventScroll:!0}),ha.getOrCreateInstance(i).show())}_getChildren(){return X.find(da,this._parent)}_getActiveElem(){return this._getChildren().find((e=>this._elemIsActive(e)))||null}_setInitialAttributes(e,t){this._setAttributeIfNotExists(e,"role","tablist");for(const e of t)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(e){e=this._getInnerElement(e);const t=this._elemIsActive(e),i=this._getOuterElement(e);e.setAttribute("aria-selected",t),i!==e&&this._setAttributeIfNotExists(i,"role","presentation"),t||e.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(e,"role","tab"),this._setInitialAttributesOnTargetPanel(e)}_setInitialAttributesOnTargetPanel(e){const t=X.getElementFromSelector(e);t&&(this._setAttributeIfNotExists(t,"role","tabpanel"),e.id&&this._setAttributeIfNotExists(t,"aria-labelledby",`${e.id}`))}_toggleDropDown(e,t){const i=this._getOuterElement(e);if(!i.classList.contains(na))return;const n=(e,n)=>{const s=X.findOne(e,i);s&&s.classList.toggle(n,t)};n(sa,ea),n(oa,ia),i.setAttribute("aria-expanded",t)}_setAttributeIfNotExists(e,t,i){e.hasAttribute(t)||e.setAttribute(t,i)}_elemIsActive(e){return e.classList.contains(ea)}_getInnerElement(e){return e.matches(da)?e:X.findOne(da,e)}_getOuterElement(e){return e.closest(la)||e}static jQueryInterface(e){return this.each((function(){const t=ha.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}z.on(document,Wr,ca,(function(e){["A","AREA"].includes(this.tagName)&&e.preventDefault(),p(this)||ha.getOrCreateInstance(this).show()})),z.on(window,Ur,(()=>{for(const e of X.find(ua))ha.getOrCreateInstance(e)})),w(ha);const pa="toast",fa=".bs.toast",ga=`mouseover${fa}`,ma=`mouseout${fa}`,va=`focusin${fa}`,_a=`focusout${fa}`,ba=`hide${fa}`,ya=`hidden${fa}`,wa=`show${fa}`,Oa=`shown${fa}`,Ea="fade",Aa="hide",xa="show",Sa="showing",Ca={animation:"boolean",autohide:"boolean",delay:"number"},ka={animation:!0,autohide:!0,delay:5e3};class Ia extends J{constructor(e,t){super(e,t),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return ka}static get DefaultType(){return Ca}static get NAME(){return pa}show(){if(z.trigger(this._element,wa).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(Ea);const e=()=>{this._element.classList.remove(Sa),z.trigger(this._element,Oa),this._maybeScheduleHide()};this._element.classList.remove(Aa),m(this._element),this._element.classList.add(xa,Sa),this._queueCallback(e,this._element,this._config.animation)}hide(){if(!this.isShown())return;if(z.trigger(this._element,ba).defaultPrevented)return;const e=()=>{this._element.classList.add(Aa),this._element.classList.remove(Sa,xa),z.trigger(this._element,ya)};this._element.classList.add(Sa),this._queueCallback(e,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(xa),super.dispose()}isShown(){return this._element.classList.contains(xa)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(e,t){switch(e.type){case"mouseover":case"mouseout":this._hasMouseInteraction=t;break;case"focusin":case"focusout":this._hasKeyboardInteraction=t}if(t)return void this._clearTimeout();const i=e.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){z.on(this._element,ga,(e=>this._onInteraction(e,!0))),z.on(this._element,ma,(e=>this._onInteraction(e,!1))),z.on(this._element,va,(e=>this._onInteraction(e,!0))),z.on(this._element,_a,(e=>this._onInteraction(e,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(e){return this.each((function(){const t=Ia.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}return G(Ia),w(Ia),{Alert:oe,Button:de,Carousel:rt,Collapse:St,Dropdown:bs,Modal:ho,Offcanvas:$o,Popover:wr,ScrollSpy:Mr,Tab:ha,Toast:Ia,Tooltip:gr}}()},538:(e,t,i)=>{"use strict";i.r(t)},766:function(e){e.exports=function(){"use strict";function e(e,t){e.split(/\s+/).forEach((e=>{t(e)}))}class t{constructor(){this._events={}}on(t,i){e(t,(e=>{const t=this._events[e]||[];t.push(i),this._events[e]=t}))}off(t,i){var n=arguments.length;0!==n?e(t,(e=>{if(1===n)return void delete this._events[e];const t=this._events[e];void 0!==t&&(t.splice(t.indexOf(i),1),this._events[e]=t)})):this._events={}}trigger(t,...i){var n=this;e(t,(e=>{const t=n._events[e];void 0!==t&&t.forEach((e=>{e.apply(n,i)}))}))}}const i=e=>(e=e.filter(Boolean)).length<2?e[0]||"":1==a(e)?"["+e.join("")+"]":"(?:"+e.join("|")+")",n=e=>{if(!o(e))return e.join("");let t="",i=0;const n=()=>{i>1&&(t+="{"+i+"}")};return e.forEach(((s,o)=>{s!==e[o-1]?(n(),t+=s,i=1):i++})),n(),t},s=e=>{let t=Array.from(e);return i(t)},o=e=>new Set(e).size!==e.length,r=e=>(e+"").replace(/([\$\(\)\*\+\.\?\[\]\^\{\|\}\\])/gu,"\\$1"),a=e=>e.reduce(((e,t)=>Math.max(e,l(t))),0),l=e=>Array.from(e).length,c=e=>{if(1===e.length)return[[e]];let t=[];const i=e.substring(1);return c(i).forEach((function(i){let n=i.slice(0);n[0]=e.charAt(0)+n[0],t.push(n),n=i.slice(0),n.unshift(e.charAt(0)),t.push(n)})),t},d=[[0,65535]];let u,h;const p={},f={"/":"⁄∕",0:"߀",a:"ⱥɐɑ",aa:"ꜳ",ae:"æǽǣ",ao:"ꜵ",au:"ꜷ",av:"ꜹꜻ",ay:"ꜽ",b:"ƀɓƃ",c:"ꜿƈȼↄ",d:"đɗɖᴅƌꮷԁɦ",e:"ɛǝᴇɇ",f:"ꝼƒ",g:"ǥɠꞡᵹꝿɢ",h:"ħⱨⱶɥ",i:"ɨı",j:"ɉȷ",k:"ƙⱪꝁꝃꝅꞣ",l:"łƚɫⱡꝉꝇꞁɭ",m:"ɱɯϻ",n:"ꞥƞɲꞑᴎлԉ",o:"øǿɔɵꝋꝍᴑ",oe:"œ",oi:"ƣ",oo:"ꝏ",ou:"ȣ",p:"ƥᵽꝑꝓꝕρ",q:"ꝗꝙɋ",r:"ɍɽꝛꞧꞃ",s:"ßȿꞩꞅʂ",t:"ŧƭʈⱦꞇ",th:"þ",tz:"ꜩ",u:"ʉ",v:"ʋꝟʌ",vy:"ꝡ",w:"ⱳ",y:"ƴɏỿ",z:"ƶȥɀⱬꝣ",hv:"ƕ"};for(let e in f){let t=f[e]||"";for(let i=0;ie.normalize(t),v=e=>Array.from(e).reduce(((e,t)=>e+_(t)),""),_=e=>(e=m(e).toLowerCase().replace(g,(e=>p[e]||"")),m(e,"NFC")),b=e=>{const t={},i=(e,i)=>{const n=t[e]||new Set,o=new RegExp("^"+s(n)+"$","iu");i.match(o)||(n.add(r(i)),t[e]=n)};for(let t of function*(e){for(const[t,i]of e)for(let e=t;e<=i;e++){let t=String.fromCharCode(e),i=v(t);i!=t.toLowerCase()&&(i.length>3||0!=i.length&&(yield{folded:i,composed:t,code_point:e}))}}(e))i(t.folded,t.folded),i(t.folded,t.composed);return t},y=e=>{const t=b(e),n={};let o=[];for(let e in t){let i=t[e];i&&(n[e]=s(i)),e.length>1&&o.push(r(e))}o.sort(((e,t)=>t.length-e.length));const a=i(o);return h=new RegExp("^"+a,"u"),n},w=(e,t=1)=>(t=Math.max(t,e.length-1),i(c(e).map((e=>((e,t=1)=>{let i=0;return e=e.map((e=>(u[e]&&(i+=e.length),u[e]||e))),i>=t?n(e):""})(e,t))))),O=(e,t=!0)=>{let s=e.length>1?1:0;return i(e.map((e=>{let i=[];const o=t?e.length():e.length()-1;for(let t=0;t{for(const i of t){if(i.start!=e.start||i.end!=e.end)continue;if(i.substrs.join("")!==e.substrs.join(""))continue;let t=e.parts;const n=e=>{for(const i of t){if(i.start===e.start&&i.substr===e.substr)return!1;if(1!=e.length&&1!=i.length){if(e.starti.start)return!0;if(i.starte.start)return!0}}return!1};if(!(i.parts.filter(n).length>0))return!0}return!1};class A{parts;substrs;start;end;constructor(){this.parts=[],this.substrs=[],this.start=0,this.end=0}add(e){e&&(this.parts.push(e),this.substrs.push(e.substr),this.start=Math.min(e.start,this.start),this.end=Math.max(e.end,this.end))}last(){return this.parts[this.parts.length-1]}length(){return this.parts.length}clone(e,t){let i=new A,n=JSON.parse(JSON.stringify(this.parts)),s=n.pop();for(const e of n)i.add(e);let o=t.substr.substring(0,e-s.start),r=o.length;return i.add({start:s.start,end:s.start+r,length:r,substr:o}),i}}const x=e=>{void 0===u&&(u=y(d)),e=v(e);let t="",i=[new A];for(let n=0;n0){a=a.sort(((e,t)=>e.length()-t.length()));for(let e of a)E(e,i)||i.push(e)}else if(n>0&&1==l.size&&!l.has("3")){t+=O(i,!1);let e=new A;const n=i[0];n&&e.add(n.last()),i=[e]}}return t+=O(i,!0),t},S=(e,t)=>{if(e)return e[t]},C=(e,t)=>{if(e){for(var i,n=t.split(".");(i=n.shift())&&(e=e[i]););return e}},k=(e,t,i)=>{var n,s;return e?(e+="",null==t.regex||-1===(s=e.search(t.regex))?0:(n=t.string.length/e.length,0===s&&(n+=.5),n*i)):0},I=(e,t)=>{var i=e[t];if("function"==typeof i)return i;i&&!Array.isArray(i)&&(e[t]=[i])},T=(e,t)=>{if(Array.isArray(e))e.forEach(t);else for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},L=(e,t)=>"number"==typeof e&&"number"==typeof t?e>t?1:e(t=v(t+"").toLowerCase())?1:t>e?-1:0;class N{items;settings;constructor(e,t){this.items=e,this.settings=t||{diacritics:!0}}tokenize(e,t,i){if(!e||!e.length)return[];const n=[],s=e.split(/\s+/);var o;return i&&(o=new RegExp("^("+Object.keys(i).map(r).join("|")+"):(.*)$")),s.forEach((e=>{let i,s=null,a=null;o&&(i=e.match(o))&&(s=i[1],e=i[2]),e.length>0&&(a=this.settings.diacritics?x(e)||null:r(e),a&&t&&(a="\\b"+a)),n.push({string:e,regex:a?new RegExp(a,"iu"):null,field:s})})),n}getScoreFunction(e,t){var i=this.prepareSearch(e,t);return this._getScoreFunction(i)}_getScoreFunction(e){const t=e.tokens,i=t.length;if(!i)return function(){return 0};const n=e.options.fields,s=e.weights,o=n.length,r=e.getAttrFn;if(!o)return function(){return 1};const a=1===o?function(e,t){const i=n[0].field;return k(r(t,i),e,s[i]||1)}:function(e,t){var i=0;if(e.field){const n=r(t,e.field);!e.regex&&n?i+=1/o:i+=k(n,e,1)}else T(s,((n,s)=>{i+=k(r(t,s),e,n)}));return i/o};return 1===i?function(e){return a(t[0],e)}:"and"===e.options.conjunction?function(e){var n,s=0;for(let i of t){if((n=a(i,e))<=0)return 0;s+=n}return s/i}:function(e){var n=0;return T(t,(t=>{n+=a(t,e)})),n/i}}getSortFunction(e,t){var i=this.prepareSearch(e,t);return this._getSortFunction(i)}_getSortFunction(e){var t,i=[];const n=this,s=e.options,o=!e.query&&s.sort_empty?s.sort_empty:s.sort;if("function"==typeof o)return o.bind(this);const r=function(t,i){return"$score"===t?i.score:e.getAttrFn(n.items[i.id],t)};if(o)for(let t of o)(e.query||"$score"!==t.field)&&i.push(t);if(e.query){t=!0;for(let e of i)if("$score"===e.field){t=!1;break}t&&i.unshift({field:"$score",direction:"desc"})}else i=i.filter((e=>"$score"!==e.field));return i.length?function(e,t){var n,s;for(let o of i)if(s=o.field,n=("desc"===o.direction?-1:1)*L(r(s,e),r(s,t)))return n;return 0}:null}prepareSearch(e,t){const i={};var n=Object.assign({},t);if(I(n,"sort"),I(n,"sort_empty"),n.fields){I(n,"fields");const e=[];n.fields.forEach((t=>{"string"==typeof t&&(t={field:t,weight:1}),e.push(t),i[t.field]="weight"in t?t.weight:1})),n.fields=e}return{options:n,query:e.toLowerCase().trim(),tokens:this.tokenize(e,n.respect_word_boundaries,i),total:0,items:[],weights:i,getAttrFn:n.nesting?C:S}}search(e,t){var i,n,s=this;n=this.prepareSearch(e,t),t=n.options,e=n.query;const o=t.score||s._getScoreFunction(n);e.length?T(s.items,((e,s)=>{i=o(e),(!1===t.filter||i>0)&&n.items.push({score:i,id:s})})):T(s.items,((e,t)=>{n.items.push({score:1,id:t})}));const r=s._getSortFunction(n);return r&&n.items.sort(r),n.total=n.items.length,"number"==typeof t.limit&&(n.items=n.items.slice(0,t.limit)),n}}const P=e=>null==e?null:$(e),$=e=>"boolean"==typeof e?e?"1":"0":e+"",D=e=>(e+"").replace(/&/g,"&").replace(//g,">").replace(/"/g,"""),j=(e,t)=>{var i;return function(n,s){var o=this;i&&(o.loading=Math.max(o.loading-1,0),clearTimeout(i)),i=setTimeout((function(){i=null,o.loadedSearches[n]=!0,e.call(o,n,s)}),t)}},F=(e,t,i)=>{var n,s=e.trigger,o={};for(n of(e.trigger=function(){var i=arguments[0];if(-1===t.indexOf(i))return s.apply(e,arguments);o[i]=arguments},i.apply(e,[]),e.trigger=s,t))n in o&&s.apply(e,o[n])},M=(e,t=!1)=>{e&&(e.preventDefault(),t&&e.stopPropagation())},q=(e,t,i,n)=>{e.addEventListener(t,i,n)},R=(e,t)=>!!t&&!!t[e]&&1==(t.altKey?1:0)+(t.ctrlKey?1:0)+(t.shiftKey?1:0)+(t.metaKey?1:0),H=(e,t)=>e.getAttribute("id")||(e.setAttribute("id",t),t),z=e=>e.replace(/[\\"']/g,"\\$&"),B=(e,t)=>{t&&e.append(t)},V=(e,t)=>{if(Array.isArray(e))e.forEach(t);else for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},W=e=>{if(e.jquery)return e[0];if(e instanceof HTMLElement)return e;if(K(e)){var t=document.createElement("template");return t.innerHTML=e.trim(),t.content.firstChild}return document.querySelector(e)},K=e=>"string"==typeof e&&e.indexOf("<")>-1,U=(e,t)=>{var i=document.createEvent("HTMLEvents");i.initEvent(t,!0,!1),e.dispatchEvent(i)},Q=(e,t)=>{Object.assign(e.style,t)},J=(e,...t)=>{var i=X(t);(e=G(e)).map((e=>{i.map((t=>{e.classList.add(t)}))}))},Y=(e,...t)=>{var i=X(t);(e=G(e)).map((e=>{i.map((t=>{e.classList.remove(t)}))}))},X=e=>{var t=[];return V(e,(e=>{"string"==typeof e&&(e=e.trim().split(/[\t\n\f\r\s]/)),Array.isArray(e)&&(t=t.concat(e))})),t.filter(Boolean)},G=e=>(Array.isArray(e)||(e=[e]),e),Z=(e,t,i)=>{if(!i||i.contains(e))for(;e&&e.matches;){if(e.matches(t))return e;e=e.parentNode}},ee=(e,t=0)=>t>0?e[e.length-1]:e[0],te=(e,t)=>{if(!e)return-1;t=t||e.nodeName;for(var i=0;e=e.previousElementSibling;)e.matches(t)&&i++;return i},ie=(e,t)=>{V(t,((t,i)=>{null==t?e.removeAttribute(i):e.setAttribute(i,""+t)}))},ne=(e,t)=>{e.parentNode&&e.parentNode.replaceChild(t,e)},se=(e,t)=>{if(null===t)return;if("string"==typeof t){if(!t.length)return;t=new RegExp(t,"i")}const i=e=>3===e.nodeType?(e=>{var i=e.data.match(t);if(i&&e.data.length>0){var n=document.createElement("span");n.className="highlight";var s=e.splitText(i.index);s.splitText(i[0].length);var o=s.cloneNode(!0);return n.appendChild(o),ne(s,n),1}return 0})(e):((e=>{1!==e.nodeType||!e.childNodes||/(script|style)/i.test(e.tagName)||"highlight"===e.className&&"SPAN"===e.tagName||Array.from(e.childNodes).forEach((e=>{i(e)}))})(e),0);i(e)},oe="undefined"!=typeof navigator&&/Mac/.test(navigator.userAgent)?"metaKey":"ctrlKey";var re={options:[],optgroups:[],plugins:[],delimiter:",",splitOn:null,persist:!0,diacritics:!0,create:null,createOnBlur:!1,createFilter:null,highlight:!0,openOnFocus:!0,shouldOpen:null,maxOptions:50,maxItems:null,hideSelected:null,duplicates:!1,addPrecedence:!1,selectOnTab:!1,preload:null,allowEmptyOption:!1,refreshThrottle:300,loadThrottle:300,loadingClass:"loading",dataAttr:null,optgroupField:"optgroup",valueField:"value",labelField:"text",disabledField:"disabled",optgroupLabelField:"label",optgroupValueField:"value",lockOptgroupOrder:!1,sortField:"$order",searchField:["text"],searchConjunction:"and",mode:null,wrapperClass:"ts-wrapper",controlClass:"ts-control",dropdownClass:"ts-dropdown",dropdownContentClass:"ts-dropdown-content",itemClass:"item",optionClass:"option",dropdownParent:null,controlInput:'',copyClassesToDropdown:!1,placeholder:null,hidePlaceholder:null,shouldLoad:function(e){return e.length>0},render:{}};function ae(e,t){var i=Object.assign({},re,t),n=i.dataAttr,s=i.labelField,o=i.valueField,r=i.disabledField,a=i.optgroupField,l=i.optgroupLabelField,c=i.optgroupValueField,d=e.tagName.toLowerCase(),u=e.getAttribute("placeholder")||e.getAttribute("data-placeholder");if(!u&&!i.allowEmptyOption){let t=e.querySelector('option[value=""]');t&&(u=t.textContent)}var h={placeholder:u,options:[],optgroups:[],items:[],maxItems:null};return"select"===d?(()=>{var t,d=h.options,u={},p=1;let f=0;var g=e=>{var t=Object.assign({},e.dataset),i=n&&t[n];return"string"==typeof i&&i.length&&(t=Object.assign(t,JSON.parse(i))),t},m=(e,t)=>{var n=P(e.value);if(null!=n&&(n||i.allowEmptyOption)){if(u.hasOwnProperty(n)){if(t){var l=u[n][a];l?Array.isArray(l)?l.push(t):u[n][a]=[l,t]:u[n][a]=t}}else{var c=g(e);c[s]=c[s]||e.textContent,c[o]=c[o]||n,c[r]=c[r]||e.disabled,c[a]=c[a]||t,c.$option=e,c.$order=c.$order||++f,u[n]=c,d.push(c)}e.selected&&h.items.push(n)}};h.maxItems=e.hasAttribute("multiple")?null:1,V(e.children,(e=>{var i,n,s;"optgroup"===(t=e.tagName.toLowerCase())?((s=g(i=e))[l]=s[l]||i.getAttribute("label")||"",s[c]=s[c]||p++,s[r]=s[r]||i.disabled,s.$order=s.$order||++f,h.optgroups.push(s),n=s[c],V(i.children,(e=>{m(e,n)}))):"option"===t&&m(e)}))})():(()=>{const t=e.getAttribute(n);if(t)h.options=JSON.parse(t),V(h.options,(e=>{h.items.push(e[o])}));else{var r=e.value.trim()||"";if(!i.allowEmptyOption&&!r.length)return;const t=r.split(i.delimiter);V(t,(e=>{const t={};t[s]=e,t[o]=e,h.options.push(t)})),h.items=t}})(),Object.assign({},re,h,t)}var le=0;class ce extends(function(e){return e.plugins={},class extends e{constructor(...e){super(...e),this.plugins={names:[],settings:{},requested:{},loaded:{}}}static define(t,i){e.plugins[t]={name:t,fn:i}}initializePlugins(e){var t,i;const n=this,s=[];if(Array.isArray(e))e.forEach((e=>{"string"==typeof e?s.push(e):(n.plugins.settings[e.name]=e.options,s.push(e.name))}));else if(e)for(t in e)e.hasOwnProperty(t)&&(n.plugins.settings[t]=e[t],s.push(t));for(;i=s.shift();)n.require(i)}loadPlugin(t){var i=this,n=i.plugins,s=e.plugins[t];if(!e.plugins.hasOwnProperty(t))throw new Error('Unable to find "'+t+'" plugin');n.requested[t]=!0,n.loaded[t]=s.fn.apply(i,[i.plugins.settings[t]||{}]),n.names.push(t)}require(e){var t=this,i=t.plugins;if(!t.plugins.loaded.hasOwnProperty(e)){if(i.requested[e])throw new Error('Plugin has circular dependency ("'+e+'")');t.loadPlugin(e)}return i.loaded[e]}}}(t)){constructor(e,t){var i;super(),this.order=0,this.isOpen=!1,this.isDisabled=!1,this.isReadOnly=!1,this.isInvalid=!1,this.isValid=!0,this.isLocked=!1,this.isFocused=!1,this.isInputHidden=!1,this.isSetup=!1,this.ignoreFocus=!1,this.ignoreHover=!1,this.hasOptions=!1,this.lastValue="",this.caretPos=0,this.loading=0,this.loadedSearches={},this.activeOption=null,this.activeItems=[],this.optgroups={},this.options={},this.userOptions={},this.items=[],this.refreshTimeout=null,le++;var n=W(e);if(n.tomselect)throw new Error("Tom Select already initialized on this element");n.tomselect=this,i=(window.getComputedStyle&&window.getComputedStyle(n,null)).getPropertyValue("direction");const s=ae(n,t);this.settings=s,this.input=n,this.tabIndex=n.tabIndex||0,this.is_select_tag="select"===n.tagName.toLowerCase(),this.rtl=/rtl/i.test(i),this.inputId=H(n,"tomselect-"+le),this.isRequired=n.required,this.sifter=new N(this.options,{diacritics:s.diacritics}),s.mode=s.mode||(1===s.maxItems?"single":"multi"),"boolean"!=typeof s.hideSelected&&(s.hideSelected="multi"===s.mode),"boolean"!=typeof s.hidePlaceholder&&(s.hidePlaceholder="multi"!==s.mode);var o=s.createFilter;"function"!=typeof o&&("string"==typeof o&&(o=new RegExp(o)),o instanceof RegExp?s.createFilter=e=>o.test(e):s.createFilter=e=>this.settings.duplicates||!this.options[e]),this.initializePlugins(s.plugins),this.setupCallbacks(),this.setupTemplates();const r=W("
"),a=W("
"),l=this._render("dropdown"),c=W('
'),d=this.input.getAttribute("class")||"",u=s.mode;var h;J(r,s.wrapperClass,d,u),J(a,s.controlClass),B(r,a),J(l,s.dropdownClass,u),s.copyClassesToDropdown&&J(l,d),J(c,s.dropdownContentClass),B(l,c),W(s.dropdownParent||r).appendChild(l),K(s.controlInput)?(h=W(s.controlInput),V(["autocorrect","autocapitalize","autocomplete","spellcheck"],(e=>{n.getAttribute(e)&&ie(h,{[e]:n.getAttribute(e)})})),h.tabIndex=-1,a.appendChild(h),this.focus_node=h):s.controlInput?(h=W(s.controlInput),this.focus_node=h):(h=W(""),this.focus_node=a),this.wrapper=r,this.dropdown=l,this.dropdown_content=c,this.control=a,this.control_input=h,this.setup()}setup(){const e=this,t=e.settings,i=e.control_input,n=e.dropdown,s=e.dropdown_content,o=e.wrapper,a=e.control,l=e.input,c=e.focus_node,d={passive:!0},u=e.inputId+"-ts-dropdown";ie(s,{id:u}),ie(c,{role:"combobox","aria-haspopup":"listbox","aria-expanded":"false","aria-controls":u});const h=H(c,e.inputId+"-ts-control"),p="label[for='"+(e=>e.replace(/['"\\]/g,"\\$&"))(e.inputId)+"']",f=document.querySelector(p),g=e.focus.bind(e);if(f){q(f,"click",g),ie(f,{for:h});const t=H(f,e.inputId+"-ts-label");ie(c,{"aria-labelledby":t}),ie(s,{"aria-labelledby":t})}if(o.style.width=l.style.width,e.plugins.names.length){const t="plugin-"+e.plugins.names.join(" plugin-");J([o,n],t)}(null===t.maxItems||t.maxItems>1)&&e.is_select_tag&&ie(l,{multiple:"multiple"}),t.placeholder&&ie(i,{placeholder:t.placeholder}),!t.splitOn&&t.delimiter&&(t.splitOn=new RegExp("\\s*"+r(t.delimiter)+"+\\s*")),t.load&&t.loadThrottle&&(t.load=j(t.load,t.loadThrottle)),q(n,"mousemove",(()=>{e.ignoreHover=!1})),q(n,"mouseenter",(t=>{var i=Z(t.target,"[data-selectable]",n);i&&e.onOptionHover(t,i)}),{capture:!0}),q(n,"click",(t=>{const i=Z(t.target,"[data-selectable]");i&&(e.onOptionSelect(t,i),M(t,!0))})),q(a,"click",(t=>{var n=Z(t.target,"[data-ts-item]",a);n&&e.onItemSelect(t,n)?M(t,!0):""==i.value&&(e.onClick(),M(t,!0))})),q(c,"keydown",(t=>e.onKeyDown(t))),q(i,"keypress",(t=>e.onKeyPress(t))),q(i,"input",(t=>e.onInput(t))),q(c,"blur",(t=>e.onBlur(t))),q(c,"focus",(t=>e.onFocus(t))),q(i,"paste",(t=>e.onPaste(t)));const m=t=>{const s=t.composedPath()[0];if(!o.contains(s)&&!n.contains(s))return e.isFocused&&e.blur(),void e.inputState();s==i&&e.isOpen?t.stopPropagation():M(t,!0)},v=()=>{e.isOpen&&e.positionDropdown()};q(document,"mousedown",m),q(window,"scroll",v,d),q(window,"resize",v,d),this._destroy=()=>{document.removeEventListener("mousedown",m),window.removeEventListener("scroll",v),window.removeEventListener("resize",v),f&&f.removeEventListener("click",g)},this.revertSettings={innerHTML:l.innerHTML,tabIndex:l.tabIndex},l.tabIndex=-1,l.insertAdjacentElement("afterend",e.wrapper),e.sync(!1),t.items=[],delete t.optgroups,delete t.options,q(l,"invalid",(()=>{e.isValid&&(e.isValid=!1,e.isInvalid=!0,e.refreshState())})),e.updateOriginalInput(),e.refreshItems(),e.close(!1),e.inputState(),e.isSetup=!0,l.disabled?e.disable():l.readOnly?e.setReadOnly(!0):e.enable(),e.on("change",this.onChange),J(l,"tomselected","ts-hidden-accessible"),e.trigger("initialize"),!0===t.preload&&e.preload()}setupOptions(e=[],t=[]){this.addOptions(e),V(t,(e=>{this.registerOptionGroup(e)}))}setupTemplates(){var e=this,t=e.settings.labelField,i=e.settings.optgroupLabelField,n={optgroup:e=>{let t=document.createElement("div");return t.className="optgroup",t.appendChild(e.options),t},optgroup_header:(e,t)=>'
'+t(e[i])+"
",option:(e,i)=>"
"+i(e[t])+"
",item:(e,i)=>"
"+i(e[t])+"
",option_create:(e,t)=>'
Add '+t(e.input)+"
",no_results:()=>'
No results found
',loading:()=>'
',not_loading:()=>{},dropdown:()=>"
"};e.settings.render=Object.assign({},n,e.settings.render)}setupCallbacks(){var e,t,i={initialize:"onInitialize",change:"onChange",item_add:"onItemAdd",item_remove:"onItemRemove",item_select:"onItemSelect",clear:"onClear",option_add:"onOptionAdd",option_remove:"onOptionRemove",option_clear:"onOptionClear",optgroup_add:"onOptionGroupAdd",optgroup_remove:"onOptionGroupRemove",optgroup_clear:"onOptionGroupClear",dropdown_open:"onDropdownOpen",dropdown_close:"onDropdownClose",type:"onType",load:"onLoad",focus:"onFocus",blur:"onBlur"};for(e in i)(t=this.settings[i[e]])&&this.on(e,t)}sync(e=!0){const t=this,i=e?ae(t.input,{delimiter:t.settings.delimiter}):t.settings;t.setupOptions(i.options,i.optgroups),t.setValue(i.items||[],!0),t.lastQuery=null}onClick(){var e=this;if(e.activeItems.length>0)return e.clearActiveItems(),void e.focus();e.isFocused&&e.isOpen?e.blur():e.focus()}onMouseDown(){}onChange(){U(this.input,"input"),U(this.input,"change")}onPaste(e){var t=this;t.isInputHidden||t.isLocked?M(e):t.settings.splitOn&&setTimeout((()=>{var e=t.inputValue();if(e.match(t.settings.splitOn)){var i=e.trim().split(t.settings.splitOn);V(i,(e=>{P(e)&&(this.options[e]?t.addItem(e):t.createItem(e))}))}}),0)}onKeyPress(e){var t=this;if(!t.isLocked){var i=String.fromCharCode(e.keyCode||e.which);return t.settings.create&&"multi"===t.settings.mode&&i===t.settings.delimiter?(t.createItem(),void M(e)):void 0}M(e)}onKeyDown(e){var t=this;if(t.ignoreHover=!0,t.isLocked)9!==e.keyCode&&M(e);else{switch(e.keyCode){case 65:if(R(oe,e)&&""==t.control_input.value)return M(e),void t.selectAll();break;case 27:return t.isOpen&&(M(e,!0),t.close()),void t.clearActiveItems();case 40:if(!t.isOpen&&t.hasOptions)t.open();else if(t.activeOption){let e=t.getAdjacent(t.activeOption,1);e&&t.setActiveOption(e)}return void M(e);case 38:if(t.activeOption){let e=t.getAdjacent(t.activeOption,-1);e&&t.setActiveOption(e)}return void M(e);case 13:return void(t.canSelect(t.activeOption)?(t.onOptionSelect(e,t.activeOption),M(e)):(t.settings.create&&t.createItem()||document.activeElement==t.control_input&&t.isOpen)&&M(e));case 37:return void t.advanceSelection(-1,e);case 39:return void t.advanceSelection(1,e);case 9:return void(t.settings.selectOnTab&&(t.canSelect(t.activeOption)&&(t.onOptionSelect(e,t.activeOption),M(e)),t.settings.create&&t.createItem()&&M(e)));case 8:case 46:return void t.deleteSelection(e)}t.isInputHidden&&!R(oe,e)&&M(e)}}onInput(e){if(this.isLocked)return;const t=this.inputValue();this.lastValue!==t&&(this.lastValue=t,""!=t?(this.refreshTimeout&&window.clearTimeout(this.refreshTimeout),this.refreshTimeout=((e,t)=>t>0?window.setTimeout(e,t):(e.call(null),null))((()=>{this.refreshTimeout=null,this._onInput()}),this.settings.refreshThrottle)):this._onInput())}_onInput(){const e=this.lastValue;this.settings.shouldLoad.call(this,e)&&this.load(e),this.refreshOptions(),this.trigger("type",e)}onOptionHover(e,t){this.ignoreHover||this.setActiveOption(t,!1)}onFocus(e){var t=this,i=t.isFocused;if(t.isDisabled||t.isReadOnly)return t.blur(),void M(e);t.ignoreFocus||(t.isFocused=!0,"focus"===t.settings.preload&&t.preload(),i||t.trigger("focus"),t.activeItems.length||(t.inputState(),t.refreshOptions(!!t.settings.openOnFocus)),t.refreshState())}onBlur(e){if(!1!==document.hasFocus()){var t=this;if(t.isFocused){t.isFocused=!1,t.ignoreFocus=!1;var i=()=>{t.close(),t.setActiveItem(),t.setCaret(t.items.length),t.trigger("blur")};t.settings.create&&t.settings.createOnBlur?t.createItem(null,i):i()}}}onOptionSelect(e,t){var i,n=this;t.parentElement&&t.parentElement.matches("[data-disabled]")||(t.classList.contains("create")?n.createItem(null,(()=>{n.settings.closeAfterSelect&&n.close()})):void 0!==(i=t.dataset.value)&&(n.lastQuery=null,n.addItem(i),n.settings.closeAfterSelect&&n.close(),!n.settings.hideSelected&&e.type&&/click/.test(e.type)&&n.setActiveOption(t)))}canSelect(e){return!!(this.isOpen&&e&&this.dropdown_content.contains(e))}onItemSelect(e,t){var i=this;return!i.isLocked&&"multi"===i.settings.mode&&(M(e),i.setActiveItem(t,e),!0)}canLoad(e){return!!this.settings.load&&!this.loadedSearches.hasOwnProperty(e)}load(e){const t=this;if(!t.canLoad(e))return;J(t.wrapper,t.settings.loadingClass),t.loading++;const i=t.loadCallback.bind(t);t.settings.load.call(t,e,i)}loadCallback(e,t){const i=this;i.loading=Math.max(i.loading-1,0),i.lastQuery=null,i.clearActiveOption(),i.setupOptions(e,t),i.refreshOptions(i.isFocused&&!i.isInputHidden),i.loading||Y(i.wrapper,i.settings.loadingClass),i.trigger("load",e,t)}preload(){var e=this.wrapper.classList;e.contains("preloaded")||(e.add("preloaded"),this.load(""))}setTextboxValue(e=""){var t=this.control_input;t.value!==e&&(t.value=e,U(t,"update"),this.lastValue=e)}getValue(){return this.is_select_tag&&this.input.hasAttribute("multiple")?this.items:this.items.join(this.settings.delimiter)}setValue(e,t){F(this,t?[]:["change"],(()=>{this.clear(t),this.addItems(e,t)}))}setMaxItems(e){0===e&&(e=null),this.settings.maxItems=e,this.refreshState()}setActiveItem(e,t){var i,n,s,o,r,a,l=this;if("single"!==l.settings.mode){if(!e)return l.clearActiveItems(),void(l.isFocused&&l.inputState());if("click"===(i=t&&t.type.toLowerCase())&&R("shiftKey",t)&&l.activeItems.length){for(a=l.getLastActive(),(s=Array.prototype.indexOf.call(l.control.children,a))>(o=Array.prototype.indexOf.call(l.control.children,e))&&(r=s,s=o,o=r),n=s;n<=o;n++)e=l.control.children[n],-1===l.activeItems.indexOf(e)&&l.setActiveItemClass(e);M(t)}else"click"===i&&R(oe,t)||"keydown"===i&&R("shiftKey",t)?e.classList.contains("active")?l.removeActiveItem(e):l.setActiveItemClass(e):(l.clearActiveItems(),l.setActiveItemClass(e));l.inputState(),l.isFocused||l.focus()}}setActiveItemClass(e){const t=this,i=t.control.querySelector(".last-active");i&&Y(i,"last-active"),J(e,"active last-active"),t.trigger("item_select",e),-1==t.activeItems.indexOf(e)&&t.activeItems.push(e)}removeActiveItem(e){var t=this.activeItems.indexOf(e);this.activeItems.splice(t,1),Y(e,"active")}clearActiveItems(){Y(this.activeItems,"active"),this.activeItems=[]}setActiveOption(e,t=!0){e!==this.activeOption&&(this.clearActiveOption(),e&&(this.activeOption=e,ie(this.focus_node,{"aria-activedescendant":e.getAttribute("id")}),ie(e,{"aria-selected":"true"}),J(e,"active"),t&&this.scrollToOption(e)))}scrollToOption(e,t){if(!e)return;const i=this.dropdown_content,n=i.clientHeight,s=i.scrollTop||0,o=e.offsetHeight,r=e.getBoundingClientRect().top-i.getBoundingClientRect().top+s;r+o>n+s?this.scroll(r-n+o,t):r{e.setActiveItemClass(t)})))}inputState(){var e=this;e.control.contains(e.control_input)&&(ie(e.control_input,{placeholder:e.settings.placeholder}),e.activeItems.length>0||!e.isFocused&&e.settings.hidePlaceholder&&e.items.length>0?(e.setTextboxValue(),e.isInputHidden=!0):(e.settings.hidePlaceholder&&e.items.length>0&&ie(e.control_input,{placeholder:""}),e.isInputHidden=!1),e.wrapper.classList.toggle("input-hidden",e.isInputHidden))}inputValue(){return this.control_input.value.trim()}focus(){var e=this;e.isDisabled||e.isReadOnly||(e.ignoreFocus=!0,e.control_input.offsetWidth?e.control_input.focus():e.focus_node.focus(),setTimeout((()=>{e.ignoreFocus=!1,e.onFocus()}),0))}blur(){this.focus_node.blur(),this.onBlur()}getScoreFunction(e){return this.sifter.getScoreFunction(e,this.getSearchOptions())}getSearchOptions(){var e=this.settings,t=e.sortField;return"string"==typeof e.sortField&&(t=[{field:e.sortField}]),{fields:e.searchField,conjunction:e.searchConjunction,sort:t,nesting:e.nesting}}search(e){var t,i,n=this,s=this.getSearchOptions();if(n.settings.score&&"function"!=typeof(i=n.settings.score.call(n,e)))throw new Error('Tom Select "score" setting must be a function that returns a function');return e!==n.lastQuery?(n.lastQuery=e,t=n.sifter.search(e,Object.assign(s,{score:i})),n.currentResults=t):t=Object.assign({},n.currentResults),n.settings.hideSelected&&(t.items=t.items.filter((e=>{let t=P(e.id);return!(t&&-1!==n.items.indexOf(t))}))),t}refreshOptions(e=!0){var t,i,n,s,o,r,a,l,c,d;const u={},h=[];var p=this,f=p.inputValue();const g=f===p.lastQuery||""==f&&null==p.lastQuery;var m=p.search(f),v=null,_=p.settings.shouldOpen||!1,b=p.dropdown_content;g&&(v=p.activeOption)&&(c=v.closest("[data-group]")),s=m.items.length,"number"==typeof p.settings.maxOptions&&(s=Math.min(s,p.settings.maxOptions)),s>0&&(_=!0);const y=(e,t)=>{let i=u[e];if(void 0!==i){let e=h[i];if(void 0!==e)return[i,e.fragment]}let n=document.createDocumentFragment();return i=h.length,h.push({fragment:n,order:t,optgroup:e}),[i,n]};for(t=0;t0&&(d=d.cloneNode(!0),ie(d,{id:a.$id+"-clone-"+i,"aria-selected":null}),d.classList.add("ts-cloned"),Y(d,"active"),p.activeOption&&p.activeOption.dataset.value==s&&c&&c.dataset.group===o.toString()&&(v=d)),l.appendChild(d),""!=o&&(u[o]=n)}}var w;p.settings.lockOptgroupOrder&&h.sort(((e,t)=>e.order-t.order)),a=document.createDocumentFragment(),V(h,(e=>{let t=e.fragment,i=e.optgroup;if(!t||!t.children.length)return;let n=p.optgroups[i];if(void 0!==n){let e=document.createDocumentFragment(),i=p.render("optgroup_header",n);B(e,i),B(e,t);let s=p.render("optgroup",{group:n,options:e});B(a,s)}else B(a,t)})),b.innerHTML="",B(b,a),p.settings.highlight&&(w=b.querySelectorAll("span.highlight"),Array.prototype.forEach.call(w,(function(e){var t=e.parentNode;t.replaceChild(e.firstChild,e),t.normalize()})),m.query.length&&m.tokens.length&&V(m.tokens,(e=>{se(b,e.regex)})));var O=e=>{let t=p.render(e,{input:f});return t&&(_=!0,b.insertBefore(t,b.firstChild)),t};if(p.loading?O("loading"):p.settings.shouldLoad.call(p,f)?0===m.items.length&&O("no_results"):O("not_loading"),(l=p.canCreate(f))&&(d=O("option_create")),p.hasOptions=m.items.length>0||l,_){if(m.items.length>0){if(v||"single"!==p.settings.mode||null==p.items[0]||(v=p.getOption(p.items[0])),!b.contains(v)){let e=0;d&&!p.settings.addPrecedence&&(e=1),v=p.selectable()[e]}}else d&&(v=d);e&&!p.isOpen&&(p.open(),p.scrollToOption(v,"auto")),p.setActiveOption(v)}else p.clearActiveOption(),e&&p.isOpen&&p.close(!1)}selectable(){return this.dropdown_content.querySelectorAll("[data-selectable]")}addOption(e,t=!1){const i=this;if(Array.isArray(e))return i.addOptions(e,t),!1;const n=P(e[i.settings.valueField]);return null!==n&&!i.options.hasOwnProperty(n)&&(e.$order=e.$order||++i.order,e.$id=i.inputId+"-opt-"+e.$order,i.options[n]=e,i.lastQuery=null,t&&(i.userOptions[n]=t,i.trigger("option_add",n,e)),n)}addOptions(e,t=!1){V(e,(e=>{this.addOption(e,t)}))}registerOption(e){return this.addOption(e)}registerOptionGroup(e){var t=P(e[this.settings.optgroupValueField]);return null!==t&&(e.$order=e.$order||++this.order,this.optgroups[t]=e,t)}addOptionGroup(e,t){var i;t[this.settings.optgroupValueField]=e,(i=this.registerOptionGroup(t))&&this.trigger("optgroup_add",i,t)}removeOptionGroup(e){this.optgroups.hasOwnProperty(e)&&(delete this.optgroups[e],this.clearCache(),this.trigger("optgroup_remove",e))}clearOptionGroups(){this.optgroups={},this.clearCache(),this.trigger("optgroup_clear")}updateOption(e,t){const i=this;var n,s;const o=P(e),r=P(t[i.settings.valueField]);if(null===o)return;const a=i.options[o];if(null==a)return;if("string"!=typeof r)throw new Error("Value must be set in option data");const l=i.getOption(o),c=i.getItem(o);if(t.$order=t.$order||a.$order,delete i.options[o],i.uncacheValue(r),i.options[r]=t,l){if(i.dropdown_content.contains(l)){const e=i._render("option",t);ne(l,e),i.activeOption===l&&i.setActiveOption(e)}l.remove()}c&&(-1!==(s=i.items.indexOf(o))&&i.items.splice(s,1,r),n=i._render("item",t),c.classList.contains("active")&&J(n,"active"),ne(c,n)),i.lastQuery=null}removeOption(e,t){const i=this;e=$(e),i.uncacheValue(e),delete i.userOptions[e],delete i.options[e],i.lastQuery=null,i.trigger("option_remove",e),i.removeItem(e,t)}clearOptions(e){const t=(e||this.clearFilter).bind(this);this.loadedSearches={},this.userOptions={},this.clearCache();const i={};V(this.options,((e,n)=>{t(e,n)&&(i[n]=e)})),this.options=this.sifter.items=i,this.lastQuery=null,this.trigger("option_clear")}clearFilter(e,t){return this.items.indexOf(t)>=0}getOption(e,t=!1){const i=P(e);if(null===i)return null;const n=this.options[i];if(null!=n){if(n.$div)return n.$div;if(t)return this._render("option",n)}return null}getAdjacent(e,t,i="option"){var n;if(!e)return null;n="item"==i?this.controlChildren():this.dropdown_content.querySelectorAll("[data-selectable]");for(let i=0;i0?n[i+1]:n[i-1];return null}getItem(e){if("object"==typeof e)return e;var t=P(e);return null!==t?this.control.querySelector(`[data-value="${z(t)}"]`):null}addItems(e,t){var i=this,n=Array.isArray(e)?e:[e];const s=(n=n.filter((e=>-1===i.items.indexOf(e))))[n.length-1];n.forEach((e=>{i.isPending=e!==s,i.addItem(e,t)}))}addItem(e,t){F(this,t?[]:["change","dropdown_close"],(()=>{var i,n;const s=this,o=s.settings.mode,r=P(e);if((!r||-1===s.items.indexOf(r)||("single"===o&&s.close(),"single"!==o&&s.settings.duplicates))&&null!==r&&s.options.hasOwnProperty(r)&&("single"===o&&s.clear(t),"multi"!==o||!s.isFull())){if(i=s._render("item",s.options[r]),s.control.contains(i)&&(i=i.cloneNode(!0)),n=s.isFull(),s.items.splice(s.caretPos,0,r),s.insertAtCaret(i),s.isSetup){if(!s.isPending&&s.settings.hideSelected){let e=s.getOption(r),t=s.getAdjacent(e,1);t&&s.setActiveOption(t)}s.isPending||s.settings.closeAfterSelect||s.refreshOptions(s.isFocused&&"single"!==o),0!=s.settings.closeAfterSelect&&s.isFull()?s.close():s.isPending||s.positionDropdown(),s.trigger("item_add",r,i),s.isPending||s.updateOriginalInput({silent:t})}(!s.isPending||!n&&s.isFull())&&(s.inputState(),s.refreshState())}}))}removeItem(e=null,t){const i=this;if(!(e=i.getItem(e)))return;var n,s;const o=e.dataset.value;n=te(e),e.remove(),e.classList.contains("active")&&(s=i.activeItems.indexOf(e),i.activeItems.splice(s,1),Y(e,"active")),i.items.splice(n,1),i.lastQuery=null,!i.settings.persist&&i.userOptions.hasOwnProperty(o)&&i.removeOption(o,t),n{}){3===arguments.length&&(t=arguments[2]),"function"!=typeof t&&(t=()=>{});var i,n=this,s=n.caretPos;if(e=e||n.inputValue(),!n.canCreate(e))return t(),!1;n.lock();var o=!1,r=e=>{if(n.unlock(),!e||"object"!=typeof e)return t();var i=P(e[n.settings.valueField]);if("string"!=typeof i)return t();n.setTextboxValue(),n.addOption(e,!0),n.setCaret(s),n.addItem(i),t(e),o=!0};return i="function"==typeof n.settings.create?n.settings.create.call(this,e,r):{[n.settings.labelField]:e,[n.settings.valueField]:e},o||r(i),!0}refreshItems(){var e=this;e.lastQuery=null,e.isSetup&&e.addItems(e.items),e.updateOriginalInput(),e.refreshState()}refreshState(){const e=this;e.refreshValidityState();const t=e.isFull(),i=e.isLocked;e.wrapper.classList.toggle("rtl",e.rtl);const n=e.wrapper.classList;var s;n.toggle("focus",e.isFocused),n.toggle("disabled",e.isDisabled),n.toggle("readonly",e.isReadOnly),n.toggle("required",e.isRequired),n.toggle("invalid",!e.isValid),n.toggle("locked",i),n.toggle("full",t),n.toggle("input-active",e.isFocused&&!e.isInputHidden),n.toggle("dropdown-active",e.isOpen),n.toggle("has-options",(s=e.options,0===Object.keys(s).length)),n.toggle("has-items",e.items.length>0)}refreshValidityState(){var e=this;e.input.validity&&(e.isValid=e.input.validity.valid,e.isInvalid=!e.isValid)}isFull(){return null!==this.settings.maxItems&&this.items.length>=this.settings.maxItems}updateOriginalInput(e={}){const t=this;var i,n;const s=t.input.querySelector('option[value=""]');if(t.is_select_tag){const o=[],r=t.input.querySelectorAll("option:checked").length;function a(e,i,n){return e||(e=W('")),e!=s&&t.input.append(e),o.push(e),(e!=s||r>0)&&(e.selected=!0),e}t.input.querySelectorAll("option:checked").forEach((e=>{e.selected=!1})),0==t.items.length&&"single"==t.settings.mode?a(s,"",""):t.items.forEach((e=>{i=t.options[e],n=i[t.settings.labelField]||"",o.includes(i.$option)?a(t.input.querySelector(`option[value="${z(e)}"]:not(:checked)`),e,n):i.$option=a(i.$option,e,n)}))}else t.input.value=t.getValue();t.isSetup&&(e.silent||t.trigger("change",t.getValue()))}open(){var e=this;e.isLocked||e.isOpen||"multi"===e.settings.mode&&e.isFull()||(e.isOpen=!0,ie(e.focus_node,{"aria-expanded":"true"}),e.refreshState(),Q(e.dropdown,{visibility:"hidden",display:"block"}),e.positionDropdown(),Q(e.dropdown,{visibility:"visible",display:"block"}),e.focus(),e.trigger("dropdown_open",e.dropdown))}close(e=!0){var t=this,i=t.isOpen;e&&(t.setTextboxValue(),"single"===t.settings.mode&&t.items.length&&t.inputState()),t.isOpen=!1,ie(t.focus_node,{"aria-expanded":"false"}),Q(t.dropdown,{display:"none"}),t.settings.hideSelected&&t.clearActiveOption(),t.refreshState(),i&&t.trigger("dropdown_close",t.dropdown)}positionDropdown(){if("body"===this.settings.dropdownParent){var e=this.control,t=e.getBoundingClientRect(),i=e.offsetHeight+t.top+window.scrollY,n=t.left+window.scrollX;Q(this.dropdown,{width:t.width+"px",top:i+"px",left:n+"px"})}}clear(e){var t=this;if(t.items.length){var i=t.controlChildren();V(i,(e=>{t.removeItem(e,!0)})),t.inputState(),e||t.updateOriginalInput(),t.trigger("clear")}}insertAtCaret(e){const t=this,i=t.caretPos,n=t.control;n.insertBefore(e,n.children[i]||null),t.setCaret(i+1)}deleteSelection(e){var t,i,n,s,o,r=this;t=e&&8===e.keyCode?-1:1,i={start:(o=r.control_input).selectionStart||0,length:(o.selectionEnd||0)-(o.selectionStart||0)};const a=[];if(r.activeItems.length)s=ee(r.activeItems,t),n=te(s),t>0&&n++,V(r.activeItems,(e=>a.push(e)));else if((r.isFocused||"single"===r.settings.mode)&&r.items.length){const e=r.controlChildren();let n;t<0&&0===i.start&&0===i.length?n=e[r.caretPos-1]:t>0&&i.start===r.inputValue().length&&(n=e[r.caretPos]),void 0!==n&&a.push(n)}if(!r.shouldDelete(a,e))return!1;for(M(e,!0),void 0!==n&&r.setCaret(n);a.length;)r.removeItem(a.pop());return r.inputState(),r.positionDropdown(),r.refreshOptions(!1),!0}shouldDelete(e,t){const i=e.map((e=>e.dataset.value));return!(!i.length||"function"==typeof this.settings.onDelete&&!1===this.settings.onDelete(i,t))}advanceSelection(e,t){var i,n,s=this;s.rtl&&(e*=-1),s.inputValue().length||(R(oe,t)||R("shiftKey",t)?(n=(i=s.getLastActive(e))?i.classList.contains("active")?s.getAdjacent(i,e,"item"):i:e>0?s.control_input.nextElementSibling:s.control_input.previousElementSibling)&&(n.classList.contains("active")&&s.removeActiveItem(i),s.setActiveItemClass(n)):s.moveCaret(e))}moveCaret(e){}getLastActive(e){let t=this.control.querySelector(".last-active");if(t)return t;var i=this.control.querySelectorAll(".active");return i?ee(i,e):void 0}setCaret(e){this.caretPos=this.items.length}controlChildren(){return Array.from(this.control.querySelectorAll("[data-ts-item]"))}lock(){this.setLocked(!0)}unlock(){this.setLocked(!1)}setLocked(e=this.isReadOnly||this.isDisabled){this.isLocked=e,this.refreshState()}disable(){this.setDisabled(!0),this.close()}enable(){this.setDisabled(!1)}setDisabled(e){this.focus_node.tabIndex=e?-1:this.tabIndex,this.isDisabled=e,this.input.disabled=e,this.control_input.disabled=e,this.setLocked()}setReadOnly(e){this.isReadOnly=e,this.input.readOnly=e,this.control_input.readOnly=e,this.setLocked()}destroy(){var e=this,t=e.revertSettings;e.trigger("destroy"),e.off(),e.wrapper.remove(),e.dropdown.remove(),e.input.innerHTML=t.innerHTML,e.input.tabIndex=t.tabIndex,Y(e.input,"tomselected","ts-hidden-accessible"),e._destroy(),delete e.input.tomselect}render(e,t){var i,n;const s=this;if("function"!=typeof this.settings.render[e])return null;if(!(n=s.settings.render[e].call(this,t,D)))return null;if(n=W(n),"option"===e||"option_create"===e?t[s.settings.disabledField]?ie(n,{"aria-disabled":"true"}):ie(n,{"data-selectable":""}):"optgroup"===e&&(i=t.group[s.settings.optgroupValueField],ie(n,{"data-group":i}),t.group[s.settings.disabledField]&&ie(n,{"data-disabled":""})),"option"===e||"item"===e){const i=$(t[s.settings.valueField]);ie(n,{"data-value":i}),"item"===e?(J(n,s.settings.itemClass),ie(n,{"data-ts-item":""})):(J(n,s.settings.optionClass),ie(n,{role:"option",id:t.$id}),t.$div=n,s.options[i]=t)}return n}_render(e,t){const i=this.render(e,t);if(null==i)throw"HTMLElement expected";return i}clearCache(){V(this.options,(e=>{e.$div&&(e.$div.remove(),delete e.$div)}))}uncacheValue(e){const t=this.getOption(e);t&&t.remove()}canCreate(e){return this.settings.create&&e.length>0&&this.settings.createFilter.call(this,e)}hook(e,t,i){var n=this,s=n[t];n[t]=function(){var t,o;return"after"===e&&(t=s.apply(n,arguments)),o=i.apply(n,arguments),"instead"===e?o:("before"===e&&(t=s.apply(n,arguments)),t)}}}return ce.define("change_listener",(function(){q(this.input,"change",(()=>{this.sync()}))})),ce.define("checkbox_options",(function(e){var t=this,i=t.onOptionSelect;t.settings.hideSelected=!1;const n=Object.assign({className:"tomselect-checkbox",checkedClassNames:void 0,uncheckedClassNames:void 0},e);var s=function(e,t){t?(e.checked=!0,n.uncheckedClassNames&&e.classList.remove(...n.uncheckedClassNames),n.checkedClassNames&&e.classList.add(...n.checkedClassNames)):(e.checked=!1,n.checkedClassNames&&e.classList.remove(...n.checkedClassNames),n.uncheckedClassNames&&e.classList.add(...n.uncheckedClassNames))},o=function(e){setTimeout((()=>{var t=e.querySelector("input."+n.className);t instanceof HTMLInputElement&&s(t,e.classList.contains("selected"))}),1)};t.hook("after","setupTemplates",(()=>{var e=t.settings.render.option;t.settings.render.option=(i,o)=>{var r=W(e.call(t,i,o)),a=document.createElement("input");n.className&&a.classList.add(n.className),a.addEventListener("click",(function(e){M(e)})),a.type="checkbox";const l=P(i[t.settings.valueField]);return s(a,!!(l&&t.items.indexOf(l)>-1)),r.prepend(a),r}})),t.on("item_remove",(e=>{var i=t.getOption(e);i&&(i.classList.remove("selected"),o(i))})),t.on("item_add",(e=>{var i=t.getOption(e);i&&o(i)})),t.hook("instead","onOptionSelect",((e,n)=>{if(n.classList.contains("selected"))return n.classList.remove("selected"),t.removeItem(n.dataset.value),t.refreshOptions(),void M(e,!0);i.call(t,e,n),o(n)}))})),ce.define("clear_button",(function(e){const t=this,i=Object.assign({className:"clear-button",title:"Clear All",html:e=>`
`},e);t.on("initialize",(()=>{var e=W(i.html(i));e.addEventListener("click",(e=>{t.isLocked||(t.clear(),"single"===t.settings.mode&&t.settings.allowEmptyOption&&t.addItem(""),e.preventDefault(),e.stopPropagation())})),t.control.appendChild(e)}))})),ce.define("drag_drop",(function(){var e=this;if("multi"!==e.settings.mode)return;var t=e.lock,i=e.unlock;let n,s=!0;e.hook("after","setupTemplates",(()=>{var t=e.settings.render.item;e.settings.render.item=(i,o)=>{const r=W(t.call(e,i,o));ie(r,{draggable:"true"});const a=e=>{e.preventDefault(),r.classList.add("ts-drag-over"),l(r,n)},l=(e,t)=>{var i,n,s;void 0!==t&&(((e,t)=>{do{var i;if(e==(t=null==(i=t)?void 0:i.previousElementSibling))return!0}while(t&&t.previousElementSibling);return!1})(t,r)?(n=t,null==(s=(i=e).parentNode)||s.insertBefore(n,i.nextSibling)):((e,t)=>{var i;null==(i=e.parentNode)||i.insertBefore(t,e)})(e,t))};return q(r,"mousedown",(e=>{s||M(e),e.stopPropagation()})),q(r,"dragstart",(e=>{n=r,setTimeout((()=>{r.classList.add("ts-dragging")}),0)})),q(r,"dragenter",a),q(r,"dragover",a),q(r,"dragleave",(()=>{r.classList.remove("ts-drag-over")})),q(r,"dragend",(()=>{var t;document.querySelectorAll(".ts-drag-over").forEach((e=>e.classList.remove("ts-drag-over"))),null==(t=n)||t.classList.remove("ts-dragging"),n=void 0;var i=[];e.control.querySelectorAll("[data-value]").forEach((e=>{if(e.dataset.value){let t=e.dataset.value;t&&i.push(t)}})),e.setValue(i)})),r}})),e.hook("instead","lock",(()=>(s=!1,t.call(e)))),e.hook("instead","unlock",(()=>(s=!0,i.call(e))))})),ce.define("dropdown_header",(function(e){const t=this,i=Object.assign({title:"Untitled",headerClass:"dropdown-header",titleRowClass:"dropdown-header-title",labelClass:"dropdown-header-label",closeClass:"dropdown-header-close",html:e=>'
'+e.title+'×
'},e);t.on("initialize",(()=>{var e=W(i.html(i)),n=e.querySelector("."+i.closeClass);n&&n.addEventListener("click",(e=>{M(e,!0),t.close()})),t.dropdown.insertBefore(e,t.dropdown.firstChild)}))})),ce.define("caret_position",(function(){var e=this;e.hook("instead","setCaret",(t=>{"single"!==e.settings.mode&&e.control.contains(e.control_input)?(t=Math.max(0,Math.min(e.items.length,t)))==e.caretPos||e.isPending||e.controlChildren().forEach(((i,n)=>{n{if(!e.isFocused)return;const i=e.getLastActive(t);if(i){const n=te(i);e.setCaret(t>0?n+1:n),e.setActiveItem(),Y(i,"last-active")}else e.setCaret(e.caretPos+t)}))})),ce.define("dropdown_input",(function(){const e=this;e.settings.shouldOpen=!0,e.hook("before","setup",(()=>{e.focus_node=e.control,J(e.control_input,"dropdown-input");const t=W('")}},plugins:{dropdown_input:{}}};return null===e.getAttribute("required")&&null===e.getAttribute("disabled")&&(t.plugins.clear_button={title:""}),null!==e.getAttribute("multiple")&&(t.plugins.remove_button={title:""}),null!==e.getAttribute("data-ea-autocomplete-endpoint-url")&&(t.plugins.virtual_scroll={}),"true"===e.getAttribute("data-ea-autocomplete-allow-item-create")&&(t.create=!0),t}function b(e){var t=g(m,this,E).call(this,g(m,this,_).call(this,e),{maxOptions:null});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:t,prefix:"autocomplete"},bubbles:!0}));var i=new(a())(e,t);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:i,config:t,prefix:"autocomplete"},bubbles:!0})),i}function y(e){for(var t=[],i=0;i".concat(e.label_raw,"
")},option:function(e,t){return"
".concat(e.label_raw,"
")}}});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:o,prefix:"autocomplete"},bubbles:!0}));var r=new(a())(e,o);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:r,config:o,prefix:"autocomplete"},bubbles:!0})),r}function w(e,t){var i="true"===e.getAttribute("data-ea-autocomplete-render-items-as-html"),n=g(m,this,E).call(this,g(m,this,_).call(this,e),{valueField:"entityId",labelField:"entityAsString",searchField:["entityAsString"],firstUrl:function(e){return"".concat(t,"&query=").concat(encodeURIComponent(e))},load:function(e,t){var i=this,n=this.getUrl(e);fetch(n).then((function(e){return e.json()})).then((function(n){i.setNextUrl(e,n.next_page),t(n.results)})).catch((function(){return t()}))},preload:"focus",maxOptions:null,score:function(e){return function(e){return 1}},render:{option:function(e,t){return"
".concat(i?e.entityAsString:t(e.entityAsString),"
")},item:function(e,t){return"
".concat(i?e.entityAsString:t(e.entityAsString),"
")},loading_more:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-loading-more-results"),"
")},no_more_results:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-no-more-results"),"
")},no_results:function(t,i){return'
'.concat(e.getAttribute("data-ea-i18n-no-results-found"),"
")}}});e.dispatchEvent(new CustomEvent("ea.autocomplete.pre-connect",{detail:{config:n,prefix:"autocomplete"},bubbles:!0}));var s=new(a())(e,n);return e.dispatchEvent(new CustomEvent("ea.autocomplete.connect",{detail:{tomSelect:s,config:n,prefix:"autocomplete"},bubbles:!0})),s}function O(e){return e.replace(/(<([^>]+)>)/gi,"")}function E(e,t){return d(d({},e),t)}function A(e,t){t?(e.classList.remove("d-block"),e.classList.add("d-none")):(e.classList.remove("d-none"),e.classList.add("d-block"))}function x(e){return x="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},x(e)}function S(e,t){for(var i=0;i
',fetch(t.getAttribute("href")).then((function(e){return e.text()})).then((function(t){s.innerHTML=t,P(j,e,W).call(e),P(j,e,J).call(e)})).catch((function(e){console.error(e)})),n.preventDefault()}));var n=function(e){e.closest("form").querySelectorAll('input[name^="filters['.concat(e.dataset.filterProperty,']"]')).forEach((function(e){e.remove()})),e.remove()};document.querySelector("#modal-clear-button").addEventListener("click",(function(){i.querySelectorAll(".filter-field").forEach((function(e){n(e)})),i.querySelector("form").submit()})),document.querySelector("#modal-apply-button").addEventListener("click",(function(){i.querySelectorAll(".filter-checkbox:not(:checked)").forEach((function(e){n(e.closest(".filter-field"))})),i.querySelector("form").submit()}))}}function V(){var e=null,t=document.querySelector(".form-batch-checkbox-all");if(null!==t){var i=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox');t.addEventListener("change",(function(){i.forEach((function(e){e.checked=t.checked,e.dispatchEvent(new Event("change"))}))}));var n=document.querySelector(".deselect-batch-button");null!==n&&n.addEventListener("click",(function(){t.checked=!1,t.dispatchEvent(new Event("change"))})),i.forEach((function(n,s){n.dataset.rowIndex=s,n.addEventListener("click",(function(t){if(e&&t.shiftKey){var n=Number.parseInt(e.dataset.rowIndex),s=Number.parseInt(t.target.dataset.rowIndex),o=t.target.checked,r=Math.min(n,s),a=Math.max(n,s);i.forEach((function(e,t){r<=t&&t<=a&&(e.checked=o,e.dispatchEvent(new Event("change")))}))}e=t.target})),n.addEventListener("change",(function(){var e=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox:checked'),i=n.closest("tr"),s=n.closest(".content");n.checked?i.classList.add("selected-row"):(i.classList.remove("selected-row"),t.checked=!1);var o=0!==e.length,r=document.querySelector(".content-header-title > .title"),a=s.querySelector(".datagrid-filters"),l=s.querySelector(".global-actions"),c=s.querySelector(".batch-actions");null!==r&&A(r,o),null!==a&&A(a,o),null!==l&&A(l,o),null!==c&&A(c,!o)}))}));var s=document.querySelector("#batch-action-confirmation-title"),o=s.textContent;document.querySelectorAll("[data-action-batch]").forEach((function(e){e.addEventListener("click",(function(e){e.preventDefault();var t=e.currentTarget,i=t.textContent.trim()||t.getAttribute("title"),n=document.querySelectorAll('input[type="checkbox"].form-batch-checkbox:checked');s.textContent=o.replace("%action_name%",i).replace("%num_items%",n.length.toString()),document.querySelector("#modal-batch-action-button").addEventListener("click",(function(){t.setAttribute("disabled","disabled");var e={batchActionName:t.getAttribute("data-action-name"),entityFqcn:t.getAttribute("data-entity-fqcn"),batchActionUrl:t.getAttribute("data-action-url"),batchActionCsrfToken:t.getAttribute("data-action-csrf-token")};n.forEach((function(t,i){e["batchActionEntityIds[".concat(i,"]")]=t.value}));var i=document.createElement("form");for(var s in i.setAttribute("method","POST"),i.setAttribute("action",t.getAttribute("data-action-url")),e){var o=document.createElement("input");o.setAttribute("type","hidden"),o.setAttribute("name",s),o.setAttribute("value",e[s]),i.appendChild(o)}document.body.appendChild(i),i.submit()}))}))}))}}function W(){var e=new v;document.querySelectorAll('[data-ea-widget="ea-autocomplete"]').forEach((function(t){e.create(t)}))}function K(){document.querySelectorAll('[data-action-name="delete"]').forEach((function(e){e.addEventListener("click",(function(t){t.preventDefault(),document.querySelector("#modal-delete-button").addEventListener("click",(function(){var t=e.getAttribute("formaction"),i=document.querySelector("#delete-form");i.setAttribute("action",t),i.submit()}))}))}))}function U(){document.querySelectorAll('[data-bs-toggle="popover"]').forEach((function(e){new(t().Popover)(e)}))}function Q(){document.querySelectorAll('[data-bs-toggle="tooltip"]').forEach((function(e){new(t().Tooltip)(e)}))}function J(){document.querySelectorAll(".filter-checkbox").forEach((function(e){e.addEventListener("change",(function(){var t=e.nextElementSibling,i=e.nextElementSibling.getAttribute("aria-expanded");(e.checked&&"false"===i||!e.checked&&"true"===i)&&t.click()}))})),document.querySelectorAll("form[data-ea-filters-form-id]").forEach((function(e){e.addEventListener("change",(function(e){if(!e.target.classList.contains("filter-checkbox")){var t=e.target.closest(".filter-field").querySelector(".filter-checkbox");t.checked||(t.checked=!0)}}))})),document.querySelectorAll("[data-ea-comparison-id]").forEach((function(e){e.addEventListener("change",(function(e){var t=e.currentTarget,i=t.dataset.eaComparisonId;if(void 0!==i){var n=document.querySelector('[data-ea-value2-of-comparison-id="'.concat(i,'"]'));null!==n&&A(n,"between"!==t.value)}}))}))}function Y(){document.querySelectorAll(".list-pagination-counter select[data-ea-paginator-list-size-per-page]").forEach((function(e){e.addEventListener("change",(function(e){var t=new URL(window.location.href);t.searchParams.set("size",e.currentTarget.value),t.searchParams.set("page","1"),window.location.replace(t.toString())}))}))}})()})(); \ No newline at end of file diff --git a/public/app.09038c6d.js.LICENSE.txt b/public/app.b25cfb59.js.LICENSE.txt similarity index 100% rename from public/app.09038c6d.js.LICENSE.txt rename to public/app.b25cfb59.js.LICENSE.txt diff --git a/public/entrypoints.json b/public/entrypoints.json index 7595d514cd..2ee21470b1 100644 --- a/public/entrypoints.json +++ b/public/entrypoints.json @@ -5,7 +5,7 @@ "/app.54fc226c.css" ], "js": [ - "/app.09038c6d.js" + "/app.b25cfb59.js" ] }, "form": { diff --git a/public/manifest.json b/public/manifest.json index 73a015f01d..c9b8fa9b7a 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -1,6 +1,6 @@ { "app.css": "app.54fc226c.css", - "app.js": "app.09038c6d.js", + "app.js": "app.b25cfb59.js", "form.js": "form.875c88d4.js", "page-layout.js": "page-layout.6e9fe55d.js", "page-color-scheme.js": "page-color-scheme.30cb23c2.js", diff --git a/src/Config/Crud.php b/src/Config/Crud.php index 29a8ab2ee6..40bab05851 100644 --- a/src/Config/Crud.php +++ b/src/Config/Crud.php @@ -39,6 +39,11 @@ class Crud private bool $paginatorFetchJoinCollection = true; private ?bool $paginatorUseOutputWalkers = null; + /** @var int[] */ + private array $listSizePerPage = [ + 10, 20, 30, 40, 50, 100, 150, + ]; + private function __construct(private readonly CrudDto $dto) { } @@ -326,6 +331,14 @@ public function setPaginatorPageSize(int $maxResultsPerPage): self return $this; } + /** + * @param int[] $listSizePerPage + */ + public function setListSizePerPage(array $listSizePerPage): void + { + $this->listSizePerPage = $listSizePerPage; + } + public function setPaginatorRangeSize(int $maxPagesOnEachSide): self { if ($maxPagesOnEachSide < 0) { @@ -439,7 +452,13 @@ public function hideNullValues(bool $hide = true): self public function getAsDto(): CrudDto { - $this->dto->setPaginator(new PaginatorDto($this->paginatorPageSize, $this->paginatorRangeSize, 1, $this->paginatorFetchJoinCollection, $this->paginatorUseOutputWalkers)); + $this->dto->setPaginator(new PaginatorDto( + $this->paginatorPageSize, + $this->paginatorRangeSize, 1, + $this->listSizePerPage, + $this->paginatorFetchJoinCollection, + $this->paginatorUseOutputWalkers + )); return $this->dto; } diff --git a/src/Dto/PaginatorDto.php b/src/Dto/PaginatorDto.php index 906850602f..ebf5c6835e 100644 --- a/src/Dto/PaginatorDto.php +++ b/src/Dto/PaginatorDto.php @@ -9,10 +9,14 @@ final class PaginatorDto { private ?int $pageNumber = null; + /** + * @param int[] $listSizePerPage + */ public function __construct( private readonly int $pageSize, private readonly int $rangeSize, private readonly int $rangeEdgeSize, + private readonly array $listSizePerPage, private readonly bool $fetchJoinCollection, private readonly ?bool $useOutputWalkers, ) { @@ -52,4 +56,12 @@ public function useOutputWalkers(): ?bool { return $this->useOutputWalkers; } + + /** + * @return int[] + */ + public function getListSizePerPage(): array + { + return $this->listSizePerPage; + } } diff --git a/templates/crud/paginator.html.twig b/templates/crud/paginator.html.twig index e520149aae..b363fa04fd 100644 --- a/templates/crud/paginator.html.twig +++ b/templates/crud/paginator.html.twig @@ -5,6 +5,11 @@
+ {% if render_detailed_pagination is defined ? render_detailed_pagination : true %} {{ 'paginator.results'|trans({'%count%': paginator.numResults|format})|raw }} {% endif %}