-
-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathbootstrap.bundle.min.js
7 lines (7 loc) · 178 KB
/
bootstrap.bundle.min.js
1
2
3
4
5
6
7
/*!
* CoreUI v5.9.0 (https://coreui.io)
* Copyright 2025 The CoreUI Team (https://github.com/orgs/coreui/people)
* Licensed under MIT (https://github.com/coreui/coreui/blob/main/LICENSE)
*/
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).bootstrap=t()}(this,(function(){"use strict";const e=new Map,t={set(t,i,n){e.has(t)||e.set(t,new Map);const s=e.get(t);s.has(i)||0===s.size?s.set(i,n):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(t,i)=>e.has(t)&&e.get(t).get(i)||null,remove(t,i){if(!e.has(t))return;const n=e.get(t);n.delete(i),0===n.size&&e.delete(t)}},i="transitionend",n=e=>(e&&window.CSS&&window.CSS.escape&&(e=e.replace(/#([^\s"#']+)/g,((e,t)=>`#${CSS.escape(t)}`))),e),s=e=>{do{e+=Math.floor(1e6*Math.random())}while(document.getElementById(e));return e},a=e=>{e.dispatchEvent(new Event(i))},o=e=>!(!e||"object"!=typeof e)&&(void 0!==e.jquery&&(e=e[0]),void 0!==e.nodeType),r=e=>o(e)?e.jquery?e[0]:e:"string"==typeof e&&e.length>0?document.querySelector(n(e)):null,l=e=>{if(!o(e)||0===e.getClientRects().length)return!1;const t="visible"===getComputedStyle(e).getPropertyValue("visibility"),i=e.closest("details:not([open])");if(!i)return t;if(i!==e){const t=e.closest("summary");if(t&&t.parentNode!==i)return!1;if(null===t)return!1}return t},c=e=>!e||e.nodeType!==Node.ELEMENT_NODE||!!e.classList.contains("disabled")||(void 0!==e.disabled?e.disabled:e.hasAttribute("disabled")&&"false"!==e.getAttribute("disabled")),h=e=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof e.getRootNode){const t=e.getRootNode();return t instanceof ShadowRoot?t:null}return e instanceof ShadowRoot?e:e.parentNode?h(e.parentNode):null},d=()=>{},u=e=>{e.offsetHeight},_=()=>window.jQuery&&!document.body.hasAttribute("data-bs-no-jquery")?window.jQuery:null,f=[],g=()=>"rtl"===document.documentElement.dir,p=e=>{var t;t=()=>{const t=_();if(t){const i=e.NAME,n=t.fn[i];t.fn[i]=e.jQueryInterface,t.fn[i].Constructor=e,t.fn[i].noConflict=()=>(t.fn[i]=n,e.jQueryInterface)}},"loading"===document.readyState?(f.length||document.addEventListener("DOMContentLoaded",(()=>{for(const e of f)e()})),f.push(t)):t()},m=(e,t=[],i=e)=>"function"==typeof e?e.call(...t):i,b=(e,t,n=!0)=>{if(!n)return void m(e);const s=(e=>{if(!e)return 0;let{transitionDuration:t,transitionDelay:i}=window.getComputedStyle(e);const n=Number.parseFloat(t),s=Number.parseFloat(i);return n||s?(t=t.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(t)+Number.parseFloat(i))):0})(t)+5;let o=!1;const r=({target:n})=>{n===t&&(o=!0,t.removeEventListener(i,r),m(e))};t.addEventListener(i,r),setTimeout((()=>{o||a(t)}),s)},v=(e,t,i,n)=>{const s=e.length;let a=e.indexOf(t);return-1===a?!i&&n?e[s-1]:e[0]:(a+=i?1:-1,n&&(a=(a+s)%s),e[Math.max(0,Math.min(a,s-1))])},y=/[^.]*(?=\..*)\.|.*/,w=/\..*/,D=/::\d+$/,k={};let E=1;const L={mouseenter:"mouseover",mouseleave:"mouseout"},T=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 C(e,t){return t&&`${t}::${E++}`||e.uidEvent||E++}function A(e){const t=C(e);return e.uidEvent=t,k[t]=k[t]||{},k[t]}function x(e,t,i=null){return Object.values(e).find((e=>e.callable===t&&e.delegationSelector===i))}function O(e,t,i){const n="string"==typeof t,s=n?i:t||i;let a=I(e);return T.has(a)||(a=e),[n,s,a]}function $(e,t,i,n,s){if("string"!=typeof t||!e)return;let[a,o,r]=O(t,i,n);if(t in L){const e=e=>function(t){if(!t.relatedTarget||t.relatedTarget!==t.delegateTarget&&!t.delegateTarget.contains(t.relatedTarget))return e.call(this,t)};o=e(o)}const l=A(e),c=l[r]||(l[r]={}),h=x(c,o,a?i:null);if(h)return void(h.oneOff=h.oneOff&&s);const d=C(o,t.replace(y,"")),u=a?function(e,t,i){return function n(s){const a=e.querySelectorAll(t);for(let{target:o}=s;o&&o!==this;o=o.parentNode)for(const r of a)if(r===o)return P(s,{delegateTarget:o}),n.oneOff&&M.off(e,s.type,t,i),i.apply(o,[s])}}(e,i,o):function(e,t){return function i(n){return P(n,{delegateTarget:e}),i.oneOff&&M.off(e,n.type,t),t.apply(e,[n])}}(e,o);u.delegationSelector=a?i:null,u.callable=o,u.oneOff=s,u.uidEvent=d,c[d]=u,e.addEventListener(r,u,a)}function S(e,t,i,n,s){const a=x(t[i],n,s);a&&(e.removeEventListener(i,a,Boolean(s)),delete t[i][a.uidEvent])}function N(e,t,i,n){const s=t[i]||{};for(const[a,o]of Object.entries(s))a.includes(n)&&S(e,t,i,o.callable,o.delegationSelector)}function I(e){return e=e.replace(w,""),L[e]||e}const M={on(e,t,i,n){$(e,t,i,n,!1)},one(e,t,i,n){$(e,t,i,n,!0)},off(e,t,i,n){if("string"!=typeof t||!e)return;const[s,a,o]=O(t,i,n),r=o!==t,l=A(e),c=l[o]||{},h=t.startsWith(".");if(void 0===a){if(h)for(const i of Object.keys(l))N(e,l,i,t.slice(1));for(const[i,n]of Object.entries(c)){const s=i.replace(D,"");r&&!t.includes(s)||S(e,l,o,n.callable,n.delegationSelector)}}else{if(!Object.keys(c).length)return;S(e,l,o,a,s?i:null)}},trigger(e,t,i){if("string"!=typeof t||!e)return null;const n=_();let s=null,a=!0,o=!0,r=!1;t!==I(t)&&n&&(s=n.Event(t,i),n(e).trigger(s),a=!s.isPropagationStopped(),o=!s.isImmediatePropagationStopped(),r=s.isDefaultPrevented());const l=P(new Event(t,{bubbles:a,cancelable:!0}),i);return r&&l.preventDefault(),o&&e.dispatchEvent(l),l.defaultPrevented&&s&&s.preventDefault(),l}};function P(e,t={}){for(const[i,n]of Object.entries(t))try{e[i]=n}catch(t){Object.defineProperty(e,i,{configurable:!0,get:()=>n})}return e}function j(e){if("true"===e)return!0;if("false"===e)return!1;if(e===Number(e).toString())return Number(e);if(""===e||"null"===e)return null;if("string"!=typeof e)return e;try{return JSON.parse(decodeURIComponent(e))}catch(t){return e}}function B(e){return e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`))}const F={setDataAttribute(e,t,i){e.setAttribute(`data-bs-${B(t)}`,i)},removeDataAttribute(e,t){e.removeAttribute(`data-bs-${B(t)}`)},getDataAttributes(e){if(!e)return{};const t={};Object.keys(e.dataset).filter((e=>e.startsWith("bs")&&!e.startsWith("bsConfig")));for(const i of bsKeys){let n=i.replace(/^bs/,"");n=n.charAt(0).toLowerCase()+n.slice(1),t[n]=j(e.dataset[i])}return t},getDataAttribute:(e,t)=>j(e.getAttribute(`data-bs-${B(t)}`))};class H{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(e){return e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e}_mergeConfigObj(e,t){const i=o(t)?F.getDataAttribute(t,"config"):{};return{...this.constructor.Default,..."object"==typeof i?i:{},...o(t)?F.getDataAttributes(t):{},..."object"==typeof e?e:{}}}_typeCheckConfig(e,t=this.constructor.DefaultType){for(const[n,s]of Object.entries(t)){const t=e[n],a=o(t)?"element":null==(i=t)?`${i}`:Object.prototype.toString.call(i).match(/\s([a-z]+)/i)[1].toLowerCase();if(!new RegExp(s).test(a))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${n}" provided type "${a}" but expected type "${s}".`)}var i}}class z extends H{constructor(e,i){super(),(e=r(e))&&(this._element=e,this._config=this._getConfig(i),t.set(this._element,this.constructor.DATA_KEY,this))}dispose(){t.remove(this._element,this.constructor.DATA_KEY),M.off(this._element,this.constructor.EVENT_KEY);for(const e of Object.getOwnPropertyNames(this))this[e]=null}_queueCallback(e,t,i=!0){b(e,t,i)}_getConfig(e){return e=this._mergeConfigObj(e,this._element),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static getInstance(e){return t.get(r(e),this.DATA_KEY)}static getOrCreateInstance(e,t={}){return this.getInstance(e)||new this(e,"object"==typeof t?t:null)}static get VERSION(){return"5.9.0"}static get DATA_KEY(){return`bs.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(e){return`${e}${this.EVENT_KEY}`}}const V=e=>{let t=e.getAttribute("data-bs-target");if(!t||"#"===t){let i=e.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),t=i&&"#"!==i?i.trim():null}return t?t.split(",").map((e=>n(e))).join(","):null},R={find:(e,t=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(t,e)),findOne:(e,t=document.documentElement)=>Element.prototype.querySelector.call(t,e),children:(e,t)=>[].concat(...e.children).filter((e=>e.matches(t))),parents(e,t){const i=[];let n=e.parentNode.closest(t);for(;n;)i.push(n),n=n.parentNode.closest(t);return i},prev(e,t){let i=e.previousElementSibling;for(;i;){if(i.matches(t))return[i];i=i.previousElementSibling}return[]},next(e,t){let i=e.nextElementSibling;for(;i;){if(i.matches(t))return[i];i=i.nextElementSibling}return[]},focusableChildren(e){const t=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((e=>`${e}:not([tabindex^="-"])`)).join(",");return this.find(t,e).filter((e=>!c(e)&&l(e)))},getSelectorFromElement(e){const t=V(e);return t&&R.findOne(t)?t:null},getElementFromSelector(e){const t=V(e);return t?R.findOne(t):null},getMultipleElementsFromSelector(e){const t=V(e);return t?R.find(t):[]}},W=(e,t="hide")=>{const i=`click.dismiss${e.EVENT_KEY}`,n=e.NAME;M.on(document,i,`[data-bs-dismiss="${n}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),c(this))return;const s=R.getElementFromSelector(this)||this.closest(`.${n}`);e.getOrCreateInstance(s)[t]()}))},Y=".bs.alert",q=`close${Y}`,U=`closed${Y}`;class Q extends z{static get NAME(){return"alert"}close(){if(M.trigger(this._element,q).defaultPrevented)return;this._element.classList.remove("show");const e=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,e)}_destroyElement(){this._element.remove(),M.trigger(this._element,U),this.dispose()}static jQueryInterface(e){return this.each((function(){const t=Q.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}W(Q,"close"),p(Q);const K='[data-bs-toggle="button"]';class X extends z{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(e){return this.each((function(){const t=X.getOrCreateInstance(this);"toggle"===e&&t[e]()}))}}M.on(document,"click.bs.button.data-api",K,(e=>{e.preventDefault();const t=e.target.closest(K);X.getOrCreateInstance(t).toggle()})),p(X);const G=(e,t)=>{if(null===e)return null;if(e instanceof Date)return e;if("week"===t)return(e=>{const[t,i]=e.split(/[Ww]/),n=new Date(Number(t),0,4);return n.setDate(n.getDate()-(n.getDay()||7)+1+7*(Number(i)-1)),n})(e);if("month"===t||"year"===t){const t=new Date(Date.parse(e)),i=6e4*t.getTimezoneOffset();return new Date(t.getTime()+i)}return new Date(Date.parse(e))},Z=(e,t)=>{const i=Math.ceil(e.length/t);return Array.from({length:t}).fill("").map(((t,n)=>e.slice(n*i,(n+1)*i)))},J=(e,t)=>{if(null===e)return null;if("week"===t)return`${e.getFullYear()}W${ee(e)}`;if("month"===t){const t=`0${e.getMonth()+1}`.slice(-2);return`${e.getFullYear()}-${t}`}return"year"===t?`${e.getFullYear()}`:e},ee=e=>{const t=new Date(e.getTime());t.setHours(0,0,0,0),t.setDate(t.getDate()+3-(t.getDay()+6)%7);const i=new Date(t.getFullYear(),0,4);return 1+Math.round((t.getTime()-i.getTime())/864e5/7)},te=(e,t,i,n)=>{if(t&&e<t)return!0;if(i&&e>i)return!0;if(void 0===n)return!1;if("function"==typeof n)return n(e);if(n instanceof Date&&oe(e,n))return!0;if(Array.isArray(n)&&n)for(const t of n){if("function"==typeof t&&t(e))return!0;if(Array.isArray(t)&&ie(e,t[0],t[1]))return!0;if(t instanceof Date&&oe(e,t))return!0}return!1},ie=(e,t,i)=>{const n=ce(e),s=t?ce(t):null,a=i?ce(i):null;return Boolean(s&&a&&s<=n&&n<=a)},ne=(e,t,i)=>!(null===t||!oe(t,e))||!(null===i||!oe(i,e)),se=(e,t,i)=>{if(e&&t){const n=new Date(e);let s=!1;for(;n<t;)if(n.setDate(n.getDate()+1),te(n,null,null,i)){s=!0;break}return s}return!1},ae=(e,t,i)=>{const n=e.getFullYear(),s=e.getMonth(),a=t?12*t.getFullYear()+t.getMonth():null,o=i?12*i.getFullYear()+i.getMonth():null,r=12*n+s;return Boolean(a&&o&&a<=r&&r<=o)},oe=(e,t)=>e instanceof Date&&t instanceof Date?e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear():null===e&&null===t,re=e=>{const t=new Date;return oe(e,t)},le=(e,t,i)=>{const n=e.getFullYear(),s=t?t.getFullYear():null,a=i?i.getFullYear():null;return Boolean(s&&a&&s<=n&&n<=a)},ce=e=>{const t=new Date(e);return t.setHours(0,0,0,0),t},he=".bs.calendar",de=".data-api",ue="ArrowUp",_e="ArrowRight",fe="ArrowDown",ge="ArrowLeft",pe=`blur${he}`,me=`calendarDateChange${he}`,be=`calendarMouseleave${he}`,ve=`cellHover${he}`,ye=`endDateChange${he}`,we=`focus${he}`,De=`keydown${he}`,ke=`selectEndChange${he}`,Ee=`startDateChange${he}`,Le=`mouseenter${he}`,Te=`mouseleave${he}`,Ce=`load${he}${de}`,Ae=`click${he}${de}`,xe="calendar-cell",Oe="calendar-cell-inner",$e="calendar-row",Se=".btn-double-next",Ne=".btn-double-prev",Ie=".btn-month",Me=".btn-next",Pe=".btn-prev",je=".btn-year",Be=".calendar-cell",Fe=`${Be}[tabindex="0"]`,He=".calendar-row",ze=`${He}[tabindex="0"]`,Ve={ariaNavNextMonthLabel:"Next month",ariaNavNextYearLabel:"Next year",ariaNavPrevMonthLabel:"Previous month",ariaNavPrevYearLabel:"Previous year",calendarDate:null,calendars:1,disabledDates:null,endDate:null,firstDayOfWeek:1,locale:"default",maxDate:null,minDate:null,range:!1,selectAdjacementDays:!1,selectEndDate:!1,selectionType:"day",showAdjacementDays:!0,showWeekNumber:!1,startDate:null,weekdayFormat:2,weekNumbersLabel:null},Re={ariaNavNextMonthLabel:"string",ariaNavNextYearLabel:"string",ariaNavPrevMonthLabel:"string",ariaNavPrevYearLabel:"string",calendarDate:"(date|number|string|null)",calendars:"number",disabledDates:"(array|date|function|null)",endDate:"(date|number|string|null)",firstDayOfWeek:"number",locale:"string",maxDate:"(date|number|string|null)",minDate:"(date|number|string|null)",range:"boolean",selectAdjacementDays:"boolean",selectEndDate:"boolean",selectionType:"string",showAdjacementDays:"boolean",showWeekNumber:"boolean",startDate:"(date|number|string|null)",weekdayFormat:"(number|string)",weekNumbersLabel:"(string|null)"};class We extends z{constructor(e,t){super(e),this._config=this._getConfig(t),this._initializeDates(),this._initializeView(),this._createCalendar(),this._addEventListeners()}static get Default(){return Ve}static get DefaultType(){return Re}static get NAME(){return"calendar"}update(e){this._config=this._getConfig(e),this._initializeDates(),this._initializeView(),this._element.innerHTML="",this._createCalendar()}_focusOnFirstAvailableCell(){const e=R.findOne(Fe,this._element);e&&e.focus()}_getDate(e){if("week"===this._config.selectionType){const t=R.findOne(Be,e.closest(He));return new Date(F.getDataAttribute(t,"date"))}return new Date(F.getDataAttribute(e,"date"))}_handleCalendarClick(e){const t=e.target.classList.contains(Oe)?e.target.parentElement:e.target,i=this._getDate(t),n=new Date(i),s=F.getDataAttribute(t.closest(".calendar"),"calendar-index");return"days"===this._view&&this._setCalendarDate(s?new Date(n.setMonth(n.getMonth()-s)):i),"months"===this._view&&"month"!==this._config.selectionType?(this._setCalendarDate(s?new Date(n.setMonth(n.getMonth()-s)):i),this._view="days",void this._updateCalendar(this._focusOnFirstAvailableCell.bind(this))):"years"===this._view&&"year"!==this._config.selectionType?(this._setCalendarDate(s?new Date(n.setFullYear(n.getFullYear()-s)):i),this._view="months",void this._updateCalendar(this._focusOnFirstAvailableCell.bind(this))):void(te(i,this._config.minDate,this._config.maxDate,this._config.disabledDates)||(this._hoverDate=null,this._selectDate(i),this._updateClassNamesAndAriaLabels()))}_handleCalendarKeydown(e){const t=this._getDate(e.target);if("Space"!==e.code&&"Enter"!==e.key||(e.preventDefault(),this._handleCalendarClick(e)),e.key===_e||e.key===ge||e.key===ue||e.key===fe){if(e.preventDefault(),this._config.maxDate&&t>=G(this._config.maxDate,this._config.selectionType)&&(e.key===_e||e.key===fe))return;if(this._config.minDate&&t<=G(this._config.minDate,this._config.selectionType)&&(e.key===ge||e.key===ue))return;let i=e.target;"week"===this._config.selectionType&&-1===i.tabIndex&&(i=i.closest(ze));const n=R.find("week"===this._config.selectionType?ze:Fe,this._element),s=n.indexOf(i),a=0===s,o=s===n.length-1,r={start:s,end:n.length-(s+1)},l={ArrowRight:1,ArrowLeft:-1,ArrowUp:"week"===this._config.selectionType&&"days"===this._view?-1:"days"===this._view?-7:-3,ArrowDown:"week"===this._config.selectionType&&"days"===this._view?1:"days"===this._view?7:3};if(e.key===_e&&o||e.key===fe&&r.end<l.ArrowDown||e.key===ge&&a||e.key===ue&&r.start<Math.abs(l.ArrowUp)){const t=e=>{const t=R.find(`${Fe}, ${ze}`,this._element);t.length&&e===_e&&t[0].focus(),t.length&&e===ge&&t[t.length-1].focus(),t.length&&e===fe&&t[l.ArrowDown-(n.length-s)].focus(),t.length&&e===ue&&t[t.length-(Math.abs(l.ArrowUp)+1-(s+1))].focus()};return"days"===this._view&&this._modifyCalendarDate(0,e.key===_e||e.key===fe?1:-1,t.bind(this,e.key)),"months"===this._view&&this._modifyCalendarDate(e.key===_e||e.key===fe?1:-1,0,t.bind(this,e.key)),void("years"===this._view&&this._modifyCalendarDate(e.key===_e||e.key===fe?10:-10,0,t.bind(this,e.key)))}if(0===n[s+l[e.key]].tabIndex)return void n[s+l[e.key]].focus();for(let t=s;t<n.length;e.key===_e||e.key===fe?t++:t--)if(0===n[t+l[e.key]].tabIndex){n[t+l[e.key]].focus();break}}}_handleCalendarMouseEnter(e){const t=e.target.classList.contains(Oe)?e.target.parentElement:e.target,i=this._getDate(t);te(i,this._config.minDate,this._config.maxDate,this._config.disabledDates)||(this._hoverDate=i,M.trigger(this._element,ve,{date:J(i,this._config.selectionType)}),this._updateClassNamesAndAriaLabels())}_handleCalendarMouseLeave(){this._hoverDate=null,M.trigger(this._element,ve,{date:null}),this._updateClassNamesAndAriaLabels()}_addEventListeners(){M.on(this._element,Ae,Fe,(e=>{this._handleCalendarClick(e)})),M.on(this._element,De,Fe,(e=>{this._handleCalendarKeydown(e)})),M.on(this._element,Le,Fe,(e=>{this._handleCalendarMouseEnter(e)})),M.on(this._element,Te,Fe,(()=>{this._handleCalendarMouseLeave()})),M.on(this._element,we,Fe,(e=>{this._handleCalendarMouseEnter(e)})),M.on(this._element,pe,Fe,(()=>{this._handleCalendarMouseLeave()})),M.on(this._element,Ae,ze,(e=>{this._handleCalendarClick(e)})),M.on(this._element,De,ze,(e=>{this._handleCalendarKeydown(e)})),M.on(this._element,Le,ze,(e=>{this._handleCalendarMouseEnter(e)})),M.on(this._element,Te,ze,(()=>{this._handleCalendarMouseLeave()})),M.on(this._element,we,ze,(e=>{this._handleCalendarMouseEnter(e)})),M.on(this._element,pe,ze,(()=>{this._handleCalendarMouseLeave()})),this._addNavigationEventListeners(),M.on(this._element,Te,"table",(()=>{M.trigger(this._element,be)}))}_addNavigationEventListeners(){const e={[Pe]:()=>this._modifyCalendarDate(0,-1),[Ne]:()=>this._modifyCalendarDate("years"===this._view?-10:-1),[Me]:()=>this._modifyCalendarDate(0,1),[Se]:()=>this._modifyCalendarDate("years"===this._view?10:1),[Ie]:()=>{this._view="months",this._updateCalendar()},[je]:()=>{this._view="years",this._updateCalendar()}};for(const[t,i]of Object.entries(e))M.on(this._element,Ae,t,(e=>{e.preventDefault();const n=R.find(t,this._element).indexOf(e.target.closest(t));i();const s=R.find(t,this._element);s&&s[n]&&s[n].focus()}))}_setCalendarDate(e){this._calendarDate=e,M.trigger(this._element,me,{date:e})}_modifyCalendarDate(e,t=0,i){const n=this._calendarDate.getFullYear(),s=this._calendarDate.getMonth(),a=new Date(n,s,1);e&&a.setFullYear(a.getFullYear()+e),t&&a.setMonth(a.getMonth()+t),this._calendarDate=a,"days"===this._view&&M.trigger(this._element,me,{date:a}),this._updateCalendar(i)}_setEndDate(e){this._endDate=e,M.trigger(this._element,ye,{date:J(this._endDate,this._config.selectionType)})}_setStartDate(e){this._startDate=e,M.trigger(this._element,Ee,{date:J(this._startDate,this._config.selectionType)})}_setSelectEndDate(e){this._selectEndDate=e,M.trigger(this._element,ke,{value:e})}_selectDate(e){if(!te(e,this._config.minDate,this._config.maxDate,this._config.disabledDates))return this._config.range?this._selectEndDate?(this._setSelectEndDate(!1),this._startDate&&this._startDate>e||se(this._startDate,e,this._config.disabledDates)?(this._setStartDate(null),void this._setEndDate(null)):void this._setEndDate(e)):this._endDate&&this._endDate<e||se(e,this._endDate,this._config.disabledDates)?(this._setStartDate(null),void this._setEndDate(null)):(this._setSelectEndDate(!0),void this._setStartDate(e)):void this._setStartDate(e)}_createCalendarPanel(e){var t;const i=((e,t,i)=>0!==t&&"days"===i?new Date(e.getFullYear(),e.getMonth()+t,1):0!==t&&"months"===i?new Date(e.getFullYear()+t,e.getMonth(),1):0!==t&&"years"===i?new Date(e.getFullYear()+12*t,e.getMonth(),1):e)(this._calendarDate,e,this._view),n=i.getFullYear(),s=i.getMonth(),a=document.createElement("div");a.classList.add("calendar"),F.setDataAttribute(a,"calendar-index",e);const o=document.createElement("div");o.classList.add("calendar-nav"),o.innerHTML=`\n <div class="calendar-nav-prev">\n <button class="btn btn-transparent btn-sm btn-double-prev" aria-label="${this._config.ariaNavPrevYearLabel}">\n <span class="calendar-nav-icon calendar-nav-icon-double-prev"></span>\n </button>\n ${"days"===this._view?`<button class="btn btn-transparent btn-sm btn-prev" aria-label="${this._config.ariaNavPrevMonthLabel}">\n <span class="calendar-nav-icon calendar-nav-icon-prev"></span>\n </button>`:""}\n </div>\n <div class="calendar-nav-date" aria-live="polite">\n ${"days"===this._view?`<button class="btn btn-transparent btn-sm btn-month">\n ${i.toLocaleDateString(this._config.locale,{month:"long"})}\n </button>`:""}\n <button class="btn btn-transparent btn-sm btn-year">\n ${i.toLocaleDateString(this._config.locale,{year:"numeric"})}\n </button>\n </div>\n <div class="calendar-nav-next">\n ${"days"===this._view?`<button class="btn btn-transparent btn-sm btn-next" aria-label="${this._config.ariaNavNextMonthLabel}">\n <span class="calendar-nav-icon calendar-nav-icon-next"></span>\n </button>`:""}\n <button class="btn btn-transparent btn-sm btn-double-next" aria-label="${this._config.ariaNavNextYearLabel}">\n <span class="calendar-nav-icon calendar-nav-icon-double-next"></span>\n </button>\n </div>\n `;const r=((e,t,i)=>{const n=((e,t,i)=>{const n=[],s=new Date(e,t),a=s.getFullYear(),o=s.getMonth();let r=6-(6-new Date(a,o,1).getDay())-i;i&&(r=r<0?7+r:r);for(let e=-1*r;e<0;e++)n.push({date:new Date(a,o,e+1),month:"previous"});return n})(e,t,i),s=((e,t)=>{const i=[],n=new Date(e,t+1,0).getDate();for(let s=1;s<=n;s++)i.push({date:new Date(e,t,s),month:"current"});return i})(e,t),a=((e,t,i,n)=>{const s=[],a=42-(i.length+n.length);for(let i=1;i<=a;i++)s.push({date:new Date(e,t+1,i),month:"next"});return s})(e,t,n,s),o=[...n,...s,...a],r=[];for(const[e,t]of o.entries())e%7!=0&&0!==r.length||r.push({days:[]}),(e+1)%7==0&&(r[r.length-1].weekNumber=ee(t.date)),r[r.length-1].days.push(t);return r})(n,s,this._config.firstDayOfWeek),l=Z(((e,t="short")=>Array.from({length:12},((i,n)=>new Date(2e3,n,1).toLocaleString(e,{month:t}))))(this._config.locale),4),c=Z(((e,t=6)=>Array.from({length:2*t},((i,n)=>e-t+n)))(i.getFullYear()),4),h=r[0].days,d=document.createElement("table");return d.innerHTML=`\n ${"days"===this._view?`\n <thead>\n <tr>\n ${this._config.showWeekNumber?`<th class="${xe}">\n <div class="calendar-header-cell-inner">\n ${null!=(t=this._config.weekNumbersLabel)?t:""}\n </div>\n </th>`:""}\n ${h.map((({date:e})=>`<th class="${xe}" abbr="${e.toLocaleDateString(this._config.locale,{weekday:"long"})}">\n <div class="calendar-header-cell-inner">\n ${"string"==typeof this._config.weekdayFormat?e.toLocaleDateString(this._config.locale,{weekday:this._config.weekdayFormat}):e.toLocaleDateString(this._config.locale,{weekday:"long"}).slice(0,this._config.weekdayFormat)}\n </div>\n </th>`)).join("")}\n </tr>\n </thead>`:""}\n <tbody>\n ${"days"===this._view?r.map((e=>{const t=G(0===e.weekNumber?`${i.getFullYear()}W53`:`${i.getFullYear()}W${e.weekNumber}`,this._config.selectionType),n=this._rowWeekAttributes(t);return`<tr \n class="${n.className}"\n tabindex="${n.tabIndex}"\n ${n.ariaSelected?'aria-selected="true"':""}\n >\n ${this._config.showWeekNumber?`<th class="calendar-cell-week-number">${0===e.weekNumber?53:e.weekNumber}</td>`:""}\n ${e.days.map((({date:e,month:t})=>{const i=this._cellDayAttributes(e,t);return"current"===t||this._config.showAdjacementDays?`<td \n class="${i.className}"\n tabindex="${i.tabIndex}"\n ${i.ariaSelected?'aria-selected="true"':""}\n data-bs-date="${e}"\n >\n <div class="calendar-cell-inner day">\n ${e.toLocaleDateString(this._config.locale,{day:"numeric"})}\n </div>\n </td>`:"<td></td>"})).join("")}</tr>`})).join(""):""}\n ${"months"===this._view?l.map(((e,t)=>`<tr>\n ${e.map(((e,n)=>{const s=new Date(i.getFullYear(),3*t+n,1),a=this._cellMonthAttributes(s);return`<td\n class="${a.className}"\n tabindex="${a.tabIndex}"\n ${a.ariaSelected?'aria-selected="true"':""}\n data-bs-date="${s.toDateString()}"\n >\n <div class="calendar-cell-inner month">\n ${e}\n </div>\n </td>`})).join("")}\n </tr>`)).join(""):""}\n ${"years"===this._view?c.map((e=>`<tr>\n ${e.map((e=>{const t=new Date(e,0,1),i=this._cellYearAttributes(t);return`<td\n class="${i.className}"\n tabindex="${i.tabIndex}"\n ${i.ariaSelected?'aria-selected="true"':""}\n data-bs-date="${t.toDateString()}"\n >\n <div class="calendar-cell-inner year">\n ${e}\n </div>\n </td>`})).join("")}\n </tr>`)).join(""):""}\n </tbody>\n `,a.append(o,d),a}_createCalendar(){this._config.selectionType&&"days"===this._view&&this._element.classList.add(`select-${this._config.selectionType}`),this._config.showWeekNumber&&this._element.classList.add("show-week-numbers");for(const[e,t]of Array.from({length:this._config.calendars}).entries())this._element.append(this._createCalendarPanel(e));this._element.classList.add("calendars")}_initializeDates(){this._calendarDate=G(this._config.calendarDate||this._config.startDate||this._config.endDate||new Date,this._config.selectionType),this._startDate=G(this._config.startDate,this._config.selectionType),this._endDate=G(this._config.endDate,this._config.selectionType),this._hoverDate=null,this._selectEndDate=this._config.selectEndDate}_initializeView(){this._view={day:"days",week:"days",month:"months",year:"years"}[this._config.selectionType]||"days"}_updateCalendar(e){this._element.innerHTML="",this._createCalendar(),e&&setTimeout(e,1)}_updateClassNamesAndAriaLabels(){if("week"===this._config.selectionType){const e=R.find(He,this._element);for(const t of e){const e=R.findOne(Be,t),i=new Date(F.getDataAttribute(e,"date")),n=this._rowWeekAttributes(i);t.className=n.className,t.tabIndex=n.tabIndex,n.ariaSelected?t.setAttribute("aria-selected",!0):t.removeAttribute("aria-selected")}return}const e=R.find(Fe,this._element);for(const t of e){const e=new Date(F.getDataAttribute(t,"date"));let i;i="days"===this._view?this._cellDayAttributes(e,"current"):"months"===this._view?this._cellMonthAttributes(e):this._cellYearAttributes(e),t.className=i.className,t.tabIndex=i.tabIndex,i.ariaSelected?t.setAttribute("aria-selected",!0):t.removeAttribute("aria-selected")}}_classNames(e){return Object.entries(e).filter((([e,t])=>Boolean(t))).map((([e])=>e)).join(" ")}_cellDayAttributes(e,t){const i="current"===t,n=te(e,this._config.minDate,this._config.maxDate,this._config.disabledDates),s=ne(e,this._startDate,this._endDate);return{className:this._classNames({[xe]:!0,..."day"===this._config.selectionType&&"days"===this._view&&{clickable:!i&&this._config.selectAdjacementDays,disabled:n,range:i&&ie(e,this._startDate,this._endDate),"range-hover":i&&(this._hoverDate&&this._selectEndDate?ie(e,this._startDate,this._hoverDate):ie(e,this._hoverDate,this._endDate)),selected:s},today:re(e),[t]:!0}),tabIndex:"day"!==this._config.selectionType||!i&&!this._config.selectAdjacementDays||n?-1:0,ariaSelected:s}}_cellMonthAttributes(e){const t=((e,t,i,n)=>{const s=12*e.getFullYear()+e.getMonth(),a=t?12*t.getFullYear()+t.getMonth():null,o=i?12*i.getFullYear()+i.getMonth():null;if(a&&s<a)return!0;if(o&&s>o)return!0;if(void 0===n)return!1;const r=t?Math.max(e.getTime(),t.getTime()):e,l=i?Math.min(e.getTime(),i.getTime()):new Date((new Date).getFullYear(),11,31);for(const e=new Date(r);e<=l;e.setDate(e.getDate()+1))if(!te(e,t,i,n))return!1;return!1})(e,this._config.minDate,this._config.maxDate,this._config.disabledDates),i=((e,t,i)=>{const n=e.getFullYear(),s=e.getMonth();return null!==t&&n===t.getFullYear()&&s===t.getMonth()||null!==i&&n===i.getFullYear()&&s===i.getMonth()})(e,this._startDate,this._endDate);return{className:this._classNames({[xe]:!0,disabled:t,"range-hover":"month"===this._config.selectionType&&(this._hoverDate&&this._selectEndDate?ae(e,this._startDate,this._hoverDate):ae(e,this._hoverDate,this._endDate)),range:ae(e,this._startDate,this._endDate),selected:i}),tabIndex:t?-1:0,ariaSelected:i}}_cellYearAttributes(e){const t=((e,t,i,n)=>{const s=e.getFullYear(),a=t?t.getFullYear():null,o=i?i.getFullYear():null;if(a&&s<a)return!0;if(o&&s>o)return!0;if(void 0===n)return!1;const r=t?Math.max(e.getTime(),t.getTime()):e,l=i?Math.min(e.getTime(),i.getTime()):new Date((new Date).getFullYear(),11,31);for(const e=new Date(r);e<=l;e.setDate(e.getDate()+1))if(!te(e,t,i,n))return!1;return!1})(e,this._config.minDate,this._config.maxDate,this._config.disabledDates),i=((e,t,i)=>{const n=e.getFullYear();return null!==t&&n===t.getFullYear()||null!==i&&n===i.getFullYear()})(e,this._startDate,this._endDate);return{className:this._classNames({[xe]:!0,disabled:t,"range-hover":"year"===this._config.selectionType&&(this._hoverDate&&this._selectEndDate?le(e,this._startDate,this._hoverDate):le(e,this._hoverDate,this._endDate)),range:le(e,this._startDate,this._endDate),selected:i}),tabIndex:t?-1:0,ariaSelected:i}}_rowWeekAttributes(e){const t=te(e,this._config.minDate,this._config.maxDate,this._config.disabledDates),i=ne(e,this._startDate,this._endDate);return{className:this._classNames({[$e]:!0,disabled:t,range:"week"===this._config.selectionType&&ie(e,this._startDate,this._endDate),"range-hover":"week"===this._config.selectionType&&(this._hoverDate&&this._selectEndDate?le(e,this._startDate,this._hoverDate):le(e,this._hoverDate,this._endDate)),selected:i}),tabIndex:"week"!==this._config.selectionType||t?-1:0,ariaSelected:i}}static calendarInterface(e,t){const i=We.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=We.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}M.on(window,Ce,(()=>{for(const e of Array.from(document.querySelectorAll('[data-bs-toggle="calendar"]')))We.calendarInterface(e)})),p(We);const Ye=".bs.swipe",qe=`touchstart${Ye}`,Ue=`touchmove${Ye}`,Qe=`touchend${Ye}`,Ke=`pointerdown${Ye}`,Xe=`pointerup${Ye}`,Ge={endCallback:null,leftCallback:null,rightCallback:null},Ze={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class Je extends H{constructor(e,t){super(),this._element=e,e&&Je.isSupported()&&(this._config=this._getConfig(t),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return Ge}static get DefaultType(){return Ze}static get NAME(){return"swipe"}dispose(){M.off(this._element,Ye)}_start(e){this._supportPointerEvents?this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX):this._deltaX=e.touches[0].clientX}_end(e){this._eventIsPointerPenTouch(e)&&(this._deltaX=e.clientX-this._deltaX),this._handleSwipe(),m(this._config.endCallback)}_move(e){this._deltaX=e.touches&&e.touches.length>1?0:e.touches[0].clientX-this._deltaX}_handleSwipe(){const e=Math.abs(this._deltaX);if(e<=40)return;const t=e/this._deltaX;this._deltaX=0,t&&m(t>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(M.on(this._element,Ke,(e=>this._start(e))),M.on(this._element,Xe,(e=>this._end(e))),this._element.classList.add("pointer-event")):(M.on(this._element,qe,(e=>this._start(e))),M.on(this._element,Ue,(e=>this._move(e))),M.on(this._element,Qe,(e=>this._end(e))))}_eventIsPointerPenTouch(e){return this._supportPointerEvents&&("pen"===e.pointerType||"touch"===e.pointerType)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const et=".bs.carousel",tt=".data-api",it="ArrowLeft",nt="ArrowRight",st="next",at="prev",ot="left",rt="right",lt=`slide${et}`,ct=`slid${et}`,ht=`keydown${et}`,dt=`mouseenter${et}`,ut=`mouseleave${et}`,_t=`dragstart${et}`,ft=`load${et}${tt}`,gt=`click${et}${tt}`,pt="carousel",mt="active",bt=".active",vt=".carousel-item",yt=bt+vt,wt={[it]:rt,[nt]:ot},Dt={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},kt={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class Et extends z{constructor(e,t){super(e,t),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=R.findOne(".carousel-indicators",this._element),this._addEventListeners(),this._config.ride===pt&&this.cycle()}static get Default(){return Dt}static get DefaultType(){return kt}static get NAME(){return"carousel"}next(){this._slide(st)}nextWhenVisible(){!document.hidden&&l(this._element)&&this.next()}prev(){this._slide(at)}pause(){this._isSliding&&a(this._element),this._clearInterval()}cycle(){this._clearInterval(),this._updateInterval(),this._interval=setInterval((()=>this.nextWhenVisible()),this._config.interval)}_maybeEnableCycle(){this._config.ride&&(this._isSliding?M.one(this._element,ct,(()=>this.cycle())):this.cycle())}to(e){const t=this._getItems();if(e>t.length-1||e<0)return;if(this._isSliding)return void M.one(this._element,ct,(()=>this.to(e)));const i=this._getItemIndex(this._getActive());if(i===e)return;const n=e>i?st:at;this._slide(n,t[e])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(e){return e.defaultInterval=e.interval,e}_addEventListeners(){this._config.keyboard&&M.on(this._element,ht,(e=>this._keydown(e))),"hover"===this._config.pause&&(M.on(this._element,dt,(()=>this.pause())),M.on(this._element,ut,(()=>this._maybeEnableCycle()))),this._config.touch&&Je.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const e of R.find(".carousel-item img",this._element))M.on(e,_t,(e=>e.preventDefault()));const e={leftCallback:()=>this._slide(this._directionToOrder(ot)),rightCallback:()=>this._slide(this._directionToOrder(rt)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),500+this._config.interval))}};this._swipeHelper=new Je(this._element,e)}_keydown(e){if(/input|textarea/i.test(e.target.tagName))return;const t=wt[e.key];t&&(e.preventDefault(),this._slide(this._directionToOrder(t)))}_getItemIndex(e){return this._getItems().indexOf(e)}_setActiveIndicatorElement(e){if(!this._indicatorsElement)return;const t=R.findOne(bt,this._indicatorsElement);t.classList.remove(mt),t.removeAttribute("aria-current");const i=R.findOne(`[data-bs-slide-to="${e}"]`,this._indicatorsElement);i&&(i.classList.add(mt),i.setAttribute("aria-current","true"))}_updateInterval(){const e=this._activeElement||this._getActive();if(!e)return;const t=Number.parseInt(e.getAttribute("data-bs-interval"),10);this._config.interval=t||this._config.defaultInterval}_slide(e,t=null){if(this._isSliding)return;const i=this._getActive(),n=e===st,s=t||v(this._getItems(),i,n,this._config.wrap);if(s===i)return;const a=this._getItemIndex(s),o=t=>M.trigger(this._element,t,{relatedTarget:s,direction:this._orderToDirection(e),from:this._getItemIndex(i),to:a});if(o(lt).defaultPrevented)return;if(!i||!s)return;const r=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(a),this._activeElement=s;const l=n?"carousel-item-start":"carousel-item-end",c=n?"carousel-item-next":"carousel-item-prev";s.classList.add(c),u(s),i.classList.add(l),s.classList.add(l),this._queueCallback((()=>{s.classList.remove(l,c),s.classList.add(mt),i.classList.remove(mt,c,l),this._isSliding=!1,o(ct)}),i,this._isAnimated()),r&&this.cycle()}_isAnimated(){return this._element.classList.contains("slide")}_getActive(){return R.findOne(yt,this._element)}_getItems(){return R.find(vt,this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(e){return g()?e===ot?at:st:e===ot?st:at}_orderToDirection(e){return g()?e===at?ot:rt:e===at?rt:ot}static jQueryInterface(e){return this.each((function(){const t=Et.getOrCreateInstance(this,e);if("number"!=typeof e){if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}else t.to(e)}))}}M.on(document,gt,"[data-bs-slide], [data-bs-slide-to]",(function(e){const t=R.getElementFromSelector(this);if(!t||!t.classList.contains(pt))return;e.preventDefault();const i=Et.getOrCreateInstance(t),n=this.getAttribute("data-bs-slide-to");return n?(i.to(n),void i._maybeEnableCycle()):"next"===F.getDataAttribute(this,"slide")?(i.next(),void i._maybeEnableCycle()):(i.prev(),void i._maybeEnableCycle())})),M.on(window,ft,(()=>{const e=R.find('[data-bs-ride="carousel"]');for(const t of e)Et.getOrCreateInstance(t)})),p(Et);const Lt=".bs.collapse",Tt=`show${Lt}`,Ct=`shown${Lt}`,At=`hide${Lt}`,xt=`hidden${Lt}`,Ot=`click${Lt}.data-api`,$t="show",St="collapse",Nt="collapsing",It=`:scope .${St} .${St}`,Mt='[data-bs-toggle="collapse"]',Pt={parent:null,toggle:!0},jt={parent:"(null|element)",toggle:"boolean"};class Bt extends z{constructor(e,t){super(e,t),this._isTransitioning=!1,this._triggerArray=[];const i=R.find(Mt);for(const e of i){const t=R.getSelectorFromElement(e),i=R.find(t).filter((e=>e===this._element));null!==t&&i.length&&this._triggerArray.push(e)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return Pt}static get DefaultType(){return jt}static get NAME(){return"collapse"}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let e=[];if(this._config.parent&&(e=this._getFirstLevelChildren(".collapse.show, .collapse.collapsing").filter((e=>e!==this._element)).map((e=>Bt.getOrCreateInstance(e,{toggle:!1})))),e.length&&e[0]._isTransitioning)return;if(M.trigger(this._element,Tt).defaultPrevented)return;for(const t of e)t.hide();const t=this._getDimension();this._element.classList.remove(St),this._element.classList.add(Nt),this._element.style[t]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=`scroll${t[0].toUpperCase()+t.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(Nt),this._element.classList.add(St,$t),this._element.style[t]="",M.trigger(this._element,Ct)}),this._element,!0),this._element.style[t]=`${this._element[i]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(M.trigger(this._element,At).defaultPrevented)return;const e=this._getDimension();this._element.style[e]=`${this._element.getBoundingClientRect()[e]}px`,u(this._element),this._element.classList.add(Nt),this._element.classList.remove(St,$t);for(const e of this._triggerArray){const t=R.getElementFromSelector(e);t&&!this._isShown(t)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0,this._element.style[e]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(Nt),this._element.classList.add(St),M.trigger(this._element,xt)}),this._element,!0)}_isShown(e=this._element){return e.classList.contains($t)}_configAfterMerge(e){return e.toggle=Boolean(e.toggle),e.parent=r(e.parent),e}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const e=this._getFirstLevelChildren(Mt);for(const t of e){const e=R.getElementFromSelector(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}}_getFirstLevelChildren(e){const t=R.find(It,this._config.parent);return R.find(e,this._config.parent).filter((e=>!t.includes(e)))}_addAriaAndCollapsedClass(e,t){if(e.length)for(const i of e)i.classList.toggle("collapsed",!t),i.setAttribute("aria-expanded",t)}static jQueryInterface(e){const t={};return"string"==typeof e&&/show|hide/.test(e)&&(t.toggle=!1),this.each((function(){const i=Bt.getOrCreateInstance(this,t);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}))}}M.on(document,Ot,Mt,(function(e){("A"===e.target.tagName||e.delegateTarget&&"A"===e.delegateTarget.tagName)&&e.preventDefault();for(const e of R.getMultipleElementsFromSelector(this))Bt.getOrCreateInstance(e,{toggle:!1}).toggle()})),p(Bt);var Ft="top",Ht="bottom",zt="right",Vt="left",Rt="auto",Wt=[Ft,Ht,zt,Vt],Yt="start",qt="end",Ut="clippingParents",Qt="viewport",Kt="popper",Xt="reference",Gt=Wt.reduce((function(e,t){return e.concat([t+"-"+Yt,t+"-"+qt])}),[]),Zt=[].concat(Wt,[Rt]).reduce((function(e,t){return e.concat([t,t+"-"+Yt,t+"-"+qt])}),[]),Jt="beforeRead",ei="read",ti="afterRead",ii="beforeMain",ni="main",si="afterMain",ai="beforeWrite",oi="write",ri="afterWrite",li=[Jt,ei,ti,ii,ni,si,ai,oi,ri];function ci(e){return e?(e.nodeName||"").toLowerCase():null}function hi(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function di(e){return e instanceof hi(e).Element||e instanceof Element}function ui(e){return e instanceof hi(e).HTMLElement||e instanceof HTMLElement}function _i(e){return"undefined"!=typeof ShadowRoot&&(e instanceof hi(e).ShadowRoot||e instanceof ShadowRoot)}const fi={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach((function(e){var i=t.styles[e]||{},n=t.attributes[e]||{},s=t.elements[e];ui(s)&&ci(s)&&(Object.assign(s.style,i),Object.keys(n).forEach((function(e){var t=n[e];!1===t?s.removeAttribute(e):s.setAttribute(e,!0===t?"":t)})))}))},effect:function(e){var t=e.state,i={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,i.popper),t.styles=i,t.elements.arrow&&Object.assign(t.elements.arrow.style,i.arrow),function(){Object.keys(t.elements).forEach((function(e){var n=t.elements[e],s=t.attributes[e]||{},a=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:i[e]).reduce((function(e,t){return e[t]="",e}),{});ui(n)&&ci(n)&&(Object.assign(n.style,a),Object.keys(s).forEach((function(e){n.removeAttribute(e)})))}))}},requires:["computeStyles"]};function gi(e){return e.split("-")[0]}var pi=Math.max,mi=Math.min,bi=Math.round;function vi(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map((function(e){return e.brand+"/"+e.version})).join(" "):navigator.userAgent}function yi(){return!/^((?!chrome|android).)*safari/i.test(vi())}function wi(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);var n=e.getBoundingClientRect(),s=1,a=1;t&&ui(e)&&(s=e.offsetWidth>0&&bi(n.width)/e.offsetWidth||1,a=e.offsetHeight>0&&bi(n.height)/e.offsetHeight||1);var o=(di(e)?hi(e):window).visualViewport,r=!yi()&&i,l=(n.left+(r&&o?o.offsetLeft:0))/s,c=(n.top+(r&&o?o.offsetTop:0))/a,h=n.width/s,d=n.height/a;return{width:h,height:d,top:c,right:l+h,bottom:c+d,left:l,x:l,y:c}}function Di(e){var t=wi(e),i=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-i)<=1&&(i=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:i,height:n}}function ki(e,t){var i=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(i&&_i(i)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Ei(e){return hi(e).getComputedStyle(e)}function Li(e){return["table","td","th"].indexOf(ci(e))>=0}function Ti(e){return((di(e)?e.ownerDocument:e.document)||window.document).documentElement}function Ci(e){return"html"===ci(e)?e:e.assignedSlot||e.parentNode||(_i(e)?e.host:null)||Ti(e)}function Ai(e){return ui(e)&&"fixed"!==Ei(e).position?e.offsetParent:null}function xi(e){for(var t=hi(e),i=Ai(e);i&&Li(i)&&"static"===Ei(i).position;)i=Ai(i);return i&&("html"===ci(i)||"body"===ci(i)&&"static"===Ei(i).position)?t:i||function(e){var t=/firefox/i.test(vi());if(/Trident/i.test(vi())&&ui(e)&&"fixed"===Ei(e).position)return null;var i=Ci(e);for(_i(i)&&(i=i.host);ui(i)&&["html","body"].indexOf(ci(i))<0;){var n=Ei(i);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return i;i=i.parentNode}return null}(e)||t}function Oi(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function $i(e,t,i){return pi(e,mi(t,i))}function Si(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function Ni(e,t){return t.reduce((function(t,i){return t[i]=e,t}),{})}const Ii={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,i=e.state,n=e.name,s=e.options,a=i.elements.arrow,o=i.modifiersData.popperOffsets,r=gi(i.placement),l=Oi(r),c=[Vt,zt].indexOf(r)>=0?"height":"width";if(a&&o){var h=function(e,t){return Si("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:Ni(e,Wt))}(s.padding,i),d=Di(a),u="y"===l?Ft:Vt,_="y"===l?Ht:zt,f=i.rects.reference[c]+i.rects.reference[l]-o[l]-i.rects.popper[c],g=o[l]-i.rects.reference[l],p=xi(a),m=p?"y"===l?p.clientHeight||0:p.clientWidth||0:0,b=f/2-g/2,v=h[u],y=m-d[c]-h[_],w=m/2-d[c]/2+b,D=$i(v,w,y),k=l;i.modifiersData[n]=((t={})[k]=D,t.centerOffset=D-w,t)}},effect:function(e){var t=e.state,i=e.options.element,n=void 0===i?"[data-popper-arrow]":i;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&ki(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Mi(e){return e.split("-")[1]}var Pi={top:"auto",right:"auto",bottom:"auto",left:"auto"};function ji(e){var t,i=e.popper,n=e.popperRect,s=e.placement,a=e.variation,o=e.offsets,r=e.position,l=e.gpuAcceleration,c=e.adaptive,h=e.roundOffsets,d=e.isFixed,u=o.x,_=void 0===u?0:u,f=o.y,g=void 0===f?0:f,p="function"==typeof h?h({x:_,y:g}):{x:_,y:g};_=p.x,g=p.y;var m=o.hasOwnProperty("x"),b=o.hasOwnProperty("y"),v=Vt,y=Ft,w=window;if(c){var D=xi(i),k="clientHeight",E="clientWidth";D===hi(i)&&"static"!==Ei(D=Ti(i)).position&&"absolute"===r&&(k="scrollHeight",E="scrollWidth"),(s===Ft||(s===Vt||s===zt)&&a===qt)&&(y=Ht,g-=(d&&D===w&&w.visualViewport?w.visualViewport.height:D[k])-n.height,g*=l?1:-1),s!==Vt&&(s!==Ft&&s!==Ht||a!==qt)||(v=zt,_-=(d&&D===w&&w.visualViewport?w.visualViewport.width:D[E])-n.width,_*=l?1:-1)}var L,T=Object.assign({position:r},c&&Pi),C=!0===h?function(e,t){var i=e.x,n=e.y,s=t.devicePixelRatio||1;return{x:bi(i*s)/s||0,y:bi(n*s)/s||0}}({x:_,y:g},hi(i)):{x:_,y:g};return _=C.x,g=C.y,l?Object.assign({},T,((L={})[y]=b?"0":"",L[v]=m?"0":"",L.transform=(w.devicePixelRatio||1)<=1?"translate("+_+"px, "+g+"px)":"translate3d("+_+"px, "+g+"px, 0)",L)):Object.assign({},T,((t={})[y]=b?g+"px":"",t[v]=m?_+"px":"",t.transform="",t))}const Bi={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,i=e.options,n=i.gpuAcceleration,s=void 0===n||n,a=i.adaptive,o=void 0===a||a,r=i.roundOffsets,l=void 0===r||r,c={placement:gi(t.placement),variation:Mi(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,ji(Object.assign({},c,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:l})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,ji(Object.assign({},c,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}};var Fi={passive:!0};const Hi={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,i=e.instance,n=e.options,s=n.scroll,a=void 0===s||s,o=n.resize,r=void 0===o||o,l=hi(t.elements.popper),c=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&c.forEach((function(e){e.addEventListener("scroll",i.update,Fi)})),r&&l.addEventListener("resize",i.update,Fi),function(){a&&c.forEach((function(e){e.removeEventListener("scroll",i.update,Fi)})),r&&l.removeEventListener("resize",i.update,Fi)}},data:{}};var zi={left:"right",right:"left",bottom:"top",top:"bottom"};function Vi(e){return e.replace(/left|right|bottom|top/g,(function(e){return zi[e]}))}var Ri={start:"end",end:"start"};function Wi(e){return e.replace(/start|end/g,(function(e){return Ri[e]}))}function Yi(e){var t=hi(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function qi(e){return wi(Ti(e)).left+Yi(e).scrollLeft}function Ui(e){var t=Ei(e),i=t.overflow,n=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(i+s+n)}function Qi(e){return["html","body","#document"].indexOf(ci(e))>=0?e.ownerDocument.body:ui(e)&&Ui(e)?e:Qi(Ci(e))}function Ki(e,t){var i;void 0===t&&(t=[]);var n=Qi(e),s=n===(null==(i=e.ownerDocument)?void 0:i.body),a=hi(n),o=s?[a].concat(a.visualViewport||[],Ui(n)?n:[]):n,r=t.concat(o);return s?r:r.concat(Ki(Ci(o)))}function Xi(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Gi(e,t,i){return t===Qt?Xi(function(e,t){var i=hi(e),n=Ti(e),s=i.visualViewport,a=n.clientWidth,o=n.clientHeight,r=0,l=0;if(s){a=s.width,o=s.height;var c=yi();(c||!c&&"fixed"===t)&&(r=s.offsetLeft,l=s.offsetTop)}return{width:a,height:o,x:r+qi(e),y:l}}(e,i)):di(t)?function(e,t){var i=wi(e,!1,"fixed"===t);return i.top=i.top+e.clientTop,i.left=i.left+e.clientLeft,i.bottom=i.top+e.clientHeight,i.right=i.left+e.clientWidth,i.width=e.clientWidth,i.height=e.clientHeight,i.x=i.left,i.y=i.top,i}(t,i):Xi(function(e){var t,i=Ti(e),n=Yi(e),s=null==(t=e.ownerDocument)?void 0:t.body,a=pi(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),o=pi(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),r=-n.scrollLeft+qi(e),l=-n.scrollTop;return"rtl"===Ei(s||i).direction&&(r+=pi(i.clientWidth,s?s.clientWidth:0)-a),{width:a,height:o,x:r,y:l}}(Ti(e)))}function Zi(e){var t,i=e.reference,n=e.element,s=e.placement,a=s?gi(s):null,o=s?Mi(s):null,r=i.x+i.width/2-n.width/2,l=i.y+i.height/2-n.height/2;switch(a){case Ft:t={x:r,y:i.y-n.height};break;case Ht:t={x:r,y:i.y+i.height};break;case zt:t={x:i.x+i.width,y:l};break;case Vt:t={x:i.x-n.width,y:l};break;default:t={x:i.x,y:i.y}}var c=a?Oi(a):null;if(null!=c){var h="y"===c?"height":"width";switch(o){case Yt:t[c]=t[c]-(i[h]/2-n[h]/2);break;case qt:t[c]=t[c]+(i[h]/2-n[h]/2)}}return t}function Ji(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=void 0===n?e.placement:n,a=i.strategy,o=void 0===a?e.strategy:a,r=i.boundary,l=void 0===r?Ut:r,c=i.rootBoundary,h=void 0===c?Qt:c,d=i.elementContext,u=void 0===d?Kt:d,_=i.altBoundary,f=void 0!==_&&_,g=i.padding,p=void 0===g?0:g,m=Si("number"!=typeof p?p:Ni(p,Wt)),b=u===Kt?Xt:Kt,v=e.rects.popper,y=e.elements[f?b:u],w=function(e,t,i,n){var s="clippingParents"===t?function(e){var t=Ki(Ci(e)),i=["absolute","fixed"].indexOf(Ei(e).position)>=0&&ui(e)?xi(e):e;return di(i)?t.filter((function(e){return di(e)&&ki(e,i)&&"body"!==ci(e)})):[]}(e):[].concat(t),a=[].concat(s,[i]),o=a[0],r=a.reduce((function(t,i){var s=Gi(e,i,n);return t.top=pi(s.top,t.top),t.right=mi(s.right,t.right),t.bottom=mi(s.bottom,t.bottom),t.left=pi(s.left,t.left),t}),Gi(e,o,n));return r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}(di(y)?y:y.contextElement||Ti(e.elements.popper),l,h,o),D=wi(e.elements.reference),k=Zi({reference:D,element:v,strategy:"absolute",placement:s}),E=Xi(Object.assign({},v,k)),L=u===Kt?E:D,T={top:w.top-L.top+m.top,bottom:L.bottom-w.bottom+m.bottom,left:w.left-L.left+m.left,right:L.right-w.right+m.right},C=e.modifiersData.offset;if(u===Kt&&C){var A=C[s];Object.keys(T).forEach((function(e){var t=[zt,Ht].indexOf(e)>=0?1:-1,i=[Ft,Ht].indexOf(e)>=0?"y":"x";T[e]+=A[i]*t}))}return T}function en(e,t){void 0===t&&(t={});var i=t,n=i.placement,s=i.boundary,a=i.rootBoundary,o=i.padding,r=i.flipVariations,l=i.allowedAutoPlacements,c=void 0===l?Zt:l,h=Mi(n),d=h?r?Gt:Gt.filter((function(e){return Mi(e)===h})):Wt,u=d.filter((function(e){return c.indexOf(e)>=0}));0===u.length&&(u=d);var _=u.reduce((function(t,i){return t[i]=Ji(e,{placement:i,boundary:s,rootBoundary:a,padding:o})[gi(i)],t}),{});return Object.keys(_).sort((function(e,t){return _[e]-_[t]}))}const tn={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var s=i.mainAxis,a=void 0===s||s,o=i.altAxis,r=void 0===o||o,l=i.fallbackPlacements,c=i.padding,h=i.boundary,d=i.rootBoundary,u=i.altBoundary,_=i.flipVariations,f=void 0===_||_,g=i.allowedAutoPlacements,p=t.options.placement,m=gi(p),b=l||(m!==p&&f?function(e){if(gi(e)===Rt)return[];var t=Vi(e);return[Wi(e),t,Wi(t)]}(p):[Vi(p)]),v=[p].concat(b).reduce((function(e,i){return e.concat(gi(i)===Rt?en(t,{placement:i,boundary:h,rootBoundary:d,padding:c,flipVariations:f,allowedAutoPlacements:g}):i)}),[]),y=t.rects.reference,w=t.rects.popper,D=new Map,k=!0,E=v[0],L=0;L<v.length;L++){var T=v[L],C=gi(T),A=Mi(T)===Yt,x=[Ft,Ht].indexOf(C)>=0,O=x?"width":"height",$=Ji(t,{placement:T,boundary:h,rootBoundary:d,altBoundary:u,padding:c}),S=x?A?zt:Vt:A?Ht:Ft;y[O]>w[O]&&(S=Vi(S));var N=Vi(S),I=[];if(a&&I.push($[C]<=0),r&&I.push($[S]<=0,$[N]<=0),I.every((function(e){return e}))){E=T,k=!1;break}D.set(T,I)}if(k)for(var M=function(e){var t=v.find((function(t){var i=D.get(t);if(i)return i.slice(0,e).every((function(e){return e}))}));if(t)return E=t,"break"},P=f?3:1;P>0&&"break"!==M(P);P--);t.placement!==E&&(t.modifiersData[n]._skip=!0,t.placement=E,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function nn(e,t,i){return void 0===i&&(i={x:0,y:0}),{top:e.top-t.height-i.y,right:e.right-t.width+i.x,bottom:e.bottom-t.height+i.y,left:e.left-t.width-i.x}}function sn(e){return[Ft,zt,Ht,Vt].some((function(t){return e[t]>=0}))}const an={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,i=e.name,n=t.rects.reference,s=t.rects.popper,a=t.modifiersData.preventOverflow,o=Ji(t,{elementContext:"reference"}),r=Ji(t,{altBoundary:!0}),l=nn(o,n),c=nn(r,s,a),h=sn(l),d=sn(c);t.modifiersData[i]={referenceClippingOffsets:l,popperEscapeOffsets:c,isReferenceHidden:h,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":h,"data-popper-escaped":d})}},on={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,i=e.options,n=e.name,s=i.offset,a=void 0===s?[0,0]:s,o=Zt.reduce((function(e,i){return e[i]=function(e,t,i){var n=gi(e),s=[Vt,Ft].indexOf(n)>=0?-1:1,a="function"==typeof i?i(Object.assign({},t,{placement:e})):i,o=a[0],r=a[1];return o=o||0,r=(r||0)*s,[Vt,zt].indexOf(n)>=0?{x:r,y:o}:{x:o,y:r}}(i,t.rects,a),e}),{}),r=o[t.placement],l=r.x,c=r.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=c),t.modifiersData[n]=o}},rn={name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,i=e.name;t.modifiersData[i]=Zi({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},ln={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,i=e.options,n=e.name,s=i.mainAxis,a=void 0===s||s,o=i.altAxis,r=void 0!==o&&o,l=i.boundary,c=i.rootBoundary,h=i.altBoundary,d=i.padding,u=i.tether,_=void 0===u||u,f=i.tetherOffset,g=void 0===f?0:f,p=Ji(t,{boundary:l,rootBoundary:c,padding:d,altBoundary:h}),m=gi(t.placement),b=Mi(t.placement),v=!b,y=Oi(m),w="x"===y?"y":"x",D=t.modifiersData.popperOffsets,k=t.rects.reference,E=t.rects.popper,L="function"==typeof g?g(Object.assign({},t.rects,{placement:t.placement})):g,T="number"==typeof L?{mainAxis:L,altAxis:L}:Object.assign({mainAxis:0,altAxis:0},L),C=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,A={x:0,y:0};if(D){if(a){var x,O="y"===y?Ft:Vt,$="y"===y?Ht:zt,S="y"===y?"height":"width",N=D[y],I=N+p[O],M=N-p[$],P=_?-E[S]/2:0,j=b===Yt?k[S]:E[S],B=b===Yt?-E[S]:-k[S],F=t.elements.arrow,H=_&&F?Di(F):{width:0,height:0},z=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},V=z[O],R=z[$],W=$i(0,k[S],H[S]),Y=v?k[S]/2-P-W-V-T.mainAxis:j-W-V-T.mainAxis,q=v?-k[S]/2+P+W+R+T.mainAxis:B+W+R+T.mainAxis,U=t.elements.arrow&&xi(t.elements.arrow),Q=U?"y"===y?U.clientTop||0:U.clientLeft||0:0,K=null!=(x=null==C?void 0:C[y])?x:0,X=N+q-K,G=$i(_?mi(I,N+Y-K-Q):I,N,_?pi(M,X):M);D[y]=G,A[y]=G-N}if(r){var Z,J="x"===y?Ft:Vt,ee="x"===y?Ht:zt,te=D[w],ie="y"===w?"height":"width",ne=te+p[J],se=te-p[ee],ae=-1!==[Ft,Vt].indexOf(m),oe=null!=(Z=null==C?void 0:C[w])?Z:0,re=ae?ne:te-k[ie]-E[ie]-oe+T.altAxis,le=ae?te+k[ie]+E[ie]-oe-T.altAxis:se,ce=_&&ae?function(e,t,i){var n=$i(e,t,i);return n>i?i:n}(re,te,le):$i(_?re:ne,te,_?le:se);D[w]=ce,A[w]=ce-te}t.modifiersData[n]=A}},requiresIfExists:["offset"]};function cn(e,t,i){void 0===i&&(i=!1);var n,s,a=ui(t),o=ui(t)&&function(e){var t=e.getBoundingClientRect(),i=bi(t.width)/e.offsetWidth||1,n=bi(t.height)/e.offsetHeight||1;return 1!==i||1!==n}(t),r=Ti(t),l=wi(e,o,i),c={scrollLeft:0,scrollTop:0},h={x:0,y:0};return(a||!a&&!i)&&(("body"!==ci(t)||Ui(r))&&(c=(n=t)!==hi(n)&&ui(n)?{scrollLeft:(s=n).scrollLeft,scrollTop:s.scrollTop}:Yi(n)),ui(t)?((h=wi(t,!0)).x+=t.clientLeft,h.y+=t.clientTop):r&&(h.x=qi(r))),{x:l.left+c.scrollLeft-h.x,y:l.top+c.scrollTop-h.y,width:l.width,height:l.height}}function hn(e){var t=new Map,i=new Set,n=[];function s(e){i.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach((function(e){if(!i.has(e)){var n=t.get(e);n&&s(n)}})),n.push(e)}return e.forEach((function(e){t.set(e.name,e)})),e.forEach((function(e){i.has(e.name)||s(e)})),n}var dn={placement:"bottom",modifiers:[],strategy:"absolute"};function un(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return!t.some((function(e){return!(e&&"function"==typeof e.getBoundingClientRect)}))}function _n(e){void 0===e&&(e={});var t=e,i=t.defaultModifiers,n=void 0===i?[]:i,s=t.defaultOptions,a=void 0===s?dn:s;return function(e,t,i){void 0===i&&(i=a);var s,o,r={placement:"bottom",orderedModifiers:[],options:Object.assign({},dn,a),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},l=[],c=!1,h={state:r,setOptions:function(i){var s="function"==typeof i?i(r.options):i;d(),r.options=Object.assign({},a,r.options,s),r.scrollParents={reference:di(e)?Ki(e):e.contextElement?Ki(e.contextElement):[],popper:Ki(t)};var o,c,u=function(e){var t=hn(e);return li.reduce((function(e,i){return e.concat(t.filter((function(e){return e.phase===i})))}),[])}((o=[].concat(n,r.options.modifiers),c=o.reduce((function(e,t){var i=e[t.name];return e[t.name]=i?Object.assign({},i,t,{options:Object.assign({},i.options,t.options),data:Object.assign({},i.data,t.data)}):t,e}),{}),Object.keys(c).map((function(e){return c[e]}))));return r.orderedModifiers=u.filter((function(e){return e.enabled})),r.orderedModifiers.forEach((function(e){var t=e.name,i=e.options,n=void 0===i?{}:i,s=e.effect;if("function"==typeof s){var a=s({state:r,name:t,instance:h,options:n});l.push(a||function(){})}})),h.update()},forceUpdate:function(){if(!c){var e=r.elements,t=e.reference,i=e.popper;if(un(t,i)){r.rects={reference:cn(t,xi(i),"fixed"===r.options.strategy),popper:Di(i)},r.reset=!1,r.placement=r.options.placement,r.orderedModifiers.forEach((function(e){return r.modifiersData[e.name]=Object.assign({},e.data)}));for(var n=0;n<r.orderedModifiers.length;n++)if(!0!==r.reset){var s=r.orderedModifiers[n],a=s.fn,o=s.options,l=void 0===o?{}:o,d=s.name;"function"==typeof a&&(r=a({state:r,options:l,name:d,instance:h})||r)}else r.reset=!1,n=-1}}},update:(s=function(){return new Promise((function(e){h.forceUpdate(),e(r)}))},function(){return o||(o=new Promise((function(e){Promise.resolve().then((function(){o=void 0,e(s())}))}))),o}),destroy:function(){d(),c=!0}};if(!un(e,t))return h;function d(){l.forEach((function(e){return e()})),l=[]}return h.setOptions(i).then((function(e){!c&&i.onFirstUpdate&&i.onFirstUpdate(e)})),h}}var fn=_n(),gn=_n({defaultModifiers:[Hi,rn,Bi,fi]}),pn=_n({defaultModifiers:[Hi,rn,Bi,fi,on,tn,ln,Ii,an]});const mn=Object.freeze(Object.defineProperty({__proto__:null,afterMain:si,afterRead:ti,afterWrite:ri,applyStyles:fi,arrow:Ii,auto:Rt,basePlacements:Wt,beforeMain:ii,beforeRead:Jt,beforeWrite:ai,bottom:Ht,clippingParents:Ut,computeStyles:Bi,createPopper:pn,createPopperBase:fn,createPopperLite:gn,detectOverflow:Ji,end:qt,eventListeners:Hi,flip:tn,hide:an,left:Vt,main:ni,modifierPhases:li,offset:on,placements:Zt,popper:Kt,popperGenerator:_n,popperOffsets:rn,preventOverflow:ln,read:ei,reference:Xt,right:zt,start:Yt,top:Ft,variationPlacements:Gt,viewport:Qt,write:oi},Symbol.toStringTag,{value:"Module"})),bn=(e,t)=>e.toLocaleTimeString(t).includes("AM")?"am":e.toLocaleTimeString(t).includes("PM")||e.getHours()>=12?"pm":"am",vn=(e,t,i)=>{const n=new Date,s=new Intl.DateTimeFormat(t,{hour:"numeric",minute:"2-digit",second:"2-digit"});return e.map((e=>{var t;return"hour"===i&&n.setHours(e),"minute"===i&&n.setMinutes(e),"second"===i&&n.setSeconds(e),{value:e,label:(null==(t=s.formatToParts(n).find((e=>e.type===i)))?void 0:t.value)||""}}))},yn=e=>["am","AM","pm","PM"].some((t=>(new Date).toLocaleString(e).includes(t))),wn=".bs.time-picker",Dn=".data-api",kn="Enter",En=`click${wn}`,Ln=`hide${wn}`,Tn=`hidden${wn}`,Cn=`keydown${wn}`,An=`show${wn}`,xn=`shown${wn}`,On=`timeChange${wn}`,$n=`click${wn}${Dn}`,Sn=`keyup${wn}${Dn}`,Nn=`load${wn}${Dn}`,In="is-invalid",Mn="is-valid",Pn="selected",jn="show",Bn="time-picker",Fn='[data-bs-toggle="time-picker"]:not(.disabled):not(:disabled)',Hn=`${Fn}.${jn}`,zn={cancelButton:"Cancel",cancelButtonClasses:["btn","btn-sm","btn-ghost-primary"],cleaner:!0,confirmButton:"OK",confirmButtonClasses:["btn","btn-sm","btn-primary"],container:!1,disabled:!1,footer:!0,hours:null,indicator:!0,inputReadOnly:!1,invalid:!1,locale:"default",minutes:!0,name:null,placeholder:"Select time",required:!0,seconds:!0,size:null,time:null,type:"dropdown",valid:!1,variant:"roll"},Vn={cancelButton:"(boolean|string)",cancelButtonClasses:"(array|string)",cleaner:"boolean",confirmButton:"(boolean|string)",confirmButtonClasses:"(array|string)",container:"(string|element|boolean)",disabled:"boolean",footer:"boolean",hours:"(array|function|null)",indicator:"boolean",inputReadOnly:"boolean",invalid:"boolean",locale:"string",minutes:"(array|boolean|function)",name:"(string|null)",placeholder:"string",required:"boolean",seconds:"(array|boolean|function)",size:"(string|null)",time:"(date|string|null)",type:"string",valid:"boolean",variant:"string"};class Rn extends z{constructor(e,t){super(e),this._handleTimeChange=(e,t)=>{const i=this._date||new Date("1970-01-01");var n,s;"toggle"===e&&("am"===t&&(this._ampm="am",i.setHours(i.getHours()-12)),"pm"===t&&(this._ampm="pm",i.setHours(i.getHours()+12))),"hours"===e&&(yn(this._config.locale)?i.setHours((n=this._ampm,s=Number.parseInt(t,10),"am"===n&&12===s?0:"am"===n?s:"pm"===n&&12===s?12:s+12)):i.setHours(Number.parseInt(t,10))),"minutes"===e&&i.setMinutes(Number.parseInt(t,10)),"seconds"===e&&i.setSeconds(Number.parseInt(t,10)),this._date=new Date(i),this._input&&(this._setInputValue(i),this._input.dispatchEvent(new Event("change"))),M.trigger(this._element,On,{timeString:i.toTimeString(),localeTimeString:i.toLocaleTimeString(),date:i})},this._config=this._getConfig(t),this._date=this._convertStringToDate(this._config.time),this._initialDate=null,this._ampm=this._date?bn(new Date(this._date),this._config.locale):"am",this._popper=null,this._indicatorElement=null,this._input=null,this._menu=null,this._timePickerBody=null,this._localizedTimePartials=((e,t="auto",i=[],n=[],s=[])=>{const a="auto"===t&&yn(e)||!0===t,o=Array.isArray(i)&&i.length>0?i:"function"==typeof i?Array.from({length:a?12:24},((e,t)=>a?t+1:t)).filter((e=>i(e))):Array.from({length:a?12:24},((e,t)=>a?t+1:t)),r=Array.isArray(n)&&n.length>0?n:"function"==typeof n?Array.from({length:60},((e,t)=>t)).filter((e=>n(e))):Array.from({length:60},((e,t)=>t)),l=Array.isArray(s)&&s.length>0?s:"function"==typeof s?Array.from({length:60},((e,t)=>t)).filter((e=>s(e))):Array.from({length:60},((e,t)=>t));return{listOfHours:vn(o,e,"hour"),listOfMinutes:vn(r,e,"minute"),listOfSeconds:vn(l,e,"second"),hour12:a}})(this._config.locale,this.ampm,this._config.hours,this._config.minutes,this._config.seconds),this._createTimePicker(),this._createTimePickerSelection(),this._addEventListeners(),this._setUpSelects()}static get Default(){return zn}static get DefaultType(){return Vn}static get NAME(){return"time-picker"}toggle(){return this._isShown()?this.hide():this.show()}show(){this._config.disabled||this._isShown()||(this._initialDate=new Date(this._date),M.trigger(this._element,An),this._element.classList.add(jn),this._element.setAttribute("aria-expanded",!0),this._config.container&&this._menu.classList.add(jn),M.trigger(this._element,xn),this._createPopper())}hide(){M.trigger(this._element,Ln),this._popper&&this._popper.destroy(),this._element.classList.remove(jn),this._element.setAttribute("aria-expanded","false"),this._config.container&&this._menu.classList.remove(jn),M.trigger(this._element,Tn)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}cancel(){this._date=this._initialDate,this._setInputValue(this._initialDate||""),this._timePickerBody.innerHTML="",this.hide(),this._createTimePickerSelection(),this._emitChangeEvent(this._date)}clear(){this._date=null,this._setInputValue(""),this._timePickerBody.innerHTML="",this._createTimePickerSelection(),this._emitChangeEvent(this._date)}reset(){this._date=this._convertStringToDate(this._config.time),this._setInputValue(this._config.time),this._timePickerBody.innerHTML="",this._createTimePickerSelection(),this._emitChangeEvent(this._date)}update(e){this._config=this._getConfig(e),this._date=this._convertStringToDate(this._config.time),this._ampm=this._date?bn(new Date(this._date),this._config.locale):"am",this._timePickerBody.innerHTML="",this._createTimePickerSelection()}_addEventListeners(){M.on(this._indicatorElement,En,(()=>{this._config.disabled||this.toggle()})),M.on(this._indicatorElement,Cn,(e=>{this._config.disabled||e.key!==kn||this.toggle()})),M.on(this._togglerElement,En,(e=>{this._config.disabled||e.target===this._indicatorElement||(this.show(),"roll"===this._config.variant&&this._setUpRolls(!0),"select"===this._config.variant&&this._setUpSelects())})),M.on(this._element,Cn,(e=>{"Escape"===e.key&&this.hide()})),M.on(this._element,"timeChange.bs.time-picker",(()=>{"roll"===this._config.variant&&this._setUpRolls(),"select"===this._config.variant&&this._setUpSelects()})),M.on(this._element,"onCancelClick.bs.picker",(()=>{this.cancel()})),M.on(this._input,"input",(e=>{(e=>{const t=new Date(`1970-01-01 ${e}`);return t instanceof Date&&!Number.isNaN(t.getTime())})(e.target.value)&&(this._date=this._convertStringToDate(e.target.value),M.trigger(this._element,On,{timeString:this._date?this._date.toTimeString():null,localeTimeString:this._date?this._date.toLocaleTimeString():null,date:this._date}))})),"dropdown"===this._config.type&&M.on(this._input.form,"submit",(()=>{if(this._input.form.classList.contains("was-validated")){if(Number.isNaN(Date.parse(`1970-01-01 ${this._input.value}`)))return this._element.classList.add(In);if(this._date instanceof Date)return this._element.classList.add(Mn);this._element.classList.add(In)}}))}_createTimePicker(){if(this._element.classList.add(Bn),F.setDataAttribute(this._element,"toggle",Bn),this._config.size&&this._element.classList.add(`time-picker-${this._config.size}`),this._element.classList.toggle(Mn,this._config.valid),this._config.disabled&&this._element.classList.add("disabled"),this._element.classList.toggle(In,this._config.invalid),"dropdown"===this._config.type){this._element.append(this._createTimePickerInputGroup());const e=document.createElement("div");e.classList.add("time-picker-dropdown"),e.append(this._createTimePickerBody()),(this._config.footer||this._config.timepicker)&&e.append(this._createTimePickerFooter());const{container:t}=this._config;t?t.append(e):this._element.append(e),this._menu=e}"inline"===this._config.type&&this._element.append(this._createTimePickerBody())}_createTimePickerInputGroup(){const e=document.createElement("div");e.classList.add("time-picker-input-group");const t=document.createElement("input");t.classList.add("time-picker-input"),t.autocomplete="off",t.disabled=this._config.disabled,t.placeholder=this._config.placeholder,t.readOnly=this._config.inputReadOnly,t.required=this._config.required,t.type="text",this._setInputValue(this._date||"",t),(this._config.name||this._element.id)&&(t.name=this._config.name||`time-picker-${this._element.id}`);const i=["change","keyup","paste"];for(const e of i)t.addEventListener(e,(({target:e})=>{if(e.closest("form.was-validated")){if(Number.isNaN(Date.parse(`1970-01-01 ${e.value}`)))return this._element.classList.add(In),void this._element.classList.remove(Mn);if(this._date instanceof Date)return this._element.classList.add(Mn),void this._element.classList.remove(In);this._element.classList.add(In),this._element.classList.remove(Mn)}}));if(e.append(t),this._config.indicator){const t=document.createElement("div");t.classList.add("time-picker-indicator"),this._config.disabled||(t.tabIndex=0),e.append(t),this._indicatorElement=t}if(this._config.cleaner){const t=document.createElement("div");t.classList.add("time-picker-cleaner"),t.addEventListener("click",(e=>{e.stopPropagation(),this.clear()})),e.append(t)}return this._input=t,this._togglerElement=e,e}_createTimePickerSelection(){"roll"===this._config.variant&&this._createTimePickerRoll(),"select"===this._config.variant&&this._createTimePickerInlineSelects()}_createTimePickerBody(){const e=document.createElement("div");return e.classList.add("time-picker-body"),"roll"===this._config.variant&&e.classList.add("time-picker-roll"),this._timePickerBody=e,e}_createTimePickerInlineSelect(e,t){const i=document.createElement("select");i.classList.add("time-picker-inline-select",e),i.disabled=this._config.disabled,i.addEventListener("change",(t=>this._handleTimeChange(e,t.target.value)));for(const e of t){const t=document.createElement("option");t.value=e.value,t.innerHTML=e.label,i.append(t)}return i}_createTimePickerInlineSelects(){const e=document.createElement("div");e.innerHTML=":",this._timePickerBody.innerHTML='<span class="time-picker-inline-icon"></span>',this._timePickerBody.append(this._createTimePickerInlineSelect("hours",this._localizedTimePartials.listOfHours)),this._config.minutes&&this._timePickerBody.append(e.cloneNode(!0),this._createTimePickerInlineSelect("minutes",this._localizedTimePartials.listOfMinutes)),this._config.seconds&&this._timePickerBody.append(e,this._createTimePickerInlineSelect("seconds",this._localizedTimePartials.listOfSeconds)),this._localizedTimePartials.hour12&&this._timePickerBody.append(this._createTimePickerInlineSelect("toggle",[{value:"am",label:"AM"},{value:"pm",label:"PM"}],"_selectAmPm",this._ampm))}_createTimePickerRoll(){this._timePickerBody.append(this._createTimePickerRollCol(this._localizedTimePartials.listOfHours,"hours")),this._config.minutes&&this._timePickerBody.append(this._createTimePickerRollCol(this._localizedTimePartials.listOfMinutes,"minutes")),this._config.seconds&&this._timePickerBody.append(this._createTimePickerRollCol(this._localizedTimePartials.listOfSeconds,"seconds")),this._localizedTimePartials.hour12&&this._timePickerBody.append(this._createTimePickerRollCol([{value:"am",label:"AM"},{value:"pm",label:"PM"}],"toggle",this._ampm))}_createTimePickerRollCol(e,t){const i=document.createElement("div");i.classList.add("time-picker-roll-col");for(const n of e){const e=document.createElement("div");e.classList.add("time-picker-roll-cell"),e.setAttribute("role","button"),e.tabIndex=0,e.innerHTML=n.label,e.addEventListener("click",(()=>{this._handleTimeChange(t,n.value)})),e.addEventListener("keydown",(e=>{"Space"!==e.code&&e.key!==kn||(e.preventDefault(),this._handleTimeChange(t,n.value))})),F.setDataAttribute(e,t,n.value),i.append(e)}return i}_createTimePickerFooter(){const e=document.createElement("div");if(e.classList.add("time-picker-footer"),this._config.cancelButton){const t=document.createElement("button");t.classList.add(...this._getButtonClasses(this._config.cancelButtonClasses)),t.type="button",t.innerHTML=this._config.cancelButton,t.addEventListener("click",(()=>{this.cancel()})),e.append(t)}if(this._config.confirmButton){const t=document.createElement("button");t.classList.add(...this._getButtonClasses(this._config.confirmButtonClasses)),t.type="button",t.innerHTML=this._config.confirmButton,t.addEventListener("click",(()=>{this.hide()})),e.append(t)}return e}_emitChangeEvent(e){this._input.dispatchEvent(new Event("change")),M.trigger(this._element,On,{timeString:null===e?null:e.toTimeString(),localeTimeString:null===e?null:e.toLocaleTimeString(),date:e})}_setUpRolls(e=!1){for(const t of Array.from(["hours","minutes","seconds","toggle"]))for(const i of R.find(`[data-bs-${t}]`,this._element))if(this._getPartOfTime(t)===F.getDataAttribute(i,t)){i.classList.add(Pn),this._scrollTo(i.parentElement,i,e);for(const e of i.parentElement.children)e!==i&&e.classList.remove(Pn)}}_setInputValue(e,t=this._input){t.value=e instanceof Date?e.toLocaleTimeString(this._config.locale,{hour12:this._localizedTimePartials.hour12,hour:"numeric",...this._config.minutes&&{minute:"numeric"},...this._config.seconds&&{second:"numeric"}}):e}_setUpSelects(){for(const e of Array.from(["hours","minutes","seconds","toggle"]))for(const t of R.find(`select.${e}`,this._element))this._getPartOfTime(e)&&(t.value=this._getPartOfTime(e))}_updateTimePicker(){this._element.innerHTML="",this._createTimePicker()}_convertStringToDate(e){return e?e instanceof Date?e:new Date(`1970-01-01 ${e}`):null}_createPopper(){if(void 0===mn)throw new TypeError("CoreUI's time picker require Popper (https://popper.js.org)");const e={modifiers:[{name:"preventOverflow",options:{boundary:"clippingParents"}},{name:"offset",options:{offset:[0,2]}}],placement:g()?"bottom-end":"bottom-start"};this._popper=pn(this._togglerElement,this._menu,e)}_getButtonClasses(e){return"string"==typeof e?e.split(" "):e}_getPartOfTime(e){return null===this._date?null:"hours"===e?yn(this._config.locale)?this._date.getHours()%12||12:this._date.getHours():"minutes"===e?this._date.getMinutes():"seconds"===e?this._date.getSeconds():"toggle"===e?bn(new Date(this._date),this._config.locale):void 0}_isShown(){return this._element.classList.contains(jn)}_scrollTo(e,t,i=!1){e.scrollTo({top:t.offsetTop,behavior:i?"instant":"smooth"})}_configAfterMerge(e){return"dropdown"!==e.container&&"inline"!==e.container||(e.type=e.container),!0===e.container&&(e.container=document.body),("object"==typeof e.container||"string"==typeof e.container&&"dropdown"===e.container&&"inline"===e.container)&&(e.container=r(e.container)),e}static timePickerInterface(e,t){const i=Rn.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=Rn.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=R.find(Hn);for(const i of t){const t=Rn.getInstance(i);t&&(e.composedPath().includes(t._element)||(t._element,e.type,t.hide()))}}}M.on(window,Nn,(()=>{const e=R.find(Fn);for(let t=0,i=e.length;t<i;t++)Rn.timePickerInterface(e[t])})),M.on(document,$n,Rn.clearMenus),M.on(document,Sn,Rn.clearMenus),p(Rn);const Wn=".bs.date-range-picker",Yn=".data-api",qn=`click${Wn}`,Un=`endDateChange${Wn}`,Qn=`hide${Wn}`,Kn=`hidden${Wn}`,Xn="input",Gn=`keydown${Wn}`,Zn=`show${Wn}`,Jn=`shown${Wn}`,es=`startDateChange${Wn}`,ts=`click${Wn}${Yn}`,is=`keyup${Wn}${Yn}`,ns=`load${Wn}${Yn}`,ss="date-picker",as="is-invalid",os="is-valid",rs="show",ls="time-picker",cs='[data-bs-toggle="date-range-picker"]:not(.disabled):not(:disabled)',hs=`${cs}.${rs}`,ds={ariaNavNextMonthLabel:"Next month",ariaNavNextYearLabel:"Next year",ariaNavPrevMonthLabel:"Previous month",ariaNavPrevYearLabel:"Previous year",calendarDate:null,calendars:2,cancelButton:"Cancel",cancelButtonClasses:["btn","btn-sm","btn-ghost-primary"],confirmButton:"OK",confirmButtonClasses:["btn","btn-sm","btn-primary"],cleaner:!0,container:!1,date:null,disabled:!1,disabledDates:null,endDate:null,endName:null,firstDayOfWeek:1,footer:!1,inputDateFormat:null,inputDateParse:null,inputReadOnly:!1,invalid:!1,indicator:!0,locale:"default",maxDate:null,minDate:null,name:null,placeholder:["Start date","End date"],range:!0,ranges:{},rangesButtonsClasses:["btn","btn-ghost-secondary"],required:!0,separator:!0,size:null,startDate:null,startName:null,selectAdjacementDays:!1,selectEndDate:!1,selectionType:"day",showAdjacementDays:!0,showWeekNumber:!1,timepicker:!1,todayButton:"Today",todayButtonClasses:["btn","btn-sm","btn-primary","me-auto"],valid:!1,weekdayFormat:2,weekNumbersLabel:null},us={ariaNavNextMonthLabel:"string",ariaNavNextYearLabel:"string",ariaNavPrevMonthLabel:"string",ariaNavPrevYearLabel:"string",calendarDate:"(date|number|string|null)",calendars:"number",cancelButton:"(boolean|string)",cancelButtonClasses:"(array|string)",cleaner:"boolean",confirmButton:"(boolean|string)",confirmButtonClasses:"(array|string)",container:"(string|element|boolean)",date:"(date|number|string|null)",disabledDates:"(array|date|function|null)",disabled:"boolean",endDate:"(date|number|string|null)",endName:"(string|null)",firstDayOfWeek:"number",footer:"boolean",indicator:"boolean",inputDateFormat:"(function|null)",inputDateParse:"(function|null)",inputReadOnly:"boolean",invalid:"boolean",locale:"string",maxDate:"(date|number|string|null)",minDate:"(date|number|string|null)",name:"(string|null)",placeholder:"(array|string)",range:"boolean",ranges:"object",rangesButtonsClasses:"(array|string)",required:"boolean",separator:"boolean",size:"(string|null)",startDate:"(date|number|string|null)",startName:"(string|null)",selectAdjacementDays:"boolean",selectEndDate:"boolean",selectionType:"string",showAdjacementDays:"boolean",showWeekNumber:"boolean",timepicker:"boolean",todayButton:"(boolean|string)",todayButtonClasses:"(array|string)",valid:"boolean",weekdayFormat:"(number|string)",weekNumbersLabel:"(string|null)"};class _s extends z{constructor(e,t){super(e),this._config=this._getConfig(t),this._calendarDate=this._config.calendarDate,this._startDate=this._config.date||this._config.startDate,this._endDate=this._config.endDate,this._initialStartDate=null,this._initialEndDate=null,this._mobile=window.innerWidth<768,this._popper=null,this._selectEndDate=this._config.selectEndDate,this._calendar=null,this._calendars=null,this._endInput=null,this._indicatorElement=null,this._menu=null,this._startInput=null,this._timepickers=null,this._timePickerEnd=null,this._timePickerStart=null,this._togglerElement=null,this._createDateRangePicker(),this._createDateRangePickerCalendars(),this._addEventListeners(),this._addCalendarEventListeners()}static get Default(){return ds}static get DefaultType(){return us}static get NAME(){return"date-range-picker"}toggle(){return this._isShown()?this.hide():this.show()}show(){this._config.disabled||this._isShown()||(this._initialStartDate=new Date(this._startDate),this._initialEndDate=new Date(this._endDate),M.trigger(this._element,Zn),this._element.classList.add(rs),this._element.setAttribute("aria-expanded",!0),this._config.container&&this._menu.classList.add(rs),M.trigger(this._element,Jn),this._createPopper())}hide(){M.trigger(this._element,Qn),this._popper&&this._popper.destroy(),this._element.classList.remove(rs),this._element.setAttribute("aria-expanded","false"),this._config.container&&this._menu.classList.remove(rs),M.trigger(this._element,Kn)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}cancel(){this._changeStartDate(this._initialStartDate),this._config.range&&this._changeEndDate(this._initialEndDate),this.hide(),this._calendar.update(this._getCalendarConfig)}clear(){this._changeStartDate(null),this._changeEndDate(null),this._calendar.update(this._getCalendarConfig())}reset(){this._changeStartDate(this._config.startDate),this._changeEndDate(this._config.endDate),this._calendar.update(this._getCalendarConfig())}update(e){this._config=this._getConfig(e),this._calendarDate=this._config.calendarDate,this._startDate=this._config.date||this._config.startDate,this._endDate=this._config.endDate,this._selectEndDate=this._config.selectEndDate,this._element.innerHTML="",this._createDateRangePicker(),this._createDateRangePickerCalendars(),this._addEventListeners(),this._addCalendarEventListeners()}_addEventListeners(){M.on(this._indicatorElement,qn,(()=>{this._config.disabled||this.toggle()})),M.on(this._indicatorElement,Gn,(e=>{this._config.disabled||"Enter"!==e.key||this.toggle()})),M.on(this._togglerElement,qn,(e=>{this._config.disabled||e.target===this._indicatorElement||this.show()})),M.on(this._element,Gn,(e=>{"Escape"===e.key&&this.hide()})),M.on(this._startInput,qn,(()=>{this._selectEndDate=!1,this._calendar.update(this._getCalendarConfig())})),M.on(this._startInput,Xn,(e=>{const t=this._parseDate(e.target.value);(t instanceof Date&&!Number.isNaN(t)||null===t)&&(this._startDate=t,this._calendarDate=t,this._calendar.update(this._getCalendarConfig()),M.trigger(this._element,es,{date:t}))})),M.on(this._startInput.form,"submit",(()=>{if(this._startInput.form.classList.contains("was-validated")){if(this._config.range&&(Number.isNaN(Date.parse(this._startInput.value))||Number.isNaN(Date.parse(this._endInput.value))))return this._element.classList.add(as);if(this._config.range&&this._startDate instanceof Date&&this._endDate instanceof Date)return this._element.classList.add(os);if(!this._config.range&&Number.isNaN(Date.parse(this._startInput.value)))return this._element.classList.add(as);if(!this._config.range&&this._startDate instanceof Date)return this._element.classList.add(os);this._element.classList.add(as)}})),M.on(this._endInput,qn,(()=>{this._selectEndDate=!0,this._calendar.update(this._getCalendarConfig())})),M.on(this._endInput,Xn,(e=>{const t=this._parseDate(e.target.value);(t instanceof Date&&!Number.isNaN(t)||null===t)&&(this._endDate=t,this._calendarDate=t,this._calendar.update(this._getCalendarConfig()),M.trigger(this._element,Un,{date:t}))})),M.on(window,"resize",(()=>{this._mobile=window.innerWidth<768}))}_addCalendarEventListeners(){for(const e of R.find(".calendars",this._element))M.on(e,"startDateChange.bs.calendar",(e=>{this._changeStartDate(e.date),this._config.range||this._config.footer||this._config.timepicker||this.hide()})),M.on(e,"endDateChange.bs.calendar",(e=>{this._changeEndDate(e.date),!this._startDate||this._config.footer||this._config.timepicker||this.hide()})),M.on(e,"cellHover.bs.calendar",(e=>{this._selectEndDate?this._endInput.value=e.date?this._setInputValue(e.date):this._setInputValue(this._endDate):this._startInput.value=e.date?this._setInputValue(e.date):this._setInputValue(this._startDate)})),M.on(e,"selectEndChange.bs.calendar",(e=>{this._selectEndDate=e.value}))}_changeStartDate(e,t=!1){this._startDate=e,this._startInput.value=this._setInputValue(e),this._startInput.dispatchEvent(new Event("change")),M.trigger(this._element,es,{date:e}),this._timePickerStart&&!t&&this._timePickerStart.update(this._getTimePickerConfig(!0))}_changeEndDate(e,t=!1){this._endDate=e,this._endInput.value=this._setInputValue(e),this._endInput.dispatchEvent(new Event("change")),M.trigger(this._element,Un,{date:e}),this._timePickerEnd&&!t&&this._timePickerEnd.update(this._getTimePickerConfig(!1))}_getCalendarConfig(){return{ariaNavNextMonthLabel:this._config.ariaNavNextMonthLabel,ariaNavNextYearLabel:this._config.ariaNavNextYearLabel,ariaNavPrevMonthLabel:this._config.ariaNavPrevMonthLabel,ariaNavPrevYearLabel:this._config.ariaNavPrevYearLabel,calendarDate:this._calendarDate,calendars:this._config.calendars,disabledDates:this._config.disabledDates,endDate:this._endDate,firstDayOfWeek:this._config.firstDayOfWeek,locale:this._config.locale,maxDate:this._config.maxDate,minDate:this._config.minDate,range:this._config.range,selectAdjacementDays:this._config.selectAdjacementDays,selectEndDate:this._selectEndDate,selectionType:this._config.selectionType,showAdjacementDays:this._config.showAdjacementDays,showWeekNumber:this._config.showWeekNumber,startDate:this._startDate,weekdayFormat:this._config.weekdayFormat,weekNumbersLabel:this._config.weekNumbersLabel}}_getTimePickerConfig(e){return{disabled:e?!this._startDate:!this._endDate,locale:this._config.locale,time:e?this._startDate&&new Date(this._startDate):this._endDate&&new Date(this._endDate),type:"inline",variant:"select"}}_createDateRangePicker(){this._element.classList.add(ss),F.setDataAttribute(this._element,"toggle",this._config.range?"date-range-picker":ss),this._config.size&&this._element.classList.add(`date-picker-${this._config.size}`),this._config.disabled&&this._element.classList.add("disabled"),this._element.classList.toggle(as,this._config.invalid),this._element.classList.toggle(os,this._config.valid),this._element.append(this._createDateRangePickerInputGroup());const e=document.createElement("div");e.classList.add("date-picker-dropdown"),e.append(this._createDateRangePickerBody()),(this._config.footer||this._config.timepicker)&&e.append(this._createDateRangeFooter());const{container:t}=this._config;t?t.append(e):this._element.append(e),this._menu=e}_createDateRangePickerInputGroup(){const e=document.createElement("div");e.classList.add("date-picker-input-group");let t=null;(this._config.name||this._config.startName||this._element.id)&&(t=this._config.name||this._config.startName||(this._config.range?`date-range-picker-start-date-${this._element.id}`:`date-picker-${this._element.id}`));const i=this._createInput(t,this._getPlaceholder()[0],this._setInputValue(this._startDate));let n=null;(this._config.endName||this._element.id)&&(n=this._config.endName||`date-range-picker-end-date-${this._element.id}`);const s=this._createInput(n,this._getPlaceholder()[1],this._setInputValue(this._endDate)),a=document.createElement("div");if(a.classList.add("date-picker-separator"),this._startInput=i,this._endInput=s,e.append(i),this._config.separator&&e.append(a),this._config.range&&e.append(s),this._config.indicator){const t=document.createElement("div");t.classList.add("date-picker-indicator"),this._config.disabled||(t.tabIndex=0),e.append(t),this._indicatorElement=t}if(this._config.cleaner){const t=document.createElement("div");t.classList.add("date-picker-cleaner"),t.addEventListener("click",(e=>{e.stopPropagation(),this.clear()})),e.append(t)}return this._togglerElement=e,e}_createDateRangePickerBody(){const e=document.createElement("div");if(e.classList.add("date-picker-body"),Object.keys(this._config.ranges).length){const t=document.createElement("div");t.classList.add("date-picker-ranges");for(const e of Object.keys(this._config.ranges)){const i=document.createElement("button");i.classList.add(...this._getButtonClasses(this._config.rangesButtonsClasses)),i.role="button",i.addEventListener("click",(()=>{this._changeStartDate(this._config.ranges[e][0]),this._changeEndDate(this._config.ranges[e][1]),this._calendar.update(this._getCalendarConfig())})),i.innerHTML=e,t.append(i)}e.append(t)}const t=document.createElement("div");if(t.classList.add("date-picker-calendars"),this._calendars=t,e.append(t),this._config.timepicker){const t=document.createElement("div");t.classList.add("date-picker-timepickers"),this._timepickers=t,e.append(t)}return e}_createDateRangePickerCalendars(){const e=document.createElement("div");if(e.classList.add("date-picker-calendar"),this._calendars.append(e),this._calendar=new We(e,this._getCalendarConfig()),M.on(e,"calendarDateChange.bs.calendar",(e=>{this._calendarDate=e.date})),M.on(e,"calendarMouseleave.bs.calendar",(()=>{this._startDate&&(this._startInput.value=this._setInputValue(this._startDate)),this._endDate&&(this._endInput.value=this._setInputValue(this._endDate))})),this._config.timepicker)if(this._mobile||this._range&&1===this._config.calendars){const t=document.createElement("div");t.classList.add(ls),this._timePickerStart=new Rn(t,this._getTimePickerConfig(!0)),e.append(t),M.on(t,"timeChange.bs.time-picker",(e=>{this._changeStartDate(e.date,!0),this._calendar.update(this._getCalendarConfig())}));const i=document.createElement("div");i.classList.add(ls),this._timePickerEnd=new Rn(i,this._getTimePickerConfig(!1)),this._timepickers.append(i),M.on(i,"timeChange.bs.time-picker",(e=>{this._changeEndDate(e.date,!0),this._calendar.update(this._getCalendarConfig())}))}else for(const[e,t]of Array.from({length:this._config.calendars}).entries()){const t=document.createElement("div");t.classList.add(ls);const i=new Rn(t,this._getTimePickerConfig(0===e));0===e?this._timePickerStart=i:this._timePickerEnd=i,this._timepickers.append(t),M.on(t,"timeChange.bs.time-picker",(t=>{0===e?this._changeStartDate(t.date,!0):this._changeEndDate(t.date,!0),this._calendar.update(this._getCalendarConfig())}))}}_createDateRangeFooter(){const e=document.createElement("div");if(e.classList.add("date-picker-footer"),this._config.todayButton){const t=document.createElement("button");t.classList.add(...this._getButtonClasses(this._config.todayButtonClasses)),t.type="button",t.innerHTML=this._config.todayButton,t.addEventListener("click",(()=>{const e=new Date;this._calendarDate=e,this._changeStartDate(e),this._config.range&&this._changeEndDate(e),this._calendar.update(this._getCalendarConfig())})),e.append(t)}if(this._config.cancelButton){const t=document.createElement("button");t.classList.add(...this._getButtonClasses(this._config.cancelButtonClasses)),t.type="button",t.innerHTML=this._config.cancelButton,t.addEventListener("click",(()=>{this.cancel()})),e.append(t)}if(this._config.confirmButton){const t=document.createElement("button");t.classList.add(...this._getButtonClasses(this._config.confirmButtonClasses)),t.type="button",t.innerHTML=this._config.confirmButton,t.addEventListener("click",(()=>{this.hide()})),e.append(t)}return e}_createInput(e,t,i){const n=document.createElement("input");n.classList.add("date-picker-input"),n.autocomplete="off",n.disabled=this._config.disabled,n.placeholder=t,n.readOnly=this._config.inputReadOnly,n.required=this._config.required,n.type="text",n.value=i,e&&(n.name=e);const s=["change","keyup","paste"];for(const e of s)n.addEventListener(e,(({target:e})=>{if(e.closest("form.was-validated")){const e=R.find(".date-picker-input",this._element);for(const t of e)if(Number.isNaN(Date.parse(t.value)))return this._element.classList.add(as),void this._element.classList.remove(os);if(this._config.range&&this._startDate instanceof Date&&this._endDate instanceof Date)return this._element.classList.add(os),void this._element.classList.remove(as);if(!this._config.range&&this._startDate instanceof Date)return this._element.classList.add(os),void this._element.classList.remove(as);this._element.classList.add(as),this._element.classList.remove(os)}}));return n}_createPopper(){if(void 0===mn)throw new TypeError("CoreUI's date picker require Popper (https://popper.js.org)");const e={modifiers:[{name:"preventOverflow",options:{boundary:"clippingParents"}},{name:"offset",options:{offset:[0,2]}}],placement:g()?"bottom-end":"bottom-start"};this._popper=pn(this._togglerElement,this._menu,e)}_parseDate(e){return e?this._config.inputDateParse?this._config.inputDateParse(e):((e,t,i)=>{const n=new Date(2013,11,31,17,19,22);let s=i?n.toLocaleString(t):n.toLocaleDateString(t);s=s.replace("2013","(?<year>[0-9]{2,4})").replace("12","(?<month>[0-9]{1,2})").replace("31","(?<day>[0-9]{1,2})"),i&&(s=s.replace("5","(?<hour>[0-9]{1,2})").replace("17","(?<hour>[0-9]{1,2})").replace("19","(?<minute>[0-9]{1,2})").replace("22","(?<second>[0-9]{1,2})").replace("PM","(?<ampm>[A-Z]{2})"));const a=new RegExp(`${s}`),o=e.match(a);if(null!==o)return o.groups&&(i?new Date(Number(o.groups.year,10),Number(o.groups.month,10)-1,Number(o.groups.day),o.groups.ampm&&"PM"===o.groups.ampm?Number(o.groups.hour)+12:Number(o.groups.hour),Number(o.groups.minute),Number(o.groups.second)):new Date(Number(o.groups.year),Number(o.groups.month)-1,Number(o.groups.day)))})(e,this._config.locale,this._config.timepicker):null}_formatDate(e){if(!e)return"";if(this._config.inputDateFormat)return this._config.inputDateFormat(e instanceof Date?new Date(e):G(e,this._config.selectionType));if("day"!==this._config.selectionType)return e;const t=new Date(e);return this._config.timepicker?t.toLocaleString(this._config.locale):t.toLocaleDateString(this._config.locale)}_getButtonClasses(e){return"string"==typeof e?e.split(" "):e}_getPlaceholder(){const{placeholder:e}=this._config;return"string"==typeof e?e.split(","):e}_isShown(){return this._element.classList.contains(rs)}_setInputValue(e){return e?this._formatDate(e):""}_configAfterMerge(e){return!0===e.container&&(e.container=document.body),"object"!=typeof e.container&&"string"!=typeof e.container||(e.container=r(e.container)),e}static dateRangePickerInterface(e,t){const i=_s.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=_s.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=R.find(hs);for(const i of t){const t=_s.getInstance(i);t&&(e.composedPath().includes(t._element)||(t._element,e.type,t.hide()))}}}M.on(window,ns,(()=>{const e=R.find(cs);for(let t=0,i=e.length;t<i;t++)_s.dateRangePickerInterface(e[t])})),M.on(document,ts,_s.clearMenus),M.on(document,is,_s.clearMenus),p(_s);const fs=".bs.date-picker",gs=".data-api",ps=`dateChange${fs}`,ms=`hide${fs}`,bs=`hidden${fs}`,vs=`show${fs}`,ys=`shown${fs}`,ws=`click${fs}${gs}`,Ds=`keyup${fs}${gs}`,ks=`load${fs}${gs}`,Es='[data-bs-toggle="date-picker"]:not(.disabled):not(:disabled)',Ls=`${Es}.show`,Ts={..._s.Default,calendars:1,placeholder:["Select date"],range:!1,separator:!1},Cs={..._s.DefaultType,date:"(date|number|string|null)"};class As extends _s{static get Default(){return Ts}static get DefaultType(){return Cs}static get NAME(){return"date-picker"}_addEventListeners(){super._addEventListeners(),M.on(this._element,"startDateChange.bs.date-range-picker",(e=>{M.trigger(this._element,ps,{date:e.date})})),M.on(this._element,"show.bs.date-range-picker",(()=>{M.trigger(this._element,vs)})),M.on(this._element,"shown.bs.date-range-picker",(()=>{M.trigger(this._element,ys)})),M.on(this._element,"hide.bs.date-range-picker",(()=>{M.trigger(this._element,ms)})),M.on(this._element,"hidden.bs.date-range-picker",(()=>{M.trigger(this._element,bs)}))}static datePickerInterface(e,t){const i=As.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=As.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=R.find(Ls);for(const i of t){const t=As.getInstance(i);t&&(e.composedPath().includes(t._element)||(t._element,e.type,t.hide()))}}}M.on(window,ks,(()=>{const e=R.find(Es);for(let t=0,i=e.length;t<i;t++)As.datePickerInterface(e[t])})),M.on(document,ws,As.clearMenus),M.on(document,Ds,As.clearMenus),p(As);const xs="dropdown",Os=".bs.dropdown",$s=".data-api",Ss="ArrowUp",Ns="ArrowDown",Is=`hide${Os}`,Ms=`hidden${Os}`,Ps=`show${Os}`,js=`shown${Os}`,Bs=`click${Os}${$s}`,Fs=`keydown${Os}${$s}`,Hs=`keyup${Os}${$s}`,zs="show",Vs='[data-bs-toggle="dropdown"]:not(.disabled):not(:disabled)',Rs=`${Vs}.${zs}`,Ws=".dropdown-menu",Ys=g()?"top-end":"top-start",qs=g()?"top-start":"top-end",Us=g()?"bottom-end":"bottom-start",Qs=g()?"bottom-start":"bottom-end",Ks=g()?"left-start":"right-start",Xs=g()?"right-start":"left-start",Gs={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Zs={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class Js extends z{constructor(e,t){super(e,t),this._popper=null,this._parent=this._element.parentNode,this._menu=R.next(this._element,Ws)[0]||R.prev(this._element,Ws)[0]||R.findOne(Ws,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Gs}static get DefaultType(){return Zs}static get NAME(){return xs}toggle(){return this._isShown()?this.hide():this.show()}show(){if(c(this._element)||this._isShown())return;const e={relatedTarget:this._element};if(!M.trigger(this._element,Ps,e).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(".navbar-nav"))for(const e of[].concat(...document.body.children))M.on(e,"mouseover",d);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(zs),this._element.classList.add(zs),M.trigger(this._element,js,e)}}hide(){if(c(this._element)||!this._isShown())return;const e={relatedTarget:this._element};this._completeHide(e)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(e){if(!M.trigger(this._element,Is,e).defaultPrevented){if("ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))M.off(e,"mouseover",d);this._popper&&this._popper.destroy(),this._menu.classList.remove(zs),this._element.classList.remove(zs),this._element.setAttribute("aria-expanded","false"),F.removeDataAttribute(this._menu,"popper"),M.trigger(this._element,Ms,e)}}_getConfig(e){if("object"==typeof(e=super._getConfig(e)).reference&&!o(e.reference)&&"function"!=typeof e.reference.getBoundingClientRect)throw new TypeError(`${xs.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return e}_createPopper(){if(void 0===mn)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=this._parent:o(this._config.reference)?e=r(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const t=this._getPopperConfig();this._popper=pn(e,this._menu,t)}_isShown(){return this._menu.classList.contains(zs)}_getPlacement(){const e=this._parent;if(e.classList.contains("dropend"))return Ks;if(e.classList.contains("dropstart"))return Xs;if(e.classList.contains("dropup-center"))return"top";if(e.classList.contains("dropdown-center"))return"bottom";const t="end"===getComputedStyle(this._menu).getPropertyValue("--bs-position").trim();return e.classList.contains("dropup")?t?qs:Ys:t?Qs:Us}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_getPopperConfig(){const e={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(F.setDataAttribute(this._menu,"popper","static"),e.modifiers=[{name:"applyStyles",enabled:!1}]),{...e,...m(this._config.popperConfig,[void 0,e])}}_selectMenuItem({key:e,target:t}){const i=R.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter((e=>l(e)));i.length&&v(i,t,e===Ns,!i.includes(t)).focus()}static jQueryInterface(e){return this.each((function(){const t=Js.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}static clearMenus(e){if(2===e.button||"keyup"===e.type&&"Tab"!==e.key)return;const t=R.find(Rs);for(const i of t){const t=Js.getInstance(i);if(!t||!1===t._config.autoClose)continue;const n=e.composedPath(),s=n.includes(t._menu);if(n.includes(t._element)||"inside"===t._config.autoClose&&!s||"outside"===t._config.autoClose&&s)continue;if(t._menu.contains(e.target)&&("keyup"===e.type&&"Tab"===e.key||/input|select|option|textarea|form/i.test(e.target.tagName)))continue;const a={relatedTarget:t._element};"click"===e.type&&(a.clickEvent=e),t._completeHide(a)}}static dataApiKeydownHandler(e){const t=/input|textarea/i.test(e.target.tagName),i="Escape"===e.key,n=[Ss,Ns].includes(e.key);if(!n&&!i)return;if(t&&!i)return;e.preventDefault();const s=this.matches(Vs)?this:R.prev(this,Vs)[0]||R.next(this,Vs)[0]||R.findOne(Vs,e.delegateTarget.parentNode),a=Js.getOrCreateInstance(s);if(n)return e.stopPropagation(),a.show(),void a._selectMenuItem(e);a._isShown()&&(e.stopPropagation(),a.hide(),s.focus())}}M.on(document,Fs,Vs,Js.dataApiKeydownHandler),M.on(document,Fs,Ws,Js.dataApiKeydownHandler),M.on(document,Bs,Js.clearMenus),M.on(document,Hs,Js.clearMenus),M.on(document,Bs,Vs,(function(e){e.preventDefault(),Js.getOrCreateInstance(this).toggle()})),p(Js);const ea="bs.loading-button",ta=`.${ea}`,ia=`start${ta}`,na=`stop${ta}`,sa=`click${ta}.data-api`,aa="is-loading",oa='[data-bs-toggle="loading-button"]',ra={disabledOnLoading:!1,spinner:!0,spinnerType:"border",timeout:!1},la={disabledOnLoading:"boolean",spinner:"boolean",spinnerType:"string",timeout:"(boolean|number)"};class ca extends z{constructor(e,i){super(e),this._config=this._getConfig(i),this._timeout=this._config.timeout,this._spinner=null,this._state="idle",this._element&&t.set(e,ea,this),this._createButton()}static get Default(){return ra}static get DefaultType(){return la}static get NAME(){return"loading-button"}start(){"loading"!==this._state&&(this._createSpinner(),this._state="loading",setTimeout((()=>{this._element.classList.add(aa),M.trigger(this._element,ia),this._config.disabledOnLoading&&this._element.setAttribute("disabled",!0)}),1),this._config.timeout&&setTimeout((()=>{this.stop()}),this._config.timeout))}stop(){this._element.classList.remove(aa);const e=()=>{this._removeSpinner(),this._state="idle",this._config.disabledOnLoading&&this._element.removeAttribute("disabled"),M.trigger(this._element,na)};this._spinner?this._queueCallback(e,this._spinner,!0):e()}dispose(){t.removeData(this._element,ea),this._element=null}_createButton(){this._element.classList.add("btn-loading")}_createSpinner(){if(this._config.spinner){const e=document.createElement("span"),t=this._config.spinnerType;e.classList.add("btn-loading-spinner",`spinner-${t}`,`spinner-${t}-sm`),e.setAttribute("role","status"),e.setAttribute("aria-hidden","true"),this._element.insertBefore(e,this._element.firstChild),this._spinner=e}}_removeSpinner(){this._config.spinner&&(this._spinner.remove(),this._spinner=null)}static loadingButtonInterface(e,t){const i=ca.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){ca.loadingButtonInterface(this,e)}))}}M.on(document,sa,oa,(e=>{e.preventDefault();const t=e.target.closest(oa);ca.getOrCreateInstance(t).start()})),p(ca);const ha="backdrop",da="show",ua=`mousedown.bs.${ha}`,_a={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},fa={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class ga extends H{constructor(e){super(),this._config=this._getConfig(e),this._isAppended=!1,this._element=null}static get Default(){return _a}static get DefaultType(){return fa}static get NAME(){return ha}show(e){if(!this._config.isVisible)return void m(e);this._append();const t=this._getElement();this._config.isAnimated&&u(t),t.classList.add(da),this._emulateAnimation((()=>{m(e)}))}hide(e){this._config.isVisible?(this._getElement().classList.remove(da),this._emulateAnimation((()=>{this.dispose(),m(e)}))):m(e)}dispose(){this._isAppended&&(M.off(this._element,ua),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const e=document.createElement("div");e.className=this._config.className,this._config.isAnimated&&e.classList.add("fade"),this._element=e}return this._element}_configAfterMerge(e){return e.rootElement=r(e.rootElement),e}_append(){if(this._isAppended)return;const e=this._getElement();this._config.rootElement.append(e),M.on(e,ua,(()=>{m(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(e){b(e,this._getElement(),this._config.isAnimated)}}const pa=".bs.focustrap",ma=`focusin${pa}`,ba=`keydown.tab${pa}`,va="backward",ya={autofocus:!0,trapElement:null},wa={autofocus:"boolean",trapElement:"element"};class Da extends H{constructor(e){super(),this._config=this._getConfig(e),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return ya}static get DefaultType(){return wa}static get NAME(){return"focustrap"}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),M.off(document,pa),M.on(document,ma,(e=>this._handleFocusin(e))),M.on(document,ba,(e=>this._handleKeydown(e))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,M.off(document,pa))}_handleFocusin(e){const{trapElement:t}=this._config;if(e.target===document||e.target===t||t.contains(e.target))return;const i=R.focusableChildren(t);0===i.length?t.focus():this._lastTabNavDirection===va?i[i.length-1].focus():i[0].focus()}_handleKeydown(e){"Tab"===e.key&&(this._lastTabNavDirection=e.shiftKey?va:"forward")}}const ka=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",Ea=".sticky-top",La="padding-right",Ta="margin-right";class Ca{constructor(){this._element=document.body}getWidth(){const e=document.documentElement.clientWidth;return Math.abs(window.innerWidth-e)}hide(){const e=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,La,(t=>t+e)),this._setElementAttributes(ka,La,(t=>t+e)),this._setElementAttributes(Ea,Ta,(t=>t-e))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,La),this._resetElementAttributes(ka,La),this._resetElementAttributes(Ea,Ta)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(e,t,i){const n=this.getWidth();this._applyManipulationCallback(e,(e=>{if(e!==this._element&&window.innerWidth>e.clientWidth+n)return;this._saveInitialAttribute(e,t);const s=window.getComputedStyle(e).getPropertyValue(t);e.style.setProperty(t,`${i(Number.parseFloat(s))}px`)}))}_saveInitialAttribute(e,t){const i=e.style.getPropertyValue(t);i&&F.setDataAttribute(e,t,i)}_resetElementAttributes(e,t){this._applyManipulationCallback(e,(e=>{const i=F.getDataAttribute(e,t);null!==i?(F.removeDataAttribute(e,t),e.style.setProperty(t,i)):e.style.removeProperty(t)}))}_applyManipulationCallback(e,t){if(o(e))t(e);else for(const i of R.find(e,this._element))t(i)}}const Aa=".bs.modal",xa=`hide${Aa}`,Oa=`hidePrevented${Aa}`,$a=`hidden${Aa}`,Sa=`show${Aa}`,Na=`shown${Aa}`,Ia=`resize${Aa}`,Ma=`click.dismiss${Aa}`,Pa=`mousedown.dismiss${Aa}`,ja=`keydown.dismiss${Aa}`,Ba=`click${Aa}.data-api`,Fa="modal-open",Ha="show",za="modal-static",Va={backdrop:!0,focus:!0,keyboard:!0},Ra={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class Wa extends z{constructor(e,t){super(e,t),this._dialog=R.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new Ca,this._addEventListeners()}static get Default(){return Va}static get DefaultType(){return Ra}static get NAME(){return"modal"}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){this._isShown||this._isTransitioning||M.trigger(this._element,Sa,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(Fa),this._adjustDialog(),this._backdrop.show((()=>this._showElement(e))))}hide(){this._isShown&&!this._isTransitioning&&(M.trigger(this._element,xa).defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(Ha),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated())))}dispose(){M.off(window,Aa),M.off(this._dialog,Aa),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new ga({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Da({trapElement:this._element})}_showElement(e){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const t=R.findOne(".modal-body",this._dialog);t&&(t.scrollTop=0),u(this._element),this._element.classList.add(Ha),this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,M.trigger(this._element,Na,{relatedTarget:e})}),this._dialog,this._isAnimated())}_addEventListeners(){M.on(this._element,ja,(e=>{"Escape"===e.key&&(this._config.keyboard?this.hide():this._triggerBackdropTransition())})),M.on(window,Ia,(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),M.on(this._element,Pa,(e=>{M.one(this._element,Ma,(t=>{this._element===e.target&&this._element===t.target&&("static"!==this._config.backdrop?this._config.backdrop&&this.hide():this._triggerBackdropTransition())}))}))}_hideModal(){this._element.style.display="none",this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._isTransitioning=!1,this._backdrop.hide((()=>{document.body.classList.remove(Fa),this._resetAdjustments(),this._scrollBar.reset(),M.trigger(this._element,$a)}))}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(M.trigger(this._element,Oa).defaultPrevented)return;const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._element.style.overflowY;"hidden"===t||this._element.classList.contains(za)||(e||(this._element.style.overflowY="hidden"),this._element.classList.add(za),this._queueCallback((()=>{this._element.classList.remove(za),this._queueCallback((()=>{this._element.style.overflowY=t}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const e=this._element.scrollHeight>document.documentElement.clientHeight,t=this._scrollBar.getWidth(),i=t>0;if(i&&!e){const e=g()?"paddingLeft":"paddingRight";this._element.style[e]=`${t}px`}if(!i&&e){const e=g()?"paddingRight":"paddingLeft";this._element.style[e]=`${t}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(e,t){return this.each((function(){const i=Wa.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e](t)}}))}}M.on(document,Ba,'[data-bs-toggle="modal"]',(function(e){const t=R.getElementFromSelector(this);["A","AREA"].includes(this.tagName)&&e.preventDefault(),M.one(t,Sa,(e=>{e.defaultPrevented||M.one(t,$a,(()=>{l(this)&&this.focus()}))}));const i=R.findOne(".modal.show");i&&Wa.getInstance(i).hide(),Wa.getOrCreateInstance(t).toggle(this)})),W(Wa),p(Wa);const Ya="bs.multi-select",qa=`.${Ya}`,Ua=".data-api",Qa="ArrowUp",Ka="ArrowDown",Xa="Backspace",Ga="Delete",Za="Enter",Ja=".form-multi-select-option",eo=".form-multi-select-options-empty",to=".form-multi-select-search",io=".form-multi-select",no=`changed${qa}`,so=`click${qa}`,ao=`hide${qa}`,oo=`hidden${qa}`,ro=`keydown${qa}`,lo=`keyup${qa}`,co=`search${qa}`,ho=`show${qa}`,uo=`shown${qa}`,_o=`click${qa}${Ua}`,fo=`keyup${qa}${Ua}`,go=`load${qa}${Ua}`,po="disabled",mo="form-multi-select",bo="form-multi-select-option",vo="form-multi-selected",yo="show",wo={ariaCleanerLabel:"Clear all selections",cleaner:!0,container:!1,disabled:!1,invalid:!1,multiple:!0,name:null,options:!1,optionsMaxHeight:"auto",optionsStyle:"checkbox",placeholder:"Select...",required:!1,search:!1,searchNoResultsLabel:"No results found",selectAll:!0,selectAllLabel:"Select all options",selectionType:"tags",selectionTypeCounterText:"item(s) selected",valid:!1},Do={ariaCleanerLabel:"string",cleaner:"boolean",container:"(string|element|boolean)",disabled:"boolean",invalid:"boolean",multiple:"boolean",name:"(string|null)",options:"(boolean|array)",optionsMaxHeight:"(number|string)",optionsStyle:"string",placeholder:"string",required:"boolean",search:"(boolean|string)",searchNoResultsLabel:"string",selectAll:"boolean",selectAllLabel:"string",selectionType:"string",selectionTypeCounterText:"string",valid:"boolean"};class ko extends z{constructor(e,i){super(e,i),this._indicatorElement=null,this._selectAllElement=null,this._selectionElement=null,this._selectionCleanerElement=null,this._searchElement=null,this._togglerElement=null,this._optionsElement=null,this._clone=null,this._menu=null,this._options=this._getOptions(),this._popper=null,this._search="",this._selected=this._getSelectedOptions(this._options),this._config.options.length>0&&this._createNativeSelect(this._config.options),this._createSelect(),this._addEventListeners(),t.set(this._element,Ya,this)}static get Default(){return wo}static get DefaultType(){return Do}static get NAME(){return"multi-select"}toggle(){return this._isShown()?this.hide():this.show()}show(){this._config.disabled||this._isShown()||(M.trigger(this._element,ho),this._clone.classList.add(yo),this._clone.setAttribute("aria-expanded",!0),this._config.container&&(this._menu.style.minWidth=`${this._clone.offsetWidth}px`,this._menu.classList.add(yo)),M.trigger(this._element,uo),this._createPopper(),this._config.search&&R.findOne(to,this._clone).focus())}hide(){M.trigger(this._element,ao),this._popper&&this._popper.destroy(),this._config.search&&(this._searchElement.value=""),this._onSearchChange(this._searchElement),this._clone.classList.remove(yo),this._clone.setAttribute("aria-expanded","false"),this._config.container&&this._menu.classList.remove(yo),M.trigger(this._element,oo)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}search(e){this._search=e.length>0?e.toLowerCase():e,this._filterOptionsList(),M.trigger(this._element,co)}update(e){this._config=this._getConfig(e),this._options=this._getOptions(),this._selected=this._getSelectedOptions(this._options),this._menu.remove(),this._clone.remove(),this._element.innerHTML="",this._createNativeOptions(this._element,this._options),this._createSelect(),this._addEventListeners()}selectAll(e=this._options){for(const t of e)t.disabled||(t.label?this.selectAll(t.options):this._selectOption(t.value,t.text))}deselectAll(e=this._options){for(const t of e)t.disabled||(t.label?this.deselectAll(t.options):this._deselectOption(t.value))}getValue(){return this._selected}_addEventListeners(){M.on(this._clone,so,(()=>{this._config.disabled||this.show()})),M.on(this._clone,ro,(e=>{"Escape"!==e.key?"global"!==this._config.search||1!==e.key.length&&e.key!==Xa&&e.key!==Ga||this._searchElement.focus():this.hide()})),M.on(this._menu,ro,(e=>{"global"!==this._config.search||1!==e.key.length&&e.key!==Xa&&e.key!==Ga||this._searchElement.focus()})),M.on(this._togglerElement,ro,(e=>{if(!this._isShown()&&(e.key===Za||e.key===Ka))return e.preventDefault(),void this.show();this._isShown()&&e.key===Ka&&(e.preventDefault(),this._selectMenuItem(e))})),M.on(this._indicatorElement,so,(e=>{e.preventDefault(),e.stopPropagation(),this.toggle()})),M.on(this._searchElement,lo,(()=>{this._onSearchChange(this._searchElement)})),M.on(this._searchElement,ro,(e=>{this._isShown()||this.show(),e.key!==Ka||this._searchElement.value.length!==this._searchElement.selectionStart?(e.key!==Xa&&e.key!==Ga||0!==e.target.value.length||this._deselectLastOption(),this._searchElement.focus()):this._selectMenuItem(e)})),M.on(this._selectAllElement,so,(e=>{e.preventDefault(),e.stopPropagation(),this.selectAll()})),M.on(this._optionsElement,so,(e=>{e.preventDefault(),e.stopPropagation(),this._onOptionsClick(e.target)})),M.on(this._selectionCleanerElement,so,(e=>{this._config.disabled||(e.preventDefault(),e.stopPropagation(),this.deselectAll())})),M.on(this._optionsElement,ro,(e=>{e.key===Za&&this._onOptionsClick(e.target),[Qa,Ka].includes(e.key)&&(e.preventDefault(),this._selectMenuItem(e))}))}_getClassNames(){return this._element.classList.value.split(" ")}_getOptions(e=this._element){if(this._config.options)return this._config.options;const t=Array.from(e.childNodes).filter((e=>"OPTION"===e.nodeName||"OPTGROUP"===e.nodeName)),i=[];for(const e of t)"OPTION"===e.nodeName&&e.value&&i.push({value:e.value,text:e.innerHTML,selected:e.selected,disabled:e.disabled}),"OPTGROUP"===e.nodeName&&i.push({label:e.label,options:this._getOptions(e)});return i}_getSelectedOptions(e){const t=[];for(const i of e)void 0!==i.value?i.selected&&(this._config.multiple||(t.length=0),t.push({value:String(i.value),text:i.text})):this._getSelectedOptions(i.options);return t}_createNativeSelect(e){this._element.classList.add(mo),this._config.multiple&&this._element.setAttribute("multiple",!0),this._config.required&&this._element.setAttribute("required",!0),this._createNativeOptions(this._element,e)}_createNativeOptions(e,t){for(const i of t)if(void 0===i.options){const t=document.createElement("OPTION");t.value=i.value,!0===i.disabled&&t.setAttribute("disabled","disabled"),!0===i.selected&&t.setAttribute("selected","selected"),t.innerHTML=i.text,e.append(t)}else{const t=document.createElement("optgroup");t.label=i.label,this._createNativeOptions(t,i.options),e.append(t)}}_hideNativeSelect(){this._element.tabIndex="-1",this._element.style.display="none"}_createSelect(){const e=document.createElement("div");e.classList.add(mo),e.classList.toggle("is-invalid",this._config.invalid),e.classList.toggle("is-valid",this._config.valid),e.setAttribute("aria-expanded","false"),this._config.disabled&&this._element.classList.add(po);for(const t of this._getClassNames())e.classList.add(t);this._clone=e,this._element.parentNode.insertBefore(e,this._element.nextSibling),this._createSelection(),this._createButtons(),this._config.search&&(this._createSearchInput(),this._updateSearch()),(this._config.name||this._element.id||this._element.name)&&this._element.setAttribute("name",this._config.name||this._element.name||`multi-select-${this._element.id}`),this._createOptionsContainer(),this._hideNativeSelect(),this._updateOptionsList()}_createSelection(){const e=document.createElement("div");e.classList.add("form-multi-select-input-group"),this._togglerElement=e,this._config.search||this._config.disabled||(e.tabIndex=0);const t=document.createElement("div");t.classList.add("form-multi-select-selection"),this._config.multiple&&"tags"===this._config.selectionType&&t.classList.add("form-multi-select-selection-tags"),e.append(t),this._clone.append(e),this._updateSelection(),this._selectionElement=t}_createButtons(){const e=document.createElement("div");if(e.classList.add("form-multi-select-buttons"),!this._config.disabled&&this._config.cleaner&&this._config.multiple){const t=document.createElement("button");t.type="button",t.classList.add("form-multi-select-cleaner"),t.style.display="none",t.setAttribute("aria-label",this._config.ariaCleanerLabel),e.append(t),this._selectionCleanerElement=t}const t=document.createElement("button");t.type="button",t.classList.add("form-multi-select-indicator"),this._config.disabled&&(t.tabIndex=-1),e.append(t),this._indicatorElement=t,this._togglerElement.append(e),this._updateSelectionCleaner()}_createPopper(){if(void 0===mn)throw new TypeError("CoreUI's multi select require Popper (https://popper.js.org)");const e={modifiers:[{name:"preventOverflow",options:{boundary:"clippingParents"}},{name:"offset",options:{offset:[0,2]}}],placement:g()?"bottom-end":"bottom-start"};this._popper=pn(this._togglerElement,this._menu,e)}_createSearchInput(){const e=document.createElement("input");e.classList.add("form-multi-select-search"),this._config.disabled&&(e.disabled=!0),this._searchElement=e,this._updateSearchSize(),this._selectionElement.append(e)}_createOptionsContainer(){const e=document.createElement("div");if(e.classList.add("form-multi-select-dropdown"),this._config.selectAll&&this._config.multiple){const t=document.createElement("button");t.classList.add("form-multi-select-all"),t.innerHTML=this._config.selectAllLabel,this._selectAllElement=t,e.append(t)}const t=document.createElement("div");t.classList.add("form-multi-select-options"),"auto"!==this._config.optionsMaxHeight&&(t.style.maxHeight=`${this._config.optionsMaxHeight}px`,t.style.overflow="auto"),e.append(t);const{container:i}=this._config;i?i.append(e):this._clone.append(e),this._createOptions(t,this._options),this._optionsElement=t,this._menu=e}_createOptions(e,t){for(const i of t){if(void 0!==i.value){const t=document.createElement("div");t.classList.add(bo),i.disabled&&t.classList.add(po),"checkbox"===this._config.optionsStyle&&t.classList.add("form-multi-select-option-with-checkbox"),t.dataset.value=String(i.value),t.tabIndex=0,t.innerHTML=i.text,e.append(t)}if(void 0!==i.label){const t=document.createElement("div");t.classList.add("form-multi-select-optgroup");const n=document.createElement("div");n.innerHTML=i.label,n.classList.add("form-multi-select-optgroup-label"),t.append(n),this._createOptions(t,i.options),e.append(t)}}}_createTag(e,t){const i=document.createElement("div");if(i.classList.add("form-multi-select-tag"),i.dataset.value=e,i.innerHTML=t,!this._config.disabled){const t=document.createElement("button");t.type="button",t.classList.add("form-multi-select-tag-delete"),t.setAttribute("aria-label","Close"),M.on(t,so,(t=>{t.preventDefault(),t.stopPropagation(),i.remove(),this._deselectOption(e)})),i.append(t)}return i}_onOptionsClick(e){if(!e.classList.contains(bo)||e.classList.contains("label"))return;const t=String(e.dataset.value),{text:i}=this._findOptionByValue(t);this._config.multiple&&e.classList.contains(vo)?this._deselectOption(t):this._config.multiple&&!e.classList.contains(vo)?this._selectOption(t,i):this._config.multiple||this._selectOption(t,i),this._config.multiple||(this.hide(),this.search(""),this._searchElement.value=null)}_findOptionByValue(e,t=this._options){for(const i of t){if(i.value===e)return i;if(i.options&&Array.isArray(i.options)){const t=this._findOptionByValue(e,i.options);if(t)return t}}return null}_selectOption(e,t){this._config.multiple||this.deselectAll(),0===this._selected.filter((t=>t.value===String(e))).length&&this._selected.push({value:String(e),text:t});const i=R.findOne(`option[value="${e}"]`,this._element);i&&(i.selected=!0);const n=R.findOne(`[data-value="${e}"]`,this._optionsElement);n&&n.classList.add(vo),M.trigger(this._element,no,{value:this._selected}),this._updateSelection(),this._updateSelectionCleaner(),this._updateSearch(),this._updateSearchSize()}_deselectOption(e){const t=this._selected.filter((t=>t.value!==String(e)));this._selected=t,R.findOne(`option[value="${e}"]`,this._element).selected=!1;const i=R.findOne(`[data-value="${e}"]`,this._optionsElement);i&&i.classList.remove(vo),M.trigger(this._element,no,{value:this._selected}),this._updateSelection(),this._updateSelectionCleaner(),this._updateSearch(),this._updateSearchSize()}_deselectLastOption(){if(this._selected.length>0){const e=this._selected.pop();this._deselectOption(e.value)}}_updateSelection(){const e=R.findOne(".form-multi-select-selection",this._clone),t=R.findOne(to,this._clone);if(0!==this._selected.length||this._config.search){if(this._config.multiple&&"counter"===this._config.selectionType&&!this._config.search&&(e.innerHTML=`${this._selected.length} ${this._config.selectionTypeCounterText}`),this._config.multiple&&"tags"===this._config.selectionType){e.innerHTML="";for(const t of this._selected)e.append(this._createTag(t.value,t.text))}this._config.multiple&&"text"===this._config.selectionType&&(e.innerHTML=this._selected.map(((e,t)=>`<span>${e.text}${t===this._selected.length-1?"":","} </span>`)).join("")),!this._config.multiple&&this._selected.length>0&&!this._config.search&&(e.innerHTML=this._selected[0].text),t&&e.append(t),this._popper&&this._popper.update()}else e.innerHTML=`<span class="form-multi-select-placeholder">${this._config.placeholder}</span>`}_updateSelectionCleaner(){if(!this._config.cleaner||null===this._selectionCleanerElement)return;const e=R.findOne(".form-multi-select-cleaner",this._clone);this._selected.length>0?e.style.removeProperty("display"):e.style.display="none"}_updateSearch(){this._config.search&&(!this._config.multiple&&this._selected.length>0?this._searchElement.placeholder=this._selected[0].text:this._config.multiple||0!==this._selected.length?this._config.multiple&&this._selected.length>0&&"counter"!==this._config.selectionType?this._searchElement.removeAttribute("placeholder"):this._config.multiple&&0===this._selected.length?this._searchElement.placeholder=this._config.placeholder:this._config.multiple&&"counter"===this._config.selectionType&&(this._searchElement.placeholder=`${this._selected.length} ${this._config.selectionTypeCounterText}`):this._searchElement.placeholder=this._config.placeholder)}_updateSearchSize(e=2){this._searchElement&&this._config.multiple&&(this._selected.length>0&&("tags"===this._config.selectionType||"text"===this._config.selectionType)?this._searchElement.size=e:0!==this._selected.length||"tags"!==this._config.selectionType&&"text"!==this._config.selectionType||this._searchElement.removeAttribute("size"))}_onSearchChange(e){e&&(this.search(e.value),this._updateSearchSize(e.value.length+1))}_updateOptionsList(e=this._options){for(const t of e)t.label?this._updateOptionsList(t.options):t.selected&&this._selectOption(t.value,t.text)}_isVisible(e){return"none"!==window.getComputedStyle(e).display}_isShown(){return this._clone.classList.contains(yo)}_filterOptionsList(){const e=R.find(Ja,this._menu);let t=0;for(const i of e){-1===i.textContent.toLowerCase().indexOf(this._search)?i.style.display="none":(i.style.removeProperty("display"),t++);const e=i.closest(".form-multi-select-optgroup");e&&(R.children(e,Ja).filter((e=>this._isVisible(e))).length>0?e.style.removeProperty("display"):e.style.display="none")}if(t>0)R.findOne(eo,this._menu)&&R.findOne(eo,this._menu).remove();else if(0===t){const e=document.createElement("div");e.classList.add("form-multi-select-options-empty"),e.innerHTML=this._config.searchNoResultsLabel,R.findOne(eo,this._menu)||R.findOne(".form-multi-select-options",this._menu).append(e)}}_selectMenuItem({key:e,target:t}){const i=R.find(".form-multi-select-options .form-multi-select-option:not(.disabled):not(:disabled)",this._menu).filter((e=>l(e)));i.length&&v(i,t,e===Ka,!i.includes(t)).focus()}_configAfterMerge(e){return!0===e.container&&(e.container=document.body),"object"!=typeof e.container&&"string"!=typeof e.container||(e.container=r(e.container)),e}static multiSelectInterface(e,t){const i=ko.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){ko.multiSelectInterface(this,e)}))}static clearMenus(e){if(e&&(2===e.button||"keyup"===e.type&&"Tab"!==e.key))return;const i=R.find(io);for(let n=0,s=i.length;n<s;n++){const s=t.get(i[n],Ya);i[n],e&&e.type,s&&s._clone.classList.contains(yo)&&(s._clone.contains(e.target)||(s.hide(),M.trigger(s._element,oo)))}}}M.on(window,go,(()=>{for(const e of R.find(io))-1!==e.tabIndex&&ko.multiSelectInterface(e)})),M.on(document,_o,ko.clearMenus),M.on(document,fo,ko.clearMenus),p(ko);const Eo="bs.navigation",Lo=`.${Eo}`,To=".data-api",Co={activeLinksExact:!0,groupsAutoCollapse:!0},Ao={activeLinksExact:"boolean",groupsAutoCollapse:"(string|boolean)"},xo="active",Oo="show",$o="nav-group-toggle",So=`click${Lo}${To}`,No=`load${Lo}${To}`,Io=".nav-group",Mo=".nav-group-items",Po=".nav-group-toggle";class jo extends z{constructor(e,i){super(e),this._config=this._getConfig(i),this._setActiveLink(),this._addEventListeners(),t.set(e,Eo,this)}static get Default(){return Co}static get DATA_KEY(){return Eo}static get DefaultType(){return Ao}static get NAME(){return"navigation"}_setActiveLink(){for(const e of Array.from(this._element.querySelectorAll(".nav-link"))){if(e.classList.contains($o))continue;let t=String(window.location);const i=/\?./,n=/#./;(/\?.*=/.test(t)||i.test(t))&&(t=t.split("?")[0]),n.test(t)&&(t=t.split("#")[0]),this._config.activeLinksExact&&e.href===t&&(e.classList.add(xo),Array.from(this._getParents(e,Io)).forEach((e=>{e.classList.add(Oo),e.setAttribute("aria-expanded",!0)}))),!this._config.activeLinksExact&&e.href.startsWith(t)&&(e.classList.add(xo),Array.from(this._getParents(e,Io)).forEach((e=>{e.classList.add(Oo),e.setAttribute("aria-expanded",!0)})))}}_getParents(e,t){const i=[];for(;e&&e!==document;e=e.parentNode)t?e.matches(t)&&i.push(e):i.push(e);return i}_getAllSiblings(e,t){const i=[];e=e.parentNode.firstChild;do{3!==e.nodeType&&8!==e.nodeType&&(t&&!t(e)||i.push(e))}while(e=e.nextSibling);return i}_getChildren(e,t){const i=[];for(;e;e=e.nextSibling)1===e.nodeType&&e!==t&&i.push(e);return i}_getSiblings(e,t){return this._getChildren(e.parentNode.firstChild,e).filter(t)}_slideDown(e){e.style.height="auto";const t=e.clientHeight;e.style.height="0px",setTimeout((()=>{e.style.height=`${t}px`}),0),this._queueCallback((()=>{e.style.height="auto"}),e,!0)}_slideUp(e,t){const i=e.clientHeight;e.style.height=`${i}px`,setTimeout((()=>{e.style.height="0px"}),0),this._queueCallback((()=>{"function"==typeof t&&t()}),e,!0)}_toggleGroupItems(e){let t=e.target;t.classList.contains($o)||(t=t.closest(Po));const i=e=>Boolean(e.classList.contains("nav-group")&&e.classList.contains(Oo));if(!0===this._config.groupsAutoCollapse)for(const e of this._getSiblings(t.parentNode,i))this._slideUp(R.findOne(Mo,e),(()=>{e.classList.remove(Oo),e.setAttribute("aria-expanded",!1)}));t.parentNode.classList.contains(Oo)?this._slideUp(R.findOne(Mo,t.parentNode),(()=>{t.parentNode.classList.remove(Oo),t.parentNode.setAttribute("aria-expanded",!1)})):(t.parentNode.classList.add(Oo),t.parentNode.setAttribute("aria-expanded",!0),this._slideDown(R.findOne(Mo,t.parentNode)))}_addEventListeners(){M.on(this._element,So,Po,(e=>{e.preventDefault(),this._toggleGroupItems(e,this)}))}static navigationInterface(e,t){const i=jo.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){jo.navigationInterface(this,e)}))}}M.on(window,No,(()=>{for(const e of Array.from(document.querySelectorAll('[data-bs="navigation"]')))jo.navigationInterface(e)})),p(jo);const Bo=".bs.offcanvas",Fo=".data-api",Ho=`load${Bo}${Fo}`,zo="show",Vo="showing",Ro="hiding",Wo=".offcanvas.show",Yo=`show${Bo}`,qo=`shown${Bo}`,Uo=`hide${Bo}`,Qo=`hidePrevented${Bo}`,Ko=`hidden${Bo}`,Xo=`resize${Bo}`,Go=`click${Bo}${Fo}`,Zo=`keydown.dismiss${Bo}`,Jo={backdrop:!0,keyboard:!0,scroll:!1},er={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class tr extends z{constructor(e,t){super(e,t),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Jo}static get DefaultType(){return er}static get NAME(){return"offcanvas"}toggle(e){return this._isShown?this.hide():this.show(e)}show(e){this._isShown||M.trigger(this._element,Yo,{relatedTarget:e}).defaultPrevented||(this._isShown=!0,this._backdrop.show(),this._config.scroll||(new Ca).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Vo),this._queueCallback((()=>{this._config.scroll&&!this._config.backdrop||this._focustrap.activate(),this._element.classList.add(zo),this._element.classList.remove(Vo),M.trigger(this._element,qo,{relatedTarget:e})}),this._element,!0))}hide(){this._isShown&&(M.trigger(this._element,Uo).defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(Ro),this._backdrop.hide(),this._queueCallback((()=>{this._element.classList.remove(zo,Ro),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new Ca).reset(),M.trigger(this._element,Ko)}),this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const e=Boolean(this._config.backdrop);return new ga({className:"offcanvas-backdrop",isVisible:e,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:e?()=>{"static"!==this._config.backdrop?this.hide():M.trigger(this._element,Qo)}:null})}_initializeFocusTrap(){return new Da({trapElement:this._element})}_addEventListeners(){M.on(this._element,Zo,(e=>{"Escape"===e.key&&(this._config.keyboard?this.hide():M.trigger(this._element,Qo))}))}static jQueryInterface(e){return this.each((function(){const t=tr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}M.on(document,Go,'[data-bs-toggle="offcanvas"]',(function(e){const t=R.getElementFromSelector(this);if(["A","AREA"].includes(this.tagName)&&e.preventDefault(),c(this))return;M.one(t,Ko,(()=>{l(this)&&this.focus()}));const i=R.findOne(Wo);i&&i!==t&&tr.getInstance(i).hide(),tr.getOrCreateInstance(t).toggle(this)})),M.on(window,Ho,(()=>{for(const e of R.find(Wo))tr.getOrCreateInstance(e).show()})),M.on(window,Xo,(()=>{for(const e of R.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(e).position&&tr.getOrCreateInstance(e).hide()})),W(tr),p(tr);const ir={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],dd:[],div:[],dl:[],dt:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","srcset","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},nr=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),sr=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:/?#]*(?:[/?#]|$))/i,ar=(e,t)=>{const i=e.nodeName.toLowerCase();return t.includes(i)?!nr.has(i)||Boolean(sr.test(e.nodeValue)):t.filter((e=>e instanceof RegExp)).some((e=>e.test(i)))};function or(e,t,i){if(!e.length)return e;if(i&&"function"==typeof i)return i(e);const n=(new window.DOMParser).parseFromString(e,"text/html"),s=[].concat(...n.body.querySelectorAll("*"));for(const e of s){const i=e.nodeName.toLowerCase();if(!Object.keys(t).includes(i)){e.remove();continue}const n=[].concat(...e.attributes),s=[].concat(t["*"]||[],t[i]||[]);for(const t of n)ar(t,s)||e.removeAttribute(t.nodeName)}return n.body.innerHTML}const rr={allowList:ir,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},lr={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},cr={entry:"(string|element|function|null)",selector:"(string|element)"};class hr extends H{constructor(e){super(),this._config=this._getConfig(e)}static get Default(){return rr}static get DefaultType(){return lr}static get NAME(){return"TemplateFactory"}getContent(){return Object.values(this._config.content).map((e=>this._resolvePossibleFunction(e))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(e){return this._checkContent(e),this._config.content={...this._config.content,...e},this}toHtml(){const e=document.createElement("div");e.innerHTML=this._maybeSanitize(this._config.template);for(const[t,i]of Object.entries(this._config.content))this._setContent(e,i,t);const t=e.children[0],i=this._resolvePossibleFunction(this._config.extraClass);return i&&t.classList.add(...i.split(" ")),t}_typeCheckConfig(e){super._typeCheckConfig(e),this._checkContent(e.content)}_checkContent(e){for(const[t,i]of Object.entries(e))super._typeCheckConfig({selector:t,entry:i},cr)}_setContent(e,t,i){const n=R.findOne(i,e);n&&((t=this._resolvePossibleFunction(t))?o(t)?this._putElementInTemplate(r(t),n):this._config.html?n.innerHTML=this._maybeSanitize(t):n.textContent=t:n.remove())}_maybeSanitize(e){return this._config.sanitize?or(e,this._config.allowList,this._config.sanitizeFn):e}_resolvePossibleFunction(e){return m(e,[void 0,this])}_putElementInTemplate(e,t){if(this._config.html)return t.innerHTML="",void t.append(e);t.textContent=e.textContent}}const dr=new Set(["sanitize","allowList","sanitizeFn"]),ur="fade",_r="show",fr=".tooltip-inner",gr=".modal",pr="hide.bs.modal",mr="hover",br="focus",vr={AUTO:"auto",TOP:"top",RIGHT:g()?"left":"right",BOTTOM:"bottom",LEFT:g()?"right":"left"},yr={allowList:ir,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,6],placement:"top",popperConfig:null,sanitize:!0,sanitizeFn:null,selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',title:"",trigger:"hover focus"},wr={allowList:"object",animation:"boolean",boundary:"(string|element)",container:"(string|element|boolean)",customClass:"(string|function)",delay:"(number|object)",fallbackPlacements:"array",html:"boolean",offset:"(array|string|function)",placement:"(string|function)",popperConfig:"(null|object|function)",sanitize:"boolean",sanitizeFn:"(null|function)",selector:"(string|boolean)",template:"string",title:"(string|element|function)",trigger:"string"};class Dr extends z{constructor(e,t){if(void 0===mn)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(e,t),this._isEnabled=!0,this._timeout=0,this._isHovered=null,this._activeTrigger={},this._popper=null,this._templateFactory=null,this._newContent=null,this.tip=null,this._setListeners(),this._config.selector||this._fixTitle()}static get Default(){return yr}static get DefaultType(){return wr}static get NAME(){return"tooltip"}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(){this._isEnabled&&(this._activeTrigger.click=!this._activeTrigger.click,this._isShown()?this._leave():this._enter())}dispose(){clearTimeout(this._timeout),M.off(this._element.closest(gr),pr,this._hideModalHandler),this._element.getAttribute("data-bs-original-title")&&this._element.setAttribute("title",this._element.getAttribute("data-bs-original-title")),this._disposePopper(),super.dispose()}show(){if("none"===this._element.style.display)throw new Error("Please use show on visible elements");if(!this._isWithContent()||!this._isEnabled)return;const e=M.trigger(this._element,this.constructor.eventName("show")),t=(h(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(e.defaultPrevented||!t)return;this._disposePopper();const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:n}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(n.append(i),M.trigger(this._element,this.constructor.eventName("inserted"))),this._popper=this._createPopper(i),i.classList.add(_r),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))M.on(e,"mouseover",d);this._queueCallback((()=>{M.trigger(this._element,this.constructor.eventName("shown")),!1===this._isHovered&&this._leave(),this._isHovered=!1}),this.tip,this._isAnimated())}hide(){if(this._isShown()&&!M.trigger(this._element,this.constructor.eventName("hide")).defaultPrevented){if(this._getTipElement().classList.remove(_r),"ontouchstart"in document.documentElement)for(const e of[].concat(...document.body.children))M.off(e,"mouseover",d);this._activeTrigger.click=!1,this._activeTrigger[br]=!1,this._activeTrigger[mr]=!1,this._isHovered=null,this._queueCallback((()=>{this._isWithActiveTrigger()||(this._isHovered||this._disposePopper(),this._element.removeAttribute("aria-describedby"),M.trigger(this._element,this.constructor.eventName("hidden")))}),this.tip,this._isAnimated())}}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._newContent||this._getContentForTemplate())),this.tip}_createTipElement(e){const t=this._getTemplateFactory(e).toHtml();if(!t)return null;t.classList.remove(ur,_r),t.classList.add(`bs-${this.constructor.NAME}-auto`);const i=s(this.constructor.NAME).toString();return t.setAttribute("id",i),this._isAnimated()&&t.classList.add(ur),t}setContent(e){this._newContent=e,this._isShown()&&(this._disposePopper(),this.show())}_getTemplateFactory(e){return this._templateFactory?this._templateFactory.changeContent(e):this._templateFactory=new hr({...this._config,content:e,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{[fr]:this._getTitle()}}_getTitle(){return this._resolvePossibleFunction(this._config.title)||this._element.getAttribute("data-bs-original-title")}_initializeOnDelegatedTarget(e){return this.constructor.getOrCreateInstance(e.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(ur)}_isShown(){return this.tip&&this.tip.classList.contains(_r)}_createPopper(e){const t=m(this._config.placement,[this,e,this._element]),i=vr[t.toUpperCase()];return pn(this._element,e,this._getPopperConfig(i))}_getOffset(){const{offset:e}=this._config;return"string"==typeof e?e.split(",").map((e=>Number.parseInt(e,10))):"function"==typeof e?t=>e(t,this._element):e}_resolvePossibleFunction(e){return m(e,[this._element,this._element])}_getPopperConfig(e){const t={placement:e,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:e=>{this._getTipElement().setAttribute("data-popper-placement",e.state.placement)}}]};return{...t,...m(this._config.popperConfig,[void 0,t])}}_setListeners(){const e=this._config.trigger.split(" ");for(const t of e)if("click"===t)M.on(this._element,this.constructor.eventName("click"),this._config.selector,(e=>{this._initializeOnDelegatedTarget(e).toggle()}));else if("manual"!==t){const e=t===mr?this.constructor.eventName("mouseenter"):this.constructor.eventName("focusin"),i=t===mr?this.constructor.eventName("mouseleave"):this.constructor.eventName("focusout");M.on(this._element,e,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusin"===e.type?br:mr]=!0,t._enter()})),M.on(this._element,i,this._config.selector,(e=>{const t=this._initializeOnDelegatedTarget(e);t._activeTrigger["focusout"===e.type?br:mr]=t._element.contains(e.relatedTarget),t._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},M.on(this._element.closest(gr),pr,this._hideModalHandler)}_fixTitle(){const e=this._element.getAttribute("title");e&&(this._element.getAttribute("aria-label")||this._element.textContent.trim()||this._element.setAttribute("aria-label",e),this._element.setAttribute("data-bs-original-title",e),this._element.removeAttribute("title"))}_enter(){this._isShown()||this._isHovered?this._isHovered=!0:(this._isHovered=!0,this._setTimeout((()=>{this._isHovered&&this.show()}),this._config.delay.show))}_leave(){this._isWithActiveTrigger()||(this._isHovered=!1,this._setTimeout((()=>{this._isHovered||this.hide()}),this._config.delay.hide))}_setTimeout(e,t){clearTimeout(this._timeout),this._timeout=setTimeout(e,t)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(e){const t=F.getDataAttributes(this._element);for(const e of Object.keys(t))dr.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}_configAfterMerge(e){return e.container=!1===e.container?document.body:r(e.container),"number"==typeof e.delay&&(e.delay={show:e.delay,hide:e.delay}),"number"==typeof e.title&&(e.title=e.title.toString()),"number"==typeof e.content&&(e.content=e.content.toString()),e}_getDelegateConfig(){const e={};for(const[t,i]of Object.entries(this._config))this.constructor.Default[t]!==i&&(e[t]=i);return e.selector=!1,e.trigger="manual",e}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null),this.tip&&(this.tip.remove(),this.tip=null)}static jQueryInterface(e){return this.each((function(){const t=Dr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}p(Dr);const kr=".popover-header",Er=".popover-body",Lr={...Dr.Default,content:"",offset:[0,8],placement:"right",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>',trigger:"click"},Tr={...Dr.DefaultType,content:"(null|string|element|function)"};class Cr extends Dr{static get Default(){return Lr}static get DefaultType(){return Tr}static get NAME(){return"popover"}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{[kr]:this._getTitle(),[Er]:this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(e){return this.each((function(){const t=Cr.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e]()}}))}}p(Cr);const Ar=".bs.range-slider",xr=`change${Ar}`,Or=`load${Ar}.data-api`,$r=`mousedown${Ar}`,Sr=`mousemove${Ar}`,Nr=`mouseup${Ar}`,Ir=`resize${Ar}`,Mr="range-slider-track",Pr=".range-slider-input",jr=".range-slider-label",Br={clickableLabels:!0,disabled:!1,distance:0,labels:!1,max:100,min:0,name:null,step:1,tooltips:!0,tooltipsFormat:null,track:"fill",value:0,vertical:!1},Fr={clickableLabels:"boolean",disabled:"boolean",distance:"number",labels:"(array|boolean|string)",max:"number",min:"number",name:"(array|string|null)",step:"(number|string)",tooltips:"boolean",tooltipsFormat:"(function|null)",track:"(boolean|string)",value:"(array|number)",vertical:"boolean"};class Hr extends z{constructor(e,t){super(e),this._config=this._getConfig(t),this._currentValue=this._config.value,this._dragIndex=0,this._inputs=[],this._isDragging=!1,this._sliderTrack=null,this._thumbSize=null,this._tooltips=[],this._initializeRangeSlider()}static get Default(){return Br}static get DefaultType(){return Fr}static get NAME(){return"range-slider"}update(e){this._config=this._getConfig(e),this._currentValue=this._config.value,this._element.innerHTML="",this._initializeRangeSlider()}_addEventListeners(){this._config.disabled||(M.on(this._element,"input",Pr,(e=>{const{target:t}=e;this._isDragging=!1;const i=R.children(t.parentElement,Pr),n=Array.from(i).indexOf(t);this._updateValue(t.value,n)})),M.on(this._element,$r,jr,(e=>{if(!this._config.clickableLabels||0!==e.button)return;const t=F.getDataAttribute(e.target,"value");this._updateNearestValue(t)})),M.on(this._element,$r,".range-slider-inputs-container",(e=>{if(0!==e.button)return;if(!(e.target instanceof HTMLInputElement||e.target.className.includes(Mr)))return;this._isDragging=!0;const t=this._calculateClickValue(e);this._dragIndex=this._getNearestValueIndex(t),this._updateNearestValue(t)})),M.on(document.documentElement,Nr,(()=>{this._isDragging=!1})),M.on(document.documentElement,Sr,(e=>{if(!this._isDragging)return;const t=this._calculateMoveValue(e);this._updateValue(t,this._dragIndex)})),M.on(window,Ir,(()=>{this._updateLabelsContainerSize()})))}_initializeRangeSlider(){this._element.classList.add("range-slider"),this._config.vertical&&this._element.classList.add("range-slider-vertical"),this._config.disabled&&this._element.classList.add("disabled"),this._sliderTrack=this._createSliderTrack(),this._createInputs(),this._createLabels(),this._updateLabelsContainerSize(),this._createTooltips(),this._updateGradient(),this._addEventListeners()}_createSliderTrack(){return this._createElement("div",Mr)}_createInputs(){const e=this._createElement("div","range-slider-inputs-container");for(const[t,i]of this._currentValue.entries()){const n=this._createInput(t,i);e.append(n),this._inputs[t]=n}e.append(this._sliderTrack),this._element.append(e)}_createInput(e,t){const i=this._createElement("input","range-slider-input");return i.type="range",i.min=this._config.min,i.max=this._config.max,i.step=this._config.step,i.value=t,i.name=Array.isArray(this._config.name)?`${this._config.name[e]}`:`${this._config.name||""}-${e}`,i.disabled=this._config.disabled,i.setAttribute("role","slider"),i.setAttribute("aria-valuemin",this._config.min),i.setAttribute("aria-valuemax",this._config.max),i.setAttribute("aria-valuenow",t),i.setAttribute("aria-orientation",this._config.vertical?"vertical":"horizontal"),i}_createLabels(){const{clickableLabels:e,disabled:t,labels:i,min:n,max:s,vertical:a}=this._config;if(!i||!Array.isArray(i)||0===i.length)return;const o=this._createElement("div","range-slider-labels-container");for(const[r,l]of this._config.labels.entries()){const c=this._createElement("div","range-slider-label");if(e&&!t&&c.classList.add("clickable"),l.class){const e=Array.isArray(l.class)?l.class:[l.class];c.classList.add(...e)}l.style&&"object"==typeof l.style&&Object.assign(c.style,l.style);const h=1===i.length?0:r/(i.length-1)*100,d="object"==typeof l?l.value:n+h/100*(s-n);F.setDataAttribute(c,"value",d),c.textContent="object"==typeof l?l.label:l;const u=this._calculateLabelPosition(l,r,h);a?c.style.bottom=u:c.style[g()?"right":"left"]=u,o.append(c)}this._element.append(o)}_calculateLabelPosition(e,t){return"object"==typeof e&&void 0!==e.value?(e.value-this._config.min)/(this._config.max-this._config.min)*100+"%":t/(this._config.labels.length-1)*100+"%"}_updateLabelsContainerSize(){const e=R.findOne(".range-slider-labels-container",this._element);if(!this._config.labels||!e)return;const t=R.find(jr,this._element);if(0===t.length)return;const i=Math.max(...t.map((e=>this._config.vertical?e.offsetWidth:e.offsetHeight)));e.style[this._config.vertical?"width":"height"]=`${i}px`}_createTooltips(){if(!this._config.tooltips)return;const e=R.find(Pr,this._element);this._thumbSize=this._getThumbSize();for(const t of e){const e=this._createElement("div","range-slider-tooltip"),i=this._createElement("div","range-slider-tooltip-inner"),n=this._createElement("div","range-slider-tooltip-arrow");i.innerHTML=this._config.tooltipsFormat?this._config.tooltipsFormat(t.value):t.value,e.append(i,n),t.parentNode.insertBefore(e,t.nextSibling),this._positionTooltip(e,t),this._tooltips.push(e)}}_getThumbSize(){const e=window.getComputedStyle(this._element,null).getPropertyValue(this._config.vertical?"--bs-range-slider-thumb-height":"--bs-range-slider-thumb-width").match(/^(\d+\.?\d*)([%a-z]*)$/i);return e?{value:Number.parseFloat(e[1]),unit:e[2]||null}:"1rem"}_positionTooltip(e,t){const i=this._thumbSize,n=(t.value-this._config.min)/(this._config.max-this._config.min),s=n>.5?`-${(n-.5)*i.value}${i.unit}`:`${(.5-n)*i.value}${i.unit}`;this._config.vertical?Object.assign(e.style,{bottom:100*n+"%",marginBottom:s}):Object.assign(e.style,g()?{right:100*n+"%",marginRight:s}:{left:100*n+"%",marginLeft:s})}_updateTooltip(e,t){if(this._config.tooltips&&this._tooltips[e]){this._tooltips[e].children[0].innerHTML=this._config.tooltipsFormat?this._config.tooltipsFormat(t):t;const i=R.find(Pr,this._element)[e];this._positionTooltip(this._tooltips[e],i)}}_calculateClickValue(e){const t=this._getClickPosition(e),i=this._config.min+t*(this._config.max-this._config.min);return this._roundToStep(i,this._config.step)}_calculateMoveValue(e){const t=this._sliderTrack.getBoundingClientRect(),i=this._config.vertical?this._calculateVerticalPosition(e.clientY,t):this._calculateHorizontalPosition(e.clientX,t);if("string"==typeof i)return"max"===i?this._config.max:this._config.min;const n=this._config.min+i*(this._config.max-this._config.min);return this._roundToStep(n,this._config.step)}_calculateVerticalPosition(e,t){return e<t.top?"max":e>t.bottom?"min":Math.min(Math.max((t.bottom-e)/t.height,0),1)}_calculateHorizontalPosition(e,t){if(e<t.left)return g()?"max":"min";if(e>t.right)return g()?"min":"max";const i=g()?t.right-e:e-t.left;return Math.min(Math.max(i/t.width,0),1)}_createElement(e,t){const i=document.createElement(e);return i.classList.add(t),i}_getClickPosition(e){const{offsetX:t,offsetY:i}=e,{offsetWidth:n,offsetHeight:s}=this._sliderTrack;return this._config.vertical?1-i/s:g()?1-t/n:t/n}_getNearestValueIndex(e){const t=this._currentValue,i=t.length;if(e<t[0])return 0;if(e>t[i-1])return i-1;const n=t.map((t=>Math.abs(t-e))),s=Math.min(...n),a=n.indexOf(s);return e<t[a]?a:n.lastIndexOf(s)}_updateGradient(){if(!this._config.track)return;const[e,t]=[Math.min(...this._currentValue),Math.max(...this._currentValue)],i=(e-this._config.min)/(this._config.max-this._config.min)*100,n=(t-this._config.min)/(this._config.max-this._config.min)*100,s=this._config.vertical?"to top":g()?"to left":"to right";1!==this._currentValue.length?this._sliderTrack.style.backgroundImage=`linear-gradient(\n ${s},\n transparent 0%,\n transparent ${i}%,\n var(--bs-range-slider-track-in-range-bg) ${i}%,\n var(--bs-range-slider-track-in-range-bg) ${n}%,\n transparent ${n}%,\n transparent 100%\n )`:this._sliderTrack.style.backgroundImage=`linear-gradient(\n ${s},\n var(--bs-range-slider-track-in-range-bg) 0%,\n var(--bs-range-slider-track-in-range-bg) ${n}%,\n transparent ${n}%,\n transparent 100%\n )`}_updateNearestValue(e){const t=this._getNearestValueIndex(e);this._updateValue(e,t)}_updateValue(e,t){const i=this._validateValue(e,t);this._currentValue[t]=i,this._updateInput(t,i),this._updateGradient(),this._updateTooltip(t,i),M.trigger(this._element,xr,{value:this._currentValue})}_updateInput(e,t){const i=this._inputs[e];i.value=t,i.setAttribute("aria-valuenow",t),setTimeout((()=>{i.focus()}))}_validateValue(e,t){const{distance:i}=this._config,{length:n}=this._currentValue;if(1===n)return e;const s=t>0?this._currentValue[t-1]:void 0,a=t<n-1?this._currentValue[t+1]:void 0;if(0===t&&void 0!==a)return Math.min(e,a-i);if(t===n-1&&void 0!==s)return Math.max(e,s+i);if(void 0!==s&&void 0!==a){const t=s+i,n=a-i;return Math.min(Math.max(e,t),n)}return e}_roundToStep(e,t){const i=0===t?1:t;return Math.round(e/i)*i}_configAfterMerge(e){return"string"==typeof e.labels&&(e.labels=e.labels.split(/,\s*/)),"string"==typeof e.name&&(e.name=e.name.split(/,\s*/)),"number"==typeof e.value&&(e.value=[e.value]),"string"==typeof e.value&&(e.value=e.value.split(/,\s*/).map(Number)),e}_getConfig(e){return e={...F.getDataAttributes(this._element),..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static rangeSliderInterface(e,t){const i=Hr.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=Hr.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}M.on(window,Or,(()=>{const e=R.find('[data-bs-toggle="range-slider"]');for(let t=0,i=e.length;t<i;t++)Hr.rangeSliderInterface(e[t])})),p(Hr);const zr=".bs.rating",Vr=new Set(["sanitize","allowList","sanitizeFn"]),Rr=`change${zr}`,Wr=`click${zr}`,Yr=`focusin${zr}`,qr=`focusout${zr}`,Ur=`hover${zr}`,Qr=`load${zr}.data-api`,Kr=`mouseenter${zr}`,Xr=`mouseleave${zr}`,Gr="active",Zr=".rating-item-input",Jr=".rating-item-label",el={activeIcon:null,allowClear:!1,allowList:{...ir,svg:["xmlns","version","baseprofile","width","height","viewbox","preserveaspectratio","aria-hidden","role","focusable"],g:["id","class","transform","style"],path:["id","class","d","fill","fill-opacity","fill-rule","stroke","stroke-width","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-dasharray","stroke-dashoffset","stroke-opacity"],circle:["id","class","cx","cy","r","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],rect:["id","class","x","y","width","height","rx","ry","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],ellipse:["id","class","cx","cy","rx","ry","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],line:["id","class","x1","y1","x2","y2","stroke","stroke-width","stroke-opacity"],polygon:["id","class","points","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],polyline:["id","class","points","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],text:["id","class","x","y","dx","dy","text-anchor","font-family","font-size","font-weight","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],tspan:["id","class","x","y","dx","dy","text-anchor","font-family","font-size","font-weight","fill","fill-opacity","stroke","stroke-width","stroke-opacity"],defs:[],symbol:["id","class","viewbox","preserveaspectratio"],use:["id","class","x","y","width","height","href"],image:["id","class","x","y","width","height","href","preserveaspectratio","xlink:href"],pattern:["id","class","x","y","width","height","patternunits","patterncontentunits","patterntransform","preserveaspectratio"],lineargradient:["id","class","gradientunits","x1","y1","x2","y2","spreadmethod","gradienttransform"],radialgradient:["id","class","gradientunits","cx","cy","r","fx","fy","spreadmethod","gradienttransform"],mask:["id","class","x","y","width","height","maskunits","maskcontentunits","masktransform"],clippath:["id","class","clippathunits"],marker:["id","class","markerunits","markerwidth","markerheight","orient","preserveaspectratio","viewbox","refx","refy"],title:[],desc:[]},disabled:!1,highlightOnlySelected:!1,icon:null,itemCount:5,name:null,precision:1,readOnly:!1,sanitizeFn:null,size:null,tooltips:!1,value:null},tl={activeIcon:"(object|string|null)",allowClear:"boolean",allowList:"object",disabled:"boolean",highlightOnlySelected:"boolean",icon:"(object|string|null)",itemCount:"number",name:"(string|null)",precision:"number",readOnly:"boolean",sanitizeFn:"(null|function)",size:"(string|null)",tooltips:"(array|boolean|object)",value:"(number|null)"};class il extends z{constructor(e,t){super(e),this._config=this._getConfig(t),this._currentValue=this._config.value,this._name=this._config.name||s(`${this.constructor.NAME}-name-`).toString(),this._tooltip=null,this._createRating(),this._addEventListeners()}static get Default(){return el}static get DefaultType(){return tl}static get NAME(){return"rating"}update(e){this._config=this._getConfig(e),this._currentValue=this._config.value,this._element.innerHTML="",this._createRating(),this._addEventListeners()}reset(e=null){this._currentValue=e,this._element.innerHTML="",this._createRating(),this._addEventListeners(),M.trigger(this._element,Rr,{value:e})}_addEventListeners(){M.on(this._element,Wr,Zr,(({target:e})=>{this._config.disabled||this._config.readOnly||this._config.allowClear&&this._currentValue==e.value&&(this._currentValue=null,e.checked=!1,this._resetLabels(),M.trigger(this._element,Rr,{value:null}))})),M.on(this._element,Rr,Zr,(({target:e})=>{if(this._config.disabled||this._config.readOnly)return;this._currentValue=e.value,M.trigger(this._element,Rr,{value:e.value});const t=R.find(Zr,this._element);if(this._resetLabels(),this._config.highlightOnlySelected)R.findOne(Jr,e.parentElement).classList.add(Gr);else for(const i of t)if(R.findOne(Jr,i.parentElement).classList.add(Gr),i===e)break})),M.on(this._element,Kr,Jr,(({target:e})=>{if(this._config.disabled||this._config.readOnly)return;const t=e.closest(Jr),i=R.find(Jr,this._element);this._resetLabels();const n=R.findOne(Zr,t.parentElement);if(M.trigger(this._element,Ur,{value:n.value}),this._createTooltip(t.parentElement,n.value),this._config.highlightOnlySelected)t.classList.add(Gr);else for(const e of i)if(e.classList.add(Gr),e===t)break})),M.on(this._element,Xr,Jr,(()=>{if(this._config.disabled||this._config.readOnly)return;this._tooltip&&this._tooltip.hide();const e=R.findOne(`${Zr}[value="${this._currentValue}"]`,this._element);if(this._resetLabels(),M.trigger(this._element,Ur,{value:null}),e&&this._config.highlightOnlySelected)R.findOne(Jr,e.parentElement).classList.add(Gr);else if(e){const t=R.find(Zr,this._element);this._resetLabels();for(const i of t)if(R.findOne(Jr,i.parentElement).classList.add(Gr),i===e)break}})),M.on(this._element,Yr,Zr,(({target:e})=>{M.trigger(this._element,Ur,{value:e.value}),this._createTooltip(e.parentElement,e.value)})),M.on(this._element,qr,Zr,(()=>{M.trigger(this._element,Ur,{value:null}),this._tooltip&&this._tooltip.hide()}))}_createTooltip(e,t){if(!1===this._config.tooltips)return;let i;this._tooltip&&this._tooltip.hide(),"boolean"==typeof this._config.tooltips&&(i=t),"object"==typeof this._config.tooltips&&(i=this._config.tooltips[t]),Array.isArray(this._config.tooltips)&&(i=this._config.tooltips[t-1]),this._tooltip=new Dr(e,{title:i})}_configAfterMerge(e){return"string"==typeof e.tooltips&&(e.tooltips=e.tooltips.split(",")),e}_resetLabels(){const e=R.find(Jr,this._element);for(const t of e)t.classList.remove(Gr)}_createRating(){this._element.classList.add("rating"),this._config.size&&this._element.classList.add(`rating-${this._config.size}`),this._config.disabled&&this._element.classList.add("disabled"),this._config.readOnly&&this._element.classList.add("readonly"),this._element.setAttribute("role","radiogroup"),Array.from({length:this._config.itemCount},((e,t)=>this._createRatingItem(t)))}_createRatingItem(e){const t=document.createElement("div");t.classList.add("rating-item");const i=1/this._config.precision;Array.from({length:i},((n,a)=>{const o=s(`${this.constructor.NAME}${e}`).toString(),r=a+1<i,l=1===i?e+1:(a+1)*Number(this._config.precision)+e,c=document.createElement("label");if(c.classList.add("rating-item-label"),c.setAttribute("for",o),this._config.highlightOnlySelected&&this._currentValue==l&&c.classList.add(Gr),!this._config.highlightOnlySelected&&this._currentValue>=l&&c.classList.add(Gr),r&&(c.style.zIndex=1/this._config.precision-a,c.style.position="absolute",c.style.width=this._config.precision*(a+1)*100+"%",c.style.overflow="hidden",c.style.opacity=0),this._config.icon){const t=document.createElement("div");t.classList.add("rating-item-custom-icon"),t.innerHTML=this._sanitizeIcon("object"==typeof this._config.icon?this._config.icon[e+1]:this._config.icon),c.append(t)}else{const e=document.createElement("div");e.classList.add("rating-item-icon"),c.append(e)}if(this._config.icon&&this._config.activeIcon){const t=document.createElement("div");t.classList.add("rating-item-custom-icon-active"),t.innerHTML=this._sanitizeIcon("object"==typeof this._config.activeIcon?this._config.activeIcon[e+1]:this._config.activeIcon),c.append(t)}const h=document.createElement("input");if(h.classList.add("rating-item-input"),h.id=o,h.type="radio",h.value=l,h.name=this._name,(this._config.disabled||this._config.readOnly)&&h.setAttribute("disabled",!0),this._currentValue===l&&(h.checked=!0),1===this._config.precision)t.append(c),t.append(h);else{const e=document.createElement("div");e.append(c),e.append(h),t.append(e)}})),this._element.append(t)}_sanitizeIcon(e){return this._config.sanitize?or(e,this._config.allowList,this._config.sanitizeFn):e}_getConfig(e){const t=F.getDataAttributes(this._element);for(const e of Object.keys(t))Vr.has(e)&&delete t[e];return e={...t,..."object"==typeof e&&e?e:{}},e=this._mergeConfigObj(e),e=this._configAfterMerge(e),this._typeCheckConfig(e),e}static ratingInterface(e,t){const i=il.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){const t=il.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}M.on(window,Qr,(()=>{const e=R.find('[data-bs-toggle="rating"]');for(let t=0,i=e.length;t<i;t++)il.ratingInterface(e[t])})),p(il);const nl=".bs.scrollspy",sl=`activate${nl}`,al=`click${nl}`,ol=`load${nl}.data-api`,rl="active",ll="[href]",cl=".nav-link",hl=`${cl}, .nav-item > ${cl}, .list-group-item`,dl={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null,threshold:[.1,.5,1]},ul={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element",threshold:"array"};class _l extends z{constructor(e,t){super(e,t),this._targetLinks=new Map,this._observableSections=new Map,this._rootElement="visible"===getComputedStyle(this._element).overflowY?null:this._element,this._activeTarget=null,this._observer=null,this._previousScrollData={visibleEntryTop:0,parentScrollTop:0},this.refresh()}static get Default(){return dl}static get DefaultType(){return ul}static get NAME(){return"scrollspy"}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const e of this._observableSections.values())this._observer.observe(e)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(e){return e.target=r(e.target)||document.body,e.rootMargin=e.offset?`${e.offset}px 0px -30%`:e.rootMargin,"string"==typeof e.threshold&&(e.threshold=e.threshold.split(",").map((e=>Number.parseFloat(e)))),e}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(M.off(this._config.target,al),M.on(this._config.target,al,ll,(e=>{const t=this._observableSections.get(e.target.hash);if(t){e.preventDefault();const i=this._rootElement||window,n=t.offsetTop-this._element.offsetTop;if(i.scrollTo)return void i.scrollTo({top:n,behavior:"smooth"});i.scrollTop=n}})))}_getNewObserver(){const e={root:this._rootElement,threshold:this._config.threshold,rootMargin:this._config.rootMargin};return new IntersectionObserver((e=>this._observerCallback(e)),e)}_observerCallback(e){const t=e=>this._targetLinks.get(`#${e.target.id}`),i=e=>{this._previousScrollData.visibleEntryTop=e.target.offsetTop,this._process(t(e))},n=(this._rootElement||document.documentElement).scrollTop,s=n>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=n;for(const a of e){if(!a.isIntersecting){this._activeTarget=null,this._clearActiveClass(t(a));continue}const e=a.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(s&&e){if(i(a),!n)return}else s||e||i(a)}}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const e=R.find(ll,this._config.target);for(const t of e){if(!t.hash||c(t))continue;const e=R.findOne(decodeURI(t.hash),this._element);l(e)&&(this._targetLinks.set(decodeURI(t.hash),t),this._observableSections.set(t.hash,e))}}_process(e){this._activeTarget!==e&&(this._clearActiveClass(this._config.target),this._activeTarget=e,e.classList.add(rl),this._activateParents(e),M.trigger(this._element,sl,{relatedTarget:e}))}_activateParents(e){if(e.classList.contains("dropdown-item"))R.findOne(".dropdown-toggle",e.closest(".dropdown")).classList.add(rl);else for(const t of R.parents(e,".nav, .list-group"))for(const e of R.prev(t,hl))e.classList.add(rl)}_clearActiveClass(e){e.classList.remove(rl);const t=R.find(`${ll}.${rl}`,e);for(const e of t)e.classList.remove(rl)}static jQueryInterface(e){return this.each((function(){const t=_l.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}M.on(window,ol,(()=>{for(const e of R.find('[data-bs-spy="scroll"]'))_l.getOrCreateInstance(e)})),p(_l);const fl=".bs.sidebar",gl=".data-api",pl={},ml={},bl="hide",vl="show",yl="sidebar-narrow",wl="sidebar-narrow-unfoldable",Dl=`hide${fl}`,kl=`hidden${fl}`,El=`show${fl}`,Ll=`shown${fl}`,Tl=`click${fl}${gl}`,Cl=`load${fl}${gl}`,Al=".sidebar";class xl extends z{constructor(e,t){super(e),this._config=this._getConfig(t),this._show=this._isVisible(),this._mobile=this._isMobile(),this._overlaid=this._isOverlaid(),this._narrow=this._isNarrow(),this._unfoldable=this._isUnfoldable(),this._backdrop=this._initializeBackDrop(),this._addEventListeners()}static get Default(){return pl}static get DefaultType(){return ml}static get NAME(){return"sidebar"}show(){M.trigger(this._element,El),this._element.classList.contains(bl)&&this._element.classList.remove(bl),this._overlaid&&this._element.classList.add(vl),this._isMobile()&&(this._element.classList.add(vl),this._backdrop.show(),(new Ca).hide()),this._queueCallback((()=>{!0===this._isVisible()&&(this._show=!0,(this._isMobile()||this._isOverlaid())&&this._addClickOutListener(),M.trigger(this._element,Ll))}),this._element,!0)}hide(){M.trigger(this._element,Dl),this._element.classList.contains(vl)&&this._element.classList.remove(vl),this._isMobile()&&(this._backdrop.hide(),(new Ca).reset()),this._isMobile()||this._overlaid||this._element.classList.add(bl),this._queueCallback((()=>{!1===this._isVisible()&&(this._show=!1,(this._isMobile()||this._isOverlaid())&&this._removeClickOutListener(),M.trigger(this._element,kl))}),this._element,!0)}toggle(){this._isVisible()?this.hide():this.show()}narrow(){this._isMobile()||(this._addClassName(yl),this._narrow=!0)}unfoldable(){this._isMobile()||(this._addClassName(wl),this._unfoldable=!0)}reset(){this._isMobile()||(this._narrow&&(this._element.classList.remove(yl),this._narrow=!1),this._unfoldable&&(this._element.classList.remove(wl),this._unfoldable=!1))}toggleNarrow(){this._narrow?this.reset():this.narrow()}toggleUnfoldable(){this._unfoldable?this.reset():this.unfoldable()}_initializeBackDrop(){return new ga({className:"sidebar-backdrop",isVisible:this._isMobile(),isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_isMobile(){return Boolean(window.getComputedStyle(this._element,null).getPropertyValue("--bs-is-mobile"))}_isNarrow(){return this._element.classList.contains(yl)}_isOverlaid(){return this._element.classList.contains("sidebar-overlaid")}_isUnfoldable(){return this._element.classList.contains(wl)}_isVisible(){const e=this._element.getBoundingClientRect();return e.top>=0&&e.left>=0&&Math.floor(e.bottom)<=(window.innerHeight||document.documentElement.clientHeight)&&Math.floor(e.right)<=(window.innerWidth||document.documentElement.clientWidth)}_addClassName(e){this._element.classList.add(e)}_clickOutListener(e,t){null===e.target.closest(Al)&&(e.preventDefault(),e.stopPropagation(),t.hide())}_addClickOutListener(){M.on(document,Tl,(e=>{this._clickOutListener(e,this)}))}_removeClickOutListener(){M.off(document,Tl)}_addEventListeners(){this._mobile&&this._show&&this._addClickOutListener(),this._overlaid&&this._show&&this._addClickOutListener(),M.on(this._element,Tl,"[data-bs-toggle]",(e=>{e.preventDefault();const t=F.getDataAttribute(e.target,"toggle");"narrow"===t&&this.toggleNarrow(),"unfoldable"===t&&this.toggleUnfoldable()})),M.on(this._element,Tl,'[data-bs-close="sidebar"]',(e=>{e.preventDefault(),this.hide()})),M.on(window,"resize",(()=>{this._isMobile()&&this._isVisible()&&(this.hide(),this._backdrop=this._initializeBackDrop())}))}static sidebarInterface(e,t){const i=xl.getOrCreateInstance(e,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}static jQueryInterface(e){return this.each((function(){xl.sidebarInterface(this,e)}))}}M.on(window,Cl,(()=>{for(const e of Array.from(document.querySelectorAll(Al)))xl.sidebarInterface(e)})),p(xl);const Ol=".bs.tab",$l=`hide${Ol}`,Sl=`hidden${Ol}`,Nl=`show${Ol}`,Il=`shown${Ol}`,Ml=`click${Ol}`,Pl=`keydown${Ol}`,jl=`load${Ol}`,Bl="ArrowLeft",Fl="ArrowRight",Hl="ArrowUp",zl="ArrowDown",Vl="Home",Rl="End",Wl="active",Yl="fade",ql="show",Ul=".dropdown-toggle",Ql=`:not(${Ul})`,Kl='[data-bs-toggle="tab"], [data-bs-toggle="pill"], [data-bs-toggle="list"]',Xl=`.nav-link${Ql}, .list-group-item${Ql}, [role="tab"]${Ql}, ${Kl}`,Gl=`.${Wl}[data-bs-toggle="tab"], .${Wl}[data-bs-toggle="pill"], .${Wl}[data-bs-toggle="list"]`;class Zl extends z{constructor(e){super(e),this._parent=this._element.closest('.list-group, .nav, [role="tablist"]'),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),M.on(this._element,Pl,(e=>this._keydown(e))))}static get NAME(){return"tab"}show(){const e=this._element;if(this._elemIsActive(e))return;const t=this._getActiveElem(),i=t?M.trigger(t,$l,{relatedTarget:e}):null;M.trigger(e,Nl,{relatedTarget:t}).defaultPrevented||i&&i.defaultPrevented||(this._deactivate(t,e),this._activate(e,t))}_activate(e,t){e&&(e.classList.add(Wl),this._activate(R.getElementFromSelector(e)),this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.removeAttribute("tabindex"),e.setAttribute("aria-selected",!0),this._toggleDropDown(e,!0),M.trigger(e,Il,{relatedTarget:t})):e.classList.add(ql)}),e,e.classList.contains(Yl)))}_deactivate(e,t){e&&(e.classList.remove(Wl),e.blur(),this._deactivate(R.getElementFromSelector(e)),this._queueCallback((()=>{"tab"===e.getAttribute("role")?(e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1"),this._toggleDropDown(e,!1),M.trigger(e,Sl,{relatedTarget:t})):e.classList.remove(ql)}),e,e.classList.contains(Yl)))}_keydown(e){if(![Bl,Fl,Hl,zl,Vl,Rl].includes(e.key))return;e.stopPropagation(),e.preventDefault();const t=this._getChildren().filter((e=>!c(e)));let i;if([Vl,Rl].includes(e.key))i=t[e.key===Vl?0:t.length-1];else{const n=[Fl,zl].includes(e.key);i=v(t,e.target,n,!0)}i&&(i.focus({preventScroll:!0}),Zl.getOrCreateInstance(i).show())}_getChildren(){return R.find(Xl,this._parent)}_getActiveElem(){return this._getChildren().find((e=>this._elemIsActive(e)))||null}_setInitialAttributes(e,t){this._setAttributeIfNotExists(e,"role","tablist");for(const e of t)this._setInitialAttributesOnChild(e)}_setInitialAttributesOnChild(e){e=this._getInnerElement(e);const t=this._elemIsActive(e),i=this._getOuterElement(e);e.setAttribute("aria-selected",t),i!==e&&this._setAttributeIfNotExists(i,"role","presentation"),t||e.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(e,"role","tab"),this._setInitialAttributesOnTargetPanel(e)}_setInitialAttributesOnTargetPanel(e){const t=R.getElementFromSelector(e);t&&(this._setAttributeIfNotExists(t,"role","tabpanel"),e.id&&this._setAttributeIfNotExists(t,"aria-labelledby",`${e.id}`))}_toggleDropDown(e,t){const i=this._getOuterElement(e);if(!i.classList.contains("dropdown"))return;const n=(e,n)=>{const s=R.findOne(e,i);s&&s.classList.toggle(n,t)};n(Ul,Wl),n(".dropdown-menu",ql),i.setAttribute("aria-expanded",t)}_setAttributeIfNotExists(e,t,i){e.hasAttribute(t)||e.setAttribute(t,i)}_elemIsActive(e){return e.classList.contains(Wl)}_getInnerElement(e){return e.matches(Xl)?e:R.findOne(Xl,e)}_getOuterElement(e){return e.closest(".nav-item, .list-group-item")||e}static jQueryInterface(e){return this.each((function(){const t=Zl.getOrCreateInstance(this);if("string"==typeof e){if(void 0===t[e]||e.startsWith("_")||"constructor"===e)throw new TypeError(`No method named "${e}"`);t[e]()}}))}}M.on(document,Ml,Kl,(function(e){["A","AREA"].includes(this.tagName)&&e.preventDefault(),c(this)||Zl.getOrCreateInstance(this).show()})),M.on(window,jl,(()=>{for(const e of R.find(Gl))Zl.getOrCreateInstance(e)})),p(Zl);const Jl=".bs.toast",ec=`mouseover${Jl}`,tc=`mouseout${Jl}`,ic=`focusin${Jl}`,nc=`focusout${Jl}`,sc=`hide${Jl}`,ac=`hidden${Jl}`,oc=`show${Jl}`,rc=`shown${Jl}`,lc="hide",cc="show",hc="showing",dc={animation:"boolean",autohide:"boolean",delay:"number"},uc={animation:!0,autohide:!0,delay:5e3};class _c extends z{constructor(e,t){super(e,t),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return uc}static get DefaultType(){return dc}static get NAME(){return"toast"}show(){M.trigger(this._element,oc).defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove(lc),u(this._element),this._element.classList.add(cc,hc),this._queueCallback((()=>{this._element.classList.remove(hc),M.trigger(this._element,rc),this._maybeScheduleHide()}),this._element,this._config.animation))}hide(){this.isShown()&&(M.trigger(this._element,sc).defaultPrevented||(this._element.classList.add(hc),this._queueCallback((()=>{this._element.classList.add(lc),this._element.classList.remove(hc,cc),M.trigger(this._element,ac)}),this._element,this._config.animation)))}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(cc),super.dispose()}isShown(){return this._element.classList.contains(cc)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(e,t){switch(e.type){case"mouseover":case"mouseout":this._hasMouseInteraction=t;break;case"focusin":case"focusout":this._hasKeyboardInteraction=t}if(t)return void this._clearTimeout();const i=e.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){M.on(this._element,ec,(e=>this._onInteraction(e,!0))),M.on(this._element,tc,(e=>this._onInteraction(e,!1))),M.on(this._element,ic,(e=>this._onInteraction(e,!0))),M.on(this._element,nc,(e=>this._onInteraction(e,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(e){return this.each((function(){const t=_c.getOrCreateInstance(this,e);if("string"==typeof e){if(void 0===t[e])throw new TypeError(`No method named "${e}"`);t[e](this)}}))}}return W(_c),p(_c),{Alert:Q,Button:X,Calendar:We,Carousel:Et,Collapse:Bt,DatePicker:As,DateRangePicker:_s,Dropdown:Js,LoadingButton:ca,Modal:Wa,MultiSelect:ko,Navigation:jo,OffCanvas:tr,Popover:Cr,RangeSlider:Hr,Rating:il,ScrollSpy:_l,Sidebar:xl,Tab:Zl,TimePicker:Rn,Toast:_c,Tooltip:Dr}}));
//# sourceMappingURL=bootstrap.bundle.min.js.map