From dce50ae0afcd86305b5203f95368f01f65367037 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Fri, 17 Jan 2025 14:49:37 -0500 Subject: [PATCH] Release v4.2.2 --- .../ISSUE_TEMPLATE/01-feature_request.yaml | 2 +- .github/ISSUE_TEMPLATE/02-bug_report.yaml | 2 +- base_requirements.txt | 2 -- docs/release-notes/version-4.2.md | 20 ++++++++++++++++++ netbox/project-static/dist/netbox.js | 10 ++++----- netbox/project-static/dist/netbox.js.map | 4 ++-- netbox/project-static/package.json | 4 ++-- netbox/project-static/yarn.lock | 16 +++++++------- netbox/release.yaml | 4 ++-- netbox/translations/ru/LC_MESSAGES/django.mo | Bin 301883 -> 301870 bytes netbox/translations/ru/LC_MESSAGES/django.po | 10 ++++----- requirements.txt | 10 ++++----- 12 files changed, 51 insertions(+), 33 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/01-feature_request.yaml b/.github/ISSUE_TEMPLATE/01-feature_request.yaml index 2215ab7a18..6212af3b82 100644 --- a/.github/ISSUE_TEMPLATE/01-feature_request.yaml +++ b/.github/ISSUE_TEMPLATE/01-feature_request.yaml @@ -14,7 +14,7 @@ body: attributes: label: NetBox version description: What version of NetBox are you currently running? - placeholder: v4.2.1 + placeholder: v4.2.2 validations: required: true - type: dropdown diff --git a/.github/ISSUE_TEMPLATE/02-bug_report.yaml b/.github/ISSUE_TEMPLATE/02-bug_report.yaml index f007b67cc9..4382a9b764 100644 --- a/.github/ISSUE_TEMPLATE/02-bug_report.yaml +++ b/.github/ISSUE_TEMPLATE/02-bug_report.yaml @@ -26,7 +26,7 @@ body: attributes: label: NetBox Version description: What version of NetBox are you currently running? - placeholder: v4.2.1 + placeholder: v4.2.2 validations: required: true - type: dropdown diff --git a/base_requirements.txt b/base_requirements.txt index 4cb355dd5a..9cf0fbf8be 100644 --- a/base_requirements.txt +++ b/base_requirements.txt @@ -8,8 +8,6 @@ django-cors-headers # Runtime UI tool for debugging Django # https://github.com/jazzband/django-debug-toolbar/blob/main/docs/changes.rst -# Pinned for DNS looukp bug; see https://github.com/netbox-community/netbox/issues/16454 -# and https://github.com/jazzband/django-debug-toolbar/issues/1927 django-debug-toolbar # Library for writing reusable URL query filters diff --git a/docs/release-notes/version-4.2.md b/docs/release-notes/version-4.2.md index a1dafaf142..61f043f3df 100644 --- a/docs/release-notes/version-4.2.md +++ b/docs/release-notes/version-4.2.md @@ -1,5 +1,25 @@ # NetBox v4.2 +## v4.2.2 (2025-01-17) + +### Bug Fixes + +* [#18336](https://github.com/netbox-community/netbox/issues/18336) - Validate new rack height against installed devices when changing a rack's type +* [#18350](https://github.com/netbox-community/netbox/issues/18350) - Fix `FieldDoesNotExist` exception when global search results include a circuit termination +* [#18353](https://github.com/netbox-community/netbox/issues/18353) - Disable fetching of plugin catalog data when `ISOLATED_DEPLOYMENT` is enabled +* [#18362](https://github.com/netbox-community/netbox/issues/18362) - Avoid transmitting census data on every worker restart +* [#18363](https://github.com/netbox-community/netbox/issues/18363) - Fix support for assigning a MAC address to an interface via the REST API +* [#18368](https://github.com/netbox-community/netbox/issues/18368) - Restore missing attributes from REST API serializer for MAC addresses (`tags`, `created`, `last_updated`, and custom fields) +* [#18369](https://github.com/netbox-community/netbox/issues/18369) - Fix `TypeError` exception when rendering the system configuration view with one or more custom classes defined under `PROTECTION_RULES` +* [#18373](https://github.com/netbox-community/netbox/issues/18373) - Fix `AttributeError` exception when attempting to assign host devices to a cluster +* [#18376](https://github.com/netbox-community/netbox/issues/18376) - Fix the display of tagged VLANs in interfaces list for Q-in-Q interfaces +* [#18379](https://github.com/netbox-community/netbox/issues/18379) - Ensure RSS feed dashboard widget content is sanitized +* [#18392](https://github.com/netbox-community/netbox/issues/18392) - Virtual machines should not inherit config contexts assigned to locations +* [#18400](https://github.com/netbox-community/netbox/issues/18400) - Fix support for `STORAGE_BACKEND` configuration parameter +* [#18406](https://github.com/netbox-community/netbox/issues/18406) - Scope column headers in object lists should not be orderable + +--- + ## v4.2.1 (2025-01-08) ### Bug Fixes diff --git a/netbox/project-static/dist/netbox.js b/netbox/project-static/dist/netbox.js index 4661582a3f..7e516f7f48 100644 --- a/netbox/project-static/dist/netbox.js +++ b/netbox/project-static/dist/netbox.js @@ -1,12 +1,12 @@ "use strict";(()=>{var Xh=Object.create;var Aa=Object.defineProperty,Jh=Object.defineProperties,Zh=Object.getOwnPropertyDescriptor,ep=Object.getOwnPropertyDescriptors,tp=Object.getOwnPropertyNames,ou=Object.getOwnPropertySymbols,ip=Object.getPrototypeOf,su=Object.prototype.hasOwnProperty,np=Object.prototype.propertyIsEnumerable;var Fl=(ii,ei,ti)=>ei in ii?Aa(ii,ei,{enumerable:!0,configurable:!0,writable:!0,value:ti}):ii[ei]=ti,Di=(ii,ei)=>{for(var ti in ei||(ei={}))su.call(ei,ti)&&Fl(ii,ti,ei[ti]);if(ou)for(var ti of ou(ei))np.call(ei,ti)&&Fl(ii,ti,ei[ti]);return ii},sn=(ii,ei)=>Jh(ii,ep(ei));var au=(ii,ei)=>()=>(ei||ii((ei={exports:{}}).exports,ei),ei.exports),lu=(ii,ei)=>{for(var ti in ei)Aa(ii,ti,{get:ei[ti],enumerable:!0})},rp=(ii,ei,ti,ni)=>{if(ei&&typeof ei=="object"||typeof ei=="function")for(let ri of tp(ei))!su.call(ii,ri)&&ri!==ti&&Aa(ii,ri,{get:()=>ei[ri],enumerable:!(ni=Zh(ei,ri))||ni.enumerable});return ii};var cu=(ii,ei,ti)=>(ti=ii!=null?Xh(ip(ii)):{},rp(ei||!ii||!ii.__esModule?Aa(ti,"default",{value:ii,enumerable:!0}):ti,ii));var en=(ii,ei,ti)=>Fl(ii,typeof ei!="symbol"?ei+"":ei,ti);var co=(ii,ei,ti)=>new Promise((ni,ri)=>{var oi=li=>{try{ai(ti.next(li))}catch(ui){ri(ui)}},si=li=>{try{ai(ti.throw(li))}catch(ui){ri(ui)}},ai=li=>li.done?ni(li.value):Promise.resolve(li.value).then(oi,si);ai((ti=ti.apply(ii,ei)).next())});var Ld=au((exports,module)=>{(function(ii,ei){typeof define=="function"&&define.amd?define([],ei):typeof module=="object"&&module.exports?module.exports=ei():ii.htmx=ii.htmx||ei()})(typeof self!="undefined"?self:exports,function(){return function(){"use strict";var Q={onLoad:F,process:zt,on:de,off:ge,trigger:ce,ajax:Nr,find:C,findAll:f,closest:v,values:function(ii,ei){var ti=dr(ii,ei||"post");return ti.values},remove:_,addClass:z,removeClass:n,toggleClass:$,takeClass:W,defineExtension:Ur,removeExtension:Br,logAll:V,logNone:j,logger:null,config:{historyEnabled:!0,historyCacheSize:10,refreshOnHistoryMiss:!1,defaultSwapStyle:"innerHTML",defaultSwapDelay:0,defaultSettleDelay:20,includeIndicatorStyles:!0,indicatorClass:"htmx-indicator",requestClass:"htmx-request",addedClass:"htmx-added",settlingClass:"htmx-settling",swappingClass:"htmx-swapping",allowEval:!0,allowScriptTags:!0,inlineScriptNonce:"",attributesToSettle:["class","style","width","height"],withCredentials:!1,timeout:0,wsReconnectDelay:"full-jitter",wsBinaryType:"blob",disableSelector:"[hx-disable], [data-hx-disable]",useTemplateFragments:!1,scrollBehavior:"smooth",defaultFocusScroll:!1,getCacheBusterParam:!1,globalViewTransitions:!1,methodsThatUseUrlParams:["get"],selfRequestsOnly:!1,ignoreTitle:!1,scrollIntoViewOnBoost:!0,triggerSpecsCache:null},parseInterval:d,_:t,createEventSource:function(ii){return new EventSource(ii,{withCredentials:!0})},createWebSocket:function(ii){var ei=new WebSocket(ii,[]);return ei.binaryType=Q.config.wsBinaryType,ei},version:"1.9.12"},r={addTriggerHandler:Lt,bodyContains:se,canAccessLocalStorage:U,findThisElement:xe,filterValues:yr,hasAttribute:o,getAttributeValue:te,getClosestAttributeValue:ne,getClosestMatch:c,getExpressionVars:Hr,getHeaders:xr,getInputValues:dr,getInternalData:ae,getSwapSpecification:wr,getTriggerSpecs:it,getTarget:ye,makeFragment:l,mergeObjects:le,makeSettleInfo:T,oobSwap:Ee,querySelectorExt:ue,selectAndSwap:je,settleImmediately:nr,shouldCancel:ut,triggerEvent:ce,triggerErrorEvent:fe,withExtensions:R},w=["get","post","put","delete","patch"],i=w.map(function(ii){return"[hx-"+ii+"], [data-hx-"+ii+"]"}).join(", "),S=e("head"),q=e("title"),H=e("svg",!0);function e(ii,ei){return new RegExp("<"+ii+"(\\s[^>]*>|>)([\\s\\S]*?)<\\/"+ii+">",ei?"gim":"im")}function d(ii){if(ii==null)return;let ei=NaN;return ii.slice(-2)=="ms"?ei=parseFloat(ii.slice(0,-2)):ii.slice(-1)=="s"?ei=parseFloat(ii.slice(0,-1))*1e3:ii.slice(-1)=="m"?ei=parseFloat(ii.slice(0,-1))*1e3*60:ei=parseFloat(ii),isNaN(ei)?void 0:ei}function ee(ii,ei){return ii.getAttribute&&ii.getAttribute(ei)}function o(ii,ei){return ii.hasAttribute&&(ii.hasAttribute(ei)||ii.hasAttribute("data-"+ei))}function te(ii,ei){return ee(ii,ei)||ee(ii,"data-"+ei)}function u(ii){return ii.parentElement}function re(){return document}function c(ii,ei){for(;ii&&!ei(ii);)ii=u(ii);return ii||null}function L(ii,ei,ti){var ni=te(ei,ti),ri=te(ei,"hx-disinherit");return ii!==ei&&ri&&(ri==="*"||ri.split(" ").indexOf(ti)>=0)?"unset":ni}function ne(ii,ei){var ti=null;if(c(ii,function(ni){return ti=L(ii,ni,ei)}),ti!=="unset")return ti}function h(ii,ei){var ti=ii.matches||ii.matchesSelector||ii.msMatchesSelector||ii.mozMatchesSelector||ii.webkitMatchesSelector||ii.oMatchesSelector;return ti&&ti.call(ii,ei)}function A(ii){var ei=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,ti=ei.exec(ii);return ti?ti[1].toLowerCase():""}function s(ii,ei){for(var ti=new DOMParser,ni=ti.parseFromString(ii,"text/html"),ri=ni.body;ei>0;)ei--,ri=ri.firstChild;return ri==null&&(ri=re().createDocumentFragment()),ri}function N(ii){return/",0),oi=ri.querySelector("template").content;return Q.config.allowScriptTags?oe(oi.querySelectorAll("script"),function(si){Q.config.inlineScriptNonce&&(si.nonce=Q.config.inlineScriptNonce),si.htmxExecuted=navigator.userAgent.indexOf("Firefox")===-1}):oe(oi.querySelectorAll("script"),function(si){_(si)}),oi}switch(ti){case"thead":case"tbody":case"tfoot":case"colgroup":case"caption":return s(""+ni+"
",1);case"col":return s(""+ni+"
",2);case"tr":return s(""+ni+"
",2);case"td":case"th":return s(""+ni+"
",3);case"script":case"style":return s("
"+ni+"
",1);default:return s(ni,0)}}function ie(ii){ii&&ii()}function I(ii,ei){return Object.prototype.toString.call(ii)==="[object "+ei+"]"}function k(ii){return I(ii,"Function")}function P(ii){return I(ii,"Object")}function ae(ii){var ei="htmx-internal-data",ti=ii[ei];return ti||(ti=ii[ei]={}),ti}function M(ii){var ei=[];if(ii)for(var ti=0;ti=0}function se(ii){return ii.getRootNode&&ii.getRootNode()instanceof window.ShadowRoot?re().body.contains(ii.getRootNode().host):re().body.contains(ii)}function D(ii){return ii.trim().split(/\s+/)}function le(ii,ei){for(var ti in ei)ei.hasOwnProperty(ti)&&(ii[ti]=ei[ti]);return ii}function E(ii){try{return JSON.parse(ii)}catch(ei){return b(ei),null}}function U(){var ii="htmx:localStorageTest";try{return localStorage.setItem(ii,ii),localStorage.removeItem(ii),!0}catch(ei){return!1}}function B(ii){try{var ei=new URL(ii);return ei&&(ii=ei.pathname+ei.search),/^\/$/.test(ii)||(ii=ii.replace(/\/+$/,"")),ii}catch(ti){return ii}}function t(e){return Tr(re().body,function(){return eval(e)})}function F(ii){var ei=Q.on("htmx:load",function(ti){ii(ti.detail.elt)});return ei}function V(){Q.logger=function(ii,ei,ti){console&&console.log(ei,ii,ti)}}function j(){Q.logger=null}function C(ii,ei){return ei?ii.querySelector(ei):C(re(),ii)}function f(ii,ei){return ei?ii.querySelectorAll(ei):f(re(),ii)}function _(ii,ei){ii=p(ii),ei?setTimeout(function(){_(ii),ii=null},ei):ii.parentElement.removeChild(ii)}function z(ii,ei,ti){ii=p(ii),ti?setTimeout(function(){z(ii,ei),ii=null},ti):ii.classList&&ii.classList.add(ei)}function n(ii,ei,ti){ii=p(ii),ti?setTimeout(function(){n(ii,ei),ii=null},ti):ii.classList&&(ii.classList.remove(ei),ii.classList.length===0&&ii.removeAttribute("class"))}function $(ii,ei){ii=p(ii),ii.classList.toggle(ei)}function W(ii,ei){ii=p(ii),oe(ii.parentElement.children,function(ti){n(ti,ei)}),z(ii,ei)}function v(ii,ei){if(ii=p(ii),ii.closest)return ii.closest(ei);do if(ii==null||h(ii,ei))return ii;while(ii=ii&&u(ii));return null}function g(ii,ei){return ii.substring(0,ei.length)===ei}function G(ii,ei){return ii.substring(ii.length-ei.length)===ei}function J(ii){var ei=ii.trim();return g(ei,"<")&&G(ei,"/>")?ei.substring(1,ei.length-2):ei}function Z(ii,ei){return ei.indexOf("closest ")===0?[v(ii,J(ei.substr(8)))]:ei.indexOf("find ")===0?[C(ii,J(ei.substr(5)))]:ei==="next"?[ii.nextElementSibling]:ei.indexOf("next ")===0?[K(ii,J(ei.substr(5)))]:ei==="previous"?[ii.previousElementSibling]:ei.indexOf("previous ")===0?[Y(ii,J(ei.substr(9)))]:ei==="document"?[document]:ei==="window"?[window]:ei==="body"?[document.body]:re().querySelectorAll(J(ei))}var K=function(ii,ei){for(var ti=re().querySelectorAll(ei),ni=0;ni=0;ni--){var ri=ti[ni];if(ri.compareDocumentPosition(ii)===Node.DOCUMENT_POSITION_FOLLOWING)return ri}};function ue(ii,ei){return ei?Z(ii,ei)[0]:Z(re().body,ii)[0]}function p(ii){return I(ii,"String")?C(ii):ii}function ve(ii,ei,ti){return k(ei)?{target:re().body,event:ii,listener:ei}:{target:p(ii),event:ei,listener:ti}}function de(ii,ei,ti){jr(function(){var ri=ve(ii,ei,ti);ri.target.addEventListener(ri.event,ri.listener)});var ni=k(ei);return ni?ei:ti}function ge(ii,ei,ti){return jr(function(){var ni=ve(ii,ei,ti);ni.target.removeEventListener(ni.event,ni.listener)}),k(ei)?ei:ti}var pe=re().createElement("output");function me(ii,ei){var ti=ne(ii,ei);if(ti){if(ti==="this")return[xe(ii,ei)];var ni=Z(ii,ti);return ni.length===0?(b('The selector "'+ti+'" on '+ei+" returned no matches!"),[pe]):ni}}function xe(ii,ei){return c(ii,function(ti){return te(ti,ei)!=null})}function ye(ii){var ei=ne(ii,"hx-target");if(ei)return ei==="this"?xe(ii,"hx-target"):ue(ii,ei);var ti=ae(ii);return ti.boosted?re().body:ii}function be(ii){for(var ei=Q.config.attributesToSettle,ti=0;ti0?(ri=ii.substr(0,ii.indexOf(":")),ni=ii.substr(ii.indexOf(":")+1,ii.length)):ri=ii);var oi=re().querySelectorAll(ni);return oi?(oe(oi,function(si){var ai,li=ei.cloneNode(!0);ai=re().createDocumentFragment(),ai.appendChild(li),Se(ri,si)||(ai=li);var ui={shouldSwap:!0,target:si,fragment:ai};ce(si,"htmx:oobBeforeSwap",ui)&&(si=ui.target,ui.shouldSwap&&Fe(ri,si,si,ai,ti),oe(ti.elts,function(ci){ce(ci,"htmx:oobAfterSwap",ui)}))}),ei.parentNode.removeChild(ei)):(ei.parentNode.removeChild(ei),fe(re().body,"htmx:oobErrorNoTarget",{content:ei})),ii}function Ce(ii,ei,ti){var ni=ne(ii,"hx-select-oob");if(ni)for(var ri=ni.split(","),oi=0;oi0){var oi=ri.replace("'","\\'"),si=ni.tagName.replace(":","\\:"),ai=ii.querySelector(si+"[id='"+oi+"']");if(ai&&ai!==ii){var li=ni.cloneNode();we(ni,ai),ti.tasks.push(function(){we(ni,li)})}}})}function Oe(ii){return function(){n(ii,Q.config.addedClass),zt(ii),Nt(ii),qe(ii),ce(ii,"htmx:load")}}function qe(ii){var ei="[autofocus]",ti=h(ii,ei)?ii:ii.querySelector(ei);ti!=null&&ti.focus()}function a(ii,ei,ti,ni){for(Te(ii,ti,ni);ti.childNodes.length>0;){var ri=ti.firstChild;z(ri,Q.config.addedClass),ii.insertBefore(ri,ei),ri.nodeType!==Node.TEXT_NODE&&ri.nodeType!==Node.COMMENT_NODE&&ni.tasks.push(Oe(ri))}}function He(ii,ei){for(var ti=0;ti-1){var ei=ii.replace(H,""),ti=ei.match(q);if(ti)return ti[2]}}function je(ii,ei,ti,ni,ri,oi){ri.title=Ve(ni);var si=l(ni);if(si)return Ce(ti,si,ri),si=Be(ti,si,oi),Re(si),Fe(ii,ti,ei,si,ri)}function _e(ii,ei,ti){var ni=ii.getResponseHeader(ei);if(ni.indexOf("{")===0){var ri=E(ni);for(var oi in ri)if(ri.hasOwnProperty(oi)){var si=ri[oi];P(si)||(si={value:si}),ce(ti,oi,si)}}else for(var ai=ni.split(","),li=0;li0;){var si=ei[0];if(si==="]"){if(ni--,ni===0){oi===null&&(ri=ri+"true"),ei.shift(),ri+=")})";try{var ai=Tr(ii,function(){return Function(ri)()},function(){return!0});return ai.source=ri,ai}catch(li){return fe(re().body,"htmx:syntax:error",{error:li,source:ri}),null}}}else si==="["&&ni++;Qe(si,oi,ti)?ri+="(("+ti+"."+si+") ? ("+ti+"."+si+") : (window."+si+"))":ri=ri+si,oi=ei.shift()}}}function y(ii,ei){for(var ti="";ii.length>0&&!ei.test(ii[0]);)ti+=ii.shift();return ti}function tt(ii){var ei;return ii.length>0&&Ze.test(ii[0])?(ii.shift(),ei=y(ii,Ke).trim(),ii.shift()):ei=y(ii,x),ei}var rt="input, textarea, select";function nt(ii,ei,ti){var ni=[],ri=Ye(ei);do{y(ri,Je);var oi=ri.length,si=y(ri,/[,\[\s]/);if(si!=="")if(si==="every"){var ai={trigger:"every"};y(ri,Je),ai.pollInterval=d(y(ri,/[,\[\s]/)),y(ri,Je);var li=et(ii,ri,"event");li&&(ai.eventFilter=li),ni.push(ai)}else if(si.indexOf("sse:")===0)ni.push({trigger:"sse",sseEvent:si.substr(4)});else{var ui={trigger:si},li=et(ii,ri,"event");for(li&&(ui.eventFilter=li);ri.length>0&&ri[0]!==",";){y(ri,Je);var ci=ri.shift();if(ci==="changed")ui.changed=!0;else if(ci==="once")ui.once=!0;else if(ci==="consume")ui.consume=!0;else if(ci==="delay"&&ri[0]===":")ri.shift(),ui.delay=d(y(ri,x));else if(ci==="from"&&ri[0]===":"){if(ri.shift(),Ze.test(ri[0]))var di=tt(ri);else{var di=y(ri,x);if(di==="closest"||di==="find"||di==="next"||di==="previous"){ri.shift();var pi=tt(ri);pi.length>0&&(di+=" "+pi)}}ui.from=di}else ci==="target"&&ri[0]===":"?(ri.shift(),ui.target=tt(ri)):ci==="throttle"&&ri[0]===":"?(ri.shift(),ui.throttle=d(y(ri,x))):ci==="queue"&&ri[0]===":"?(ri.shift(),ui.queue=y(ri,x)):ci==="root"&&ri[0]===":"?(ri.shift(),ui[ci]=tt(ri)):ci==="threshold"&&ri[0]===":"?(ri.shift(),ui[ci]=y(ri,x)):fe(ii,"htmx:syntax:error",{token:ri.shift()})}ni.push(ui)}ri.length===oi&&fe(ii,"htmx:syntax:error",{token:ri.shift()}),y(ri,Je)}while(ri[0]===","&&ri.shift());return ti&&(ti[ei]=ni),ni}function it(ii){var ei=te(ii,"hx-trigger"),ti=[];if(ei){var ni=Q.config.triggerSpecsCache;ti=ni&&ni[ei]||nt(ii,ei,ni)}return ti.length>0?ti:h(ii,"form")?[{trigger:"submit"}]:h(ii,'input[type="button"], input[type="submit"]')?[{trigger:"click"}]:h(ii,rt)?[{trigger:"change"}]:[{trigger:"click"}]}function at(ii){ae(ii).cancelled=!0}function ot(ii,ei,ti){var ni=ae(ii);ni.timeout=setTimeout(function(){se(ii)&&ni.cancelled!==!0&&(ct(ti,ii,Wt("hx:poll:trigger",{triggerSpec:ti,target:ii}))||ei(ii),ot(ii,ei,ti))},ti.pollInterval)}function st(ii){return location.hostname===ii.hostname&&ee(ii,"href")&&ee(ii,"href").indexOf("#")!==0}function lt(ii,ei,ti){if(ii.tagName==="A"&&st(ii)&&(ii.target===""||ii.target==="_self")||ii.tagName==="FORM"){ei.boosted=!0;var ni,ri;if(ii.tagName==="A")ni="get",ri=ee(ii,"href");else{var oi=ee(ii,"method");ni=oi?oi.toLowerCase():"get",ri=ee(ii,"action")}ti.forEach(function(si){ht(ii,function(ai,li){if(v(ai,Q.config.disableSelector)){m(ai);return}he(ni,ri,ai,li)},ei,si,!0)})}}function ut(ii,ei){return!!((ii.type==="submit"||ii.type==="click")&&(ei.tagName==="FORM"||h(ei,'input[type="submit"], button')&&v(ei,"form")!==null||ei.tagName==="A"&&ei.href&&(ei.getAttribute("href")==="#"||ei.getAttribute("href").indexOf("#")!==0)))}function ft(ii,ei){return ae(ii).boosted&&ii.tagName==="A"&&ei.type==="click"&&(ei.ctrlKey||ei.metaKey)}function ct(ii,ei,ti){var ni=ii.eventFilter;if(ni)try{return ni.call(ei,ti)!==!0}catch(ri){return fe(re().body,"htmx:eventFilter:error",{error:ri,source:ni.source}),!0}return!1}function ht(ii,ei,ti,ni,ri){var oi=ae(ii),si;ni.from?si=Z(ii,ni.from):si=[ii],ni.changed&&si.forEach(function(ai){var li=ae(ai);li.lastValue=ai.value}),oe(si,function(ai){var li=function(ui){if(!se(ii)){ai.removeEventListener(ni.trigger,li);return}if(!ft(ii,ui)&&((ri||ut(ui,ii))&&ui.preventDefault(),!ct(ni,ii,ui))){var ci=ae(ui);if(ci.triggerSpec=ni,ci.handledFor==null&&(ci.handledFor=[]),ci.handledFor.indexOf(ii)<0){if(ci.handledFor.push(ii),ni.consume&&ui.stopPropagation(),ni.target&&ui.target&&!h(ui.target,ni.target))return;if(ni.once){if(oi.triggeredOnce)return;oi.triggeredOnce=!0}if(ni.changed){var di=ae(ai);if(di.lastValue===ai.value)return;di.lastValue=ai.value}if(oi.delayed&&clearTimeout(oi.delayed),oi.throttle)return;ni.throttle>0?oi.throttle||(ei(ii,ui),oi.throttle=setTimeout(function(){oi.throttle=null},ni.throttle)):ni.delay>0?oi.delayed=setTimeout(function(){ei(ii,ui)},ni.delay):(ce(ii,"htmx:trigger"),ei(ii,ui))}}};ti.listenerInfos==null&&(ti.listenerInfos=[]),ti.listenerInfos.push({trigger:ni.trigger,listener:li,on:ai}),ai.addEventListener(ni.trigger,li)})}var vt=!1,dt=null;function gt(){dt||(dt=function(){vt=!0},window.addEventListener("scroll",dt),setInterval(function(){vt&&(vt=!1,oe(re().querySelectorAll("[hx-trigger='revealed'],[data-hx-trigger='revealed']"),function(ii){pt(ii)}))},200))}function pt(ii){if(!o(ii,"data-hx-revealed")&&X(ii)){ii.setAttribute("data-hx-revealed","true");var ei=ae(ii);ei.initHash?ce(ii,"revealed"):ii.addEventListener("htmx:afterProcessNode",function(ti){ce(ii,"revealed")},{once:!0})}}function mt(ii,ei,ti){for(var ni=D(ti),ri=0;ri=0){var si=wt(ti);setTimeout(function(){xt(ii,ei,ti+1)},si)}},ri.onopen=function(oi){ti=0},ae(ii).webSocket=ri,ri.addEventListener("message",function(oi){if(!yt(ii)){var si=oi.data;R(ii,function(pi){si=pi.transformResponse(si,null,ii)});for(var ai=T(ii),li=l(si),ui=M(li.children),ci=0;ci0){ce(ii,"htmx:validation:halted",si);return}ni.send(JSON.stringify(ci)),ut(ti,ii)&&ti.preventDefault()}):fe(ii,"htmx:noWebSocketSourceError")}function wt(ii){var ei=Q.config.wsReconnectDelay;if(typeof ei=="function")return ei(ii);if(ei==="full-jitter"){var ti=Math.min(ii,6),ni=1e3*Math.pow(2,ti);return ni*Math.random()}b('htmx.config.wsReconnectDelay must either be a function or the string "full-jitter"')}function St(ii,ei,ti){for(var ni=D(ti),ri=0;ri0?setTimeout(ri,ni):ri()}function Ht(ii,ei,ti){var ni=!1;return oe(w,function(ri){if(o(ii,"hx-"+ri)){var oi=te(ii,"hx-"+ri);ni=!0,ei.path=oi,ei.verb=ri,ti.forEach(function(si){Lt(ii,si,ei,function(ai,li){if(v(ai,Q.config.disableSelector)){m(ai);return}he(ri,oi,ai,li)})})}}),ni}function Lt(ii,ei,ti,ni){if(ei.sseEvent)Rt(ii,ni,ei.sseEvent);else if(ei.trigger==="revealed")gt(),ht(ii,ni,ti,ei),pt(ii);else if(ei.trigger==="intersect"){var ri={};ei.root&&(ri.root=ue(ii,ei.root)),ei.threshold&&(ri.threshold=parseFloat(ei.threshold));var oi=new IntersectionObserver(function(si){for(var ai=0;ai0?(ti.polling=!0,ot(ii,ni,ei)):ht(ii,ni,ti,ei)}function At(ii){if(!ii.htmxExecuted&&Q.config.allowScriptTags&&(ii.type==="text/javascript"||ii.type==="module"||ii.type==="")){var ei=re().createElement("script");oe(ii.attributes,function(ni){ei.setAttribute(ni.name,ni.value)}),ei.textContent=ii.textContent,ei.async=!1,Q.config.inlineScriptNonce&&(ei.nonce=Q.config.inlineScriptNonce);var ti=ii.parentElement;try{ti.insertBefore(ei,ii)}catch(ni){b(ni)}finally{ii.parentElement&&ii.parentElement.removeChild(ii)}}}function Nt(ii){h(ii,"script")&&At(ii),oe(f(ii,"script"),function(ei){At(ei)})}function It(ii){var ei=ii.attributes;if(!ei)return!1;for(var ti=0;ti0;){var si=ni.shift(),ai=si.match(/^\s*([a-zA-Z:\-\.]+:)(.*)/);oi===0&&ai?(si.split(":"),ri=ai[1].slice(0,-1),ti[ri]=ai[2]):ti[ri]+=si,oi+=Bt(si)}for(var li in ti)Ft(ii,li,ti[li])}}function jt(ii){Ae(ii);for(var ei=0;eiQ.config.historyCacheSize;)ri.shift();for(;ri.length>0;)try{localStorage.setItem("htmx-history-cache",JSON.stringify(ri));break}catch(ai){fe(re().body,"htmx:historyCacheError",{cause:ai,cache:ri}),ri.shift()}}}function Yt(ii){if(!U())return null;ii=B(ii);for(var ei=E(localStorage.getItem("htmx-history-cache"))||[],ti=0;ti=200&&this.status<400){ce(re().body,"htmx:historyCacheMissLoad",ti);var ni=l(this.response);ni=ni.querySelector("[hx-history-elt],[data-hx-history-elt]")||ni;var ri=Zt(),oi=T(ri),si=Ve(this.response);if(si){var ai=C("title");ai?ai.innerHTML=si:window.document.title=si}Ue(ri,ni,oi),nr(oi.tasks),Jt=ii,ce(re().body,"htmx:historyRestore",{path:ii,cacheMiss:!0,serverResponse:this.response})}else fe(re().body,"htmx:historyCacheMissLoadError",ti)},ei.send()}function ar(ii){er(),ii=ii||location.pathname+location.search;var ei=Yt(ii);if(ei){var ti=l(ei.content),ni=Zt(),ri=T(ni);Ue(ni,ti,ri),nr(ri.tasks),document.title=ei.title,setTimeout(function(){window.scrollTo(0,ei.scroll)},0),Jt=ii,ce(re().body,"htmx:historyRestore",{path:ii,item:ei})}else Q.config.refreshOnHistoryMiss?window.location.reload(!0):ir(ii)}function or(ii){var ei=me(ii,"hx-indicator");return ei==null&&(ei=[ii]),oe(ei,function(ti){var ni=ae(ti);ni.requestCount=(ni.requestCount||0)+1,ti.classList.add.call(ti.classList,Q.config.requestClass)}),ei}function sr(ii){var ei=me(ii,"hx-disabled-elt");return ei==null&&(ei=[]),oe(ei,function(ti){var ni=ae(ti);ni.requestCount=(ni.requestCount||0)+1,ti.setAttribute("disabled","")}),ei}function lr(ii,ei){oe(ii,function(ti){var ni=ae(ti);ni.requestCount=(ni.requestCount||0)-1,ni.requestCount===0&&ti.classList.remove.call(ti.classList,Q.config.requestClass)}),oe(ei,function(ti){var ni=ae(ti);ni.requestCount=(ni.requestCount||0)-1,ni.requestCount===0&&ti.removeAttribute("disabled")})}function ur(ii,ei){for(var ti=0;ti=0}function wr(ii,ei){var ti=ei||ne(ii,"hx-swap"),ni={swapStyle:ae(ii).boosted?"innerHTML":Q.config.defaultSwapStyle,swapDelay:Q.config.defaultSwapDelay,settleDelay:Q.config.defaultSettleDelay};if(Q.config.scrollIntoViewOnBoost&&ae(ii).boosted&&!br(ii)&&(ni.show="top"),ti){var ri=D(ti);if(ri.length>0)for(var oi=0;oi0?li.join(":"):null;ni.scroll=ui,ni.scrollTarget=ci}else if(si.indexOf("show:")===0){var di=si.substr(5),li=di.split(":"),pi=li.pop(),ci=li.length>0?li.join(":"):null;ni.show=pi,ni.showTarget=ci}else if(si.indexOf("focus-scroll:")===0){var yi=si.substr(13);ni.focusScroll=yi=="true"}else oi==0?ni.swapStyle=si:b("Unknown modifier in hx-swap: "+si)}}return ni}function Sr(ii){return ne(ii,"hx-encoding")==="multipart/form-data"||h(ii,"form")&&ee(ii,"enctype")==="multipart/form-data"}function Er(ii,ei,ti){var ni=null;return R(ei,function(ri){ni==null&&(ni=ri.encodeParameters(ii,ti,ei))}),ni!=null?ni:Sr(ei)?mr(ti):pr(ti)}function T(ii){return{tasks:[],elts:[ii]}}function Cr(ii,ei){var ti=ii[0],ni=ii[ii.length-1];if(ei.scroll){var ri=null;ei.scrollTarget&&(ri=ue(ti,ei.scrollTarget)),ei.scroll==="top"&&(ti||ri)&&(ri=ri||ti,ri.scrollTop=0),ei.scroll==="bottom"&&(ni||ri)&&(ri=ri||ni,ri.scrollTop=ri.scrollHeight)}if(ei.show){var ri=null;if(ei.showTarget){var oi=ei.showTarget;ei.showTarget==="window"&&(oi="body"),ri=ue(ti,oi)}ei.show==="top"&&(ti||ri)&&(ri=ri||ti,ri.scrollIntoView({block:"start",behavior:Q.config.scrollBehavior})),ei.show==="bottom"&&(ni||ri)&&(ri=ri||ni,ri.scrollIntoView({block:"end",behavior:Q.config.scrollBehavior}))}}function Rr(ii,ei,ti,ni){if(ni==null&&(ni={}),ii==null)return ni;var ri=te(ii,ei);if(ri){var oi=ri.trim(),si=ti;if(oi==="unset")return null;oi.indexOf("javascript:")===0?(oi=oi.substr(11),si=!0):oi.indexOf("js:")===0&&(oi=oi.substr(3),si=!0),oi.indexOf("{")!==0&&(oi="{"+oi+"}");var ai;si?ai=Tr(ii,function(){return Function("return ("+oi+")")()},{}):ai=E(oi);for(var li in ai)ai.hasOwnProperty(li)&&ni[li]==null&&(ni[li]=ai[li])}return Rr(u(ii),ei,ti,ni)}function Tr(ii,ei,ti){return Q.config.allowEval?ei():(fe(ii,"htmx:evalDisallowedError"),ti)}function Or(ii,ei){return Rr(ii,"hx-vars",!0,ei)}function qr(ii,ei){return Rr(ii,"hx-vals",!1,ei)}function Hr(ii){return le(Or(ii),qr(ii))}function Lr(ii,ei,ti){if(ti!==null)try{ii.setRequestHeader(ei,ti)}catch(ni){ii.setRequestHeader(ei,encodeURIComponent(ti)),ii.setRequestHeader(ei+"-URI-AutoEncoded","true")}}function Ar(ii){if(ii.responseURL&&typeof URL!="undefined")try{var ei=new URL(ii.responseURL);return ei.pathname+ei.search}catch(ti){fe(re().body,"htmx:badResponseUrl",{url:ii.responseURL})}}function O(ii,ei){return ei.test(ii.getAllResponseHeaders())}function Nr(ii,ei,ti){return ii=ii.toLowerCase(),ti?ti instanceof Element||I(ti,"String")?he(ii,ei,null,null,{targetOverride:p(ti),returnPromise:!0}):he(ii,ei,p(ti.source),ti.event,{handler:ti.handler,headers:ti.headers,values:ti.values,targetOverride:p(ti.target),swapOverride:ti.swap,select:ti.select,returnPromise:!0}):he(ii,ei,null,null,{returnPromise:!0})}function Ir(ii){for(var ei=[];ii;)ei.push(ii),ii=ii.parentElement;return ei}function kr(ii,ei,ti){var ni,ri;if(typeof URL=="function"){ri=new URL(ei,document.location.href);var oi=document.location.origin;ni=oi===ri.origin}else ri=ei,ni=g(ei,document.location.origin);return Q.config.selfRequestsOnly&&!ni?!1:ce(ii,"htmx:validateUrl",le({url:ri,sameHost:ni},ti))}function he(ii,ei,ti,ni,ri,oi){var si=null,ai=null;if(ri=ri!=null?ri:{},ri.returnPromise&&typeof Promise!="undefined")var li=new Promise(function(On,zn){si=On,ai=zn});ti==null&&(ti=re().body);var ui=ri.handler||Mr,ci=ri.select||null;if(!se(ti))return ie(si),li;var di=ri.targetOverride||ye(ti);if(di==null||di==pe)return fe(ti,"htmx:targetError",{target:te(ti,"hx-target")}),ie(ai),li;var pi=ae(ti),yi=pi.lastButtonClicked;if(yi){var gi=ee(yi,"formaction");gi!=null&&(ei=gi);var vi=ee(yi,"formmethod");vi!=null&&vi.toLowerCase()!=="dialog"&&(ii=vi)}var Ei=ne(ti,"hx-confirm");if(oi===void 0){var Ci=function(On){return he(ii,ei,ti,ni,ri,!!On)},xi={target:di,elt:ti,path:ei,verb:ii,triggeringEvent:ni,etc:ri,issueRequest:Ci,question:Ei};if(ce(ti,"htmx:confirm",xi)===!1)return ie(si),li}var Li=ti,Oi=ne(ti,"hx-sync"),zi=null,Vi=!1;if(Oi){var ki=Oi.split(":"),Mi=ki[0].trim();if(Mi==="this"?Li=xe(ti,"hx-sync"):Li=ue(ti,Mi),Oi=(ki[1]||"drop").trim(),pi=ae(Li),Oi==="drop"&&pi.xhr&&pi.abortable!==!0)return ie(si),li;if(Oi==="abort"){if(pi.xhr)return ie(si),li;Vi=!0}else if(Oi==="replace")ce(Li,"htmx:abort");else if(Oi.indexOf("queue")===0){var Ai=Oi.split(" ");zi=(Ai[1]||"last").trim()}}if(pi.xhr)if(pi.abortable)ce(Li,"htmx:abort");else{if(zi==null){if(ni){var qi=ae(ni);qi&&qi.triggerSpec&&qi.triggerSpec.queue&&(zi=qi.triggerSpec.queue)}zi==null&&(zi="last")}return pi.queuedRequests==null&&(pi.queuedRequests=[]),zi==="first"&&pi.queuedRequests.length===0?pi.queuedRequests.push(function(){he(ii,ei,ti,ni,ri)}):zi==="all"?pi.queuedRequests.push(function(){he(ii,ei,ti,ni,ri)}):zi==="last"&&(pi.queuedRequests=[],pi.queuedRequests.push(function(){he(ii,ei,ti,ni,ri)})),ie(si),li}var Si=new XMLHttpRequest;pi.xhr=Si,pi.abortable=Vi;var Qi=function(){if(pi.xhr=null,pi.abortable=!1,pi.queuedRequests!=null&&pi.queuedRequests.length>0){var On=pi.queuedRequests.shift();On()}},Ji=ne(ti,"hx-prompt");if(Ji){var gn=prompt(Ji);if(gn===null||!ce(ti,"htmx:prompt",{prompt:gn,target:di}))return ie(si),Qi(),li}if(Ei&&!oi&&!confirm(Ei))return ie(si),Qi(),li;var rn=xr(ti,di,gn);ii!=="get"&&!Sr(ti)&&(rn["Content-Type"]="application/x-www-form-urlencoded"),ri.headers&&(rn=le(rn,ri.headers));var Zi=dr(ti,ii),on=Zi.errors,Mn=Zi.values;ri.values&&(Mn=le(Mn,ri.values));var vn=Hr(ti),Yi=le(Mn,vn),Ri=yr(Yi,ti);Q.config.getCacheBusterParam&&ii==="get"&&(Ri["org.htmx.cache-buster"]=ee(di,"id")||"true"),(ei==null||ei==="")&&(ei=re().location.href);var Ii=Rr(ti,"hx-request"),Ui=ae(ti).boosted,ji=Q.config.methodsThatUseUrlParams.indexOf(ii)>=0,Pi={boosted:Ui,useUrlParams:ji,parameters:Ri,unfilteredParameters:Yi,headers:rn,target:di,verb:ii,errors:on,withCredentials:ri.credentials||Ii.credentials||Q.config.withCredentials,timeout:ri.timeout||Ii.timeout||Q.config.timeout,path:ei,triggeringEvent:ni};if(!ce(ti,"htmx:configRequest",Pi))return ie(si),Qi(),li;if(ei=Pi.path,ii=Pi.verb,rn=Pi.headers,Ri=Pi.parameters,on=Pi.errors,ji=Pi.useUrlParams,on&&on.length>0)return ce(ti,"htmx:validation:halted",Pi),ie(si),Qi(),li;var ln=ei.split("#"),kn=ln[0],yn=ln[1],Cn=ei;if(ji){Cn=kn;var $s=Object.keys(Ri).length!==0;$s&&(Cn.indexOf("?")<0?Cn+="?":Cn+="&",Cn+=pr(Ri),yn&&(Cn+="#"+yn))}if(!kr(ti,Cn,Pi))return fe(ti,"htmx:invalidPath",Pi),ie(ai),li;if(Si.open(ii.toUpperCase(),Cn,!0),Si.overrideMimeType("text/html"),Si.withCredentials=Pi.withCredentials,Si.timeout=Pi.timeout,!Ii.noHeaders){for(var ro in rn)if(rn.hasOwnProperty(ro)){var wo=rn[ro];Lr(Si,ro,wo)}}var bn={xhr:Si,target:di,requestConfig:Pi,etc:ri,boosted:Ui,select:ci,pathInfo:{requestPath:ei,finalRequestPath:Cn,anchor:yn}};if(Si.onload=function(){try{var On=Ir(ti);if(bn.pathInfo.responsePath=Ar(Si),ui(ti,bn),lr(xo,ao),ce(ti,"htmx:afterRequest",bn),ce(ti,"htmx:afterOnLoad",bn),!se(ti)){for(var zn=null;On.length>0&&zn==null;){var Gn=On.shift();se(Gn)&&(zn=Gn)}zn&&(ce(zn,"htmx:afterRequest",bn),ce(zn,"htmx:afterOnLoad",bn))}ie(si),Qi()}catch(Jn){throw fe(ti,"htmx:onLoadError",le({error:Jn},bn)),Jn}},Si.onerror=function(){lr(xo,ao),fe(ti,"htmx:afterRequest",bn),fe(ti,"htmx:sendError",bn),ie(ai),Qi()},Si.onabort=function(){lr(xo,ao),fe(ti,"htmx:afterRequest",bn),fe(ti,"htmx:sendAbort",bn),ie(ai),Qi()},Si.ontimeout=function(){lr(xo,ao),fe(ti,"htmx:afterRequest",bn),fe(ti,"htmx:timeout",bn),ie(ai),Qi()},!ce(ti,"htmx:beforeRequest",bn))return ie(si),Qi(),li;var xo=or(ti),ao=sr(ti);oe(["loadstart","loadend","progress","abort"],function(On){oe([Si,Si.upload],function(zn){zn.addEventListener(On,function(Gn){ce(ti,"htmx:xhr:"+On,{lengthComputable:Gn.lengthComputable,loaded:Gn.loaded,total:Gn.total})})})}),ce(ti,"htmx:beforeSend",bn);var ls=ji?null:Er(Si,ti,Ri);return Si.send(ls),li}function Pr(ii,ei){var ti=ei.xhr,ni=null,ri=null;if(O(ti,/HX-Push:/i)?(ni=ti.getResponseHeader("HX-Push"),ri="push"):O(ti,/HX-Push-Url:/i)?(ni=ti.getResponseHeader("HX-Push-Url"),ri="push"):O(ti,/HX-Replace-Url:/i)&&(ni=ti.getResponseHeader("HX-Replace-Url"),ri="replace"),ni)return ni==="false"?{}:{type:ri,path:ni};var oi=ei.pathInfo.finalRequestPath,si=ei.pathInfo.responsePath,ai=ne(ii,"hx-push-url"),li=ne(ii,"hx-replace-url"),ui=ae(ii).boosted,ci=null,di=null;return ai?(ci="push",di=ai):li?(ci="replace",di=li):ui&&(ci="push",di=si||oi),di?di==="false"?{}:(di==="true"&&(di=si||oi),ei.pathInfo.anchor&&di.indexOf("#")===-1&&(di=di+"#"+ei.pathInfo.anchor),{type:ci,path:di}):{}}function Mr(ii,ei){var ti=ei.xhr,ni=ei.target,ri=ei.etc,oi=ei.requestConfig,si=ei.select;if(ce(ii,"htmx:beforeOnLoad",ei)){if(O(ti,/HX-Trigger:/i)&&_e(ti,"HX-Trigger",ii),O(ti,/HX-Location:/i)){er();var ai=ti.getResponseHeader("HX-Location"),li;ai.indexOf("{")===0&&(li=E(ai),ai=li.path,delete li.path),Nr("GET",ai,li).then(function(){tr(ai)});return}var ui=O(ti,/HX-Refresh:/i)&&ti.getResponseHeader("HX-Refresh")==="true";if(O(ti,/HX-Redirect:/i)){location.href=ti.getResponseHeader("HX-Redirect"),ui&&location.reload();return}if(ui){location.reload();return}O(ti,/HX-Retarget:/i)&&(ti.getResponseHeader("HX-Retarget")==="this"?ei.target=ii:ei.target=ue(ii,ti.getResponseHeader("HX-Retarget")));var ci=Pr(ii,ei),di=ti.status>=200&&ti.status<400&&ti.status!==204,pi=ti.response,yi=ti.status>=400,gi=Q.config.ignoreTitle,vi=le({shouldSwap:di,serverResponse:pi,isError:yi,ignoreTitle:gi},ei);if(ce(ni,"htmx:beforeSwap",vi)){if(ni=vi.target,pi=vi.serverResponse,yi=vi.isError,gi=vi.ignoreTitle,ei.target=ni,ei.failed=yi,ei.successful=!yi,vi.shouldSwap){ti.status===286&&at(ii),R(ii,function(Mi){pi=Mi.transformResponse(pi,ti,ii)}),ci.type&&er();var Ei=ri.swapOverride;O(ti,/HX-Reswap:/i)&&(Ei=ti.getResponseHeader("HX-Reswap"));var li=wr(ii,Ei);li.hasOwnProperty("ignoreTitle")&&(gi=li.ignoreTitle),ni.classList.add(Q.config.swappingClass);var Ci=null,xi=null,Li=function(){try{var Mi=document.activeElement,Ai={};try{Ai={elt:Mi,start:Mi?Mi.selectionStart:null,end:Mi?Mi.selectionEnd:null}}catch(Zi){}var qi;si&&(qi=si),O(ti,/HX-Reselect:/i)&&(qi=ti.getResponseHeader("HX-Reselect")),ci.type&&(ce(re().body,"htmx:beforeHistoryUpdate",le({history:ci},ei)),ci.type==="push"?(tr(ci.path),ce(re().body,"htmx:pushedIntoHistory",{path:ci.path})):(rr(ci.path),ce(re().body,"htmx:replacedInHistory",{path:ci.path})));var Si=T(ni);if(je(li.swapStyle,ni,ii,pi,Si,qi),Ai.elt&&!se(Ai.elt)&&ee(Ai.elt,"id")){var Qi=document.getElementById(ee(Ai.elt,"id")),Ji={preventScroll:li.focusScroll!==void 0?!li.focusScroll:!Q.config.defaultFocusScroll};if(Qi){if(Ai.start&&Qi.setSelectionRange)try{Qi.setSelectionRange(Ai.start,Ai.end)}catch(Zi){}Qi.focus(Ji)}}if(ni.classList.remove(Q.config.swappingClass),oe(Si.elts,function(Zi){Zi.classList&&Zi.classList.add(Q.config.settlingClass),ce(Zi,"htmx:afterSwap",ei)}),O(ti,/HX-Trigger-After-Swap:/i)){var gn=ii;se(ii)||(gn=re().body),_e(ti,"HX-Trigger-After-Swap",gn)}var rn=function(){if(oe(Si.tasks,function(vn){vn.call()}),oe(Si.elts,function(vn){vn.classList&&vn.classList.remove(Q.config.settlingClass),ce(vn,"htmx:afterSettle",ei)}),ei.pathInfo.anchor){var Zi=re().getElementById(ei.pathInfo.anchor);Zi&&Zi.scrollIntoView({block:"start",behavior:"auto"})}if(Si.title&&!gi){var on=C("title");on?on.innerHTML=Si.title:window.document.title=Si.title}if(Cr(Si.elts,li),O(ti,/HX-Trigger-After-Settle:/i)){var Mn=ii;se(ii)||(Mn=re().body),_e(ti,"HX-Trigger-After-Settle",Mn)}ie(Ci)};li.settleDelay>0?setTimeout(rn,li.settleDelay):rn()}catch(Zi){throw fe(ii,"htmx:swapError",ei),ie(xi),Zi}},Oi=Q.config.globalViewTransitions;if(li.hasOwnProperty("transition")&&(Oi=li.transition),Oi&&ce(ii,"htmx:beforeTransition",ei)&&typeof Promise!="undefined"&&document.startViewTransition){var zi=new Promise(function(Mi,Ai){Ci=Mi,xi=Ai}),Vi=Li;Li=function(){document.startViewTransition(function(){return Vi(),zi})}}li.swapDelay>0?setTimeout(Li,li.swapDelay):Li()}yi&&fe(ii,"htmx:responseError",le({error:"Response Status Error Code "+ti.status+" from "+ei.pathInfo.requestPath},ei))}}}var Xr={};function Dr(){return{init:function(ii){return null},onEvent:function(ii,ei){return!0},transformResponse:function(ii,ei,ti){return ii},isInlineSwap:function(ii){return!1},handleSwap:function(ii,ei,ti,ni){return!1},encodeParameters:function(ii,ei,ti){return null}}}function Ur(ii,ei){ei.init&&ei.init(r),Xr[ii]=le(Dr(),ei)}function Br(ii){delete Xr[ii]}function Fr(ii,ei,ti){if(ii==null)return ei;ei==null&&(ei=[]),ti==null&&(ti=[]);var ni=te(ii,"hx-ext");return ni&&oe(ni.split(","),function(ri){if(ri=ri.replace(/ /g,""),ri.slice(0,7)=="ignore:"){ti.push(ri.slice(7));return}if(ti.indexOf(ri)<0){var oi=Xr[ri];oi&&ei.indexOf(oi)<0&&ei.push(oi)}}),Fr(u(ii),ei,ti)}var Vr=!1;re().addEventListener("DOMContentLoaded",function(){Vr=!0});function jr(ii){Vr||re().readyState==="complete"?ii():re().addEventListener("DOMContentLoaded",ii)}function _r(){Q.config.includeIndicatorStyles!==!1&&re().head.insertAdjacentHTML("beforeend","")}function zr(){var ii=re().querySelector('meta[name="htmx-config"]');return ii?E(ii.content):null}function $r(){var ii=zr();ii&&(Q.config=le(Q.config,ii))}return jr(function(){$r(),_r();var ii=re().body;zt(ii);var ei=re().querySelectorAll("[hx-trigger='restored'],[data-hx-trigger='restored']");ii.addEventListener("htmx:abort",function(ni){var ri=ni.target,oi=ae(ri);oi&&oi.xhr&&oi.xhr.abort()});let ti=window.onpopstate?window.onpopstate.bind(window):null;window.onpopstate=function(ni){ni.state&&ni.state.htmx?(ar(),oe(ei,function(ri){ce(ri,"htmx:restored",{document:re(),triggerEvent:ce})})):ti&&ti(ni)},setTimeout(function(){ce(ii,"htmx:load",{}),ii=null},0)}),Q}()})});var fh=au((va,Uc)=>{(function(ei,ti){typeof va=="object"&&typeof Uc=="object"?Uc.exports=ti():typeof define=="function"&&define.amd?define([],ti):typeof va=="object"?va.ClipboardJS=ti():ei.ClipboardJS=ti()})(va,function(){return function(){var ii={686:function(ni,ri,oi){"use strict";oi.d(ri,{default:function(){return vn}});var si=oi(279),ai=oi.n(si),li=oi(370),ui=oi.n(li),ci=oi(817),di=oi.n(ci);function pi(Yi){try{return document.execCommand(Yi)}catch(Ri){return!1}}var yi=function(Ri){var Ii=di()(Ri);return pi("cut"),Ii},gi=yi;function vi(Yi){var Ri=document.documentElement.getAttribute("dir")==="rtl",Ii=document.createElement("textarea");Ii.style.fontSize="12pt",Ii.style.border="0",Ii.style.padding="0",Ii.style.margin="0",Ii.style.position="absolute",Ii.style[Ri?"right":"left"]="-9999px";var Ui=window.pageYOffset||document.documentElement.scrollTop;return Ii.style.top="".concat(Ui,"px"),Ii.setAttribute("readonly",""),Ii.value=Yi,Ii}var Ei=function(Ri,Ii){var Ui=vi(Ri);Ii.container.appendChild(Ui);var ji=di()(Ui);return pi("copy"),Ui.remove(),ji},Ci=function(Ri){var Ii=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body},Ui="";return typeof Ri=="string"?Ui=Ei(Ri,Ii):Ri instanceof HTMLInputElement&&!["text","search","url","tel","password"].includes(Ri==null?void 0:Ri.type)?Ui=Ei(Ri.value,Ii):(Ui=di()(Ri),pi("copy")),Ui},xi=Ci;function Li(Yi){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Li=function(Ii){return typeof Ii}:Li=function(Ii){return Ii&&typeof Symbol=="function"&&Ii.constructor===Symbol&&Ii!==Symbol.prototype?"symbol":typeof Ii},Li(Yi)}var Oi=function(){var Ri=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},Ii=Ri.action,Ui=Ii===void 0?"copy":Ii,ji=Ri.container,Pi=Ri.target,ln=Ri.text;if(Ui!=="copy"&&Ui!=="cut")throw new Error('Invalid "action" value, use either "copy" or "cut"');if(Pi!==void 0)if(Pi&&Li(Pi)==="object"&&Pi.nodeType===1){if(Ui==="copy"&&Pi.hasAttribute("disabled"))throw new Error('Invalid "target" attribute. Please use "readonly" instead of "disabled" attribute');if(Ui==="cut"&&(Pi.hasAttribute("readonly")||Pi.hasAttribute("disabled")))throw new Error(`Invalid "target" attribute. You can't cut text from elements with "readonly" or "disabled" attributes`)}else throw new Error('Invalid "target" value, use a valid Element');if(ln)return xi(ln,{container:ji});if(Pi)return Ui==="cut"?gi(Pi):xi(Pi,{container:ji})},zi=Oi;function Vi(Yi){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Vi=function(Ii){return typeof Ii}:Vi=function(Ii){return Ii&&typeof Symbol=="function"&&Ii.constructor===Symbol&&Ii!==Symbol.prototype?"symbol":typeof Ii},Vi(Yi)}function ki(Yi,Ri){if(!(Yi instanceof Ri))throw new TypeError("Cannot call a class as a function")}function Mi(Yi,Ri){for(var Ii=0;Ii0&&arguments[0]!==void 0?arguments[0]:{};this.action=typeof ji.action=="function"?ji.action:this.defaultAction,this.target=typeof ji.target=="function"?ji.target:this.defaultTarget,this.text=typeof ji.text=="function"?ji.text:this.defaultText,this.container=Vi(ji.container)==="object"?ji.container:document.body}},{key:"listenClick",value:function(ji){var Pi=this;this.listener=ui()(ji,"click",function(ln){return Pi.onClick(ln)})}},{key:"onClick",value:function(ji){var Pi=ji.delegateTarget||ji.currentTarget,ln=this.action(Pi)||"copy",kn=zi({action:ln,container:this.container,target:this.target(Pi),text:this.text(Pi)});this.emit(kn?"success":"error",{action:ln,text:kn,trigger:Pi,clearSelection:function(){Pi&&Pi.focus(),window.getSelection().removeAllRanges()}})}},{key:"defaultAction",value:function(ji){return on("action",ji)}},{key:"defaultTarget",value:function(ji){var Pi=on("target",ji);if(Pi)return document.querySelector(Pi)}},{key:"defaultText",value:function(ji){return on("text",ji)}},{key:"destroy",value:function(){this.listener.destroy()}}],[{key:"copy",value:function(ji){var Pi=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{container:document.body};return xi(ji,Pi)}},{key:"cut",value:function(ji){return gi(ji)}},{key:"isSupported",value:function(){var ji=arguments.length>0&&arguments[0]!==void 0?arguments[0]:["copy","cut"],Pi=typeof ji=="string"?[ji]:ji,ln=!!document.queryCommandSupported;return Pi.forEach(function(kn){ln=ln&&!!document.queryCommandSupported(kn)}),ln}}]),Ii}(ai()),vn=Mn},828:function(ni){var ri=9;if(typeof Element!="undefined"&&!Element.prototype.matches){var oi=Element.prototype;oi.matches=oi.matchesSelector||oi.mozMatchesSelector||oi.msMatchesSelector||oi.oMatchesSelector||oi.webkitMatchesSelector}function si(ai,li){for(;ai&&ai.nodeType!==ri;){if(typeof ai.matches=="function"&&ai.matches(li))return ai;ai=ai.parentNode}}ni.exports=si},438:function(ni,ri,oi){var si=oi(828);function ai(ci,di,pi,yi,gi){var vi=ui.apply(this,arguments);return ci.addEventListener(pi,vi,gi),{destroy:function(){ci.removeEventListener(pi,vi,gi)}}}function li(ci,di,pi,yi,gi){return typeof ci.addEventListener=="function"?ai.apply(null,arguments):typeof pi=="function"?ai.bind(null,document).apply(null,arguments):(typeof ci=="string"&&(ci=document.querySelectorAll(ci)),Array.prototype.map.call(ci,function(vi){return ai(vi,di,pi,yi,gi)}))}function ui(ci,di,pi,yi){return function(gi){gi.delegateTarget=si(gi.target,di),gi.delegateTarget&&yi.call(ci,gi)}}ni.exports=li},879:function(ni,ri){ri.node=function(oi){return oi!==void 0&&oi instanceof HTMLElement&&oi.nodeType===1},ri.nodeList=function(oi){var si=Object.prototype.toString.call(oi);return oi!==void 0&&(si==="[object NodeList]"||si==="[object HTMLCollection]")&&"length"in oi&&(oi.length===0||ri.node(oi[0]))},ri.string=function(oi){return typeof oi=="string"||oi instanceof String},ri.fn=function(oi){var si=Object.prototype.toString.call(oi);return si==="[object Function]"}},370:function(ni,ri,oi){var si=oi(879),ai=oi(438);function li(pi,yi,gi){if(!pi&&!yi&&!gi)throw new Error("Missing required arguments");if(!si.string(yi))throw new TypeError("Second argument must be a String");if(!si.fn(gi))throw new TypeError("Third argument must be a Function");if(si.node(pi))return ui(pi,yi,gi);if(si.nodeList(pi))return ci(pi,yi,gi);if(si.string(pi))return di(pi,yi,gi);throw new TypeError("First argument must be a String, HTMLElement, HTMLCollection, or NodeList")}function ui(pi,yi,gi){return pi.addEventListener(yi,gi),{destroy:function(){pi.removeEventListener(yi,gi)}}}function ci(pi,yi,gi){return Array.prototype.forEach.call(pi,function(vi){vi.addEventListener(yi,gi)}),{destroy:function(){Array.prototype.forEach.call(pi,function(vi){vi.removeEventListener(yi,gi)})}}}function di(pi,yi,gi){return ai(document.body,pi,yi,gi)}ni.exports=li},817:function(ni){function ri(oi){var si;if(oi.nodeName==="SELECT")oi.focus(),si=oi.value;else if(oi.nodeName==="INPUT"||oi.nodeName==="TEXTAREA"){var ai=oi.hasAttribute("readonly");ai||oi.setAttribute("readonly",""),oi.select(),oi.setSelectionRange(0,oi.value.length),ai||oi.removeAttribute("readonly"),si=oi.value}else{oi.hasAttribute("contenteditable")&&oi.focus();var li=window.getSelection(),ui=document.createRange();ui.selectNodeContents(oi),li.removeAllRanges(),li.addRange(ui),si=li.toString()}return si}ni.exports=ri},279:function(ni){function ri(){}ri.prototype={on:function(oi,si,ai){var li=this.e||(this.e={});return(li[oi]||(li[oi]=[])).push({fn:si,ctx:ai}),this},once:function(oi,si,ai){var li=this;function ui(){li.off(oi,ui),si.apply(ai,arguments)}return ui._=si,this.on(oi,ui,ai)},emit:function(oi){var si=[].slice.call(arguments,1),ai=((this.e||(this.e={}))[oi]||[]).slice(),li=0,ui=ai.length;for(li;limu,afterRead:()=>fu,afterWrite:()=>yu,applyStyles:()=>ps,arrow:()=>Oa,auto:()=>js,basePlacements:()=>uo,beforeMain:()=>hu,beforeRead:()=>uu,beforeWrite:()=>gu,bottom:()=>_n,clippingParents:()=>$l,computeStyles:()=>gs,createPopper:()=>Js,createPopperBase:()=>Au,createPopperLite:()=>Du,detectOverflow:()=>Fn,end:()=>To,eventListeners:()=>vs,flip:()=>Na,hide:()=>Ra,left:()=>hn,main:()=>pu,modifierPhases:()=>zl,offset:()=>Ia,placements:()=>Ws,popper:()=>jo,popperGenerator:()=>Xo,popperOffsets:()=>_s,preventOverflow:()=>Ha,read:()=>du,reference:()=>Bl,right:()=>mn,start:()=>so,top:()=>dn,variationPlacements:()=>Da,viewport:()=>qs,write:()=>vu});var dn="top",_n="bottom",mn="right",hn="left",js="auto",uo=[dn,_n,mn,hn],so="start",To="end",$l="clippingParents",qs="viewport",jo="popper",Bl="reference",Da=uo.reduce(function(ii,ei){return ii.concat([ei+"-"+so,ei+"-"+To])},[]),Ws=[].concat(uo,[js]).reduce(function(ii,ei){return ii.concat([ei,ei+"-"+so,ei+"-"+To])},[]),uu="beforeRead",du="read",fu="afterRead",hu="beforeMain",pu="main",mu="afterMain",gu="beforeWrite",vu="write",yu="afterWrite",zl=[uu,du,fu,hu,pu,mu,gu,vu,yu];function An(ii){return ii?(ii.nodeName||"").toLowerCase():null}function cn(ii){if(ii==null)return window;if(ii.toString()!=="[object Window]"){var ei=ii.ownerDocument;return ei&&ei.defaultView||window}return ii}function Zn(ii){var ei=cn(ii).Element;return ii instanceof ei||ii instanceof Element}function Tn(ii){var ei=cn(ii).HTMLElement;return ii instanceof ei||ii instanceof HTMLElement}function hs(ii){if(typeof ShadowRoot=="undefined")return!1;var ei=cn(ii).ShadowRoot;return ii instanceof ei||ii instanceof ShadowRoot}function op(ii){var ei=ii.state;Object.keys(ei.elements).forEach(function(ti){var ni=ei.styles[ti]||{},ri=ei.attributes[ti]||{},oi=ei.elements[ti];!Tn(oi)||!An(oi)||(Object.assign(oi.style,ni),Object.keys(ri).forEach(function(si){var ai=ri[si];ai===!1?oi.removeAttribute(si):oi.setAttribute(si,ai===!0?"":ai)}))})}function sp(ii){var ei=ii.state,ti={popper:{position:ei.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(ei.elements.popper.style,ti.popper),ei.styles=ti,ei.elements.arrow&&Object.assign(ei.elements.arrow.style,ti.arrow),function(){Object.keys(ei.elements).forEach(function(ni){var ri=ei.elements[ni],oi=ei.attributes[ni]||{},si=Object.keys(ei.styles.hasOwnProperty(ni)?ei.styles[ni]:ti[ni]),ai=si.reduce(function(li,ui){return li[ui]="",li},{});!Tn(ri)||!An(ri)||(Object.assign(ri.style,ai),Object.keys(oi).forEach(function(li){ri.removeAttribute(li)}))})}}var ps={name:"applyStyles",enabled:!0,phase:"write",fn:op,effect:sp,requires:["computeStyles"]};function Dn(ii){return ii.split("-")[0]}var eo=Math.max,qo=Math.min,fo=Math.round;function ms(){var ii=navigator.userAgentData;return ii!=null&&ii.brands&&Array.isArray(ii.brands)?ii.brands.map(function(ei){return ei.brand+"/"+ei.version}).join(" "):navigator.userAgent}function Us(){return!/^((?!chrome|android).)*safari/i.test(ms())}function Wr(ii,ei,ti){ei===void 0&&(ei=!1),ti===void 0&&(ti=!1);var ni=ii.getBoundingClientRect(),ri=1,oi=1;ei&&Tn(ii)&&(ri=ii.offsetWidth>0&&fo(ni.width)/ii.offsetWidth||1,oi=ii.offsetHeight>0&&fo(ni.height)/ii.offsetHeight||1);var si=Zn(ii)?cn(ii):window,ai=si.visualViewport,li=!Us()&&ti,ui=(ni.left+(li&&ai?ai.offsetLeft:0))/ri,ci=(ni.top+(li&&ai?ai.offsetTop:0))/oi,di=ni.width/ri,pi=ni.height/oi;return{width:di,height:pi,top:ci,right:ui+di,bottom:ci+pi,left:ui,x:ui,y:ci}}function Wo(ii){var ei=Wr(ii),ti=ii.offsetWidth,ni=ii.offsetHeight;return Math.abs(ei.width-ti)<=1&&(ti=ei.width),Math.abs(ei.height-ni)<=1&&(ni=ei.height),{x:ii.offsetLeft,y:ii.offsetTop,width:ti,height:ni}}function Ys(ii,ei){var ti=ei.getRootNode&&ei.getRootNode();if(ii.contains(ei))return!0;if(ti&&hs(ti)){var ni=ei;do{if(ni&&ii.isSameNode(ni))return!0;ni=ni.parentNode||ni.host}while(ni)}return!1}function Pn(ii){return cn(ii).getComputedStyle(ii)}function Vl(ii){return["table","td","th"].indexOf(An(ii))>=0}function Ln(ii){return((Zn(ii)?ii.ownerDocument:ii.document)||window.document).documentElement}function ho(ii){return An(ii)==="html"?ii:ii.assignedSlot||ii.parentNode||(hs(ii)?ii.host:null)||Ln(ii)}function bu(ii){return!Tn(ii)||Pn(ii).position==="fixed"?null:ii.offsetParent}function ap(ii){var ei=/firefox/i.test(ms()),ti=/Trident/i.test(ms());if(ti&&Tn(ii)){var ni=Pn(ii);if(ni.position==="fixed")return null}var ri=ho(ii);for(hs(ri)&&(ri=ri.host);Tn(ri)&&["html","body"].indexOf(An(ri))<0;){var oi=Pn(ri);if(oi.transform!=="none"||oi.perspective!=="none"||oi.contain==="paint"||["transform","perspective"].indexOf(oi.willChange)!==-1||ei&&oi.willChange==="filter"||ei&&oi.filter&&oi.filter!=="none")return ri;ri=ri.parentNode}return null}function to(ii){for(var ei=cn(ii),ti=bu(ii);ti&&Vl(ti)&&Pn(ti).position==="static";)ti=bu(ti);return ti&&(An(ti)==="html"||An(ti)==="body"&&Pn(ti).position==="static")?ei:ti||ap(ii)||ei}function Uo(ii){return["top","bottom"].indexOf(ii)>=0?"x":"y"}function Yo(ii,ei,ti){return eo(ii,qo(ei,ti))}function _u(ii,ei,ti){var ni=Yo(ii,ei,ti);return ni>ti?ti:ni}function Gs(){return{top:0,right:0,bottom:0,left:0}}function Ks(ii){return Object.assign({},Gs(),ii)}function Qs(ii,ei){return ei.reduce(function(ti,ni){return ti[ni]=ii,ti},{})}var lp=function(ei,ti){return ei=typeof ei=="function"?ei(Object.assign({},ti.rects,{placement:ti.placement})):ei,Ks(typeof ei!="number"?ei:Qs(ei,uo))};function cp(ii){var ei,ti=ii.state,ni=ii.name,ri=ii.options,oi=ti.elements.arrow,si=ti.modifiersData.popperOffsets,ai=Dn(ti.placement),li=Uo(ai),ui=[hn,mn].indexOf(ai)>=0,ci=ui?"height":"width";if(!(!oi||!si)){var di=lp(ri.padding,ti),pi=Wo(oi),yi=li==="y"?dn:hn,gi=li==="y"?_n:mn,vi=ti.rects.reference[ci]+ti.rects.reference[li]-si[li]-ti.rects.popper[ci],Ei=si[li]-ti.rects.reference[li],Ci=to(oi),xi=Ci?li==="y"?Ci.clientHeight||0:Ci.clientWidth||0:0,Li=vi/2-Ei/2,Oi=di[yi],zi=xi-pi[ci]-di[gi],Vi=xi/2-pi[ci]/2+Li,ki=Yo(Oi,Vi,zi),Mi=li;ti.modifiersData[ni]=(ei={},ei[Mi]=ki,ei.centerOffset=ki-Vi,ei)}}function up(ii){var ei=ii.state,ti=ii.options,ni=ti.element,ri=ni===void 0?"[data-popper-arrow]":ni;ri!=null&&(typeof ri=="string"&&(ri=ei.elements.popper.querySelector(ri),!ri)||Ys(ei.elements.popper,ri)&&(ei.elements.arrow=ri))}var Oa={name:"arrow",enabled:!0,phase:"main",fn:cp,effect:up,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Yr(ii){return ii.split("-")[1]}var dp={top:"auto",right:"auto",bottom:"auto",left:"auto"};function fp(ii,ei){var ti=ii.x,ni=ii.y,ri=ei.devicePixelRatio||1;return{x:fo(ti*ri)/ri||0,y:fo(ni*ri)/ri||0}}function Eu(ii){var ei,ti=ii.popper,ni=ii.popperRect,ri=ii.placement,oi=ii.variation,si=ii.offsets,ai=ii.position,li=ii.gpuAcceleration,ui=ii.adaptive,ci=ii.roundOffsets,di=ii.isFixed,pi=si.x,yi=pi===void 0?0:pi,gi=si.y,vi=gi===void 0?0:gi,Ei=typeof ci=="function"?ci({x:yi,y:vi}):{x:yi,y:vi};yi=Ei.x,vi=Ei.y;var Ci=si.hasOwnProperty("x"),xi=si.hasOwnProperty("y"),Li=hn,Oi=dn,zi=window;if(ui){var Vi=to(ti),ki="clientHeight",Mi="clientWidth";if(Vi===cn(ti)&&(Vi=Ln(ti),Pn(Vi).position!=="static"&&ai==="absolute"&&(ki="scrollHeight",Mi="scrollWidth")),Vi=Vi,ri===dn||(ri===hn||ri===mn)&&oi===To){Oi=_n;var Ai=di&&Vi===zi&&zi.visualViewport?zi.visualViewport.height:Vi[ki];vi-=Ai-ni.height,vi*=li?1:-1}if(ri===hn||(ri===dn||ri===_n)&&oi===To){Li=mn;var qi=di&&Vi===zi&&zi.visualViewport?zi.visualViewport.width:Vi[Mi];yi-=qi-ni.width,yi*=li?1:-1}}var Si=Object.assign({position:ai},ui&&dp),Qi=ci===!0?fp({x:yi,y:vi},cn(ti)):{x:yi,y:vi};if(yi=Qi.x,vi=Qi.y,li){var Ji;return Object.assign({},Si,(Ji={},Ji[Oi]=xi?"0":"",Ji[Li]=Ci?"0":"",Ji.transform=(zi.devicePixelRatio||1)<=1?"translate("+yi+"px, "+vi+"px)":"translate3d("+yi+"px, "+vi+"px, 0)",Ji))}return Object.assign({},Si,(ei={},ei[Oi]=xi?vi+"px":"",ei[Li]=Ci?yi+"px":"",ei.transform="",ei))}function hp(ii){var ei=ii.state,ti=ii.options,ni=ti.gpuAcceleration,ri=ni===void 0?!0:ni,oi=ti.adaptive,si=oi===void 0?!0:oi,ai=ti.roundOffsets,li=ai===void 0?!0:ai,ui={placement:Dn(ei.placement),variation:Yr(ei.placement),popper:ei.elements.popper,popperRect:ei.rects.popper,gpuAcceleration:ri,isFixed:ei.options.strategy==="fixed"};ei.modifiersData.popperOffsets!=null&&(ei.styles.popper=Object.assign({},ei.styles.popper,Eu(Object.assign({},ui,{offsets:ei.modifiersData.popperOffsets,position:ei.options.strategy,adaptive:si,roundOffsets:li})))),ei.modifiersData.arrow!=null&&(ei.styles.arrow=Object.assign({},ei.styles.arrow,Eu(Object.assign({},ui,{offsets:ei.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:li})))),ei.attributes.popper=Object.assign({},ei.attributes.popper,{"data-popper-placement":ei.placement})}var gs={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:hp,data:{}};var La={passive:!0};function pp(ii){var ei=ii.state,ti=ii.instance,ni=ii.options,ri=ni.scroll,oi=ri===void 0?!0:ri,si=ni.resize,ai=si===void 0?!0:si,li=cn(ei.elements.popper),ui=[].concat(ei.scrollParents.reference,ei.scrollParents.popper);return oi&&ui.forEach(function(ci){ci.addEventListener("scroll",ti.update,La)}),ai&&li.addEventListener("resize",ti.update,La),function(){oi&&ui.forEach(function(ci){ci.removeEventListener("scroll",ti.update,La)}),ai&&li.removeEventListener("resize",ti.update,La)}}var vs={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:pp,data:{}};var mp={left:"right",right:"left",bottom:"top",top:"bottom"};function ys(ii){return ii.replace(/left|right|bottom|top/g,function(ei){return mp[ei]})}var gp={start:"end",end:"start"};function Ma(ii){return ii.replace(/start|end/g,function(ei){return gp[ei]})}function Go(ii){var ei=cn(ii),ti=ei.pageXOffset,ni=ei.pageYOffset;return{scrollLeft:ti,scrollTop:ni}}function Ko(ii){return Wr(Ln(ii)).left+Go(ii).scrollLeft}function jl(ii,ei){var ti=cn(ii),ni=Ln(ii),ri=ti.visualViewport,oi=ni.clientWidth,si=ni.clientHeight,ai=0,li=0;if(ri){oi=ri.width,si=ri.height;var ui=Us();(ui||!ui&&ei==="fixed")&&(ai=ri.offsetLeft,li=ri.offsetTop)}return{width:oi,height:si,x:ai+Ko(ii),y:li}}function ql(ii){var ei,ti=Ln(ii),ni=Go(ii),ri=(ei=ii.ownerDocument)==null?void 0:ei.body,oi=eo(ti.scrollWidth,ti.clientWidth,ri?ri.scrollWidth:0,ri?ri.clientWidth:0),si=eo(ti.scrollHeight,ti.clientHeight,ri?ri.scrollHeight:0,ri?ri.clientHeight:0),ai=-ni.scrollLeft+Ko(ii),li=-ni.scrollTop;return Pn(ri||ti).direction==="rtl"&&(ai+=eo(ti.clientWidth,ri?ri.clientWidth:0)-oi),{width:oi,height:si,x:ai,y:li}}function Qo(ii){var ei=Pn(ii),ti=ei.overflow,ni=ei.overflowX,ri=ei.overflowY;return/auto|scroll|overlay|hidden/.test(ti+ri+ni)}function ka(ii){return["html","body","#document"].indexOf(An(ii))>=0?ii.ownerDocument.body:Tn(ii)&&Qo(ii)?ii:ka(ho(ii))}function So(ii,ei){var ti;ei===void 0&&(ei=[]);var ni=ka(ii),ri=ni===((ti=ii.ownerDocument)==null?void 0:ti.body),oi=cn(ni),si=ri?[oi].concat(oi.visualViewport||[],Qo(ni)?ni:[]):ni,ai=ei.concat(si);return ri?ai:ai.concat(So(ho(si)))}function bs(ii){return Object.assign({},ii,{left:ii.x,top:ii.y,right:ii.x+ii.width,bottom:ii.y+ii.height})}function vp(ii,ei){var ti=Wr(ii,!1,ei==="fixed");return ti.top=ti.top+ii.clientTop,ti.left=ti.left+ii.clientLeft,ti.bottom=ti.top+ii.clientHeight,ti.right=ti.left+ii.clientWidth,ti.width=ii.clientWidth,ti.height=ii.clientHeight,ti.x=ti.left,ti.y=ti.top,ti}function wu(ii,ei,ti){return ei===qs?bs(jl(ii,ti)):Zn(ei)?vp(ei,ti):bs(ql(Ln(ii)))}function yp(ii){var ei=So(ho(ii)),ti=["absolute","fixed"].indexOf(Pn(ii).position)>=0,ni=ti&&Tn(ii)?to(ii):ii;return Zn(ni)?ei.filter(function(ri){return Zn(ri)&&Ys(ri,ni)&&An(ri)!=="body"}):[]}function Wl(ii,ei,ti,ni){var ri=ei==="clippingParents"?yp(ii):[].concat(ei),oi=[].concat(ri,[ti]),si=oi[0],ai=oi.reduce(function(li,ui){var ci=wu(ii,ui,ni);return li.top=eo(ci.top,li.top),li.right=qo(ci.right,li.right),li.bottom=qo(ci.bottom,li.bottom),li.left=eo(ci.left,li.left),li},wu(ii,si,ni));return ai.width=ai.right-ai.left,ai.height=ai.bottom-ai.top,ai.x=ai.left,ai.y=ai.top,ai}function Xs(ii){var ei=ii.reference,ti=ii.element,ni=ii.placement,ri=ni?Dn(ni):null,oi=ni?Yr(ni):null,si=ei.x+ei.width/2-ti.width/2,ai=ei.y+ei.height/2-ti.height/2,li;switch(ri){case dn:li={x:si,y:ei.y-ti.height};break;case _n:li={x:si,y:ei.y+ei.height};break;case mn:li={x:ei.x+ei.width,y:ai};break;case hn:li={x:ei.x-ti.width,y:ai};break;default:li={x:ei.x,y:ei.y}}var ui=ri?Uo(ri):null;if(ui!=null){var ci=ui==="y"?"height":"width";switch(oi){case so:li[ui]=li[ui]-(ei[ci]/2-ti[ci]/2);break;case To:li[ui]=li[ui]+(ei[ci]/2-ti[ci]/2);break;default:}}return li}function Fn(ii,ei){ei===void 0&&(ei={});var ti=ei,ni=ti.placement,ri=ni===void 0?ii.placement:ni,oi=ti.strategy,si=oi===void 0?ii.strategy:oi,ai=ti.boundary,li=ai===void 0?$l:ai,ui=ti.rootBoundary,ci=ui===void 0?qs:ui,di=ti.elementContext,pi=di===void 0?jo:di,yi=ti.altBoundary,gi=yi===void 0?!1:yi,vi=ti.padding,Ei=vi===void 0?0:vi,Ci=Ks(typeof Ei!="number"?Ei:Qs(Ei,uo)),xi=pi===jo?Bl:jo,Li=ii.rects.popper,Oi=ii.elements[gi?xi:pi],zi=Wl(Zn(Oi)?Oi:Oi.contextElement||Ln(ii.elements.popper),li,ci,si),Vi=Wr(ii.elements.reference),ki=Xs({reference:Vi,element:Li,strategy:"absolute",placement:ri}),Mi=bs(Object.assign({},Li,ki)),Ai=pi===jo?Mi:Vi,qi={top:zi.top-Ai.top+Ci.top,bottom:Ai.bottom-zi.bottom+Ci.bottom,left:zi.left-Ai.left+Ci.left,right:Ai.right-zi.right+Ci.right},Si=ii.modifiersData.offset;if(pi===jo&&Si){var Qi=Si[ri];Object.keys(qi).forEach(function(Ji){var gn=[mn,_n].indexOf(Ji)>=0?1:-1,rn=[dn,_n].indexOf(Ji)>=0?"y":"x";qi[Ji]+=Qi[rn]*gn})}return qi}function Ul(ii,ei){ei===void 0&&(ei={});var ti=ei,ni=ti.placement,ri=ti.boundary,oi=ti.rootBoundary,si=ti.padding,ai=ti.flipVariations,li=ti.allowedAutoPlacements,ui=li===void 0?Ws:li,ci=Yr(ni),di=ci?ai?Da:Da.filter(function(gi){return Yr(gi)===ci}):uo,pi=di.filter(function(gi){return ui.indexOf(gi)>=0});pi.length===0&&(pi=di);var yi=pi.reduce(function(gi,vi){return gi[vi]=Fn(ii,{placement:vi,boundary:ri,rootBoundary:oi,padding:si})[Dn(vi)],gi},{});return Object.keys(yi).sort(function(gi,vi){return yi[gi]-yi[vi]})}function bp(ii){if(Dn(ii)===js)return[];var ei=ys(ii);return[Ma(ii),ei,Ma(ei)]}function _p(ii){var ei=ii.state,ti=ii.options,ni=ii.name;if(!ei.modifiersData[ni]._skip){for(var ri=ti.mainAxis,oi=ri===void 0?!0:ri,si=ti.altAxis,ai=si===void 0?!0:si,li=ti.fallbackPlacements,ui=ti.padding,ci=ti.boundary,di=ti.rootBoundary,pi=ti.altBoundary,yi=ti.flipVariations,gi=yi===void 0?!0:yi,vi=ti.allowedAutoPlacements,Ei=ei.options.placement,Ci=Dn(Ei),xi=Ci===Ei,Li=li||(xi||!gi?[ys(Ei)]:bp(Ei)),Oi=[Ei].concat(Li).reduce(function(ji,Pi){return ji.concat(Dn(Pi)===js?Ul(ei,{placement:Pi,boundary:ci,rootBoundary:di,padding:ui,flipVariations:gi,allowedAutoPlacements:vi}):Pi)},[]),zi=ei.rects.reference,Vi=ei.rects.popper,ki=new Map,Mi=!0,Ai=Oi[0],qi=0;qi=0,rn=gn?"width":"height",Zi=Fn(ei,{placement:Si,boundary:ci,rootBoundary:di,altBoundary:pi,padding:ui}),on=gn?Ji?mn:hn:Ji?_n:dn;zi[rn]>Vi[rn]&&(on=ys(on));var Mn=ys(on),vn=[];if(oi&&vn.push(Zi[Qi]<=0),ai&&vn.push(Zi[on]<=0,Zi[Mn]<=0),vn.every(function(ji){return ji})){Ai=Si,Mi=!1;break}ki.set(Si,vn)}if(Mi)for(var Yi=gi?3:1,Ri=function(Pi){var ln=Oi.find(function(kn){var yn=ki.get(kn);if(yn)return yn.slice(0,Pi).every(function(Cn){return Cn})});if(ln)return Ai=ln,"break"},Ii=Yi;Ii>0;Ii--){var Ui=Ri(Ii);if(Ui==="break")break}ei.placement!==Ai&&(ei.modifiersData[ni]._skip=!0,ei.placement=Ai,ei.reset=!0)}}var Na={name:"flip",enabled:!0,phase:"main",fn:_p,requiresIfExists:["offset"],data:{_skip:!1}};function xu(ii,ei,ti){return ti===void 0&&(ti={x:0,y:0}),{top:ii.top-ei.height-ti.y,right:ii.right-ei.width+ti.x,bottom:ii.bottom-ei.height+ti.y,left:ii.left-ei.width-ti.x}}function Tu(ii){return[dn,mn,_n,hn].some(function(ei){return ii[ei]>=0})}function Ep(ii){var ei=ii.state,ti=ii.name,ni=ei.rects.reference,ri=ei.rects.popper,oi=ei.modifiersData.preventOverflow,si=Fn(ei,{elementContext:"reference"}),ai=Fn(ei,{altBoundary:!0}),li=xu(si,ni),ui=xu(ai,ri,oi),ci=Tu(li),di=Tu(ui);ei.modifiersData[ti]={referenceClippingOffsets:li,popperEscapeOffsets:ui,isReferenceHidden:ci,hasPopperEscaped:di},ei.attributes.popper=Object.assign({},ei.attributes.popper,{"data-popper-reference-hidden":ci,"data-popper-escaped":di})}var Ra={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Ep};function wp(ii,ei,ti){var ni=Dn(ii),ri=[hn,dn].indexOf(ni)>=0?-1:1,oi=typeof ti=="function"?ti(Object.assign({},ei,{placement:ii})):ti,si=oi[0],ai=oi[1];return si=si||0,ai=(ai||0)*ri,[hn,mn].indexOf(ni)>=0?{x:ai,y:si}:{x:si,y:ai}}function xp(ii){var ei=ii.state,ti=ii.options,ni=ii.name,ri=ti.offset,oi=ri===void 0?[0,0]:ri,si=Ws.reduce(function(ci,di){return ci[di]=wp(di,ei.rects,oi),ci},{}),ai=si[ei.placement],li=ai.x,ui=ai.y;ei.modifiersData.popperOffsets!=null&&(ei.modifiersData.popperOffsets.x+=li,ei.modifiersData.popperOffsets.y+=ui),ei.modifiersData[ni]=si}var Ia={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:xp};function Tp(ii){var ei=ii.state,ti=ii.name;ei.modifiersData[ti]=Xs({reference:ei.rects.reference,element:ei.rects.popper,strategy:"absolute",placement:ei.placement})}var _s={name:"popperOffsets",enabled:!0,phase:"read",fn:Tp,data:{}};function Yl(ii){return ii==="x"?"y":"x"}function Sp(ii){var ei=ii.state,ti=ii.options,ni=ii.name,ri=ti.mainAxis,oi=ri===void 0?!0:ri,si=ti.altAxis,ai=si===void 0?!1:si,li=ti.boundary,ui=ti.rootBoundary,ci=ti.altBoundary,di=ti.padding,pi=ti.tether,yi=pi===void 0?!0:pi,gi=ti.tetherOffset,vi=gi===void 0?0:gi,Ei=Fn(ei,{boundary:li,rootBoundary:ui,padding:di,altBoundary:ci}),Ci=Dn(ei.placement),xi=Yr(ei.placement),Li=!xi,Oi=Uo(Ci),zi=Yl(Oi),Vi=ei.modifiersData.popperOffsets,ki=ei.rects.reference,Mi=ei.rects.popper,Ai=typeof vi=="function"?vi(Object.assign({},ei.rects,{placement:ei.placement})):vi,qi=typeof Ai=="number"?{mainAxis:Ai,altAxis:Ai}:Object.assign({mainAxis:0,altAxis:0},Ai),Si=ei.modifiersData.offset?ei.modifiersData.offset[ei.placement]:null,Qi={x:0,y:0};if(Vi){if(oi){var Ji,gn=Oi==="y"?dn:hn,rn=Oi==="y"?_n:mn,Zi=Oi==="y"?"height":"width",on=Vi[Oi],Mn=on+Ei[gn],vn=on-Ei[rn],Yi=yi?-Mi[Zi]/2:0,Ri=xi===so?ki[Zi]:Mi[Zi],Ii=xi===so?-Mi[Zi]:-ki[Zi],Ui=ei.elements.arrow,ji=yi&&Ui?Wo(Ui):{width:0,height:0},Pi=ei.modifiersData["arrow#persistent"]?ei.modifiersData["arrow#persistent"].padding:Gs(),ln=Pi[gn],kn=Pi[rn],yn=Yo(0,ki[Zi],ji[Zi]),Cn=Li?ki[Zi]/2-Yi-yn-ln-qi.mainAxis:Ri-yn-ln-qi.mainAxis,$s=Li?-ki[Zi]/2+Yi+yn+kn+qi.mainAxis:Ii+yn+kn+qi.mainAxis,ro=ei.elements.arrow&&to(ei.elements.arrow),wo=ro?Oi==="y"?ro.clientTop||0:ro.clientLeft||0:0,bn=(Ji=Si==null?void 0:Si[Oi])!=null?Ji:0,xo=on+Cn-bn-wo,ao=on+$s-bn,ls=Yo(yi?qo(Mn,xo):Mn,on,yi?eo(vn,ao):vn);Vi[Oi]=ls,Qi[Oi]=ls-on}if(ai){var On,zn=Oi==="x"?dn:hn,Gn=Oi==="x"?_n:mn,Jn=Vi[zi],cs=zi==="y"?"height":"width",Bs=Jn+Ei[zn],us=Jn-Ei[Gn],ds=[dn,hn].indexOf(Ci)!==-1,Vo=(On=Si==null?void 0:Si[zi])!=null?On:0,Ta=ds?Bs:Jn-ki[cs]-Mi[cs]-Vo+qi.altAxis,zs=ds?Jn+ki[cs]+Mi[cs]-Vo-qi.altAxis:us,Sa=yi&&ds?_u(Ta,Jn,zs):Yo(yi?Ta:Bs,Jn,yi?zs:us);Vi[zi]=Sa,Qi[zi]=Sa-Jn}ei.modifiersData[ni]=Qi}}var Ha={name:"preventOverflow",enabled:!0,phase:"main",fn:Sp,requiresIfExists:["offset"]};function Gl(ii){return{scrollLeft:ii.scrollLeft,scrollTop:ii.scrollTop}}function Kl(ii){return ii===cn(ii)||!Tn(ii)?Go(ii):Gl(ii)}function Cp(ii){var ei=ii.getBoundingClientRect(),ti=fo(ei.width)/ii.offsetWidth||1,ni=fo(ei.height)/ii.offsetHeight||1;return ti!==1||ni!==1}function Ql(ii,ei,ti){ti===void 0&&(ti=!1);var ni=Tn(ei),ri=Tn(ei)&&Cp(ei),oi=Ln(ei),si=Wr(ii,ri,ti),ai={scrollLeft:0,scrollTop:0},li={x:0,y:0};return(ni||!ni&&!ti)&&((An(ei)!=="body"||Qo(oi))&&(ai=Kl(ei)),Tn(ei)?(li=Wr(ei,!0),li.x+=ei.clientLeft,li.y+=ei.clientTop):oi&&(li.x=Ko(oi))),{x:si.left+ai.scrollLeft-li.x,y:si.top+ai.scrollTop-li.y,width:si.width,height:si.height}}function Ap(ii){var ei=new Map,ti=new Set,ni=[];ii.forEach(function(oi){ei.set(oi.name,oi)});function ri(oi){ti.add(oi.name);var si=[].concat(oi.requires||[],oi.requiresIfExists||[]);si.forEach(function(ai){if(!ti.has(ai)){var li=ei.get(ai);li&&ri(li)}}),ni.push(oi)}return ii.forEach(function(oi){ti.has(oi.name)||ri(oi)}),ni}function Xl(ii){var ei=Ap(ii);return zl.reduce(function(ti,ni){return ti.concat(ei.filter(function(ri){return ri.phase===ni}))},[])}function Jl(ii){var ei;return function(){return ei||(ei=new Promise(function(ti){Promise.resolve().then(function(){ei=void 0,ti(ii())})})),ei}}function Zl(ii){var ei=ii.reduce(function(ti,ni){var ri=ti[ni.name];return ti[ni.name]=ri?Object.assign({},ri,ni,{options:Object.assign({},ri.options,ni.options),data:Object.assign({},ri.data,ni.data)}):ni,ti},{});return Object.keys(ei).map(function(ti){return ei[ti]})}var Su={placement:"bottom",modifiers:[],strategy:"absolute"};function Cu(){for(var ii=arguments.length,ei=new Array(ii),ti=0;ti(ii&&window.CSS&&window.CSS.escape&&(ii=ii.replace(/#([^\s"#']+)/g,(ei,ti)=>`#${CSS.escape(ti)}`)),ii),kp=ii=>ii==null?`${ii}`:Object.prototype.toString.call(ii).match(/\s([a-z]+)/i)[1].toLowerCase(),Np=ii=>{do ii+=Math.floor(Math.random()*Lp);while(document.getElementById(ii));return ii},Rp=ii=>{if(!ii)return 0;let{transitionDuration:ei,transitionDelay:ti}=window.getComputedStyle(ii),ni=Number.parseFloat(ei),ri=Number.parseFloat(ti);return!ni&&!ri?0:(ei=ei.split(",")[0],ti=ti.split(",")[0],(Number.parseFloat(ei)+Number.parseFloat(ti))*Mp)},rd=ii=>{ii.dispatchEvent(new Event(mc))},po=ii=>!ii||typeof ii!="object"?!1:(typeof ii.jquery!="undefined"&&(ii=ii[0]),typeof ii.nodeType!="undefined"),Ao=ii=>po(ii)?ii.jquery?ii[0]:ii:typeof ii=="string"&&ii.length>0?document.querySelector(nd(ii)):null,As=ii=>{if(!po(ii)||ii.getClientRects().length===0)return!1;let ei=getComputedStyle(ii).getPropertyValue("visibility")==="visible",ti=ii.closest("details:not([open])");if(!ti)return ei;if(ti!==ii){let ni=ii.closest("summary");if(ni&&ni.parentNode!==ti||ni===null)return!1}return ei},Do=ii=>!ii||ii.nodeType!==Node.ELEMENT_NODE||ii.classList.contains("disabled")?!0:typeof ii.disabled!="undefined"?ii.disabled:ii.hasAttribute("disabled")&&ii.getAttribute("disabled")!=="false",od=ii=>{if(!document.documentElement.attachShadow)return null;if(typeof ii.getRootNode=="function"){let ei=ii.getRootNode();return ei instanceof ShadowRoot?ei:null}return ii instanceof ShadowRoot?ii:ii.parentNode?od(ii.parentNode):null},Ua=()=>{},na=ii=>{ii.offsetHeight},sd=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,tc=[],Ip=ii=>{document.readyState==="loading"?(tc.length||document.addEventListener("DOMContentLoaded",()=>{for(let ei of tc)ei()}),tc.push(ii)):ii()},Gr=()=>document.documentElement.dir==="rtl",Qr=ii=>{Ip(()=>{let ei=sd();if(ei){let ti=ii.NAME,ni=ei.fn[ti];ei.fn[ti]=ii.jQueryInterface,ei.fn[ti].Constructor=ii,ei.fn[ti].noConflict=()=>(ei.fn[ti]=ni,ii.jQueryInterface)}})},Vn=(ii,ei=[],ti=ii)=>typeof ii=="function"?ii(...ei):ti,ad=(ii,ei,ti=!0)=>{if(!ti){Vn(ii);return}let ri=Rp(ei)+5,oi=!1,si=({target:ai})=>{ai===ei&&(oi=!0,ei.removeEventListener(mc,si),Vn(ii))};ei.addEventListener(mc,si),setTimeout(()=>{oi||rd(ei)},ri)},bc=(ii,ei,ti,ni)=>{let ri=ii.length,oi=ii.indexOf(ei);return oi===-1?!ti&&ni?ii[ri-1]:ii[0]:(oi+=ti?1:-1,ni&&(oi=(oi+ri)%ri),ii[Math.max(0,Math.min(oi,ri-1))])},Hp=/[^.]*(?=\..*)\.|.*/,Pp=/\..*/,Fp=/::\d+$/,ic={},Ou=1,ld={mouseenter:"mouseover",mouseleave:"mouseout"},$p=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 cd(ii,ei){return ei&&`${ei}::${Ou++}`||ii.uidEvent||Ou++}function ud(ii){let ei=cd(ii);return ii.uidEvent=ei,ic[ei]=ic[ei]||{},ic[ei]}function Bp(ii,ei){return function ti(ni){return _c(ni,{delegateTarget:ii}),ti.oneOff&&wi.off(ii,ni.type,ei),ei.apply(ii,[ni])}}function zp(ii,ei,ti){return function ni(ri){let oi=ii.querySelectorAll(ei);for(let{target:si}=ri;si&&si!==this;si=si.parentNode)for(let ai of oi)if(ai===si)return _c(ri,{delegateTarget:si}),ni.oneOff&&wi.off(ii,ri.type,ei,ti),ti.apply(si,[ri])}}function dd(ii,ei,ti=null){return Object.values(ii).find(ni=>ni.callable===ei&&ni.delegationSelector===ti)}function fd(ii,ei,ti){let ni=typeof ei=="string",ri=ni?ti:ei||ti,oi=hd(ii);return $p.has(oi)||(oi=ii),[ni,ri,oi]}function Lu(ii,ei,ti,ni,ri){if(typeof ei!="string"||!ii)return;let[oi,si,ai]=fd(ei,ti,ni);ei in ld&&(si=(gi=>function(vi){if(!vi.relatedTarget||vi.relatedTarget!==vi.delegateTarget&&!vi.delegateTarget.contains(vi.relatedTarget))return gi.call(this,vi)})(si));let li=ud(ii),ui=li[ai]||(li[ai]={}),ci=dd(ui,si,oi?ti:null);if(ci){ci.oneOff=ci.oneOff&&ri;return}let di=cd(si,ei.replace(Hp,"")),pi=oi?zp(ii,ti,si):Bp(ii,si);pi.delegationSelector=oi?ti:null,pi.callable=si,pi.oneOff=ri,pi.uidEvent=di,ui[di]=pi,ii.addEventListener(ai,pi,oi)}function gc(ii,ei,ti,ni,ri){let oi=dd(ei[ti],ni,ri);oi&&(ii.removeEventListener(ti,oi,!!ri),delete ei[ti][oi.uidEvent])}function Vp(ii,ei,ti,ni){let ri=ei[ti]||{};for(let[oi,si]of Object.entries(ri))oi.includes(ni)&&gc(ii,ei,ti,si.callable,si.delegationSelector)}function hd(ii){return ii=ii.replace(Pp,""),ld[ii]||ii}var wi={on(ii,ei,ti,ni){Lu(ii,ei,ti,ni,!1)},one(ii,ei,ti,ni){Lu(ii,ei,ti,ni,!0)},off(ii,ei,ti,ni){if(typeof ei!="string"||!ii)return;let[ri,oi,si]=fd(ei,ti,ni),ai=si!==ei,li=ud(ii),ui=li[si]||{},ci=ei.startsWith(".");if(typeof oi!="undefined"){if(!Object.keys(ui).length)return;gc(ii,li,si,oi,ri?ti:null);return}if(ci)for(let di of Object.keys(li))Vp(ii,li,di,ei.slice(1));for(let[di,pi]of Object.entries(ui)){let yi=di.replace(Fp,"");(!ai||ei.includes(yi))&&gc(ii,li,si,pi.callable,pi.delegationSelector)}},trigger(ii,ei,ti){if(typeof ei!="string"||!ii)return null;let ni=sd(),ri=hd(ei),oi=ei!==ri,si=null,ai=!0,li=!0,ui=!1;oi&&ni&&(si=ni.Event(ei,ti),ni(ii).trigger(si),ai=!si.isPropagationStopped(),li=!si.isImmediatePropagationStopped(),ui=si.isDefaultPrevented());let ci=_c(new Event(ei,{bubbles:ai,cancelable:!0}),ti);return ui&&ci.preventDefault(),li&&ii.dispatchEvent(ci),ci.defaultPrevented&&si&&si.preventDefault(),ci}};function _c(ii,ei={}){for(let[ti,ni]of Object.entries(ei))try{ii[ti]=ni}catch(ri){Object.defineProperty(ii,ti,{configurable:!0,get(){return ni}})}return ii}function Mu(ii){if(ii==="true")return!0;if(ii==="false")return!1;if(ii===Number(ii).toString())return Number(ii);if(ii===""||ii==="null")return null;if(typeof ii!="string")return ii;try{return JSON.parse(decodeURIComponent(ii))}catch(ei){return ii}}function nc(ii){return ii.replace(/[A-Z]/g,ei=>`-${ei.toLowerCase()}`)}var mo={setDataAttribute(ii,ei,ti){ii.setAttribute(`data-bs-${nc(ei)}`,ti)},removeDataAttribute(ii,ei){ii.removeAttribute(`data-bs-${nc(ei)}`)},getDataAttributes(ii){if(!ii)return{};let ei={},ti=Object.keys(ii.dataset).filter(ni=>ni.startsWith("bs")&&!ni.startsWith("bsConfig"));for(let ni of ti){let ri=ni.replace(/^bs/,"");ri=ri.charAt(0).toLowerCase()+ri.slice(1,ri.length),ei[ri]=Mu(ii.dataset[ni])}return ei},getDataAttribute(ii,ei){return Mu(ii.getAttribute(`data-bs-${nc(ei)}`))}},es=class{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(ei){return ei=this._mergeConfigObj(ei),ei=this._configAfterMerge(ei),this._typeCheckConfig(ei),ei}_configAfterMerge(ei){return ei}_mergeConfigObj(ei,ti){let ni=po(ti)?mo.getDataAttribute(ti,"config"):{};return Di(Di(Di(Di({},this.constructor.Default),typeof ni=="object"?ni:{}),po(ti)?mo.getDataAttributes(ti):{}),typeof ei=="object"?ei:{})}_typeCheckConfig(ei,ti=this.constructor.DefaultType){for(let[ni,ri]of Object.entries(ti)){let oi=ei[ni],si=po(oi)?"element":kp(oi);if(!new RegExp(ri).test(si))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${ni}" provided type "${si}" but expected type "${ri}".`)}}},jp="5.3.3",Qn=class extends es{constructor(ei,ti){super(),ei=Ao(ei),ei&&(this._element=ei,this._config=this._getConfig(ti),ec.set(this._element,this.constructor.DATA_KEY,this))}dispose(){ec.remove(this._element,this.constructor.DATA_KEY),wi.off(this._element,this.constructor.EVENT_KEY);for(let ei of Object.getOwnPropertyNames(this))this[ei]=null}_queueCallback(ei,ti,ni=!0){ad(ei,ti,ni)}_getConfig(ei){return ei=this._mergeConfigObj(ei,this._element),ei=this._configAfterMerge(ei),this._typeCheckConfig(ei),ei}static getInstance(ei){return ec.get(Ao(ei),this.DATA_KEY)}static getOrCreateInstance(ei,ti={}){return this.getInstance(ei)||new this(ei,typeof ti=="object"?ti:null)}static get VERSION(){return jp}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(ei){return`${ei}${this.EVENT_KEY}`}},rc=ii=>{let ei=ii.getAttribute("data-bs-target");if(!ei||ei==="#"){let ti=ii.getAttribute("href");if(!ti||!ti.includes("#")&&!ti.startsWith("."))return null;ti.includes("#")&&!ti.startsWith("#")&&(ti=`#${ti.split("#")[1]}`),ei=ti&&ti!=="#"?ti.trim():null}return ei?ei.split(",").map(ti=>nd(ti)).join(","):null},Wi={find(ii,ei=document.documentElement){return[].concat(...Element.prototype.querySelectorAll.call(ei,ii))},findOne(ii,ei=document.documentElement){return Element.prototype.querySelector.call(ei,ii)},children(ii,ei){return[].concat(...ii.children).filter(ti=>ti.matches(ei))},parents(ii,ei){let ti=[],ni=ii.parentNode.closest(ei);for(;ni;)ti.push(ni),ni=ni.parentNode.closest(ei);return ti},prev(ii,ei){let ti=ii.previousElementSibling;for(;ti;){if(ti.matches(ei))return[ti];ti=ti.previousElementSibling}return[]},next(ii,ei){let ti=ii.nextElementSibling;for(;ti;){if(ti.matches(ei))return[ti];ti=ti.nextElementSibling}return[]},focusableChildren(ii){let ei=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map(ti=>`${ti}:not([tabindex^="-"])`).join(",");return this.find(ei,ii).filter(ti=>!Do(ti)&&As(ti))},getSelectorFromElement(ii){let ei=rc(ii);return ei&&Wi.findOne(ei)?ei:null},getElementFromSelector(ii){let ei=rc(ii);return ei?Wi.findOne(ei):null},getMultipleElementsFromSelector(ii){let ei=rc(ii);return ei?Wi.find(ei):[]}},el=(ii,ei="hide")=>{let ti=`click.dismiss${ii.EVENT_KEY}`,ni=ii.NAME;wi.on(document,ti,`[data-bs-dismiss="${ni}"]`,function(ri){if(["A","AREA"].includes(this.tagName)&&ri.preventDefault(),Do(this))return;let oi=Wi.getElementFromSelector(this)||this.closest(`.${ni}`);ii.getOrCreateInstance(oi)[ei]()})},qp="alert",Wp="bs.alert",pd=`.${Wp}`,Up=`close${pd}`,Yp=`closed${pd}`,Gp="fade",Kp="show",Ya=class ii extends Qn{static get NAME(){return qp}close(){if(wi.trigger(this._element,Up).defaultPrevented)return;this._element.classList.remove(Kp);let ti=this._element.classList.contains(Gp);this._queueCallback(()=>this._destroyElement(),this._element,ti)}_destroyElement(){this._element.remove(),wi.trigger(this._element,Yp),this.dispose()}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this);if(typeof ei=="string"){if(ti[ei]===void 0||ei.startsWith("_")||ei==="constructor")throw new TypeError(`No method named "${ei}"`);ti[ei](this)}})}};el(Ya,"close");Qr(Ya);var Qp="button",Xp="bs.button",Jp=`.${Xp}`,Zp=".data-api",em="active",ku='[data-bs-toggle="button"]',tm=`click${Jp}${Zp}`,Ga=class ii extends Qn{static get NAME(){return Qp}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle(em))}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this);ei==="toggle"&&ti[ei]()})}};wi.on(document,tm,ku,ii=>{ii.preventDefault();let ei=ii.target.closest(ku);Ga.getOrCreateInstance(ei).toggle()});Qr(Ga);var im="swipe",Ds=".bs.swipe",nm=`touchstart${Ds}`,rm=`touchmove${Ds}`,om=`touchend${Ds}`,sm=`pointerdown${Ds}`,am=`pointerup${Ds}`,lm="touch",cm="pen",um="pointer-event",dm=40,fm={endCallback:null,leftCallback:null,rightCallback:null},hm={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"},Ka=class ii extends es{constructor(ei,ti){super(),this._element=ei,!(!ei||!ii.isSupported())&&(this._config=this._getConfig(ti),this._deltaX=0,this._supportPointerEvents=!!window.PointerEvent,this._initEvents())}static get Default(){return fm}static get DefaultType(){return hm}static get NAME(){return im}dispose(){wi.off(this._element,Ds)}_start(ei){if(!this._supportPointerEvents){this._deltaX=ei.touches[0].clientX;return}this._eventIsPointerPenTouch(ei)&&(this._deltaX=ei.clientX)}_end(ei){this._eventIsPointerPenTouch(ei)&&(this._deltaX=ei.clientX-this._deltaX),this._handleSwipe(),Vn(this._config.endCallback)}_move(ei){this._deltaX=ei.touches&&ei.touches.length>1?0:ei.touches[0].clientX-this._deltaX}_handleSwipe(){let ei=Math.abs(this._deltaX);if(ei<=dm)return;let ti=ei/this._deltaX;this._deltaX=0,ti&&Vn(ti>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(wi.on(this._element,sm,ei=>this._start(ei)),wi.on(this._element,am,ei=>this._end(ei)),this._element.classList.add(um)):(wi.on(this._element,nm,ei=>this._start(ei)),wi.on(this._element,rm,ei=>this._move(ei)),wi.on(this._element,om,ei=>this._end(ei)))}_eventIsPointerPenTouch(ei){return this._supportPointerEvents&&(ei.pointerType===cm||ei.pointerType===lm)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}},pm="carousel",mm="bs.carousel",ko=`.${mm}`,md=".data-api",gm="ArrowLeft",vm="ArrowRight",ym=500,Zs="next",Es="prev",xs="left",qa="right",bm=`slide${ko}`,oc=`slid${ko}`,_m=`keydown${ko}`,Em=`mouseenter${ko}`,wm=`mouseleave${ko}`,xm=`dragstart${ko}`,Tm=`load${ko}${md}`,Sm=`click${ko}${md}`,gd="carousel",Fa="active",Cm="slide",Am="carousel-item-end",Dm="carousel-item-start",Om="carousel-item-next",Lm="carousel-item-prev",vd=".active",yd=".carousel-item",Mm=vd+yd,km=".carousel-item img",Nm=".carousel-indicators",Rm="[data-bs-slide], [data-bs-slide-to]",Im='[data-bs-ride="carousel"]',Hm={[gm]:qa,[vm]:xs},Pm={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},Fm={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"},ta=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=Wi.findOne(Nm,this._element),this._addEventListeners(),this._config.ride===gd&&this.cycle()}static get Default(){return Pm}static get DefaultType(){return Fm}static get NAME(){return pm}next(){this._slide(Zs)}nextWhenVisible(){!document.hidden&&As(this._element)&&this.next()}prev(){this._slide(Es)}pause(){this._isSliding&&rd(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval(()=>this.nextWhenVisible(),this._config.interval)}_maybeEnableCycle(){if(this._config.ride){if(this._isSliding){wi.one(this._element,oc,()=>this.cycle());return}this.cycle()}}to(ei){let ti=this._getItems();if(ei>ti.length-1||ei<0)return;if(this._isSliding){wi.one(this._element,oc,()=>this.to(ei));return}let ni=this._getItemIndex(this._getActive());if(ni===ei)return;let ri=ei>ni?Zs:Es;this._slide(ri,ti[ei])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(ei){return ei.defaultInterval=ei.interval,ei}_addEventListeners(){this._config.keyboard&&wi.on(this._element,_m,ei=>this._keydown(ei)),this._config.pause==="hover"&&(wi.on(this._element,Em,()=>this.pause()),wi.on(this._element,wm,()=>this._maybeEnableCycle())),this._config.touch&&Ka.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(let ni of Wi.find(km,this._element))wi.on(ni,xm,ri=>ri.preventDefault());let ti={leftCallback:()=>this._slide(this._directionToOrder(xs)),rightCallback:()=>this._slide(this._directionToOrder(qa)),endCallback:()=>{this._config.pause==="hover"&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout(()=>this._maybeEnableCycle(),ym+this._config.interval))}};this._swipeHelper=new Ka(this._element,ti)}_keydown(ei){if(/input|textarea/i.test(ei.target.tagName))return;let ti=Hm[ei.key];ti&&(ei.preventDefault(),this._slide(this._directionToOrder(ti)))}_getItemIndex(ei){return this._getItems().indexOf(ei)}_setActiveIndicatorElement(ei){if(!this._indicatorsElement)return;let ti=Wi.findOne(vd,this._indicatorsElement);ti.classList.remove(Fa),ti.removeAttribute("aria-current");let ni=Wi.findOne(`[data-bs-slide-to="${ei}"]`,this._indicatorsElement);ni&&(ni.classList.add(Fa),ni.setAttribute("aria-current","true"))}_updateInterval(){let ei=this._activeElement||this._getActive();if(!ei)return;let ti=Number.parseInt(ei.getAttribute("data-bs-interval"),10);this._config.interval=ti||this._config.defaultInterval}_slide(ei,ti=null){if(this._isSliding)return;let ni=this._getActive(),ri=ei===Zs,oi=ti||bc(this._getItems(),ni,ri,this._config.wrap);if(oi===ni)return;let si=this._getItemIndex(oi),ai=yi=>wi.trigger(this._element,yi,{relatedTarget:oi,direction:this._orderToDirection(ei),from:this._getItemIndex(ni),to:si});if(ai(bm).defaultPrevented||!ni||!oi)return;let ui=!!this._interval;this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(si),this._activeElement=oi;let ci=ri?Dm:Am,di=ri?Om:Lm;oi.classList.add(di),na(oi),ni.classList.add(ci),oi.classList.add(ci);let pi=()=>{oi.classList.remove(ci,di),oi.classList.add(Fa),ni.classList.remove(Fa,di,ci),this._isSliding=!1,ai(oc)};this._queueCallback(pi,ni,this._isAnimated()),ui&&this.cycle()}_isAnimated(){return this._element.classList.contains(Cm)}_getActive(){return Wi.findOne(Mm,this._element)}_getItems(){return Wi.find(yd,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(ei){return Gr()?ei===xs?Es:Zs:ei===xs?Zs:Es}_orderToDirection(ei){return Gr()?ei===Es?xs:qa:ei===Es?qa:xs}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="number"){ti.to(ei);return}if(typeof ei=="string"){if(ti[ei]===void 0||ei.startsWith("_")||ei==="constructor")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}};wi.on(document,Sm,Rm,function(ii){let ei=Wi.getElementFromSelector(this);if(!ei||!ei.classList.contains(gd))return;ii.preventDefault();let ti=ta.getOrCreateInstance(ei),ni=this.getAttribute("data-bs-slide-to");if(ni){ti.to(ni),ti._maybeEnableCycle();return}if(mo.getDataAttribute(this,"slide")==="next"){ti.next(),ti._maybeEnableCycle();return}ti.prev(),ti._maybeEnableCycle()});wi.on(window,Tm,()=>{let ii=Wi.find(Im);for(let ei of ii)ta.getOrCreateInstance(ei)});Qr(ta);var $m="collapse",Bm="bs.collapse",ra=`.${Bm}`,zm=".data-api",Vm=`show${ra}`,jm=`shown${ra}`,qm=`hide${ra}`,Wm=`hidden${ra}`,Um=`click${ra}${zm}`,sc="show",Ss="collapse",$a="collapsing",Ym="collapsed",Gm=`:scope .${Ss} .${Ss}`,Km="collapse-horizontal",Qm="width",Xm="height",Jm=".collapse.show, .collapse.collapsing",vc='[data-bs-toggle="collapse"]',Zm={parent:null,toggle:!0},eg={parent:"(null|element)",toggle:"boolean"},Oo=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._isTransitioning=!1,this._triggerArray=[];let ni=Wi.find(vc);for(let ri of ni){let oi=Wi.getSelectorFromElement(ri),si=Wi.find(oi).filter(ai=>ai===this._element);oi!==null&&si.length&&this._triggerArray.push(ri)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return Zm}static get DefaultType(){return eg}static get NAME(){return $m}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let ei=[];if(this._config.parent&&(ei=this._getFirstLevelChildren(Jm).filter(ai=>ai!==this._element).map(ai=>ii.getOrCreateInstance(ai,{toggle:!1}))),ei.length&&ei[0]._isTransitioning||wi.trigger(this._element,Vm).defaultPrevented)return;for(let ai of ei)ai.hide();let ni=this._getDimension();this._element.classList.remove(Ss),this._element.classList.add($a),this._element.style[ni]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;let ri=()=>{this._isTransitioning=!1,this._element.classList.remove($a),this._element.classList.add(Ss,sc),this._element.style[ni]="",wi.trigger(this._element,jm)},si=`scroll${ni[0].toUpperCase()+ni.slice(1)}`;this._queueCallback(ri,this._element,!0),this._element.style[ni]=`${this._element[si]}px`}hide(){if(this._isTransitioning||!this._isShown()||wi.trigger(this._element,qm).defaultPrevented)return;let ti=this._getDimension();this._element.style[ti]=`${this._element.getBoundingClientRect()[ti]}px`,na(this._element),this._element.classList.add($a),this._element.classList.remove(Ss,sc);for(let ri of this._triggerArray){let oi=Wi.getElementFromSelector(ri);oi&&!this._isShown(oi)&&this._addAriaAndCollapsedClass([ri],!1)}this._isTransitioning=!0;let ni=()=>{this._isTransitioning=!1,this._element.classList.remove($a),this._element.classList.add(Ss),wi.trigger(this._element,Wm)};this._element.style[ti]="",this._queueCallback(ni,this._element,!0)}_isShown(ei=this._element){return ei.classList.contains(sc)}_configAfterMerge(ei){return ei.toggle=!!ei.toggle,ei.parent=Ao(ei.parent),ei}_getDimension(){return this._element.classList.contains(Km)?Qm:Xm}_initializeChildren(){if(!this._config.parent)return;let ei=this._getFirstLevelChildren(vc);for(let ti of ei){let ni=Wi.getElementFromSelector(ti);ni&&this._addAriaAndCollapsedClass([ti],this._isShown(ni))}}_getFirstLevelChildren(ei){let ti=Wi.find(Gm,this._config.parent);return Wi.find(ei,this._config.parent).filter(ni=>!ti.includes(ni))}_addAriaAndCollapsedClass(ei,ti){if(ei.length)for(let ni of ei)ni.classList.toggle(Ym,!ti),ni.setAttribute("aria-expanded",ti)}static jQueryInterface(ei){let ti={};return typeof ei=="string"&&/show|hide/.test(ei)&&(ti.toggle=!1),this.each(function(){let ni=ii.getOrCreateInstance(this,ti);if(typeof ei=="string"){if(typeof ni[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ni[ei]()}})}};wi.on(document,Um,vc,function(ii){(ii.target.tagName==="A"||ii.delegateTarget&&ii.delegateTarget.tagName==="A")&&ii.preventDefault();for(let ei of Wi.getMultipleElementsFromSelector(this))Oo.getOrCreateInstance(ei,{toggle:!1}).toggle()});Qr(Oo);var Nu="dropdown",tg="bs.dropdown",is=`.${tg}`,Ec=".data-api",ig="Escape",Ru="Tab",ng="ArrowUp",Iu="ArrowDown",rg=2,og=`hide${is}`,sg=`hidden${is}`,ag=`show${is}`,lg=`shown${is}`,bd=`click${is}${Ec}`,_d=`keydown${is}${Ec}`,cg=`keyup${is}${Ec}`,Ts="show",ug="dropup",dg="dropend",fg="dropstart",hg="dropup-center",pg="dropdown-center",Jo='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',mg=`${Jo}.${Ts}`,Wa=".dropdown-menu",gg=".navbar",vg=".navbar-nav",yg=".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",bg=Gr()?"top-end":"top-start",_g=Gr()?"top-start":"top-end",Eg=Gr()?"bottom-end":"bottom-start",wg=Gr()?"bottom-start":"bottom-end",xg=Gr()?"left-start":"right-start",Tg=Gr()?"right-start":"left-start",Sg="top",Cg="bottom",Ag={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Dg={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"},Lo=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._popper=null,this._parent=this._element.parentNode,this._menu=Wi.next(this._element,Wa)[0]||Wi.prev(this._element,Wa)[0]||Wi.findOne(Wa,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Ag}static get DefaultType(){return Dg}static get NAME(){return Nu}toggle(){return this._isShown()?this.hide():this.show()}show(){if(Do(this._element)||this._isShown())return;let ei={relatedTarget:this._element};if(!wi.trigger(this._element,ag,ei).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(vg))for(let ni of[].concat(...document.body.children))wi.on(ni,"mouseover",Ua);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Ts),this._element.classList.add(Ts),wi.trigger(this._element,lg,ei)}}hide(){if(Do(this._element)||!this._isShown())return;let ei={relatedTarget:this._element};this._completeHide(ei)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(ei){if(!wi.trigger(this._element,og,ei).defaultPrevented){if("ontouchstart"in document.documentElement)for(let ni of[].concat(...document.body.children))wi.off(ni,"mouseover",Ua);this._popper&&this._popper.destroy(),this._menu.classList.remove(Ts),this._element.classList.remove(Ts),this._element.setAttribute("aria-expanded","false"),mo.removeDataAttribute(this._menu,"popper"),wi.trigger(this._element,sg,ei)}}_getConfig(ei){if(ei=super._getConfig(ei),typeof ei.reference=="object"&&!po(ei.reference)&&typeof ei.reference.getBoundingClientRect!="function")throw new TypeError(`${Nu.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return ei}_createPopper(){if(typeof Pa=="undefined")throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let ei=this._element;this._config.reference==="parent"?ei=this._parent:po(this._config.reference)?ei=Ao(this._config.reference):typeof this._config.reference=="object"&&(ei=this._config.reference);let ti=this._getPopperConfig();this._popper=Js(ei,this._menu,ti)}_isShown(){return this._menu.classList.contains(Ts)}_getPlacement(){let ei=this._parent;if(ei.classList.contains(dg))return xg;if(ei.classList.contains(fg))return Tg;if(ei.classList.contains(hg))return Sg;if(ei.classList.contains(pg))return Cg;let ti=getComputedStyle(this._menu).getPropertyValue("--bs-position").trim()==="end";return ei.classList.contains(ug)?ti?_g:bg:ti?wg:Eg}_detectNavbar(){return this._element.closest(gg)!==null}_getOffset(){let{offset:ei}=this._config;return typeof ei=="string"?ei.split(",").map(ti=>Number.parseInt(ti,10)):typeof ei=="function"?ti=>ei(ti,this._element):ei}_getPopperConfig(){let ei={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||this._config.display==="static")&&(mo.setDataAttribute(this._menu,"popper","static"),ei.modifiers=[{name:"applyStyles",enabled:!1}]),Di(Di({},ei),Vn(this._config.popperConfig,[ei]))}_selectMenuItem({key:ei,target:ti}){let ni=Wi.find(yg,this._menu).filter(ri=>As(ri));ni.length&&bc(ni,ti,ei===Iu,!ni.includes(ti)).focus()}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(typeof ti[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}static clearMenus(ei){if(ei.button===rg||ei.type==="keyup"&&ei.key!==Ru)return;let ti=Wi.find(mg);for(let ni of ti){let ri=ii.getInstance(ni);if(!ri||ri._config.autoClose===!1)continue;let oi=ei.composedPath(),si=oi.includes(ri._menu);if(oi.includes(ri._element)||ri._config.autoClose==="inside"&&!si||ri._config.autoClose==="outside"&&si||ri._menu.contains(ei.target)&&(ei.type==="keyup"&&ei.key===Ru||/input|select|option|textarea|form/i.test(ei.target.tagName)))continue;let ai={relatedTarget:ri._element};ei.type==="click"&&(ai.clickEvent=ei),ri._completeHide(ai)}}static dataApiKeydownHandler(ei){let ti=/input|textarea/i.test(ei.target.tagName),ni=ei.key===ig,ri=[ng,Iu].includes(ei.key);if(!ri&&!ni||ti&&!ni)return;ei.preventDefault();let oi=this.matches(Jo)?this:Wi.prev(this,Jo)[0]||Wi.next(this,Jo)[0]||Wi.findOne(Jo,ei.delegateTarget.parentNode),si=ii.getOrCreateInstance(oi);if(ri){ei.stopPropagation(),si.show(),si._selectMenuItem(ei);return}si._isShown()&&(ei.stopPropagation(),si.hide(),oi.focus())}};wi.on(document,_d,Jo,Lo.dataApiKeydownHandler);wi.on(document,_d,Wa,Lo.dataApiKeydownHandler);wi.on(document,bd,Lo.clearMenus);wi.on(document,cg,Lo.clearMenus);wi.on(document,bd,Jo,function(ii){ii.preventDefault(),Lo.getOrCreateInstance(this).toggle()});Qr(Lo);var Ed="backdrop",Og="fade",Hu="show",Pu=`mousedown.bs.${Ed}`,Lg={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},Mg={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"},Qa=class extends es{constructor(ei){super(),this._config=this._getConfig(ei),this._isAppended=!1,this._element=null}static get Default(){return Lg}static get DefaultType(){return Mg}static get NAME(){return Ed}show(ei){if(!this._config.isVisible){Vn(ei);return}this._append();let ti=this._getElement();this._config.isAnimated&&na(ti),ti.classList.add(Hu),this._emulateAnimation(()=>{Vn(ei)})}hide(ei){if(!this._config.isVisible){Vn(ei);return}this._getElement().classList.remove(Hu),this._emulateAnimation(()=>{this.dispose(),Vn(ei)})}dispose(){this._isAppended&&(wi.off(this._element,Pu),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){let ei=document.createElement("div");ei.className=this._config.className,this._config.isAnimated&&ei.classList.add(Og),this._element=ei}return this._element}_configAfterMerge(ei){return ei.rootElement=Ao(ei.rootElement),ei}_append(){if(this._isAppended)return;let ei=this._getElement();this._config.rootElement.append(ei),wi.on(ei,Pu,()=>{Vn(this._config.clickCallback)}),this._isAppended=!0}_emulateAnimation(ei){ad(ei,this._getElement(),this._config.isAnimated)}},kg="focustrap",Ng="bs.focustrap",Xa=`.${Ng}`,Rg=`focusin${Xa}`,Ig=`keydown.tab${Xa}`,Hg="Tab",Pg="forward",Fu="backward",Fg={autofocus:!0,trapElement:null},$g={autofocus:"boolean",trapElement:"element"},Ja=class extends es{constructor(ei){super(),this._config=this._getConfig(ei),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return Fg}static get DefaultType(){return $g}static get NAME(){return kg}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),wi.off(document,Xa),wi.on(document,Rg,ei=>this._handleFocusin(ei)),wi.on(document,Ig,ei=>this._handleKeydown(ei)),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,wi.off(document,Xa))}_handleFocusin(ei){let{trapElement:ti}=this._config;if(ei.target===document||ei.target===ti||ti.contains(ei.target))return;let ni=Wi.focusableChildren(ti);ni.length===0?ti.focus():this._lastTabNavDirection===Fu?ni[ni.length-1].focus():ni[0].focus()}_handleKeydown(ei){ei.key===Hg&&(this._lastTabNavDirection=ei.shiftKey?Fu:Pg)}},$u=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",Bu=".sticky-top",Ba="padding-right",zu="margin-right",ia=class{constructor(){this._element=document.body}getWidth(){let ei=document.documentElement.clientWidth;return Math.abs(window.innerWidth-ei)}hide(){let ei=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,Ba,ti=>ti+ei),this._setElementAttributes($u,Ba,ti=>ti+ei),this._setElementAttributes(Bu,zu,ti=>ti-ei)}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,Ba),this._resetElementAttributes($u,Ba),this._resetElementAttributes(Bu,zu)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(ei,ti,ni){let ri=this.getWidth(),oi=si=>{if(si!==this._element&&window.innerWidth>si.clientWidth+ri)return;this._saveInitialAttribute(si,ti);let ai=window.getComputedStyle(si).getPropertyValue(ti);si.style.setProperty(ti,`${ni(Number.parseFloat(ai))}px`)};this._applyManipulationCallback(ei,oi)}_saveInitialAttribute(ei,ti){let ni=ei.style.getPropertyValue(ti);ni&&mo.setDataAttribute(ei,ti,ni)}_resetElementAttributes(ei,ti){let ni=ri=>{let oi=mo.getDataAttribute(ri,ti);if(oi===null){ri.style.removeProperty(ti);return}mo.removeDataAttribute(ri,ti),ri.style.setProperty(ti,oi)};this._applyManipulationCallback(ei,ni)}_applyManipulationCallback(ei,ti){if(po(ei)){ti(ei);return}for(let ni of Wi.find(ei,this._element))ti(ni)}},Bg="modal",zg="bs.modal",Kr=`.${zg}`,Vg=".data-api",jg="Escape",qg=`hide${Kr}`,Wg=`hidePrevented${Kr}`,wd=`hidden${Kr}`,xd=`show${Kr}`,Ug=`shown${Kr}`,Yg=`resize${Kr}`,Gg=`click.dismiss${Kr}`,Kg=`mousedown.dismiss${Kr}`,Qg=`keydown.dismiss${Kr}`,Xg=`click${Kr}${Vg}`,Vu="modal-open",Jg="fade",ju="show",ac="modal-static",Zg=".modal.show",ev=".modal-dialog",tv=".modal-body",iv='[data-bs-toggle="modal"]',nv={backdrop:!0,focus:!0,keyboard:!0},rv={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"},io=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._dialog=Wi.findOne(ev,this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new ia,this._addEventListeners()}static get Default(){return nv}static get DefaultType(){return rv}static get NAME(){return Bg}toggle(ei){return this._isShown?this.hide():this.show(ei)}show(ei){this._isShown||this._isTransitioning||wi.trigger(this._element,xd,{relatedTarget:ei}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(Vu),this._adjustDialog(),this._backdrop.show(()=>this._showElement(ei)))}hide(){!this._isShown||this._isTransitioning||wi.trigger(this._element,qg).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(ju),this._queueCallback(()=>this._hideModal(),this._element,this._isAnimated()))}dispose(){wi.off(window,Kr),wi.off(this._dialog,Kr),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new Qa({isVisible:!!this._config.backdrop,isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Ja({trapElement:this._element})}_showElement(ei){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;let ti=Wi.findOne(tv,this._dialog);ti&&(ti.scrollTop=0),na(this._element),this._element.classList.add(ju);let ni=()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,wi.trigger(this._element,Ug,{relatedTarget:ei})};this._queueCallback(ni,this._dialog,this._isAnimated())}_addEventListeners(){wi.on(this._element,Qg,ei=>{if(ei.key===jg){if(this._config.keyboard){this.hide();return}this._triggerBackdropTransition()}}),wi.on(window,Yg,()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()}),wi.on(this._element,Kg,ei=>{wi.one(this._element,Gg,ti=>{if(!(this._element!==ei.target||this._element!==ti.target)){if(this._config.backdrop==="static"){this._triggerBackdropTransition();return}this._config.backdrop&&this.hide()}})})}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide(()=>{document.body.classList.remove(Vu),this._resetAdjustments(),this._scrollBar.reset(),wi.trigger(this._element,wd)})}_isAnimated(){return this._element.classList.contains(Jg)}_triggerBackdropTransition(){if(wi.trigger(this._element,Wg).defaultPrevented)return;let ti=this._element.scrollHeight>document.documentElement.clientHeight,ni=this._element.style.overflowY;ni==="hidden"||this._element.classList.contains(ac)||(ti||(this._element.style.overflowY="hidden"),this._element.classList.add(ac),this._queueCallback(()=>{this._element.classList.remove(ac),this._queueCallback(()=>{this._element.style.overflowY=ni},this._dialog)},this._dialog),this._element.focus())}_adjustDialog(){let ei=this._element.scrollHeight>document.documentElement.clientHeight,ti=this._scrollBar.getWidth(),ni=ti>0;if(ni&&!ei){let ri=Gr()?"paddingLeft":"paddingRight";this._element.style[ri]=`${ti}px`}if(!ni&&ei){let ri=Gr()?"paddingRight":"paddingLeft";this._element.style[ri]=`${ti}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(ei,ti){return this.each(function(){let ni=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(typeof ni[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ni[ei](ti)}})}};wi.on(document,Xg,iv,function(ii){let ei=Wi.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&ii.preventDefault(),wi.one(ei,xd,ri=>{ri.defaultPrevented||wi.one(ei,wd,()=>{As(this)&&this.focus()})});let ti=Wi.findOne(Zg);ti&&io.getInstance(ti).hide(),io.getOrCreateInstance(ei).toggle(this)});el(io);Qr(io);var ov="offcanvas",sv="bs.offcanvas",yo=`.${sv}`,Td=".data-api",av=`load${yo}${Td}`,lv="Escape",qu="show",Wu="showing",Uu="hiding",cv="offcanvas-backdrop",Sd=".offcanvas.show",uv=`show${yo}`,dv=`shown${yo}`,fv=`hide${yo}`,Yu=`hidePrevented${yo}`,Cd=`hidden${yo}`,hv=`resize${yo}`,pv=`click${yo}${Td}`,mv=`keydown.dismiss${yo}`,gv='[data-bs-toggle="offcanvas"]',vv={backdrop:!0,keyboard:!0,scroll:!1},yv={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"},Mo=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return vv}static get DefaultType(){return yv}static get NAME(){return ov}toggle(ei){return this._isShown?this.hide():this.show(ei)}show(ei){if(this._isShown||wi.trigger(this._element,uv,{relatedTarget:ei}).defaultPrevented)return;this._isShown=!0,this._backdrop.show(),this._config.scroll||new ia().hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Wu);let ni=()=>{(!this._config.scroll||this._config.backdrop)&&this._focustrap.activate(),this._element.classList.add(qu),this._element.classList.remove(Wu),wi.trigger(this._element,dv,{relatedTarget:ei})};this._queueCallback(ni,this._element,!0)}hide(){if(!this._isShown||wi.trigger(this._element,fv).defaultPrevented)return;this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Uu),this._backdrop.hide();let ti=()=>{this._element.classList.remove(qu,Uu),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||new ia().reset(),wi.trigger(this._element,Cd)};this._queueCallback(ti,this._element,!0)}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){let ei=()=>{if(this._config.backdrop==="static"){wi.trigger(this._element,Yu);return}this.hide()},ti=!!this._config.backdrop;return new Qa({className:cv,isVisible:ti,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:ti?ei:null})}_initializeFocusTrap(){return new Ja({trapElement:this._element})}_addEventListeners(){wi.on(this._element,mv,ei=>{if(ei.key===lv){if(this._config.keyboard){this.hide();return}wi.trigger(this._element,Yu)}})}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(ti[ei]===void 0||ei.startsWith("_")||ei==="constructor")throw new TypeError(`No method named "${ei}"`);ti[ei](this)}})}};wi.on(document,pv,gv,function(ii){let ei=Wi.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&ii.preventDefault(),Do(this))return;wi.one(ei,Cd,()=>{As(this)&&this.focus()});let ti=Wi.findOne(Sd);ti&&ti!==ei&&Mo.getInstance(ti).hide(),Mo.getOrCreateInstance(ei).toggle(this)});wi.on(window,av,()=>{for(let ii of Wi.find(Sd))Mo.getOrCreateInstance(ii).show()});wi.on(window,hv,()=>{for(let ii of Wi.find("[aria-modal][class*=show][class*=offcanvas-]"))getComputedStyle(ii).position!=="fixed"&&Mo.getOrCreateInstance(ii).hide()});el(Mo);Qr(Mo);var bv=/^aria-[\w-]*$/i,Ad={"*":["class","dir","id","lang","role",bv],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:[]},_v=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),Ev=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,wv=(ii,ei)=>{let ti=ii.nodeName.toLowerCase();return ei.includes(ti)?_v.has(ti)?!!Ev.test(ii.nodeValue):!0:ei.filter(ni=>ni instanceof RegExp).some(ni=>ni.test(ti))};function xv(ii,ei,ti){if(!ii.length)return ii;if(ti&&typeof ti=="function")return ti(ii);let ri=new window.DOMParser().parseFromString(ii,"text/html"),oi=[].concat(...ri.body.querySelectorAll("*"));for(let si of oi){let ai=si.nodeName.toLowerCase();if(!Object.keys(ei).includes(ai)){si.remove();continue}let li=[].concat(...si.attributes),ui=[].concat(ei["*"]||[],ei[ai]||[]);for(let ci of li)wv(ci,ui)||si.removeAttribute(ci.nodeName)}return ri.body.innerHTML}var Tv="TemplateFactory",Sv={allowList:Ad,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"
"},Cv={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},Av={entry:"(string|element|function|null)",selector:"(string|element)"},yc=class extends es{constructor(ei){super(),this._config=this._getConfig(ei)}static get Default(){return Sv}static get DefaultType(){return Cv}static get NAME(){return Tv}getContent(){return Object.values(this._config.content).map(ei=>this._resolvePossibleFunction(ei)).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(ei){return this._checkContent(ei),this._config.content=Di(Di({},this._config.content),ei),this}toHtml(){let ei=document.createElement("div");ei.innerHTML=this._maybeSanitize(this._config.template);for(let[ri,oi]of Object.entries(this._config.content))this._setContent(ei,oi,ri);let ti=ei.children[0],ni=this._resolvePossibleFunction(this._config.extraClass);return ni&&ti.classList.add(...ni.split(" ")),ti}_typeCheckConfig(ei){super._typeCheckConfig(ei),this._checkContent(ei.content)}_checkContent(ei){for(let[ti,ni]of Object.entries(ei))super._typeCheckConfig({selector:ti,entry:ni},Av)}_setContent(ei,ti,ni){let ri=Wi.findOne(ni,ei);if(ri){if(ti=this._resolvePossibleFunction(ti),!ti){ri.remove();return}if(po(ti)){this._putElementInTemplate(Ao(ti),ri);return}if(this._config.html){ri.innerHTML=this._maybeSanitize(ti);return}ri.textContent=ti}}_maybeSanitize(ei){return this._config.sanitize?xv(ei,this._config.allowList,this._config.sanitizeFn):ei}_resolvePossibleFunction(ei){return Vn(ei,[this])}_putElementInTemplate(ei,ti){if(this._config.html){ti.innerHTML="",ti.append(ei);return}ti.textContent=ei.textContent}},Dv="tooltip",Ov=new Set(["sanitize","allowList","sanitizeFn"]),lc="fade",Lv="modal",za="show",Mv=".tooltip-inner",Gu=`.${Lv}`,Ku="hide.bs.modal",ea="hover",cc="focus",kv="click",Nv="manual",Rv="hide",Iv="hidden",Hv="show",Pv="shown",Fv="inserted",$v="click",Bv="focusin",zv="focusout",Vv="mouseenter",jv="mouseleave",qv={AUTO:"auto",TOP:"top",RIGHT:Gr()?"left":"right",BOTTOM:"bottom",LEFT:Gr()?"right":"left"},Wv={allowList:Ad,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"},Uv={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"},go=class ii extends Qn{constructor(ei,ti){if(typeof Pa=="undefined")throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(ei,ti),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 Wv}static get DefaultType(){return Uv}static get NAME(){return Dv}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){if(this._isEnabled){if(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()){this._leave();return}this._enter()}}dispose(){clearTimeout(this._timeout),wi.off(this._element.closest(Gu),Ku,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if(this._element.style.display==="none")throw new Error("Please use show on visible elements");if(!(this._isWithContent()&&this._isEnabled))return;let ei=wi.trigger(this._element,this.constructor.eventName(Hv)),ni=(od(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(ei.defaultPrevented||!ni)return;this._disposePopper();let ri=this._getTipElement();this._element.setAttribute("aria-describedby",ri.getAttribute("id"));let{container:oi}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(oi.append(ri),wi.trigger(this._element,this.constructor.eventName(Fv))),this._popper=this._createPopper(ri),ri.classList.add(za),"ontouchstart"in document.documentElement)for(let ai of[].concat(...document.body.children))wi.on(ai,"mouseover",Ua);let si=()=>{wi.trigger(this._element,this.constructor.eventName(Pv)),this._isHovered===!1&&this._leave(),this._isHovered=!1};this._queueCallback(si,this.tip,this._isAnimated())}hide(){if(!this._isShown()||wi.trigger(this._element,this.constructor.eventName(Rv)).defaultPrevented)return;if(this._getTipElement().classList.remove(za),"ontouchstart"in document.documentElement)for(let ri of[].concat(...document.body.children))wi.off(ri,"mouseover",Ua);this._activeTrigger[kv]=!1,this._activeTrigger[cc]=!1,this._activeTrigger[ea]=!1,this._isHovered=null;let ni=()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),wi.trigger(this._element,this.constructor.eventName(Iv)))};this._queueCallback(ni,this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return!!this._getTitle()}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(ei){let ti=this._getTemplateFactory(ei).toHtml();if(!ti)return null;ti.classList.remove(lc,za),ti.classList.add(`bs-${this.constructor.NAME}-auto`);let ni=Np(this.constructor.NAME).toString();return ti.setAttribute("id",ni),this._isAnimated()&&ti.classList.add(lc),ti}setContent(ei){this._newContent=ei,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(ei){return this._templateFactory?this._templateFactory.changeContent(ei):this._templateFactory=new yc(sn(Di({},this._config),{content:ei,extraClass:this._resolvePossibleFunction(this._config.customClass)})),this._templateFactory}_getContentForTemplate(){return{[Mv]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(ei){return this.constructor.getOrCreateInstance(ei.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(lc)}_isShown(){return this.tip&&this.tip.classList.contains(za)}_createPopper(ei){let ti=Vn(this._config.placement,[this,ei,this._element]),ni=qv[ti.toUpperCase()];return Js(this._element,ei,this._getPopperConfig(ni))}_getOffset(){let{offset:ei}=this._config;return typeof ei=="string"?ei.split(",").map(ti=>Number.parseInt(ti,10)):typeof ei=="function"?ti=>ei(ti,this._element):ei}_resolvePossibleFunction(ei){return Vn(ei,[this._element])}_getPopperConfig(ei){let ti={placement:ei,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:ni=>{this._getTipElement().setAttribute("data-popper-placement",ni.state.placement)}}]};return Di(Di({},ti),Vn(this._config.popperConfig,[ti]))}_setListeners(){let ei=this._config.trigger.split(" ");for(let ti of ei)if(ti==="click")wi.on(this._element,this.constructor.eventName($v),this._config.selector,ni=>{this._initializeOnDelegatedTarget(ni).toggle()});else if(ti!==Nv){let ni=ti===ea?this.constructor.eventName(Vv):this.constructor.eventName(Bv),ri=ti===ea?this.constructor.eventName(jv):this.constructor.eventName(zv);wi.on(this._element,ni,this._config.selector,oi=>{let si=this._initializeOnDelegatedTarget(oi);si._activeTrigger[oi.type==="focusin"?cc:ea]=!0,si._enter()}),wi.on(this._element,ri,this._config.selector,oi=>{let si=this._initializeOnDelegatedTarget(oi);si._activeTrigger[oi.type==="focusout"?cc:ea]=si._element.contains(oi.relatedTarget),si._leave()})}this._hideModalHandler=()=>{this._element&&this.hide()},wi.on(this._element.closest(Gu),Ku,this._hideModalHandler)}_fixTitle(){let ei=this._element.getAttribute("title");ei&&(!this._element.getAttribute("aria-label")&&!this._element.textContent.trim()&&this._element.setAttribute("aria-label",ei),this._element.setAttribute("data-bs-original-title",ei),this._element.removeAttribute("title"))}_enter(){if(this._isShown()||this._isHovered){this._isHovered=!0;return}this._isHovered=!0,this._setTimeout(()=>{this._isHovered&&this.show()},this._config.delay.show)}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout(()=>{this._isHovered||this.hide()},this._config.delay.hide))}_setTimeout(ei,ti){clearTimeout(this._timeout),this._timeout=setTimeout(ei,ti)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(ei){let ti=mo.getDataAttributes(this._element);for(let ni of Object.keys(ti))Ov.has(ni)&&delete ti[ni];return ei=Di(Di({},ti),typeof ei=="object"&&ei?ei:{}),ei=this._mergeConfigObj(ei),ei=this._configAfterMerge(ei),this._typeCheckConfig(ei),ei}_configAfterMerge(ei){return ei.container=ei.container===!1?document.body:Ao(ei.container),typeof ei.delay=="number"&&(ei.delay={show:ei.delay,hide:ei.delay}),typeof ei.title=="number"&&(ei.title=ei.title.toString()),typeof ei.content=="number"&&(ei.content=ei.content.toString()),ei}_getDelegateConfig(){let ei={};for(let[ti,ni]of Object.entries(this._config))this.constructor.Default[ti]!==ni&&(ei[ti]=ni);return ei.selector=!1,ei.trigger="manual",ei}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(typeof ti[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}};Qr(go);var Yv="popover",Gv=".popover-header",Kv=".popover-body",Qv=sn(Di({},go.Default),{content:"",offset:[0,8],placement:"right",template:'',trigger:"click"}),Xv=sn(Di({},go.DefaultType),{content:"(null|string|element|function)"}),Cs=class ii extends go{static get Default(){return Qv}static get DefaultType(){return Xv}static get NAME(){return Yv}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[Gv]:this._getTitle(),[Kv]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(typeof ti[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}};Qr(Cs);var Jv="scrollspy",Zv="bs.scrollspy",wc=`.${Zv}`,ey=".data-api",ty=`activate${wc}`,Qu=`click${wc}`,iy=`load${wc}${ey}`,ny="dropdown-item",ws="active",ry='[data-bs-spy="scroll"]',uc="[href]",oy=".nav, .list-group",Xu=".nav-link",sy=".nav-item",ay=".list-group-item",ly=`${Xu}, ${sy} > ${Xu}, ${ay}`,cy=".dropdown",uy=".dropdown-toggle",dy={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},fy={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"},Za=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement=getComputedStyle(this._element).overflowY==="visible"?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return dy}static get DefaultType(){return fy}static get NAME(){return Jv}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(let ei of this._observableSections.values())this._observer.observe(ei)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(ei){return ei.target=Ao(ei.target)||document.body,ei.rootMargin=ei.offset?`${ei.offset}px 0px -30%`:ei.rootMargin,typeof ei.threshold=="string"&&(ei.threshold=ei.threshold.split(",").map(ti=>Number.parseFloat(ti))),ei}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(wi.off(this._config.target,Qu),wi.on(this._config.target,Qu,uc,ei=>{let ti=this._observableSections.get(ei.target.hash);if(ti){ei.preventDefault();let ni=this._rootElement||window,ri=ti.offsetTop-this._element.offsetTop;if(ni.scrollTo){ni.scrollTo({top:ri,behavior:"smooth"});return}ni.scrollTop=ri}}))}_getNewObserver(){let ei={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver(ti=>this._observerCallback(ti),ei)}_observerCallback(ei){let ti=si=>this._targetLinks.get(`#${si.target.id}`),ni=si=>{this._previousScrollData.visibleEntryTop=si.target.offsetTop,this._process(ti(si))},ri=(this._rootElement||document.documentElement).scrollTop,oi=ri>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=ri;for(let si of ei){if(!si.isIntersecting){this._activeTarget=null,this._clearActiveClass(ti(si));continue}let ai=si.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(oi&&ai){if(ni(si),!ri)return;continue}!oi&&!ai&&ni(si)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;let ei=Wi.find(uc,this._config.target);for(let ti of ei){if(!ti.hash||Do(ti))continue;let ni=Wi.findOne(decodeURI(ti.hash),this._element);As(ni)&&(this._targetLinks.set(decodeURI(ti.hash),ti),this._observableSections.set(ti.hash,ni))}}_process(ei){this._activeTarget!==ei&&(this._clearActiveClass(this._config.target),this._activeTarget=ei,ei.classList.add(ws),this._activateParents(ei),wi.trigger(this._element,ty,{relatedTarget:ei}))}_activateParents(ei){if(ei.classList.contains(ny)){Wi.findOne(uy,ei.closest(cy)).classList.add(ws);return}for(let ti of Wi.parents(ei,oy))for(let ni of Wi.prev(ti,ly))ni.classList.add(ws)}_clearActiveClass(ei){ei.classList.remove(ws);let ti=Wi.find(`${uc}.${ws}`,ei);for(let ni of ti)ni.classList.remove(ws)}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(ti[ei]===void 0||ei.startsWith("_")||ei==="constructor")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}};wi.on(window,iy,()=>{for(let ii of Wi.find(ry))Za.getOrCreateInstance(ii)});Qr(Za);var hy="tab",py="bs.tab",ns=`.${py}`,my=`hide${ns}`,gy=`hidden${ns}`,vy=`show${ns}`,yy=`shown${ns}`,by=`click${ns}`,_y=`keydown${ns}`,Ey=`load${ns}`,wy="ArrowLeft",Ju="ArrowRight",xy="ArrowUp",Zu="ArrowDown",dc="Home",ed="End",Zo="active",td="fade",fc="show",Ty="dropdown",Dd=".dropdown-toggle",Sy=".dropdown-menu",hc=`:not(${Dd})`,Cy='.list-group, .nav, [role="tablist"]',Ay=".nav-item, .list-group-item",Dy=`.nav-link${hc}, .list-group-item${hc}, [role="tab"]${hc}`,Od='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',pc=`${Dy}, ${Od}`,Oy=`.${Zo}[data-bs-toggle="tab"], .${Zo}[data-bs-toggle="pill"], .${Zo}[data-bs-toggle="list"]`,ts=class ii extends Qn{constructor(ei){super(ei),this._parent=this._element.closest(Cy),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),wi.on(this._element,_y,ti=>this._keydown(ti)))}static get NAME(){return hy}show(){let ei=this._element;if(this._elemIsActive(ei))return;let ti=this._getActiveElem(),ni=ti?wi.trigger(ti,my,{relatedTarget:ei}):null;wi.trigger(ei,vy,{relatedTarget:ti}).defaultPrevented||ni&&ni.defaultPrevented||(this._deactivate(ti,ei),this._activate(ei,ti))}_activate(ei,ti){if(!ei)return;ei.classList.add(Zo),this._activate(Wi.getElementFromSelector(ei));let ni=()=>{if(ei.getAttribute("role")!=="tab"){ei.classList.add(fc);return}ei.removeAttribute("tabindex"),ei.setAttribute("aria-selected",!0),this._toggleDropDown(ei,!0),wi.trigger(ei,yy,{relatedTarget:ti})};this._queueCallback(ni,ei,ei.classList.contains(td))}_deactivate(ei,ti){if(!ei)return;ei.classList.remove(Zo),ei.blur(),this._deactivate(Wi.getElementFromSelector(ei));let ni=()=>{if(ei.getAttribute("role")!=="tab"){ei.classList.remove(fc);return}ei.setAttribute("aria-selected",!1),ei.setAttribute("tabindex","-1"),this._toggleDropDown(ei,!1),wi.trigger(ei,gy,{relatedTarget:ti})};this._queueCallback(ni,ei,ei.classList.contains(td))}_keydown(ei){if(![wy,Ju,xy,Zu,dc,ed].includes(ei.key))return;ei.stopPropagation(),ei.preventDefault();let ti=this._getChildren().filter(ri=>!Do(ri)),ni;if([dc,ed].includes(ei.key))ni=ti[ei.key===dc?0:ti.length-1];else{let ri=[Ju,Zu].includes(ei.key);ni=bc(ti,ei.target,ri,!0)}ni&&(ni.focus({preventScroll:!0}),ii.getOrCreateInstance(ni).show())}_getChildren(){return Wi.find(pc,this._parent)}_getActiveElem(){return this._getChildren().find(ei=>this._elemIsActive(ei))||null}_setInitialAttributes(ei,ti){this._setAttributeIfNotExists(ei,"role","tablist");for(let ni of ti)this._setInitialAttributesOnChild(ni)}_setInitialAttributesOnChild(ei){ei=this._getInnerElement(ei);let ti=this._elemIsActive(ei),ni=this._getOuterElement(ei);ei.setAttribute("aria-selected",ti),ni!==ei&&this._setAttributeIfNotExists(ni,"role","presentation"),ti||ei.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(ei,"role","tab"),this._setInitialAttributesOnTargetPanel(ei)}_setInitialAttributesOnTargetPanel(ei){let ti=Wi.getElementFromSelector(ei);ti&&(this._setAttributeIfNotExists(ti,"role","tabpanel"),ei.id&&this._setAttributeIfNotExists(ti,"aria-labelledby",`${ei.id}`))}_toggleDropDown(ei,ti){let ni=this._getOuterElement(ei);if(!ni.classList.contains(Ty))return;let ri=(oi,si)=>{let ai=Wi.findOne(oi,ni);ai&&ai.classList.toggle(si,ti)};ri(Dd,Zo),ri(Sy,fc),ni.setAttribute("aria-expanded",ti)}_setAttributeIfNotExists(ei,ti,ni){ei.hasAttribute(ti)||ei.setAttribute(ti,ni)}_elemIsActive(ei){return ei.classList.contains(Zo)}_getInnerElement(ei){return ei.matches(pc)?ei:Wi.findOne(pc,ei)}_getOuterElement(ei){return ei.closest(Ay)||ei}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this);if(typeof ei=="string"){if(ti[ei]===void 0||ei.startsWith("_")||ei==="constructor")throw new TypeError(`No method named "${ei}"`);ti[ei]()}})}};wi.on(document,by,Od,function(ii){["A","AREA"].includes(this.tagName)&&ii.preventDefault(),!Do(this)&&ts.getOrCreateInstance(this).show()});wi.on(window,Ey,()=>{for(let ii of Wi.find(Oy))ts.getOrCreateInstance(ii)});Qr(ts);var Ly="toast",My="bs.toast",No=`.${My}`,ky=`mouseover${No}`,Ny=`mouseout${No}`,Ry=`focusin${No}`,Iy=`focusout${No}`,Hy=`hide${No}`,Py=`hidden${No}`,Fy=`show${No}`,$y=`shown${No}`,By="fade",id="hide",Va="show",ja="showing",zy={animation:"boolean",autohide:"boolean",delay:"number"},Vy={animation:!0,autohide:!0,delay:5e3},vo=class ii extends Qn{constructor(ei,ti){super(ei,ti),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return Vy}static get DefaultType(){return zy}static get NAME(){return Ly}show(){if(wi.trigger(this._element,Fy).defaultPrevented)return;this._clearTimeout(),this._config.animation&&this._element.classList.add(By);let ti=()=>{this._element.classList.remove(ja),wi.trigger(this._element,$y),this._maybeScheduleHide()};this._element.classList.remove(id),na(this._element),this._element.classList.add(Va,ja),this._queueCallback(ti,this._element,this._config.animation)}hide(){if(!this.isShown()||wi.trigger(this._element,Hy).defaultPrevented)return;let ti=()=>{this._element.classList.add(id),this._element.classList.remove(ja,Va),wi.trigger(this._element,Py)};this._element.classList.add(ja),this._queueCallback(ti,this._element,this._config.animation)}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(Va),super.dispose()}isShown(){return this._element.classList.contains(Va)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout(()=>{this.hide()},this._config.delay)))}_onInteraction(ei,ti){switch(ei.type){case"mouseover":case"mouseout":{this._hasMouseInteraction=ti;break}case"focusin":case"focusout":{this._hasKeyboardInteraction=ti;break}}if(ti){this._clearTimeout();return}let ni=ei.relatedTarget;this._element===ni||this._element.contains(ni)||this._maybeScheduleHide()}_setListeners(){wi.on(this._element,ky,ei=>this._onInteraction(ei,!0)),wi.on(this._element,Ny,ei=>this._onInteraction(ei,!1)),wi.on(this._element,Ry,ei=>this._onInteraction(ei,!0)),wi.on(this._element,Iy,ei=>this._onInteraction(ei,!1))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(ei){return this.each(function(){let ti=ii.getOrCreateInstance(this,ei);if(typeof ei=="string"){if(typeof ti[ei]=="undefined")throw new TypeError(`No method named "${ei}"`);ti[ei](this)}})}};el(vo);Qr(vo);var FL=cu(Ld());function xc(ii,ei){ii.split(/\s+/).forEach(ti=>{ei(ti)})}var oa=class{constructor(){this._events={}}on(ei,ti){xc(ei,ni=>{let ri=this._events[ni]||[];ri.push(ti),this._events[ni]=ri})}off(ei,ti){var ni=arguments.length;if(ni===0){this._events={};return}xc(ei,ri=>{if(ni===1){delete this._events[ri];return}let oi=this._events[ri];oi!==void 0&&(oi.splice(oi.indexOf(ti),1),this._events[ri]=oi)})}trigger(ei,...ti){var ni=this;xc(ei,ri=>{let oi=ni._events[ri];oi!==void 0&&oi.forEach(si=>{si.apply(ni,ti)})})}};function Tc(ii){return ii.plugins={},class extends ii{constructor(){super(...arguments),this.plugins={names:[],settings:{},requested:{},loaded:{}}}static define(ei,ti){ii.plugins[ei]={name:ei,fn:ti}}initializePlugins(ei){var ti,ni;let ri=this,oi=[];if(Array.isArray(ei))ei.forEach(si=>{typeof si=="string"?oi.push(si):(ri.plugins.settings[si.name]=si.options,oi.push(si.name))});else if(ei)for(ti in ei)ei.hasOwnProperty(ti)&&(ri.plugins.settings[ti]=ei[ti],oi.push(ti));for(;ni=oi.shift();)ri.require(ni)}loadPlugin(ei){var ti=this,ni=ti.plugins,ri=ii.plugins[ei];if(!ii.plugins.hasOwnProperty(ei))throw new Error('Unable to find "'+ei+'" plugin');ni.requested[ei]=!0,ni.loaded[ei]=ri.fn.apply(ti,[ti.plugins.settings[ei]||{}]),ni.names.push(ei)}require(ei){var ti=this,ni=ti.plugins;if(!ti.plugins.loaded.hasOwnProperty(ei)){if(ni.requested[ei])throw new Error('Plugin has circular dependency ("'+ei+'")');ti.loadPlugin(ei)}return ni.loaded[ei]}}}var sa=ii=>(ii=ii.filter(Boolean),ii.length<2?ii[0]||"":qy(ii)==1?"["+ii.join("")+"]":"(?:"+ii.join("|")+")"),Sc=ii=>{if(!jy(ii))return ii.join("");let ei="",ti=0,ni=()=>{ti>1&&(ei+="{"+ti+"}")};return ii.forEach((ri,oi)=>{if(ri===ii[oi-1]){ti++;return}ni(),ei+=ri,ti=1}),ni(),ei},Cc=ii=>{let ei=Array.from(ii);return sa(ei)},jy=ii=>new Set(ii).size!==ii.length,Ro=ii=>(ii+"").replace(/([\$\(\)\*\+\.\?\[\]\^\{\|\}\\])/gu,"\\$1"),qy=ii=>ii.reduce((ei,ti)=>Math.max(ei,Wy(ti)),0),Wy=ii=>Array.from(ii).length;var Ac=ii=>{if(ii.length===1)return[[ii]];let ei=[],ti=ii.substring(1);return Ac(ti).forEach(function(ri){let oi=ri.slice(0);oi[0]=ii.charAt(0)+oi[0],ei.push(oi),oi=ri.slice(0),oi.unshift(ii.charAt(0)),ei.push(oi)}),ei};var Uy=[[0,65535]],Yy="[\u0300-\u036F\xB7\u02BE\u02BC]",tl,Rd,Gy=3,Dc={},Md={"/":"\u2044\u2215",0:"\u07C0",a:"\u2C65\u0250\u0251",aa:"\uA733",ae:"\xE6\u01FD\u01E3",ao:"\uA735",au:"\uA737",av:"\uA739\uA73B",ay:"\uA73D",b:"\u0180\u0253\u0183",c:"\uA73F\u0188\u023C\u2184",d:"\u0111\u0257\u0256\u1D05\u018C\uABB7\u0501\u0266",e:"\u025B\u01DD\u1D07\u0247",f:"\uA77C\u0192",g:"\u01E5\u0260\uA7A1\u1D79\uA77F\u0262",h:"\u0127\u2C68\u2C76\u0265",i:"\u0268\u0131",j:"\u0249\u0237",k:"\u0199\u2C6A\uA741\uA743\uA745\uA7A3",l:"\u0142\u019A\u026B\u2C61\uA749\uA747\uA781\u026D",m:"\u0271\u026F\u03FB",n:"\uA7A5\u019E\u0272\uA791\u1D0E\u043B\u0509",o:"\xF8\u01FF\u0254\u0275\uA74B\uA74D\u1D11",oe:"\u0153",oi:"\u01A3",oo:"\uA74F",ou:"\u0223",p:"\u01A5\u1D7D\uA751\uA753\uA755\u03C1",q:"\uA757\uA759\u024B",r:"\u024D\u027D\uA75B\uA7A7\uA783",s:"\xDF\u023F\uA7A9\uA785\u0282",t:"\u0167\u01AD\u0288\u2C66\uA787",th:"\xFE",tz:"\uA729",u:"\u0289",v:"\u028B\uA75F\u028C",vy:"\uA761",w:"\u2C73",y:"\u01B4\u024F\u1EFF",z:"\u01B6\u0225\u0240\u2C6C\uA763",hv:"\u0195"};for(let ii in Md){let ei=Md[ii]||"";for(let ti=0;ti{tl===void 0&&(tl=eb(ii||Uy))},kd=(ii,ei="NFKD")=>ii.normalize(ei),aa=ii=>Array.from(ii).reduce((ei,ti)=>ei+Xy(ti),""),Xy=ii=>(ii=kd(ii).toLowerCase().replace(Ky,ei=>Dc[ei]||""),kd(ii,"NFC"));function*Jy(ii){for(let[ei,ti]of ii)for(let ni=ei;ni<=ti;ni++){let ri=String.fromCharCode(ni),oi=aa(ri);oi!=ri.toLowerCase()&&(oi.length>Gy||oi.length!=0&&(yield{folded:oi,composed:ri,code_point:ni}))}}var Zy=ii=>{let ei={},ti=(ni,ri)=>{let oi=ei[ni]||new Set,si=new RegExp("^"+Cc(oi)+"$","iu");ri.match(si)||(oi.add(Ro(ri)),ei[ni]=oi)};for(let ni of Jy(ii))ti(ni.folded,ni.folded),ti(ni.folded,ni.composed);return ei},eb=ii=>{let ei=Zy(ii),ti={},ni=[];for(let oi in ei){let si=ei[oi];si&&(ti[oi]=Cc(si)),oi.length>1&&ni.push(Ro(oi))}ni.sort((oi,si)=>si.length-oi.length);let ri=sa(ni);return Rd=new RegExp("^"+ri,"u"),ti},tb=(ii,ei=1)=>{let ti=0;return ii=ii.map(ni=>(tl[ni]&&(ti+=ni.length),tl[ni]||ni)),ti>=ei?Sc(ii):""},ib=(ii,ei=1)=>(ei=Math.max(ei,ii.length-1),sa(Ac(ii).map(ti=>tb(ti,ei)))),Nd=(ii,ei=!0)=>{let ti=ii.length>1?1:0;return sa(ii.map(ni=>{let ri=[],oi=ei?ni.length():ni.length()-1;for(let si=0;si{for(let ti of ei){if(ti.start!=ii.start||ti.end!=ii.end||ti.substrs.join("")!==ii.substrs.join(""))continue;let ni=ii.parts,ri=si=>{for(let ai of ni){if(ai.start===si.start&&ai.substr===si.substr)return!1;if(!(si.length==1||ai.length==1)&&(si.startai.start||ai.startsi.start))return!0}return!1};if(!(ti.parts.filter(ri).length>0))return!0}return!1},il=class ii{constructor(){en(this,"parts");en(this,"substrs");en(this,"start");en(this,"end");this.parts=[],this.substrs=[],this.start=0,this.end=0}add(ei){ei&&(this.parts.push(ei),this.substrs.push(ei.substr),this.start=Math.min(ei.start,this.start),this.end=Math.max(ei.end,this.end))}last(){return this.parts[this.parts.length-1]}length(){return this.parts.length}clone(ei,ti){let ni=new ii,ri=JSON.parse(JSON.stringify(this.parts)),oi=ri.pop();for(let li of ri)ni.add(li);let si=ti.substr.substring(0,ei-oi.start),ai=si.length;return ni.add({start:oi.start,end:oi.start+ai,length:ai,substr:si}),ni}},Id=ii=>{Qy(),ii=aa(ii);let ei="",ti=[new il];for(let ni=0;ni0){li=li.sort((ci,di)=>ci.length()-di.length());for(let ci of li)nb(ci,ti)||ti.push(ci);continue}if(ni>0&&ui.size==1&&!ui.has("3")){ei+=Nd(ti,!1);let ci=new il,di=ti[0];di&&ci.add(di.last()),ti=[ci]}}return ei+=Nd(ti,!0),ei};var Hd=(ii,ei)=>{if(ii)return ii[ei]},Pd=(ii,ei)=>{if(ii){for(var ti,ni=ei.split(".");(ti=ni.shift())&&(ii=ii[ti]););return ii}},nl=(ii,ei,ti)=>{var ni,ri;return!ii||(ii=ii+"",ei.regex==null)||(ri=ii.search(ei.regex),ri===-1)?0:(ni=ei.string.length/ii.length,ri===0&&(ni+=.5),ni*ti)},rl=(ii,ei)=>{var ti=ii[ei];if(typeof ti=="function")return ti;ti&&!Array.isArray(ti)&&(ii[ei]=[ti])},la=(ii,ei)=>{if(Array.isArray(ii))ii.forEach(ei);else for(var ti in ii)ii.hasOwnProperty(ti)&&ei(ii[ti],ti)},Fd=(ii,ei)=>typeof ii=="number"&&typeof ei=="number"?ii>ei?1:iiei?1:ei>ii?-1:0);var ol=class{constructor(ei,ti){en(this,"items");en(this,"settings");this.items=ei,this.settings=ti||{diacritics:!0}}tokenize(ei,ti,ni){if(!ei||!ei.length)return[];let ri=[],oi=ei.split(/\s+/);var si;return ni&&(si=new RegExp("^("+Object.keys(ni).map(Ro).join("|")+"):(.*)$")),oi.forEach(ai=>{let li,ui=null,ci=null;si&&(li=ai.match(si))&&(ui=li[1],ai=li[2]),ai.length>0&&(this.settings.diacritics?ci=Id(ai)||null:ci=Ro(ai),ci&&ti&&(ci="\\b"+ci)),ri.push({string:ai,regex:ci?new RegExp(ci,"iu"):null,field:ui})}),ri}getScoreFunction(ei,ti){var ni=this.prepareSearch(ei,ti);return this._getScoreFunction(ni)}_getScoreFunction(ei){let ti=ei.tokens,ni=ti.length;if(!ni)return function(){return 0};let ri=ei.options.fields,oi=ei.weights,si=ri.length,ai=ei.getAttrFn;if(!si)return function(){return 1};let li=function(){return si===1?function(ui,ci){let di=ri[0].field;return nl(ai(ci,di),ui,oi[di]||1)}:function(ui,ci){var di=0;if(ui.field){let pi=ai(ci,ui.field);!ui.regex&&pi?di+=1/si:di+=nl(pi,ui,1)}else la(oi,(pi,yi)=>{di+=nl(ai(ci,yi),ui,pi)});return di/si}}();return ni===1?function(ui){return li(ti[0],ui)}:ei.options.conjunction==="and"?function(ui){var ci,di=0;for(let pi of ti){if(ci=li(pi,ui),ci<=0)return 0;di+=ci}return di/ni}:function(ui){var ci=0;return la(ti,di=>{ci+=li(di,ui)}),ci/ni}}getSortFunction(ei,ti){var ni=this.prepareSearch(ei,ti);return this._getSortFunction(ni)}_getSortFunction(ei){var ti,ni=[];let ri=this,oi=ei.options,si=!ei.query&&oi.sort_empty?oi.sort_empty:oi.sort;if(typeof si=="function")return si.bind(this);let ai=function(ui,ci){return ui==="$score"?ci.score:ei.getAttrFn(ri.items[ci.id],ui)};if(si)for(let ui of si)(ei.query||ui.field!=="$score")&&ni.push(ui);if(ei.query){ti=!0;for(let ui of ni)if(ui.field==="$score"){ti=!1;break}ti&&ni.unshift({field:"$score",direction:"desc"})}else ni=ni.filter(ui=>ui.field!=="$score");return ni.length?function(ui,ci){var di,pi;for(let yi of ni)if(pi=yi.field,di=(yi.direction==="desc"?-1:1)*Fd(ai(pi,ui),ai(pi,ci)),di)return di;return 0}:null}prepareSearch(ei,ti){let ni={};var ri=Object.assign({},ti);if(rl(ri,"sort"),rl(ri,"sort_empty"),ri.fields){rl(ri,"fields");let oi=[];ri.fields.forEach(si=>{typeof si=="string"&&(si={field:si,weight:1}),oi.push(si),ni[si.field]="weight"in si?si.weight:1}),ri.fields=oi}return{options:ri,query:ei.toLowerCase().trim(),tokens:this.tokenize(ei,ri.respect_word_boundaries,ni),total:0,items:[],weights:ni,getAttrFn:ri.nesting?Pd:Hd}}search(ei,ti){var ni=this,ri,oi;oi=this.prepareSearch(ei,ti),ti=oi.options,ei=oi.query;let si=ti.score||ni._getScoreFunction(oi);ei.length?la(ni.items,(li,ui)=>{ri=si(li),(ti.filter===!1||ri>0)&&oi.items.push({score:ri,id:ui})}):la(ni.items,(li,ui)=>{oi.items.push({score:1,id:ui})});let ai=ni._getSortFunction(oi);return ai&&oi.items.sort(ai),oi.total=oi.items.length,typeof ti.limit=="number"&&(oi.items=oi.items.slice(0,ti.limit)),oi}};var Xn=ii=>typeof ii=="undefined"||ii===null?null:ca(ii),ca=ii=>typeof ii=="boolean"?ii?"1":"0":ii+"",sl=ii=>(ii+"").replace(/&/g,"&").replace(//g,">").replace(/"/g,"""),$d=(ii,ei)=>ei>0?window.setTimeout(ii,ei):(ii.call(null),null),Bd=(ii,ei)=>{var ti;return function(ni,ri){var oi=this;ti&&(oi.loading=Math.max(oi.loading-1,0),clearTimeout(ti)),ti=setTimeout(function(){ti=null,oi.loadedSearches[ni]=!0,ii.call(oi,ni,ri)},ei)}},Oc=(ii,ei,ti)=>{var ni,ri=ii.trigger,oi={};ii.trigger=function(){var si=arguments[0];if(ei.indexOf(si)!==-1)oi[si]=arguments;else return ri.apply(ii,arguments)},ti.apply(ii,[]),ii.trigger=ri;for(ni of ei)ni in oi&&ri.apply(ii,oi[ni])},zd=ii=>({start:ii.selectionStart||0,length:(ii.selectionEnd||0)-(ii.selectionStart||0)}),fn=(ii,ei=!1)=>{ii&&(ii.preventDefault(),ei&&ii.stopPropagation())},Nn=(ii,ei,ti,ni)=>{ii.addEventListener(ei,ti,ni)},Io=(ii,ei)=>{if(!ei||!ei[ii])return!1;var ti=(ei.altKey?1:0)+(ei.ctrlKey?1:0)+(ei.shiftKey?1:0)+(ei.metaKey?1:0);return ti===1},al=(ii,ei)=>{let ti=ii.getAttribute("id");return ti||(ii.setAttribute("id",ei),ei)},Lc=ii=>ii.replace(/[\\"']/g,"\\$&"),Ho=(ii,ei)=>{ei&&ii.append(ei)},En=(ii,ei)=>{if(Array.isArray(ii))ii.forEach(ei);else for(var ti in ii)ii.hasOwnProperty(ti)&&ei(ii[ti],ti)};var no=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(Mc(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},Mc=ii=>typeof ii=="string"&&ii.indexOf("<")>-1,Vd=ii=>ii.replace(/['"\\]/g,"\\$&"),ll=(ii,ei)=>{var ti=document.createEvent("HTMLEvents");ti.initEvent(ei,!0,!1),ii.dispatchEvent(ti)},ua=(ii,ei)=>{Object.assign(ii.style,ei)},jn=(ii,...ei)=>{var ti=jd(ei);ii=qd(ii),ii.map(ni=>{ti.map(ri=>{ni.classList.add(ri)})})},bo=(ii,...ei)=>{var ti=jd(ei);ii=qd(ii),ii.map(ni=>{ti.map(ri=>{ni.classList.remove(ri)})})},jd=ii=>{var ei=[];return En(ii,ti=>{typeof ti=="string"&&(ti=ti.trim().split(/[\t\n\f\r\s]/)),Array.isArray(ti)&&(ei=ei.concat(ti))}),ei.filter(Boolean)},qd=ii=>(Array.isArray(ii)||(ii=[ii]),ii),cl=(ii,ei,ti)=>{if(!(ti&&!ti.contains(ii)))for(;ii&&ii.matches;){if(ii.matches(ei))return ii;ii=ii.parentNode}},kc=(ii,ei=0)=>ei>0?ii[ii.length-1]:ii[0],Wd=ii=>Object.keys(ii).length===0,Nc=(ii,ei)=>{if(!ii)return-1;ei=ei||ii.nodeName;for(var ti=0;ii=ii.previousElementSibling;)ii.matches(ei)&&ti++;return ti},an=(ii,ei)=>{En(ei,(ti,ni)=>{ti==null?ii.removeAttribute(ni):ii.setAttribute(ni,""+ti)})},da=(ii,ei)=>{ii.parentNode&&ii.parentNode.replaceChild(ei,ii)};var Ud=(ii,ei)=>{if(ei===null)return;if(typeof ei=="string"){if(!ei.length)return;ei=new RegExp(ei,"i")}let ti=oi=>{var si=oi.data.match(ei);if(si&&oi.data.length>0){var ai=document.createElement("span");ai.className="highlight";var li=oi.splitText(si.index);li.splitText(si[0].length);var ui=li.cloneNode(!0);return ai.appendChild(ui),da(li,ai),1}return 0},ni=oi=>{oi.nodeType===1&&oi.childNodes&&!/(script|style)/i.test(oi.tagName)&&(oi.className!=="highlight"||oi.tagName!=="SPAN")&&Array.from(oi.childNodes).forEach(si=>{ri(si)})},ri=oi=>oi.nodeType===3?ti(oi):(ni(oi),0);ri(ii)},Yd=ii=>{var ei=ii.querySelectorAll("span.highlight");Array.prototype.forEach.call(ei,function(ti){var ni=ti.parentNode;ni.replaceChild(ti.firstChild,ti),ni.normalize()})};var rb=typeof navigator=="undefined"?!1:/Mac/.test(navigator.userAgent),fa=rb?"metaKey":"ctrlKey";var Rc={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(ii){return ii.length>0},render:{}};function ul(ii,ei){var ti=Object.assign({},Rc,ei),ni=ti.dataAttr,ri=ti.labelField,oi=ti.valueField,si=ti.disabledField,ai=ti.optgroupField,li=ti.optgroupLabelField,ui=ti.optgroupValueField,ci=ii.tagName.toLowerCase(),di=ii.getAttribute("placeholder")||ii.getAttribute("data-placeholder");if(!di&&!ti.allowEmptyOption){let vi=ii.querySelector('option[value=""]');vi&&(di=vi.textContent)}var pi={placeholder:di,options:[],optgroups:[],items:[],maxItems:null},yi=()=>{var vi,Ei=pi.options,Ci={},xi=1;let Li=0;var Oi=ki=>{var Mi=Object.assign({},ki.dataset),Ai=ni&&Mi[ni];return typeof Ai=="string"&&Ai.length&&(Mi=Object.assign(Mi,JSON.parse(Ai))),Mi},zi=(ki,Mi)=>{var Ai=Xn(ki.value);if(Ai!=null&&!(!Ai&&!ti.allowEmptyOption)){if(Ci.hasOwnProperty(Ai)){if(Mi){var qi=Ci[Ai][ai];qi?Array.isArray(qi)?qi.push(Mi):Ci[Ai][ai]=[qi,Mi]:Ci[Ai][ai]=Mi}}else{var Si=Oi(ki);Si[ri]=Si[ri]||ki.textContent,Si[oi]=Si[oi]||Ai,Si[si]=Si[si]||ki.disabled,Si[ai]=Si[ai]||Mi,Si.$option=ki,Si.$order=Si.$order||++Li,Ci[Ai]=Si,Ei.push(Si)}ki.selected&&pi.items.push(Ai)}},Vi=ki=>{var Mi,Ai;Ai=Oi(ki),Ai[li]=Ai[li]||ki.getAttribute("label")||"",Ai[ui]=Ai[ui]||xi++,Ai[si]=Ai[si]||ki.disabled,Ai.$order=Ai.$order||++Li,pi.optgroups.push(Ai),Mi=Ai[ui],En(ki.children,qi=>{zi(qi,Mi)})};pi.maxItems=ii.hasAttribute("multiple")?null:1,En(ii.children,ki=>{vi=ki.tagName.toLowerCase(),vi==="optgroup"?Vi(ki):vi==="option"&&zi(ki)})},gi=()=>{let vi=ii.getAttribute(ni);if(vi)pi.options=JSON.parse(vi),En(pi.options,Ci=>{pi.items.push(Ci[oi])});else{var Ei=ii.value.trim()||"";if(!ti.allowEmptyOption&&!Ei.length)return;let Ci=Ei.split(ti.delimiter);En(Ci,xi=>{let Li={};Li[ri]=xi,Li[oi]=xi,pi.options.push(Li)}),pi.items=Ci}};return ci==="select"?yi():gi(),Object.assign({},Rc,pi,ei)}var Qd=0,Sn=class extends Tc(oa){constructor(ei,ti){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,Qd++;var ni,ri=no(ei);if(ri.tomselect)throw new Error("Tom Select already initialized on this element");ri.tomselect=this;var oi=window.getComputedStyle&&window.getComputedStyle(ri,null);ni=oi.getPropertyValue("direction");let si=ul(ri,ti);this.settings=si,this.input=ri,this.tabIndex=ri.tabIndex||0,this.is_select_tag=ri.tagName.toLowerCase()==="select",this.rtl=/rtl/i.test(ni),this.inputId=al(ri,"tomselect-"+Qd),this.isRequired=ri.required,this.sifter=new ol(this.options,{diacritics:si.diacritics}),si.mode=si.mode||(si.maxItems===1?"single":"multi"),typeof si.hideSelected!="boolean"&&(si.hideSelected=si.mode==="multi"),typeof si.hidePlaceholder!="boolean"&&(si.hidePlaceholder=si.mode!=="multi");var ai=si.createFilter;typeof ai!="function"&&(typeof ai=="string"&&(ai=new RegExp(ai)),ai instanceof RegExp?si.createFilter=Ei=>ai.test(Ei):si.createFilter=Ei=>this.settings.duplicates||!this.options[Ei]),this.initializePlugins(si.plugins),this.setupCallbacks(),this.setupTemplates();let li=no("
"),ui=no("
"),ci=this._render("dropdown"),di=no('
'),pi=this.input.getAttribute("class")||"",yi=si.mode;var gi;if(jn(li,si.wrapperClass,pi,yi),jn(ui,si.controlClass),Ho(li,ui),jn(ci,si.dropdownClass,yi),si.copyClassesToDropdown&&jn(ci,pi),jn(di,si.dropdownContentClass),Ho(ci,di),no(si.dropdownParent||li).appendChild(ci),Mc(si.controlInput)){gi=no(si.controlInput);var vi=["autocorrect","autocapitalize","autocomplete","spellcheck"];En(vi,Ei=>{ri.getAttribute(Ei)&&an(gi,{[Ei]:ri.getAttribute(Ei)})}),gi.tabIndex=-1,ui.appendChild(gi),this.focus_node=gi}else si.controlInput?(gi=no(si.controlInput),this.focus_node=gi):(gi=no(""),this.focus_node=ui);this.wrapper=li,this.dropdown=ci,this.dropdown_content=di,this.control=ui,this.control_input=gi,this.setup()}setup(){let ei=this,ti=ei.settings,ni=ei.control_input,ri=ei.dropdown,oi=ei.dropdown_content,si=ei.wrapper,ai=ei.control,li=ei.input,ui=ei.focus_node,ci={passive:!0},di=ei.inputId+"-ts-dropdown";an(oi,{id:di}),an(ui,{role:"combobox","aria-haspopup":"listbox","aria-expanded":"false","aria-controls":di});let pi=al(ui,ei.inputId+"-ts-control"),yi="label[for='"+Vd(ei.inputId)+"']",gi=document.querySelector(yi),vi=ei.focus.bind(ei);if(gi){Nn(gi,"click",vi),an(gi,{for:pi});let xi=al(gi,ei.inputId+"-ts-label");an(ui,{"aria-labelledby":xi}),an(oi,{"aria-labelledby":xi})}if(si.style.width=li.style.width,ei.plugins.names.length){let xi="plugin-"+ei.plugins.names.join(" plugin-");jn([si,ri],xi)}(ti.maxItems===null||ti.maxItems>1)&&ei.is_select_tag&&an(li,{multiple:"multiple"}),ti.placeholder&&an(ni,{placeholder:ti.placeholder}),!ti.splitOn&&ti.delimiter&&(ti.splitOn=new RegExp("\\s*"+Ro(ti.delimiter)+"+\\s*")),ti.load&&ti.loadThrottle&&(ti.load=Bd(ti.load,ti.loadThrottle)),Nn(ri,"mousemove",()=>{ei.ignoreHover=!1}),Nn(ri,"mouseenter",xi=>{var Li=cl(xi.target,"[data-selectable]",ri);Li&&ei.onOptionHover(xi,Li)},{capture:!0}),Nn(ri,"click",xi=>{let Li=cl(xi.target,"[data-selectable]");Li&&(ei.onOptionSelect(xi,Li),fn(xi,!0))}),Nn(ai,"click",xi=>{var Li=cl(xi.target,"[data-ts-item]",ai);if(Li&&ei.onItemSelect(xi,Li)){fn(xi,!0);return}ni.value==""&&(ei.onClick(),fn(xi,!0))}),Nn(ui,"keydown",xi=>ei.onKeyDown(xi)),Nn(ni,"keypress",xi=>ei.onKeyPress(xi)),Nn(ni,"input",xi=>ei.onInput(xi)),Nn(ui,"blur",xi=>ei.onBlur(xi)),Nn(ui,"focus",xi=>ei.onFocus(xi)),Nn(ni,"paste",xi=>ei.onPaste(xi));let Ei=xi=>{let Li=xi.composedPath()[0];if(!si.contains(Li)&&!ri.contains(Li)){ei.isFocused&&ei.blur(),ei.inputState();return}Li==ni&&ei.isOpen?xi.stopPropagation():fn(xi,!0)},Ci=()=>{ei.isOpen&&ei.positionDropdown()};Nn(document,"mousedown",Ei),Nn(window,"scroll",Ci,ci),Nn(window,"resize",Ci,ci),this._destroy=()=>{document.removeEventListener("mousedown",Ei),window.removeEventListener("scroll",Ci),window.removeEventListener("resize",Ci),gi&&gi.removeEventListener("click",vi)},this.revertSettings={innerHTML:li.innerHTML,tabIndex:li.tabIndex},li.tabIndex=-1,li.insertAdjacentElement("afterend",ei.wrapper),ei.sync(!1),ti.items=[],delete ti.optgroups,delete ti.options,Nn(li,"invalid",()=>{ei.isValid&&(ei.isValid=!1,ei.isInvalid=!0,ei.refreshState())}),ei.updateOriginalInput(),ei.refreshItems(),ei.close(!1),ei.inputState(),ei.isSetup=!0,li.disabled?ei.disable():li.readOnly?ei.setReadOnly(!0):ei.enable(),ei.on("change",this.onChange),jn(li,"tomselected","ts-hidden-accessible"),ei.trigger("initialize"),ti.preload===!0&&ei.preload()}setupOptions(ei=[],ti=[]){this.addOptions(ei),En(ti,ni=>{this.registerOptionGroup(ni)})}setupTemplates(){var ei=this,ti=ei.settings.labelField,ni=ei.settings.optgroupLabelField,ri={optgroup:oi=>{let si=document.createElement("div");return si.className="optgroup",si.appendChild(oi.options),si},optgroup_header:(oi,si)=>'
'+si(oi[ni])+"
",option:(oi,si)=>"
"+si(oi[ti])+"
",item:(oi,si)=>"
"+si(oi[ti])+"
",option_create:(oi,si)=>'
Add '+si(oi.input)+"
",no_results:()=>'
No results found
',loading:()=>'
',not_loading:()=>{},dropdown:()=>"
"};ei.settings.render=Object.assign({},ri,ei.settings.render)}setupCallbacks(){var ei,ti,ni={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(ei in ni)ti=this.settings[ni[ei]],ti&&this.on(ei,ti)}sync(ei=!0){let ti=this,ni=ei?ul(ti.input,{delimiter:ti.settings.delimiter}):ti.settings;ti.setupOptions(ni.options,ni.optgroups),ti.setValue(ni.items||[],!0),ti.lastQuery=null}onClick(){var ei=this;if(ei.activeItems.length>0){ei.clearActiveItems(),ei.focus();return}ei.isFocused&&ei.isOpen?ei.blur():ei.focus()}onMouseDown(){}onChange(){ll(this.input,"input"),ll(this.input,"change")}onPaste(ei){var ti=this;if(ti.isInputHidden||ti.isLocked){fn(ei);return}ti.settings.splitOn&&setTimeout(()=>{var ni=ti.inputValue();if(ni.match(ti.settings.splitOn)){var ri=ni.trim().split(ti.settings.splitOn);En(ri,oi=>{Xn(oi)&&(this.options[oi]?ti.addItem(oi):ti.createItem(oi))})}},0)}onKeyPress(ei){var ti=this;if(ti.isLocked){fn(ei);return}var ni=String.fromCharCode(ei.keyCode||ei.which);if(ti.settings.create&&ti.settings.mode==="multi"&&ni===ti.settings.delimiter){ti.createItem(),fn(ei);return}}onKeyDown(ei){var ti=this;if(ti.ignoreHover=!0,ti.isLocked){ei.keyCode!==9&&fn(ei);return}switch(ei.keyCode){case 65:if(Io(fa,ei)&&ti.control_input.value==""){fn(ei),ti.selectAll();return}break;case 27:ti.isOpen&&(fn(ei,!0),ti.close()),ti.clearActiveItems();return;case 40:if(!ti.isOpen&&ti.hasOptions)ti.open();else if(ti.activeOption){let ni=ti.getAdjacent(ti.activeOption,1);ni&&ti.setActiveOption(ni)}fn(ei);return;case 38:if(ti.activeOption){let ni=ti.getAdjacent(ti.activeOption,-1);ni&&ti.setActiveOption(ni)}fn(ei);return;case 13:ti.canSelect(ti.activeOption)?(ti.onOptionSelect(ei,ti.activeOption),fn(ei)):ti.settings.create&&ti.createItem()?fn(ei):document.activeElement==ti.control_input&&ti.isOpen&&fn(ei);return;case 37:ti.advanceSelection(-1,ei);return;case 39:ti.advanceSelection(1,ei);return;case 9:ti.settings.selectOnTab&&(ti.canSelect(ti.activeOption)&&(ti.onOptionSelect(ei,ti.activeOption),fn(ei)),ti.settings.create&&ti.createItem()&&fn(ei));return;case 8:case 46:ti.deleteSelection(ei);return}ti.isInputHidden&&!Io(fa,ei)&&fn(ei)}onInput(ei){if(this.isLocked)return;let ti=this.inputValue();if(this.lastValue!==ti){if(this.lastValue=ti,ti==""){this._onInput();return}this.refreshTimeout&&window.clearTimeout(this.refreshTimeout),this.refreshTimeout=$d(()=>{this.refreshTimeout=null,this._onInput()},this.settings.refreshThrottle)}}_onInput(){let ei=this.lastValue;this.settings.shouldLoad.call(this,ei)&&this.load(ei),this.refreshOptions(),this.trigger("type",ei)}onOptionHover(ei,ti){this.ignoreHover||this.setActiveOption(ti,!1)}onFocus(ei){var ti=this,ni=ti.isFocused;if(ti.isDisabled||ti.isReadOnly){ti.blur(),fn(ei);return}ti.ignoreFocus||(ti.isFocused=!0,ti.settings.preload==="focus"&&ti.preload(),ni||ti.trigger("focus"),ti.activeItems.length||(ti.inputState(),ti.refreshOptions(!!ti.settings.openOnFocus)),ti.refreshState())}onBlur(ei){if(document.hasFocus()!==!1){var ti=this;if(ti.isFocused){ti.isFocused=!1,ti.ignoreFocus=!1;var ni=()=>{ti.close(),ti.setActiveItem(),ti.setCaret(ti.items.length),ti.trigger("blur")};ti.settings.create&&ti.settings.createOnBlur?ti.createItem(null,ni):ni()}}}onOptionSelect(ei,ti){var ni,ri=this;ti.parentElement&&ti.parentElement.matches("[data-disabled]")||(ti.classList.contains("create")?ri.createItem(null,()=>{ri.settings.closeAfterSelect&&ri.close()}):(ni=ti.dataset.value,typeof ni!="undefined"&&(ri.lastQuery=null,ri.addItem(ni),ri.settings.closeAfterSelect&&ri.close(),!ri.settings.hideSelected&&ei.type&&/click/.test(ei.type)&&ri.setActiveOption(ti))))}canSelect(ei){return!!(this.isOpen&&ei&&this.dropdown_content.contains(ei))}onItemSelect(ei,ti){var ni=this;return!ni.isLocked&&ni.settings.mode==="multi"?(fn(ei),ni.setActiveItem(ti,ei),!0):!1}canLoad(ei){return!(!this.settings.load||this.loadedSearches.hasOwnProperty(ei))}load(ei){let ti=this;if(!ti.canLoad(ei))return;jn(ti.wrapper,ti.settings.loadingClass),ti.loading++;let ni=ti.loadCallback.bind(ti);ti.settings.load.call(ti,ei,ni)}loadCallback(ei,ti){let ni=this;ni.loading=Math.max(ni.loading-1,0),ni.lastQuery=null,ni.clearActiveOption(),ni.setupOptions(ei,ti),ni.refreshOptions(ni.isFocused&&!ni.isInputHidden),ni.loading||bo(ni.wrapper,ni.settings.loadingClass),ni.trigger("load",ei,ti)}preload(){var ei=this.wrapper.classList;ei.contains("preloaded")||(ei.add("preloaded"),this.load(""))}setTextboxValue(ei=""){var ti=this.control_input,ni=ti.value!==ei;ni&&(ti.value=ei,ll(ti,"update"),this.lastValue=ei)}getValue(){return this.is_select_tag&&this.input.hasAttribute("multiple")?this.items:this.items.join(this.settings.delimiter)}setValue(ei,ti){var ni=ti?[]:["change"];Oc(this,ni,()=>{this.clear(ti),this.addItems(ei,ti)})}setMaxItems(ei){ei===0&&(ei=null),this.settings.maxItems=ei,this.refreshState()}setActiveItem(ei,ti){var ni=this,ri,oi,si,ai,li,ui;if(ni.settings.mode!=="single"){if(!ei){ni.clearActiveItems(),ni.isFocused&&ni.inputState();return}if(ri=ti&&ti.type.toLowerCase(),ri==="click"&&Io("shiftKey",ti)&&ni.activeItems.length){for(ui=ni.getLastActive(),si=Array.prototype.indexOf.call(ni.control.children,ui),ai=Array.prototype.indexOf.call(ni.control.children,ei),si>ai&&(li=si,si=ai,ai=li),oi=si;oi<=ai;oi++)ei=ni.control.children[oi],ni.activeItems.indexOf(ei)===-1&&ni.setActiveItemClass(ei);fn(ti)}else ri==="click"&&Io(fa,ti)||ri==="keydown"&&Io("shiftKey",ti)?ei.classList.contains("active")?ni.removeActiveItem(ei):ni.setActiveItemClass(ei):(ni.clearActiveItems(),ni.setActiveItemClass(ei));ni.inputState(),ni.isFocused||ni.focus()}}setActiveItemClass(ei){let ti=this,ni=ti.control.querySelector(".last-active");ni&&bo(ni,"last-active"),jn(ei,"active last-active"),ti.trigger("item_select",ei),ti.activeItems.indexOf(ei)==-1&&ti.activeItems.push(ei)}removeActiveItem(ei){var ti=this.activeItems.indexOf(ei);this.activeItems.splice(ti,1),bo(ei,"active")}clearActiveItems(){bo(this.activeItems,"active"),this.activeItems=[]}setActiveOption(ei,ti=!0){ei!==this.activeOption&&(this.clearActiveOption(),ei&&(this.activeOption=ei,an(this.focus_node,{"aria-activedescendant":ei.getAttribute("id")}),an(ei,{"aria-selected":"true"}),jn(ei,"active"),ti&&this.scrollToOption(ei)))}scrollToOption(ei,ti){if(!ei)return;let ni=this.dropdown_content,ri=ni.clientHeight,oi=ni.scrollTop||0,si=ei.offsetHeight,ai=ei.getBoundingClientRect().top-ni.getBoundingClientRect().top+oi;ai+si>ri+oi?this.scroll(ai-ri+si,ti):ai{ei.setActiveItemClass(ni)}))}inputState(){var ei=this;ei.control.contains(ei.control_input)&&(an(ei.control_input,{placeholder:ei.settings.placeholder}),ei.activeItems.length>0||!ei.isFocused&&ei.settings.hidePlaceholder&&ei.items.length>0?(ei.setTextboxValue(),ei.isInputHidden=!0):(ei.settings.hidePlaceholder&&ei.items.length>0&&an(ei.control_input,{placeholder:""}),ei.isInputHidden=!1),ei.wrapper.classList.toggle("input-hidden",ei.isInputHidden))}inputValue(){return this.control_input.value.trim()}focus(){var ei=this;ei.isDisabled||ei.isReadOnly||(ei.ignoreFocus=!0,ei.control_input.offsetWidth?ei.control_input.focus():ei.focus_node.focus(),setTimeout(()=>{ei.ignoreFocus=!1,ei.onFocus()},0))}blur(){this.focus_node.blur(),this.onBlur()}getScoreFunction(ei){return this.sifter.getScoreFunction(ei,this.getSearchOptions())}getSearchOptions(){var ei=this.settings,ti=ei.sortField;return typeof ei.sortField=="string"&&(ti=[{field:ei.sortField}]),{fields:ei.searchField,conjunction:ei.searchConjunction,sort:ti,nesting:ei.nesting}}search(ei){var ti,ni,ri=this,oi=this.getSearchOptions();if(ri.settings.score&&(ni=ri.settings.score.call(ri,ei),typeof ni!="function"))throw new Error('Tom Select "score" setting must be a function that returns a function');return ei!==ri.lastQuery?(ri.lastQuery=ei,ti=ri.sifter.search(ei,Object.assign(oi,{score:ni})),ri.currentResults=ti):ti=Object.assign({},ri.currentResults),ri.settings.hideSelected&&(ti.items=ti.items.filter(si=>{let ai=Xn(si.id);return!(ai&&ri.items.indexOf(ai)!==-1)})),ti}refreshOptions(ei=!0){var ti,ni,ri,oi,si,ai,li,ui,ci,di;let pi={},yi=[];var gi=this,vi=gi.inputValue();let Ei=vi===gi.lastQuery||vi==""&&gi.lastQuery==null;var Ci=gi.search(vi),xi=null,Li=gi.settings.shouldOpen||!1,Oi=gi.dropdown_content;Ei&&(xi=gi.activeOption,xi&&(ci=xi.closest("[data-group]"))),oi=Ci.items.length,typeof gi.settings.maxOptions=="number"&&(oi=Math.min(oi,gi.settings.maxOptions)),oi>0&&(Li=!0);let zi=(ki,Mi)=>{let Ai=pi[ki];if(Ai!==void 0){let Si=yi[Ai];if(Si!==void 0)return[Ai,Si.fragment]}let qi=document.createDocumentFragment();return Ai=yi.length,yi.push({fragment:qi,order:Mi,optgroup:ki}),[Ai,qi]};for(ti=0;ti0&&(Si=Si.cloneNode(!0),an(Si,{id:Ai.$id+"-clone-"+ni,"aria-selected":null}),Si.classList.add("ts-cloned"),bo(Si,"active"),gi.activeOption&&gi.activeOption.dataset.value==Mi&&ci&&ci.dataset.group===si.toString()&&(xi=Si)),rn.appendChild(Si),si!=""&&(pi[si]=gn)}}gi.settings.lockOptgroupOrder&&yi.sort((ki,Mi)=>ki.order-Mi.order),li=document.createDocumentFragment(),En(yi,ki=>{let Mi=ki.fragment,Ai=ki.optgroup;if(!Mi||!Mi.children.length)return;let qi=gi.optgroups[Ai];if(qi!==void 0){let Si=document.createDocumentFragment(),Qi=gi.render("optgroup_header",qi);Ho(Si,Qi),Ho(Si,Mi);let Ji=gi.render("optgroup",{group:qi,options:Si});Ho(li,Ji)}else Ho(li,Mi)}),Oi.innerHTML="",Ho(Oi,li),gi.settings.highlight&&(Yd(Oi),Ci.query.length&&Ci.tokens.length&&En(Ci.tokens,ki=>{Ud(Oi,ki.regex)}));var Vi=ki=>{let Mi=gi.render(ki,{input:vi});return Mi&&(Li=!0,Oi.insertBefore(Mi,Oi.firstChild)),Mi};if(gi.loading?Vi("loading"):gi.settings.shouldLoad.call(gi,vi)?Ci.items.length===0&&Vi("no_results"):Vi("not_loading"),ui=gi.canCreate(vi),ui&&(di=Vi("option_create")),gi.hasOptions=Ci.items.length>0||ui,Li){if(Ci.items.length>0){if(!xi&&gi.settings.mode==="single"&&gi.items[0]!=null&&(xi=gi.getOption(gi.items[0])),!Oi.contains(xi)){let ki=0;di&&!gi.settings.addPrecedence&&(ki=1),xi=gi.selectable()[ki]}}else di&&(xi=di);ei&&!gi.isOpen&&(gi.open(),gi.scrollToOption(xi,"auto")),gi.setActiveOption(xi)}else gi.clearActiveOption(),ei&&gi.isOpen&&gi.close(!1)}selectable(){return this.dropdown_content.querySelectorAll("[data-selectable]")}addOption(ei,ti=!1){let ni=this;if(Array.isArray(ei))return ni.addOptions(ei,ti),!1;let ri=Xn(ei[ni.settings.valueField]);return ri===null||ni.options.hasOwnProperty(ri)?!1:(ei.$order=ei.$order||++ni.order,ei.$id=ni.inputId+"-opt-"+ei.$order,ni.options[ri]=ei,ni.lastQuery=null,ti&&(ni.userOptions[ri]=ti,ni.trigger("option_add",ri,ei)),ri)}addOptions(ei,ti=!1){En(ei,ni=>{this.addOption(ni,ti)})}registerOption(ei){return this.addOption(ei)}registerOptionGroup(ei){var ti=Xn(ei[this.settings.optgroupValueField]);return ti===null?!1:(ei.$order=ei.$order||++this.order,this.optgroups[ti]=ei,ti)}addOptionGroup(ei,ti){var ni;ti[this.settings.optgroupValueField]=ei,(ni=this.registerOptionGroup(ti))&&this.trigger("optgroup_add",ni,ti)}removeOptionGroup(ei){this.optgroups.hasOwnProperty(ei)&&(delete this.optgroups[ei],this.clearCache(),this.trigger("optgroup_remove",ei))}clearOptionGroups(){this.optgroups={},this.clearCache(),this.trigger("optgroup_clear")}updateOption(ei,ti){let ni=this;var ri,oi;let si=Xn(ei),ai=Xn(ti[ni.settings.valueField]);if(si===null)return;let li=ni.options[si];if(li==null)return;if(typeof ai!="string")throw new Error("Value must be set in option data");let ui=ni.getOption(si),ci=ni.getItem(si);if(ti.$order=ti.$order||li.$order,delete ni.options[si],ni.uncacheValue(ai),ni.options[ai]=ti,ui){if(ni.dropdown_content.contains(ui)){let di=ni._render("option",ti);da(ui,di),ni.activeOption===ui&&ni.setActiveOption(di)}ui.remove()}ci&&(oi=ni.items.indexOf(si),oi!==-1&&ni.items.splice(oi,1,ai),ri=ni._render("item",ti),ci.classList.contains("active")&&jn(ri,"active"),da(ci,ri)),ni.lastQuery=null}removeOption(ei,ti){let ni=this;ei=ca(ei),ni.uncacheValue(ei),delete ni.userOptions[ei],delete ni.options[ei],ni.lastQuery=null,ni.trigger("option_remove",ei),ni.removeItem(ei,ti)}clearOptions(ei){let ti=(ei||this.clearFilter).bind(this);this.loadedSearches={},this.userOptions={},this.clearCache();let ni={};En(this.options,(ri,oi)=>{ti(ri,oi)&&(ni[oi]=ri)}),this.options=this.sifter.items=ni,this.lastQuery=null,this.trigger("option_clear")}clearFilter(ei,ti){return this.items.indexOf(ti)>=0}getOption(ei,ti=!1){let ni=Xn(ei);if(ni===null)return null;let ri=this.options[ni];if(ri!=null){if(ri.$div)return ri.$div;if(ti)return this._render("option",ri)}return null}getAdjacent(ei,ti,ni="option"){var ri=this,oi;if(!ei)return null;ni=="item"?oi=ri.controlChildren():oi=ri.dropdown_content.querySelectorAll("[data-selectable]");for(let si=0;si0?oi[si+1]:oi[si-1];return null}getItem(ei){if(typeof ei=="object")return ei;var ti=Xn(ei);return ti!==null?this.control.querySelector(`[data-value="${Lc(ti)}"]`):null}addItems(ei,ti){var ni=this,ri=Array.isArray(ei)?ei:[ei];ri=ri.filter(si=>ni.items.indexOf(si)===-1);let oi=ri[ri.length-1];ri.forEach(si=>{ni.isPending=si!==oi,ni.addItem(si,ti)})}addItem(ei,ti){var ni=ti?[]:["change","dropdown_close"];Oc(this,ni,()=>{var ri,oi;let si=this,ai=si.settings.mode,li=Xn(ei);if(!(li&&si.items.indexOf(li)!==-1&&(ai==="single"&&si.close(),ai==="single"||!si.settings.duplicates))&&!(li===null||!si.options.hasOwnProperty(li))&&(ai==="single"&&si.clear(ti),!(ai==="multi"&&si.isFull()))){if(ri=si._render("item",si.options[li]),si.control.contains(ri)&&(ri=ri.cloneNode(!0)),oi=si.isFull(),si.items.splice(si.caretPos,0,li),si.insertAtCaret(ri),si.isSetup){if(!si.isPending&&si.settings.hideSelected){let ui=si.getOption(li),ci=si.getAdjacent(ui,1);ci&&si.setActiveOption(ci)}!si.isPending&&!si.settings.closeAfterSelect&&si.refreshOptions(si.isFocused&&ai!=="single"),si.settings.closeAfterSelect!=!1&&si.isFull()?si.close():si.isPending||si.positionDropdown(),si.trigger("item_add",li,ri),si.isPending||si.updateOriginalInput({silent:ti})}(!si.isPending||!oi&&si.isFull())&&(si.inputState(),si.refreshState())}})}removeItem(ei=null,ti){let ni=this;if(ei=ni.getItem(ei),!ei)return;var ri,oi;let si=ei.dataset.value;ri=Nc(ei),ei.remove(),ei.classList.contains("active")&&(oi=ni.activeItems.indexOf(ei),ni.activeItems.splice(oi,1),bo(ei,"active")),ni.items.splice(ri,1),ni.lastQuery=null,!ni.settings.persist&&ni.userOptions.hasOwnProperty(si)&&ni.removeOption(si,ti),ri{}){arguments.length===3&&(ti=arguments[2]),typeof ti!="function"&&(ti=()=>{});var ni=this,ri=ni.caretPos,oi;if(ei=ei||ni.inputValue(),!ni.canCreate(ei))return ti(),!1;ni.lock();var si=!1,ai=li=>{if(ni.unlock(),!li||typeof li!="object")return ti();var ui=Xn(li[ni.settings.valueField]);if(typeof ui!="string")return ti();ni.setTextboxValue(),ni.addOption(li,!0),ni.setCaret(ri),ni.addItem(ui),ti(li),si=!0};return typeof ni.settings.create=="function"?oi=ni.settings.create.call(this,ei,ai):oi={[ni.settings.labelField]:ei,[ni.settings.valueField]:ei},si||ai(oi),!0}refreshItems(){var ei=this;ei.lastQuery=null,ei.isSetup&&ei.addItems(ei.items),ei.updateOriginalInput(),ei.refreshState()}refreshState(){let ei=this;ei.refreshValidityState();let ti=ei.isFull(),ni=ei.isLocked;ei.wrapper.classList.toggle("rtl",ei.rtl);let ri=ei.wrapper.classList;ri.toggle("focus",ei.isFocused),ri.toggle("disabled",ei.isDisabled),ri.toggle("readonly",ei.isReadOnly),ri.toggle("required",ei.isRequired),ri.toggle("invalid",!ei.isValid),ri.toggle("locked",ni),ri.toggle("full",ti),ri.toggle("input-active",ei.isFocused&&!ei.isInputHidden),ri.toggle("dropdown-active",ei.isOpen),ri.toggle("has-options",Wd(ei.options)),ri.toggle("has-items",ei.items.length>0)}refreshValidityState(){var ei=this;ei.input.validity&&(ei.isValid=ei.input.validity.valid,ei.isInvalid=!ei.isValid)}isFull(){return this.settings.maxItems!==null&&this.items.length>=this.settings.maxItems}updateOriginalInput(ei={}){let ti=this;var ni,ri;let oi=ti.input.querySelector('option[value=""]');if(ti.is_select_tag){let li=function(ui,ci,di){return ui||(ui=no('")),ui!=oi&&ti.input.append(ui),si.push(ui),(ui!=oi||ai>0)&&(ui.selected=!0),ui},si=[],ai=ti.input.querySelectorAll("option:checked").length;ti.input.querySelectorAll("option:checked").forEach(ui=>{ui.selected=!1}),ti.items.length==0&&ti.settings.mode=="single"?li(oi,"",""):ti.items.forEach(ui=>{if(ni=ti.options[ui],ri=ni[ti.settings.labelField]||"",si.includes(ni.$option)){let ci=ti.input.querySelector(`option[value="${Lc(ui)}"]:not(:checked)`);li(ci,ui,ri)}else ni.$option=li(ni.$option,ui,ri)})}else ti.input.value=ti.getValue();ti.isSetup&&(ei.silent||ti.trigger("change",ti.getValue()))}open(){var ei=this;ei.isLocked||ei.isOpen||ei.settings.mode==="multi"&&ei.isFull()||(ei.isOpen=!0,an(ei.focus_node,{"aria-expanded":"true"}),ei.refreshState(),ua(ei.dropdown,{visibility:"hidden",display:"block"}),ei.positionDropdown(),ua(ei.dropdown,{visibility:"visible",display:"block"}),ei.focus(),ei.trigger("dropdown_open",ei.dropdown))}close(ei=!0){var ti=this,ni=ti.isOpen;ei&&(ti.setTextboxValue(),ti.settings.mode==="single"&&ti.items.length&&ti.inputState()),ti.isOpen=!1,an(ti.focus_node,{"aria-expanded":"false"}),ua(ti.dropdown,{display:"none"}),ti.settings.hideSelected&&ti.clearActiveOption(),ti.refreshState(),ni&&ti.trigger("dropdown_close",ti.dropdown)}positionDropdown(){if(this.settings.dropdownParent==="body"){var ei=this.control,ti=ei.getBoundingClientRect(),ni=ei.offsetHeight+ti.top+window.scrollY,ri=ti.left+window.scrollX;ua(this.dropdown,{width:ti.width+"px",top:ni+"px",left:ri+"px"})}}clear(ei){var ti=this;if(ti.items.length){var ni=ti.controlChildren();En(ni,ri=>{ti.removeItem(ri,!0)}),ti.inputState(),ei||ti.updateOriginalInput(),ti.trigger("clear")}}insertAtCaret(ei){let ti=this,ni=ti.caretPos,ri=ti.control;ri.insertBefore(ei,ri.children[ni]||null),ti.setCaret(ni+1)}deleteSelection(ei){var ti,ni,ri,oi,si=this;ti=ei&&ei.keyCode===8?-1:1,ni=zd(si.control_input);let ai=[];if(si.activeItems.length)oi=kc(si.activeItems,ti),ri=Nc(oi),ti>0&&ri++,En(si.activeItems,li=>ai.push(li));else if((si.isFocused||si.settings.mode==="single")&&si.items.length){let li=si.controlChildren(),ui;ti<0&&ni.start===0&&ni.length===0?ui=li[si.caretPos-1]:ti>0&&ni.start===si.inputValue().length&&(ui=li[si.caretPos]),ui!==void 0&&ai.push(ui)}if(!si.shouldDelete(ai,ei))return!1;for(fn(ei,!0),typeof ri!="undefined"&&si.setCaret(ri);ai.length;)si.removeItem(ai.pop());return si.inputState(),si.positionDropdown(),si.refreshOptions(!1),!0}shouldDelete(ei,ti){let ni=ei.map(ri=>ri.dataset.value);return!(!ni.length||typeof this.settings.onDelete=="function"&&this.settings.onDelete(ni,ti)===!1)}advanceSelection(ei,ti){var ni,ri,oi=this;oi.rtl&&(ei*=-1),!oi.inputValue().length&&(Io(fa,ti)||Io("shiftKey",ti)?(ni=oi.getLastActive(ei),ni?ni.classList.contains("active")?ri=oi.getAdjacent(ni,ei,"item"):ri=ni:ei>0?ri=oi.control_input.nextElementSibling:ri=oi.control_input.previousElementSibling,ri&&(ri.classList.contains("active")&&oi.removeActiveItem(ni),oi.setActiveItemClass(ri))):oi.moveCaret(ei))}moveCaret(ei){}getLastActive(ei){let ti=this.control.querySelector(".last-active");if(ti)return ti;var ni=this.control.querySelectorAll(".active");if(ni)return kc(ni,ei)}setCaret(ei){this.caretPos=this.items.length}controlChildren(){return Array.from(this.control.querySelectorAll("[data-ts-item]"))}lock(){this.setLocked(!0)}unlock(){this.setLocked(!1)}setLocked(ei=this.isReadOnly||this.isDisabled){this.isLocked=ei,this.refreshState()}disable(){this.setDisabled(!0),this.close()}enable(){this.setDisabled(!1)}setDisabled(ei){this.focus_node.tabIndex=ei?-1:this.tabIndex,this.isDisabled=ei,this.input.disabled=ei,this.control_input.disabled=ei,this.setLocked()}setReadOnly(ei){this.isReadOnly=ei,this.input.readOnly=ei,this.control_input.readOnly=ei,this.setLocked()}destroy(){var ei=this,ti=ei.revertSettings;ei.trigger("destroy"),ei.off(),ei.wrapper.remove(),ei.dropdown.remove(),ei.input.innerHTML=ti.innerHTML,ei.input.tabIndex=ti.tabIndex,bo(ei.input,"tomselected","ts-hidden-accessible"),ei._destroy(),delete ei.input.tomselect}render(ei,ti){var ni,ri;let oi=this;if(typeof this.settings.render[ei]!="function"||(ri=oi.settings.render[ei].call(this,ti,sl),!ri))return null;if(ri=no(ri),ei==="option"||ei==="option_create"?ti[oi.settings.disabledField]?an(ri,{"aria-disabled":"true"}):an(ri,{"data-selectable":""}):ei==="optgroup"&&(ni=ti.group[oi.settings.optgroupValueField],an(ri,{"data-group":ni}),ti.group[oi.settings.disabledField]&&an(ri,{"data-disabled":""})),ei==="option"||ei==="item"){let si=ca(ti[oi.settings.valueField]);an(ri,{"data-value":si}),ei==="item"?(jn(ri,oi.settings.itemClass),an(ri,{"data-ts-item":""})):(jn(ri,oi.settings.optionClass),an(ri,{role:"option",id:ti.$id}),ti.$div=ri,oi.options[si]=ti)}return ri}_render(ei,ti){let ni=this.render(ei,ti);if(ni==null)throw"HTMLElement expected";return ni}clearCache(){En(this.options,ei=>{ei.$div&&(ei.$div.remove(),delete ei.$div)})}uncacheValue(ei){let ti=this.getOption(ei);ti&&ti.remove()}canCreate(ei){return this.settings.create&&ei.length>0&&this.settings.createFilter.call(this,ei)}hook(ei,ti,ni){var ri=this,oi=ri[ti];ri[ti]=function(){var si,ai;return ei==="after"&&(si=oi.apply(ri,arguments)),ai=ni.apply(ri,arguments),ei==="instead"?ai:(ei==="before"&&(si=oi.apply(ri,arguments)),si)}}};var pb=(ii,ei,ti,ni)=>{ii.addEventListener(ei,ti,ni)};function Xd(){pb(this.input,"change",()=>{this.sync()})}var mb=ii=>typeof ii=="undefined"||ii===null?null:gb(ii),gb=ii=>typeof ii=="boolean"?ii?"1":"0":ii+"",Jd=(ii,ei=!1)=>{ii&&(ii.preventDefault(),ei&&ii.stopPropagation())},vb=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(yb(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},yb=ii=>typeof ii=="string"&&ii.indexOf("<")>-1;function Zd(ii){var ei=this,ti=ei.onOptionSelect;ei.settings.hideSelected=!1;let ni=Object.assign({className:"tomselect-checkbox",checkedClassNames:void 0,uncheckedClassNames:void 0},ii);var ri=function(ai,li){li?(ai.checked=!0,ni.uncheckedClassNames&&ai.classList.remove(...ni.uncheckedClassNames),ni.checkedClassNames&&ai.classList.add(...ni.checkedClassNames)):(ai.checked=!1,ni.checkedClassNames&&ai.classList.remove(...ni.checkedClassNames),ni.uncheckedClassNames&&ai.classList.add(...ni.uncheckedClassNames))},oi=function(ai){setTimeout(()=>{var li=ai.querySelector("input."+ni.className);li instanceof HTMLInputElement&&ri(li,ai.classList.contains("selected"))},1)};ei.hook("after","setupTemplates",()=>{var si=ei.settings.render.option;ei.settings.render.option=(ai,li)=>{var ui=vb(si.call(ei,ai,li)),ci=document.createElement("input");ni.className&&ci.classList.add(ni.className),ci.addEventListener("click",function(pi){Jd(pi)}),ci.type="checkbox";let di=mb(ai[ei.settings.valueField]);return ri(ci,!!(di&&ei.items.indexOf(di)>-1)),ui.prepend(ci),ui}}),ei.on("item_remove",si=>{var ai=ei.getOption(si);ai&&(ai.classList.remove("selected"),oi(ai))}),ei.on("item_add",si=>{var ai=ei.getOption(si);ai&&oi(ai)}),ei.hook("instead","onOptionSelect",(si,ai)=>{if(ai.classList.contains("selected")){ai.classList.remove("selected"),ei.removeItem(ai.dataset.value),ei.refreshOptions(),Jd(si,!0);return}ti.call(ei,si,ai),oi(ai)})}var bb=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(_b(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},_b=ii=>typeof ii=="string"&&ii.indexOf("<")>-1;function ef(ii){let ei=this,ti=Object.assign({className:"clear-button",title:"Clear All",html:ni=>`
`},ii);ei.on("initialize",()=>{var ni=bb(ti.html(ti));ni.addEventListener("click",ri=>{ei.isLocked||(ei.clear(),ei.settings.mode==="single"&&ei.settings.allowEmptyOption&&ei.addItem(""),ri.preventDefault(),ri.stopPropagation())}),ei.control.appendChild(ni)})}var Eb=(ii,ei=!1)=>{ii&&(ii.preventDefault(),ei&&ii.stopPropagation())},Os=(ii,ei,ti,ni)=>{ii.addEventListener(ei,ti,ni)},wb=(ii,ei)=>{if(Array.isArray(ii))ii.forEach(ei);else for(var ti in ii)ii.hasOwnProperty(ti)&&ei(ii[ti],ti)},xb=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(Tb(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},Tb=ii=>typeof ii=="string"&&ii.indexOf("<")>-1,Sb=(ii,ei)=>{wb(ei,(ti,ni)=>{ti==null?ii.removeAttribute(ni):ii.setAttribute(ni,""+ti)})},Cb=(ii,ei)=>{var ti;(ti=ii.parentNode)==null||ti.insertBefore(ei,ii.nextSibling)},Ab=(ii,ei)=>{var ti;(ti=ii.parentNode)==null||ti.insertBefore(ei,ii)},Db=(ii,ei)=>{do{var ti;if(ei=(ti=ei)==null?void 0:ti.previousElementSibling,ii==ei)return!0}while(ei&&ei.previousElementSibling);return!1};function tf(){var ii=this;if(ii.settings.mode!=="multi")return;var ei=ii.lock,ti=ii.unlock;let ni=!0,ri;ii.hook("after","setupTemplates",()=>{var oi=ii.settings.render.item;ii.settings.render.item=(si,ai)=>{let li=xb(oi.call(ii,si,ai));Sb(li,{draggable:"true"});let ui=vi=>{ni||Eb(vi),vi.stopPropagation()},ci=vi=>{ri=li,setTimeout(()=>{li.classList.add("ts-dragging")},0)},di=vi=>{vi.preventDefault(),li.classList.add("ts-drag-over"),yi(li,ri)},pi=()=>{li.classList.remove("ts-drag-over")},yi=(vi,Ei)=>{Ei!==void 0&&(Db(Ei,li)?Cb(vi,Ei):Ab(vi,Ei))},gi=()=>{var vi;document.querySelectorAll(".ts-drag-over").forEach(Ci=>Ci.classList.remove("ts-drag-over")),(vi=ri)==null||vi.classList.remove("ts-dragging"),ri=void 0;var Ei=[];ii.control.querySelectorAll("[data-value]").forEach(Ci=>{if(Ci.dataset.value){let xi=Ci.dataset.value;xi&&Ei.push(xi)}}),ii.setValue(Ei)};return Os(li,"mousedown",ui),Os(li,"dragstart",ci),Os(li,"dragenter",di),Os(li,"dragover",di),Os(li,"dragleave",pi),Os(li,"dragend",gi),li}}),ii.hook("instead","lock",()=>(ni=!1,ei.call(ii))),ii.hook("instead","unlock",()=>(ni=!0,ti.call(ii)))}var Ob=(ii,ei=!1)=>{ii&&(ii.preventDefault(),ei&&ii.stopPropagation())},Lb=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(Mb(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},Mb=ii=>typeof ii=="string"&&ii.indexOf("<")>-1;function nf(ii){let ei=this,ti=Object.assign({title:"Untitled",headerClass:"dropdown-header",titleRowClass:"dropdown-header-title",labelClass:"dropdown-header-label",closeClass:"dropdown-header-close",html:ni=>'
'+ni.title+'×
'},ii);ei.on("initialize",()=>{var ni=Lb(ti.html(ti)),ri=ni.querySelector("."+ti.closeClass);ri&&ri.addEventListener("click",oi=>{Ob(oi,!0),ei.close()}),ei.dropdown.insertBefore(ni,ei.dropdown.firstChild)})}var kb=(ii,ei)=>{if(Array.isArray(ii))ii.forEach(ei);else for(var ti in ii)ii.hasOwnProperty(ti)&&ei(ii[ti],ti)},Nb=(ii,...ei)=>{var ti=Rb(ei);ii=Ib(ii),ii.map(ni=>{ti.map(ri=>{ni.classList.remove(ri)})})},Rb=ii=>{var ei=[];return kb(ii,ti=>{typeof ti=="string"&&(ti=ti.trim().split(/[\t\n\f\r\s]/)),Array.isArray(ti)&&(ei=ei.concat(ti))}),ei.filter(Boolean)},Ib=ii=>(Array.isArray(ii)||(ii=[ii]),ii),Hb=(ii,ei)=>{if(!ii)return-1;ei=ei||ii.nodeName;for(var ti=0;ii=ii.previousElementSibling;)ii.matches(ei)&&ti++;return ti};function rf(){var ii=this;ii.hook("instead","setCaret",ei=>{ii.settings.mode==="single"||!ii.control.contains(ii.control_input)?ei=ii.items.length:(ei=Math.max(0,Math.min(ii.items.length,ei)),ei!=ii.caretPos&&!ii.isPending&&ii.controlChildren().forEach((ti,ni)=>{ni{if(!ii.isFocused)return;let ti=ii.getLastActive(ei);if(ti){let ni=Hb(ti);ii.setCaret(ei>0?ni+1:ni),ii.setActiveItem(),Nb(ti,"last-active")}else ii.setCaret(ii.caretPos+ei)})}var Pb=(ii,ei=!1)=>{ii&&(ii.preventDefault(),ei&&ii.stopPropagation())},Fb=(ii,ei,ti,ni)=>{ii.addEventListener(ei,ti,ni)},$b=(ii,ei)=>{if(Array.isArray(ii))ii.forEach(ei);else for(var ti in ii)ii.hasOwnProperty(ti)&&ei(ii[ti],ti)},of=ii=>{if(ii.jquery)return ii[0];if(ii instanceof HTMLElement)return ii;if(Bb(ii)){var ei=document.createElement("template");return ei.innerHTML=ii.trim(),ei.content.firstChild}return document.querySelector(ii)},Bb=ii=>typeof ii=="string"&&ii.indexOf("<")>-1,zb=(ii,...ei)=>{var ti=Vb(ei);ii=jb(ii),ii.map(ni=>{ti.map(ri=>{ni.classList.add(ri)})})},Vb=ii=>{var ei=[];return $b(ii,ti=>{typeof ti=="string"&&(ti=ti.trim().split(/[\t\n\f\r\s]/)),Array.isArray(ti)&&(ei=ei.concat(ti))}),ei.filter(Boolean)},jb=ii=>(Array.isArray(ii)||(ii=[ii]),ii);function sf(){let ii=this;ii.settings.shouldOpen=!0,ii.hook("before","setup",()=>{ii.focus_node=ii.control,zb(ii.control_input,"dropdown-input");let ei=of('