@coreui/coreui 4.1.6 → 4.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +2 -2
- package/README.md +62 -10
- package/dist/css/coreui-grid.css +22 -4
- package/dist/css/coreui-grid.css.map +1 -1
- package/dist/css/coreui-grid.min.css +2 -2
- package/dist/css/coreui-grid.min.css.map +1 -1
- package/dist/css/coreui-grid.rtl.css +23 -5
- package/dist/css/coreui-grid.rtl.css.map +1 -1
- package/dist/css/coreui-grid.rtl.min.css +3 -3
- package/dist/css/coreui-grid.rtl.min.css.map +1 -1
- package/dist/css/coreui-reboot.css +34 -41
- package/dist/css/coreui-reboot.css.map +1 -1
- package/dist/css/coreui-reboot.min.css +2 -2
- package/dist/css/coreui-reboot.min.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.css +34 -42
- package/dist/css/coreui-reboot.rtl.css.map +1 -1
- package/dist/css/coreui-reboot.rtl.min.css +3 -3
- package/dist/css/coreui-reboot.rtl.min.css.map +1 -1
- package/dist/css/coreui-utilities.css +278 -163
- package/dist/css/coreui-utilities.css.map +1 -1
- package/dist/css/coreui-utilities.min.css +2 -2
- package/dist/css/coreui-utilities.min.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.css +273 -164
- package/dist/css/coreui-utilities.rtl.css.map +1 -1
- package/dist/css/coreui-utilities.rtl.min.css +3 -3
- package/dist/css/coreui-utilities.rtl.min.css.map +1 -1
- package/dist/css/coreui.css +2177 -1240
- package/dist/css/coreui.css.map +1 -1
- package/dist/css/coreui.min.css +2 -2
- package/dist/css/coreui.min.css.map +1 -1
- package/dist/css/coreui.rtl.css +2159 -1228
- package/dist/css/coreui.rtl.css.map +1 -1
- package/dist/css/coreui.rtl.min.css +3 -3
- package/dist/css/coreui.rtl.min.css.map +1 -1
- package/dist/js/coreui.bundle.js +2095 -1906
- package/dist/js/coreui.bundle.js.map +1 -1
- package/dist/js/coreui.bundle.min.js +2 -2
- package/dist/js/coreui.bundle.min.js.map +1 -1
- package/dist/js/coreui.esm.js +2098 -1909
- package/dist/js/coreui.esm.js.map +1 -1
- package/dist/js/coreui.esm.min.js +2 -2
- package/dist/js/coreui.esm.min.js.map +1 -1
- package/dist/js/coreui.js +2099 -1910
- package/dist/js/coreui.js.map +1 -1
- package/dist/js/coreui.min.js +2 -2
- package/dist/js/coreui.min.js.map +1 -1
- package/js/dist/alert.js +10 -148
- package/js/dist/alert.js.map +1 -1
- package/js/dist/base-component.js +36 -122
- package/js/dist/base-component.js.map +1 -1
- package/js/dist/button.js +9 -76
- package/js/dist/button.js.map +1 -1
- package/js/dist/carousel.js +212 -507
- package/js/dist/carousel.js.map +1 -1
- package/js/dist/collapse.js +64 -251
- package/js/dist/collapse.js.map +1 -1
- package/js/dist/dom/data.js +2 -4
- package/js/dist/dom/data.js.map +1 -1
- package/js/dist/dom/event-handler.js +82 -133
- package/js/dist/dom/event-handler.js.map +1 -1
- package/js/dist/dom/manipulator.js +22 -26
- package/js/dist/dom/manipulator.js.map +1 -1
- package/js/dist/dom/selector-engine.js +16 -81
- package/js/dist/dom/selector-engine.js.map +1 -1
- package/js/dist/dropdown.js +99 -338
- package/js/dist/dropdown.js.map +1 -1
- package/js/dist/modal.js +106 -774
- package/js/dist/modal.js.map +1 -1
- package/js/dist/navigation.js +309 -0
- package/js/dist/navigation.js.map +1 -0
- package/js/dist/offcanvas.js +88 -680
- package/js/dist/offcanvas.js.map +1 -1
- package/js/dist/popover.js +35 -120
- package/js/dist/popover.js.map +1 -1
- package/js/dist/scrollspy.js +178 -264
- package/js/dist/scrollspy.js.map +1 -1
- package/js/dist/sidebar.js +347 -0
- package/js/dist/sidebar.js.map +1 -0
- package/js/dist/tab.js +226 -216
- package/js/dist/tab.js.map +1 -1
- package/js/dist/toast.js +27 -216
- package/js/dist/toast.js.map +1 -1
- package/js/dist/tooltip.js +271 -618
- package/js/dist/tooltip.js.map +1 -1
- package/js/dist/util/backdrop.js +166 -0
- package/js/dist/util/backdrop.js.map +1 -0
- package/js/dist/util/component-functions.js +47 -0
- package/js/dist/util/component-functions.js.map +1 -0
- package/js/dist/util/config.js +80 -0
- package/js/dist/util/config.js.map +1 -0
- package/js/dist/util/focustrap.js +130 -0
- package/js/dist/util/focustrap.js.map +1 -0
- package/js/dist/util/index.js +354 -0
- package/js/dist/util/index.js.map +1 -0
- package/js/dist/util/sanitizer.js +126 -0
- package/js/dist/util/sanitizer.js.map +1 -0
- package/js/dist/util/scrollbar.js +139 -0
- package/js/dist/util/scrollbar.js.map +1 -0
- package/js/dist/util/swipe.js +156 -0
- package/js/dist/util/swipe.js.map +1 -0
- package/js/dist/util/template-factory.js +178 -0
- package/js/dist/util/template-factory.js.map +1 -0
- package/js/src/alert.js +3 -15
- package/js/src/base-component.js +28 -18
- package/js/src/button.js +3 -15
- package/js/src/carousel.js +203 -320
- package/js/src/collapse.js +61 -94
- package/js/src/dom/data.js +1 -3
- package/js/src/dom/event-handler.js +74 -107
- package/js/src/dom/manipulator.js +22 -31
- package/js/src/dom/selector-engine.js +10 -19
- package/js/src/dropdown.js +84 -138
- package/js/src/modal.js +94 -158
- package/js/src/navigation.js +12 -13
- package/js/src/offcanvas.js +71 -60
- package/js/src/popover.js +31 -62
- package/js/src/scrollspy.js +166 -171
- package/js/src/sidebar.js +5 -8
- package/js/src/tab.js +201 -110
- package/js/src/toast.js +19 -41
- package/js/src/tooltip.js +264 -374
- package/js/src/util/backdrop.js +55 -36
- package/js/src/util/component-functions.js +1 -1
- package/js/src/util/config.js +66 -0
- package/js/src/util/focustrap.js +38 -28
- package/js/src/util/index.js +41 -57
- package/js/src/util/sanitizer.js +9 -17
- package/js/src/util/scrollbar.js +47 -30
- package/js/src/util/swipe.js +146 -0
- package/js/src/util/template-factory.js +160 -0
- package/package.json +37 -37
- package/scss/_accordion.scss +53 -25
- package/scss/_alert.scss +29 -9
- package/scss/_badge.scss +15 -6
- package/scss/_breadcrumb.scss +23 -11
- package/scss/_button-group.scss +3 -0
- package/scss/_buttons.scss +77 -50
- package/scss/_callout.scss +18 -6
- package/scss/_card.scss +55 -37
- package/scss/_carousel.scss +6 -6
- package/scss/_close.scss +4 -4
- package/scss/_containers.scss +1 -1
- package/scss/_dropdown.scss +86 -64
- package/scss/_footer.scss +15 -5
- package/scss/_functions.scss +11 -24
- package/scss/_grid.scss +3 -3
- package/scss/_header.scss +59 -34
- package/scss/_helpers.scss +1 -0
- package/scss/_images.scss +3 -3
- package/scss/_list-group.scss +47 -29
- package/scss/_maps.scss +54 -0
- package/scss/_modal.scss +70 -43
- package/scss/_nav.scss +53 -20
- package/scss/_navbar.scss +84 -94
- package/scss/_offcanvas.scss +120 -60
- package/scss/_pagination.scss +66 -21
- package/scss/_popover.scss +90 -52
- package/scss/_progress.scss +20 -9
- package/scss/_reboot.scss +31 -58
- package/scss/_root.scss +41 -19
- package/scss/_spinners.scss +37 -21
- package/scss/_subheader.scss +9 -9
- package/scss/_tables.scss +34 -36
- package/scss/_toasts.scss +35 -19
- package/scss/_tooltip.scss +61 -56
- package/scss/_utilities.scss +42 -25
- package/scss/_variables.scss +169 -148
- package/scss/coreui-grid.rtl.scss +1 -1
- package/scss/coreui-grid.scss +2 -1
- package/scss/coreui-reboot.rtl.scss +1 -1
- package/scss/coreui-reboot.scss +1 -1
- package/scss/coreui-utilities.rtl.scss +1 -1
- package/scss/coreui-utilities.scss +2 -1
- package/scss/coreui.rtl.scss +1 -1
- package/scss/coreui.scss +2 -1
- package/scss/forms/_floating-labels.scss +14 -3
- package/scss/forms/_form-check.scss +41 -18
- package/scss/forms/_form-control.scss +25 -50
- package/scss/forms/_form-range.scss +8 -8
- package/scss/forms/_form-select.scss +8 -8
- package/scss/forms/_form-text.scss +1 -1
- package/scss/forms/_input-group.scss +3 -3
- package/scss/forms/_labels.scss +2 -2
- package/scss/helpers/_color-bg.scss +10 -0
- package/scss/helpers/_colored-links.scss +2 -2
- package/scss/helpers/_position.scss +7 -1
- package/scss/helpers/_ratio.scss +2 -2
- package/scss/helpers/_vr.scss +1 -0
- package/scss/mixins/_alert.scss +10 -10
- package/scss/mixins/_breakpoints.scss +8 -8
- package/scss/mixins/_buttons.scss +45 -47
- package/scss/mixins/_container.scss +4 -2
- package/scss/mixins/_css-vars.scss +47 -47
- package/scss/mixins/_forms.scss +8 -0
- package/scss/mixins/_gradients.scss +1 -1
- package/scss/mixins/_grid.scss +11 -11
- package/scss/mixins/_list-group.scss +7 -9
- package/scss/mixins/_pagination.scss +4 -25
- package/scss/mixins/_table-variants.scss +20 -12
- package/scss/mixins/_utilities.scss +8 -3
- package/scss/sidebar/_sidebar-narrow.scss +10 -10
- package/scss/sidebar/_sidebar-nav.scss +37 -32
- package/scss/sidebar/_sidebar.scss +110 -56
package/dist/js/coreui.min.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* CoreUI v4.
|
|
2
|
+
* CoreUI v4.2.2 (https://coreui.io)
|
|
3
3
|
* Copyright 2022 The CoreUI Team (https://github.com/orgs/coreui/people)
|
|
4
4
|
* Licensed under MIT (https://coreui.io)
|
|
5
5
|
*/
|
|
6
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@popperjs/core")):"function"==typeof define&&define.amd?define(["@popperjs/core"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).coreui=e(t.Popper)}(this,(function(t){"use strict";function e(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const i in t)if("default"!==i){const s=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>t[i]})}return e.default=t,Object.freeze(e)}const i=e(t),s="transitionend",n=t=>{let e=t.getAttribute("data-coreui-target");if(!e||"#"===e){let i=t.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),e=i&&"#"!==i?i.trim():null}return e},o=t=>{const e=n(t);return e&&document.querySelector(e)?e:null},r=t=>{const e=n(t);return e?document.querySelector(e):null},a=t=>{t.dispatchEvent(new Event(s))},l=t=>!(!t||"object"!=typeof t)&&(void 0!==t.jquery&&(t=t[0]),void 0!==t.nodeType),c=t=>l(t)?t.jquery?t[0]:t:"string"==typeof t&&t.length>0?document.querySelector(t):null,h=(t,e,i)=>{Object.keys(i).forEach((s=>{const n=i[s],o=e[s],r=o&&l(o)?"element":null==(a=o)?`${a}`:Object.prototype.toString.call(a).match(/\s([a-z]+)/i)[1].toLowerCase();var a;if(!new RegExp(n).test(r))throw new TypeError(`${t.toUpperCase()}: Option "${s}" provided type "${r}" but expected type "${n}".`)}))},d=t=>{if(!l(t)||0===t.getClientRects().length)return!1;const e="visible"===getComputedStyle(t).getPropertyValue("visibility"),i=t.closest("details:not([open])");if(!i)return e;if(i!==t){const e=t.closest("summary");if(e&&e.parentNode!==i)return!1;if(null===e)return!1}return e},u=t=>!t||t.nodeType!==Node.ELEMENT_NODE||!!t.classList.contains("disabled")||(void 0!==t.disabled?t.disabled:t.hasAttribute("disabled")&&"false"!==t.getAttribute("disabled")),g=t=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof t.getRootNode){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?g(t.parentNode):null},_=()=>{},f=t=>{t.offsetHeight},m=()=>{const{jQuery:t}=window;return t&&!document.body.hasAttribute("data-coreui-no-jquery")?t:null},p=[],b=()=>"rtl"===document.documentElement.dir,v=t=>{var e;e=()=>{const e=m();if(e){const i=t.NAME,s=e.fn[i];e.fn[i]=t.jQueryInterface,e.fn[i].Constructor=t,e.fn[i].noConflict=()=>(e.fn[i]=s,t.jQueryInterface)}},"loading"===document.readyState?(p.length||document.addEventListener("DOMContentLoaded",(()=>{p.forEach((t=>t()))})),p.push(e)):e()},y=t=>{"function"==typeof t&&t()},w=(t,e,i=!0)=>{if(!i)return void y(t);const n=(t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:i}=window.getComputedStyle(t);const s=Number.parseFloat(e),n=Number.parseFloat(i);return s||n?(e=e.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(e)+Number.parseFloat(i))):0})(e)+5;let o=!1;const r=({target:i})=>{i===e&&(o=!0,e.removeEventListener(s,r),y(t))};e.addEventListener(s,r),setTimeout((()=>{o||a(e)}),n)},E=(t,e,i,s)=>{let n=t.indexOf(e);if(-1===n)return t[!i&&s?t.length-1:0];const o=t.length;return n+=i?1:-1,s&&(n=(n+o)%o),t[Math.max(0,Math.min(n,o-1))]},A=/[^.]*(?=\..*)\.|.*/,C=/\..*/,T=/::\d+$/,L={};let k=1;const N={mouseenter:"mouseover",mouseleave:"mouseout"},O=/^(mouseenter|mouseleave)/i,S=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 D(t,e){return e&&`${e}::${k++}`||t.uidEvent||k++}function I(t){const e=D(t);return t.uidEvent=e,L[e]=L[e]||{},L[e]}function $(t,e,i=null){const s=Object.keys(t);for(let n=0,o=s.length;n<o;n++){const o=t[s[n]];if(o.originalHandler===e&&o.delegationSelector===i)return o}return null}function x(t,e,i){const s="string"==typeof e,n=s?i:e;let o=j(t);return S.has(o)||(o=t),[s,n,o]}function M(t,e,i,s,n){if("string"!=typeof e||!t)return;if(i||(i=s,s=null),O.test(e)){const t=t=>function(e){if(!e.relatedTarget||e.relatedTarget!==e.delegateTarget&&!e.delegateTarget.contains(e.relatedTarget))return t.call(this,e)};s?s=t(s):i=t(i)}const[o,r,a]=x(e,i,s),l=I(t),c=l[a]||(l[a]={}),h=$(c,r,o?i:null);if(h)return void(h.oneOff=h.oneOff&&n);const d=D(r,e.replace(A,"")),u=o?function(t,e,i){return function s(n){const o=t.querySelectorAll(e);for(let{target:r}=n;r&&r!==this;r=r.parentNode)for(let a=o.length;a--;)if(o[a]===r)return n.delegateTarget=r,s.oneOff&&H.off(t,n.type,e,i),i.apply(r,[n]);return null}}(t,i,s):function(t,e){return function i(s){return s.delegateTarget=t,i.oneOff&&H.off(t,s.type,e),e.apply(t,[s])}}(t,i);u.delegationSelector=o?i:null,u.originalHandler=r,u.oneOff=n,u.uidEvent=d,c[d]=u,t.addEventListener(a,u,o)}function P(t,e,i,s,n){const o=$(e[i],s,n);o&&(t.removeEventListener(i,o,Boolean(n)),delete e[i][o.uidEvent])}function j(t){return t=t.replace(C,""),N[t]||t}const H={on(t,e,i,s){M(t,e,i,s,!1)},one(t,e,i,s){M(t,e,i,s,!0)},off(t,e,i,s){if("string"!=typeof e||!t)return;const[n,o,r]=x(e,i,s),a=r!==e,l=I(t),c=e.startsWith(".");if(void 0!==o){if(!l||!l[r])return;return void P(t,l,r,o,n?i:null)}c&&Object.keys(l).forEach((i=>{!function(t,e,i,s){const n=e[i]||{};Object.keys(n).forEach((o=>{if(o.includes(s)){const s=n[o];P(t,e,i,s.originalHandler,s.delegationSelector)}}))}(t,l,i,e.slice(1))}));const h=l[r]||{};Object.keys(h).forEach((i=>{const s=i.replace(T,"");if(!a||e.includes(s)){const e=h[i];P(t,l,r,e.originalHandler,e.delegationSelector)}}))},trigger(t,e,i){if("string"!=typeof e||!t)return null;const s=m(),n=j(e),o=e!==n,r=S.has(n);let a,l=!0,c=!0,h=!1,d=null;return o&&s&&(a=s.Event(e,i),s(t).trigger(a),l=!a.isPropagationStopped(),c=!a.isImmediatePropagationStopped(),h=a.isDefaultPrevented()),r?(d=document.createEvent("HTMLEvents"),d.initEvent(n,l,!0)):d=new CustomEvent(e,{bubbles:l,cancelable:!0}),void 0!==i&&Object.keys(i).forEach((t=>{Object.defineProperty(d,t,{get:()=>i[t]})})),h&&d.preventDefault(),c&&t.dispatchEvent(d),d.defaultPrevented&&void 0!==a&&a.preventDefault(),d}},B=new Map,z={set(t,e,i){B.has(t)||B.set(t,new Map);const s=B.get(t);s.has(e)||0===s.size?s.set(e,i):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(t,e)=>B.has(t)&&B.get(t).get(e)||null,remove(t,e){if(!B.has(t))return;const i=B.get(t);i.delete(e),0===i.size&&B.delete(t)}};class R{constructor(t){(t=c(t))&&(this._element=t,z.set(this._element,this.constructor.DATA_KEY,this))}dispose(){z.remove(this._element,this.constructor.DATA_KEY),H.off(this._element,this.constructor.EVENT_KEY),Object.getOwnPropertyNames(this).forEach((t=>{this[t]=null}))}_queueCallback(t,e,i=!0){w(t,e,i)}static getInstance(t){return z.get(c(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,"object"==typeof e?e:null)}static get VERSION(){return"4.1.6"}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}static get DATA_KEY(){return`coreui.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}}const q=(t,e="hide")=>{const i=`click.dismiss${t.EVENT_KEY}`,s=t.NAME;H.on(document,i,`[data-coreui-dismiss="${s}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),u(this))return;const n=r(this)||this.closest(`.${s}`);t.getOrCreateInstance(n)[e]()}))};class W extends R{static get NAME(){return"alert"}close(){if(H.trigger(this._element,"close.coreui.alert").defaultPrevented)return;this._element.classList.remove("show");const t=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,t)}_destroyElement(){this._element.remove(),H.trigger(this._element,"closed.coreui.alert"),this.dispose()}static jQueryInterface(t){return this.each((function(){const e=W.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}q(W,"close"),v(W);const F='[data-coreui-toggle="button"]';class U extends R{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(t){return this.each((function(){const e=U.getOrCreateInstance(this);"toggle"===t&&e[t]()}))}}function V(t){return"true"===t||"false"!==t&&(t===Number(t).toString()?Number(t):""===t||"null"===t?null:t)}function K(t){return t.replace(/[A-Z]/g,(t=>`-${t.toLowerCase()}`))}H.on(document,"click.coreui.button.data-api",F,(t=>{t.preventDefault();const e=t.target.closest(F);U.getOrCreateInstance(e).toggle()})),v(U);const Q={setDataAttribute(t,e,i){t.setAttribute(`data-coreui-${K(e)}`,i)},removeDataAttribute(t,e){t.removeAttribute(`data-coreui-${K(e)}`)},getDataAttributes(t){if(!t)return{};const e={};return Object.keys(t.dataset).filter((t=>t.startsWith("coreui"))).forEach((i=>{let s=i.replace(/^coreui/,"");s=s.charAt(0).toLowerCase()+s.slice(1,s.length),e[s]=V(t.dataset[i])})),e},getDataAttribute:(t,e)=>V(t.getAttribute(`data-coreui-${K(e)}`)),offset(t){const e=t.getBoundingClientRect();return{top:e.top+window.pageYOffset,left:e.left+window.pageXOffset}},position:t=>({top:t.offsetTop,left:t.offsetLeft})},Y={find:(t,e=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(e,t)),findOne:(t,e=document.documentElement)=>Element.prototype.querySelector.call(e,t),children:(t,e)=>[].concat(...t.children).filter((t=>t.matches(e))),parents(t,e){const i=[];let s=t.parentNode;for(;s&&s.nodeType===Node.ELEMENT_NODE&&3!==s.nodeType;)s.matches(e)&&i.push(s),s=s.parentNode;return i},prev(t,e){let i=t.previousElementSibling;for(;i;){if(i.matches(e))return[i];i=i.previousElementSibling}return[]},next(t,e){let i=t.nextElementSibling;for(;i;){if(i.matches(e))return[i];i=i.nextElementSibling}return[]},focusableChildren(t){const e=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((t=>`${t}:not([tabindex^="-"])`)).join(", ");return this.find(e,t).filter((t=>!u(t)&&d(t)))}},X="carousel",G=".coreui.carousel",Z={interval:5e3,keyboard:!0,slide:!1,pause:"hover",wrap:!0,touch:!0},J={interval:"(number|boolean)",keyboard:"boolean",slide:"(boolean|string)",pause:"(string|boolean)",wrap:"boolean",touch:"boolean"},tt="next",et="prev",it="left",st="right",nt={ArrowLeft:st,ArrowRight:it},ot=`slide${G}`,rt=`slid${G}`,at=`keydown${G}`,lt=`mouseenter${G}`,ct=`mouseleave${G}`,ht=`touchstart${G}`,dt=`touchmove${G}`,ut=`touchend${G}`,gt=`pointerdown${G}`,_t=`pointerup${G}`,ft=`dragstart${G}`,mt=`load${G}.data-api`,pt=`click${G}.data-api`,bt="active",vt=".active.carousel-item";class yt extends R{constructor(t,e){super(t),this._items=null,this._interval=null,this._activeElement=null,this._isPaused=!1,this._isSliding=!1,this.touchTimeout=null,this.touchStartX=0,this.touchDeltaX=0,this._config=this._getConfig(e),this._indicatorsElement=Y.findOne(".carousel-indicators",this._element),this._touchSupported="ontouchstart"in document.documentElement||navigator.maxTouchPoints>0,this._pointerEvent=Boolean(window.PointerEvent),this._addEventListeners()}static get Default(){return Z}static get NAME(){return X}next(){this._slide(tt)}nextWhenVisible(){!document.hidden&&d(this._element)&&this.next()}prev(){this._slide(et)}pause(t){t||(this._isPaused=!0),Y.findOne(".carousel-item-next, .carousel-item-prev",this._element)&&(a(this._element),this.cycle(!0)),clearInterval(this._interval),this._interval=null}cycle(t){t||(this._isPaused=!1),this._interval&&(clearInterval(this._interval),this._interval=null),this._config&&this._config.interval&&!this._isPaused&&(this._updateInterval(),this._interval=setInterval((document.visibilityState?this.nextWhenVisible:this.next).bind(this),this._config.interval))}to(t){this._activeElement=Y.findOne(vt,this._element);const e=this._getItemIndex(this._activeElement);if(t>this._items.length-1||t<0)return;if(this._isSliding)return void H.one(this._element,rt,(()=>this.to(t)));if(e===t)return this.pause(),void this.cycle();const i=t>e?tt:et;this._slide(i,this._items[t])}_getConfig(t){return t={...Z,...Q.getDataAttributes(this._element),..."object"==typeof t?t:{}},h(X,t,J),t}_handleSwipe(){const t=Math.abs(this.touchDeltaX);if(t<=40)return;const e=t/this.touchDeltaX;this.touchDeltaX=0,e&&this._slide(e>0?st:it)}_addEventListeners(){this._config.keyboard&&H.on(this._element,at,(t=>this._keydown(t))),"hover"===this._config.pause&&(H.on(this._element,lt,(t=>this.pause(t))),H.on(this._element,ct,(t=>this.cycle(t)))),this._config.touch&&this._touchSupported&&this._addTouchEventListeners()}_addTouchEventListeners(){const t=t=>this._pointerEvent&&("pen"===t.pointerType||"touch"===t.pointerType),e=e=>{t(e)?this.touchStartX=e.clientX:this._pointerEvent||(this.touchStartX=e.touches[0].clientX)},i=t=>{this.touchDeltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this.touchStartX},s=e=>{t(e)&&(this.touchDeltaX=e.clientX-this.touchStartX),this._handleSwipe(),"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((t=>this.cycle(t)),500+this._config.interval))};Y.find(".carousel-item img",this._element).forEach((t=>{H.on(t,ft,(t=>t.preventDefault()))})),this._pointerEvent?(H.on(this._element,gt,(t=>e(t))),H.on(this._element,_t,(t=>s(t))),this._element.classList.add("pointer-event")):(H.on(this._element,ht,(t=>e(t))),H.on(this._element,dt,(t=>i(t))),H.on(this._element,ut,(t=>s(t))))}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=nt[t.key];e&&(t.preventDefault(),this._slide(e))}_getItemIndex(t){return this._items=t&&t.parentNode?Y.find(".carousel-item",t.parentNode):[],this._items.indexOf(t)}_getItemByOrder(t,e){const i=t===tt;return E(this._items,e,i,this._config.wrap)}_triggerSlideEvent(t,e){const i=this._getItemIndex(t),s=this._getItemIndex(Y.findOne(vt,this._element));return H.trigger(this._element,ot,{relatedTarget:t,direction:e,from:s,to:i})}_setActiveIndicatorElement(t){if(this._indicatorsElement){const e=Y.findOne(".active",this._indicatorsElement);e.classList.remove(bt),e.removeAttribute("aria-current");const i=Y.find("[data-coreui-target]",this._indicatorsElement);for(let e=0;e<i.length;e++)if(Number.parseInt(i[e].getAttribute("data-coreui-slide-to"),10)===this._getItemIndex(t)){i[e].classList.add(bt),i[e].setAttribute("aria-current","true");break}}}_updateInterval(){const t=this._activeElement||Y.findOne(vt,this._element);if(!t)return;const e=Number.parseInt(t.getAttribute("data-coreui-interval"),10);e?(this._config.defaultInterval=this._config.defaultInterval||this._config.interval,this._config.interval=e):this._config.interval=this._config.defaultInterval||this._config.interval}_slide(t,e){const i=this._directionToOrder(t),s=Y.findOne(vt,this._element),n=this._getItemIndex(s),o=e||this._getItemByOrder(i,s),r=this._getItemIndex(o),a=Boolean(this._interval),l=i===tt,c=l?"carousel-item-start":"carousel-item-end",h=l?"carousel-item-next":"carousel-item-prev",d=this._orderToDirection(i);if(o&&o.classList.contains(bt))return void(this._isSliding=!1);if(this._isSliding)return;if(this._triggerSlideEvent(o,d).defaultPrevented)return;if(!s||!o)return;this._isSliding=!0,a&&this.pause(),this._setActiveIndicatorElement(o),this._activeElement=o;const u=()=>{H.trigger(this._element,rt,{relatedTarget:o,direction:d,from:n,to:r})};if(this._element.classList.contains("slide")){o.classList.add(h),f(o),s.classList.add(c),o.classList.add(c);const t=()=>{o.classList.remove(c,h),o.classList.add(bt),s.classList.remove(bt,h,c),this._isSliding=!1,setTimeout(u,0)};this._queueCallback(t,s,!0)}else s.classList.remove(bt),o.classList.add(bt),this._isSliding=!1,u();a&&this.cycle()}_directionToOrder(t){return[st,it].includes(t)?b()?t===it?et:tt:t===it?tt:et:t}_orderToDirection(t){return[tt,et].includes(t)?b()?t===et?it:st:t===et?st:it:t}static carouselInterface(t,e){const i=yt.getOrCreateInstance(t,e);let{_config:s}=i;"object"==typeof e&&(s={...s,...e});const n="string"==typeof e?e:s.slide;if("number"==typeof e)i.to(e);else if("string"==typeof n){if(void 0===i[n])throw new TypeError(`No method named "${n}"`);i[n]()}else s.interval&&s.ride&&(i.pause(),i.cycle())}static jQueryInterface(t){return this.each((function(){yt.carouselInterface(this,t)}))}static dataApiClickHandler(t){const e=r(this);if(!e||!e.classList.contains("carousel"))return;const i={...Q.getDataAttributes(e),...Q.getDataAttributes(this)},s=this.getAttribute("data-coreui-slide-to");s&&(i.interval=!1),yt.carouselInterface(e,i),s&&yt.getInstance(e).to(s),t.preventDefault()}}H.on(document,pt,"[data-coreui-slide], [data-coreui-slide-to]",yt.dataApiClickHandler),H.on(window,mt,(()=>{const t=Y.find('[data-coreui-ride="carousel"]');for(let e=0,i=t.length;e<i;e++)yt.carouselInterface(t[e],yt.getInstance(t[e]))})),v(yt);const wt="collapse",Et="coreui.collapse",At=`.${Et}`,Ct={toggle:!0,parent:null},Tt={toggle:"boolean",parent:"(null|element)"},Lt=`show${At}`,kt=`shown${At}`,Nt=`hide${At}`,Ot=`hidden${At}`,St=`click${At}.data-api`,Dt="show",It="collapse",$t="collapsing",xt="collapsed",Mt=":scope .collapse .collapse",Pt='[data-coreui-toggle="collapse"]';class jt extends R{constructor(t,e){super(t),this._isTransitioning=!1,this._config=this._getConfig(e),this._triggerArray=[];const i=Y.find(Pt);for(let t=0,e=i.length;t<e;t++){const e=i[t],s=o(e),n=Y.find(s).filter((t=>t===this._element));null!==s&&n.length&&(this._selector=s,this._triggerArray.push(e))}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return Ct}static get NAME(){return wt}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t,e=[];if(this._config.parent){const t=Y.find(Mt,this._config.parent);e=Y.find(".collapse.show, .collapse.collapsing",this._config.parent).filter((e=>!t.includes(e)))}const i=Y.findOne(this._selector);if(e.length){const s=e.find((t=>i!==t));if(t=s?jt.getInstance(s):null,t&&t._isTransitioning)return}if(H.trigger(this._element,Lt).defaultPrevented)return;e.forEach((e=>{i!==e&&jt.getOrCreateInstance(e,{toggle:!1}).hide(),t||z.set(e,Et,null)}));const s=this._getDimension();this._element.classList.remove(It),this._element.classList.add($t),this._element.style[s]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const n=`scroll${s[0].toUpperCase()+s.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove($t),this._element.classList.add(It,Dt),this._element.style[s]="",H.trigger(this._element,kt)}),this._element,!0),this._element.style[s]=`${this._element[n]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(H.trigger(this._element,Nt).defaultPrevented)return;const t=this._getDimension();this._element.style[t]=`${this._element.getBoundingClientRect()[t]}px`,f(this._element),this._element.classList.add($t),this._element.classList.remove(It,Dt);const e=this._triggerArray.length;for(let t=0;t<e;t++){const e=this._triggerArray[t],i=r(e);i&&!this._isShown(i)&&this._addAriaAndCollapsedClass([e],!1)}this._isTransitioning=!0,this._element.style[t]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove($t),this._element.classList.add(It),H.trigger(this._element,Ot)}),this._element,!0)}_isShown(t=this._element){return t.classList.contains(Dt)}_getConfig(t){return(t={...Ct,...Q.getDataAttributes(this._element),...t}).toggle=Boolean(t.toggle),t.parent=c(t.parent),h(wt,t,Tt),t}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const t=Y.find(Mt,this._config.parent);Y.find(Pt,this._config.parent).filter((e=>!t.includes(e))).forEach((t=>{const e=r(t);e&&this._addAriaAndCollapsedClass([t],this._isShown(e))}))}_addAriaAndCollapsedClass(t,e){t.length&&t.forEach((t=>{e?t.classList.remove(xt):t.classList.add(xt),t.setAttribute("aria-expanded",e)}))}static jQueryInterface(t){return this.each((function(){const e={};"string"==typeof t&&/show|hide/.test(t)&&(e.toggle=!1);const i=jt.getOrCreateInstance(this,e);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}))}}H.on(document,St,Pt,(function(t){("A"===t.target.tagName||t.delegateTarget&&"A"===t.delegateTarget.tagName)&&t.preventDefault();const e=o(this);Y.find(e).forEach((t=>{jt.getOrCreateInstance(t,{toggle:!1}).toggle()}))})),v(jt);const Ht="dropdown",Bt=".coreui.dropdown",zt="Escape",Rt="Space",qt="ArrowUp",Wt="ArrowDown",Ft=new RegExp("ArrowUp|ArrowDown|Escape"),Ut=`hide${Bt}`,Vt=`hidden${Bt}`,Kt=`show${Bt}`,Qt=`shown${Bt}`,Yt=`click${Bt}.data-api`,Xt=`keydown${Bt}.data-api`,Gt=`keyup${Bt}.data-api`,Zt="show",Jt='[data-coreui-toggle="dropdown"]',te=".dropdown-menu",ee=b()?"top-end":"top-start",ie=b()?"top-start":"top-end",se=b()?"bottom-end":"bottom-start",ne=b()?"bottom-start":"bottom-end",oe=b()?"left-start":"right-start",re=b()?"right-start":"left-start",ae={offset:[0,2],boundary:"clippingParents",reference:"toggle",display:"dynamic",popperConfig:null,autoClose:!0},le={offset:"(array|string|function)",boundary:"(string|element)",reference:"(string|element|object)",display:"string",popperConfig:"(null|object|function)",autoClose:"(boolean|string)"};class ce extends R{constructor(t,e){super(t),this._popper=null,this._config=this._getConfig(e),this._menu=this._getMenuElement(),this._inNavbar=this._detectNavbar()}static get Default(){return ae}static get DefaultType(){return le}static get NAME(){return Ht}toggle(){return this._isShown()?this.hide():this.show()}show(){if(u(this._element)||this._isShown(this._menu))return;const t={relatedTarget:this._element};if(H.trigger(this._element,Kt,t).defaultPrevented)return;const e=ce.getParentFromElement(this._element);this._inNavbar?Q.setDataAttribute(this._menu,"popper","none"):this._createPopper(e),"ontouchstart"in document.documentElement&&!e.closest(".navbar-nav")&&[].concat(...document.body.children).forEach((t=>H.on(t,"mouseover",_))),this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Zt),this._element.classList.add(Zt),H.trigger(this._element,Qt,t)}hide(){if(u(this._element)||!this._isShown(this._menu))return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){H.trigger(this._element,Ut,t).defaultPrevented||("ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>H.off(t,"mouseover",_))),this._popper&&this._popper.destroy(),this._menu.classList.remove(Zt),this._element.classList.remove(Zt),this._element.setAttribute("aria-expanded","false"),Q.removeDataAttribute(this._menu,"popper"),H.trigger(this._element,Vt,t))}_getConfig(t){if(t={...this.constructor.Default,...Q.getDataAttributes(this._element),...t},h(Ht,t,this.constructor.DefaultType),"object"==typeof t.reference&&!l(t.reference)&&"function"!=typeof t.reference.getBoundingClientRect)throw new TypeError(`${Ht.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(t){if(void 0===i)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let e=this._element;"parent"===this._config.reference?e=t:l(this._config.reference)?e=c(this._config.reference):"object"==typeof this._config.reference&&(e=this._config.reference);const s=this._getPopperConfig(),n=s.modifiers.find((t=>"applyStyles"===t.name&&!1===t.enabled));this._popper=i.createPopper(e,this._menu,s),n&&Q.setDataAttribute(this._menu,"popper","static")}_isShown(t=this._element){return t.classList.contains(Zt)}_getMenuElement(){return Y.next(this._element,te)[0]}_getPlacement(){const t=this._element.parentNode;if(t.classList.contains("dropend"))return oe;if(t.classList.contains("dropstart"))return re;const e="end"===getComputedStyle(this._menu).getPropertyValue("--cui-position").trim();return t.classList.contains("dropup")?e?ie:ee:e?ne:se}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return"static"===this._config.display&&(t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,..."function"==typeof this._config.popperConfig?this._config.popperConfig(t):this._config.popperConfig}}_selectMenuItem({key:t,target:e}){const i=Y.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter(d);i.length&&E(i,e,t===Wt,!i.includes(e)).focus()}static jQueryInterface(t){return this.each((function(){const e=ce.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}static clearMenus(t){if(t&&(2===t.button||"keyup"===t.type&&"Tab"!==t.key))return;const e=Y.find(Jt);for(let i=0,s=e.length;i<s;i++){const s=ce.getInstance(e[i]);if(!s||!1===s._config.autoClose)continue;if(!s._isShown())continue;const n={relatedTarget:s._element};if(t){const e=t.composedPath(),i=e.includes(s._menu);if(e.includes(s._element)||"inside"===s._config.autoClose&&!i||"outside"===s._config.autoClose&&i)continue;if(s._menu.contains(t.target)&&("keyup"===t.type&&"Tab"===t.key||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;"click"===t.type&&(n.clickEvent=t)}s._completeHide(n)}}static getParentFromElement(t){return r(t)||t.parentNode}static dataApiKeydownHandler(t){if(/input|textarea/i.test(t.target.tagName)?t.key===Rt||t.key!==zt&&(t.key!==Wt&&t.key!==qt||t.target.closest(te)):!Ft.test(t.key))return;const e=this.classList.contains(Zt);if(!e&&t.key===zt)return;if(t.preventDefault(),t.stopPropagation(),u(this))return;const i=this.matches(Jt)?this:Y.prev(this,Jt)[0],s=ce.getOrCreateInstance(i);if(t.key!==zt)return t.key===qt||t.key===Wt?(e||s.show(),void s._selectMenuItem(t)):void(e&&t.key!==Rt||ce.clearMenus());s.hide()}}H.on(document,Xt,Jt,ce.dataApiKeydownHandler),H.on(document,Xt,te,ce.dataApiKeydownHandler),H.on(document,Yt,ce.clearMenus),H.on(document,Gt,ce.clearMenus),H.on(document,Yt,Jt,(function(t){t.preventDefault(),ce.getOrCreateInstance(this).toggle()})),v(ce);const he=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",de=".sticky-top";class ue{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,"paddingRight",(e=>e+t)),this._setElementAttributes(he,"paddingRight",(e=>e+t)),this._setElementAttributes(de,"marginRight",(e=>e-t))}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,i){const s=this.getWidth();this._applyManipulationCallback(t,(t=>{if(t!==this._element&&window.innerWidth>t.clientWidth+s)return;this._saveInitialAttribute(t,e);const n=window.getComputedStyle(t)[e];t.style[e]=`${i(Number.parseFloat(n))}px`}))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,"paddingRight"),this._resetElementAttributes(he,"paddingRight"),this._resetElementAttributes(de,"marginRight")}_saveInitialAttribute(t,e){const i=t.style[e];i&&Q.setDataAttribute(t,e,i)}_resetElementAttributes(t,e){this._applyManipulationCallback(t,(t=>{const i=Q.getDataAttribute(t,e);void 0===i?t.style.removeProperty(e):(Q.removeDataAttribute(t,e),t.style[e]=i)}))}_applyManipulationCallback(t,e){l(t)?e(t):Y.find(t,this._element).forEach(e)}isOverflowing(){return this.getWidth()>0}}const ge={className:"modal-backdrop",isVisible:!0,isAnimated:!1,rootElement:"body",clickCallback:null},_e={className:"string",isVisible:"boolean",isAnimated:"boolean",rootElement:"(element|string)",clickCallback:"(function|null)"},fe="show",me="mousedown.coreui.backdrop";class pe{constructor(t){this._config=this._getConfig(t),this._isAppended=!1,this._element=null}show(t){this._config.isVisible?(this._append(),this._config.isAnimated&&f(this._getElement()),this._getElement().classList.add(fe),this._emulateAnimation((()=>{y(t)}))):y(t)}hide(t){this._config.isVisible?(this._getElement().classList.remove(fe),this._emulateAnimation((()=>{this.dispose(),y(t)}))):y(t)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add("fade"),this._element=t}return this._element}_getConfig(t){return(t={...ge,..."object"==typeof t?t:{}}).rootElement=c(t.rootElement),h("backdrop",t,_e),t}_append(){this._isAppended||(this._config.rootElement.append(this._getElement()),H.on(this._getElement(),me,(()=>{y(this._config.clickCallback)})),this._isAppended=!0)}dispose(){this._isAppended&&(H.off(this._element,me),this._element.remove(),this._isAppended=!1)}_emulateAnimation(t){w(t,this._getElement(),this._config.isAnimated)}}const be={trapElement:null,autofocus:!0},ve={trapElement:"element",autofocus:"boolean"},ye=".coreui.focustrap",we=`focusin${ye}`,Ee=`keydown.tab${ye}`,Ae="backward";class Ce{constructor(t){this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}activate(){const{trapElement:t,autofocus:e}=this._config;this._isActive||(e&&t.focus(),H.off(document,ye),H.on(document,we,(t=>this._handleFocusin(t))),H.on(document,Ee,(t=>this._handleKeydown(t))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,H.off(document,ye))}_handleFocusin(t){const{target:e}=t,{trapElement:i}=this._config;if(e===document||e===i||i.contains(e))return;const s=Y.focusableChildren(i);0===s.length?i.focus():this._lastTabNavDirection===Ae?s[s.length-1].focus():s[0].focus()}_handleKeydown(t){"Tab"===t.key&&(this._lastTabNavDirection=t.shiftKey?Ae:"forward")}_getConfig(t){return t={...be,..."object"==typeof t?t:{}},h("focustrap",t,ve),t}}const Te="modal",Le="Escape",ke={backdrop:!0,keyboard:!0,focus:!0},Ne={backdrop:"(boolean|string)",keyboard:"boolean",focus:"boolean"},Oe="hidden.coreui.modal",Se="show.coreui.modal",De="resize.coreui.modal",Ie="click.dismiss.coreui.modal",$e="keydown.dismiss.coreui.modal",xe="mousedown.dismiss.coreui.modal",Me="modal-open",Pe="show",je="modal-static";class He extends R{constructor(t,e){super(t),this._config=this._getConfig(e),this._dialog=Y.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._ignoreBackdropClick=!1,this._isTransitioning=!1,this._scrollBar=new ue}static get Default(){return ke}static get NAME(){return Te}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||H.trigger(this._element,Se,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isAnimated()&&(this._isTransitioning=!0),this._scrollBar.hide(),document.body.classList.add(Me),this._adjustDialog(),this._setEscapeEvent(),this._setResizeEvent(),H.on(this._dialog,xe,(()=>{H.one(this._element,"mouseup.dismiss.coreui.modal",(t=>{t.target===this._element&&(this._ignoreBackdropClick=!0)}))})),this._showBackdrop((()=>this._showElement(t))))}hide(){if(!this._isShown||this._isTransitioning)return;if(H.trigger(this._element,"hide.coreui.modal").defaultPrevented)return;this._isShown=!1;const t=this._isAnimated();t&&(this._isTransitioning=!0),this._setEscapeEvent(),this._setResizeEvent(),this._focustrap.deactivate(),this._element.classList.remove(Pe),H.off(this._element,Ie),H.off(this._dialog,xe),this._queueCallback((()=>this._hideModal()),this._element,t)}dispose(){[window,this._dialog].forEach((t=>H.off(t,".coreui.modal"))),this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new pe({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new Ce({trapElement:this._element})}_getConfig(t){return t={...ke,...Q.getDataAttributes(this._element),..."object"==typeof t?t:{}},h(Te,t,Ne),t}_showElement(t){const e=this._isAnimated(),i=Y.findOne(".modal-body",this._dialog);this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE||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,i&&(i.scrollTop=0),e&&f(this._element),this._element.classList.add(Pe),this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,H.trigger(this._element,"shown.coreui.modal",{relatedTarget:t})}),this._dialog,e)}_setEscapeEvent(){this._isShown?H.on(this._element,$e,(t=>{this._config.keyboard&&t.key===Le?(t.preventDefault(),this.hide()):this._config.keyboard||t.key!==Le||this._triggerBackdropTransition()})):H.off(this._element,$e)}_setResizeEvent(){this._isShown?H.on(window,De,(()=>this._adjustDialog())):H.off(window,De)}_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(Me),this._resetAdjustments(),this._scrollBar.reset(),H.trigger(this._element,Oe)}))}_showBackdrop(t){H.on(this._element,Ie,(t=>{this._ignoreBackdropClick?this._ignoreBackdropClick=!1:t.target===t.currentTarget&&(!0===this._config.backdrop?this.hide():"static"===this._config.backdrop&&this._triggerBackdropTransition())})),this._backdrop.show(t)}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(H.trigger(this._element,"hidePrevented.coreui.modal").defaultPrevented)return;const{classList:t,scrollHeight:e,style:i}=this._element,s=e>document.documentElement.clientHeight;!s&&"hidden"===i.overflowY||t.contains(je)||(s||(i.overflowY="hidden"),t.add(je),this._queueCallback((()=>{t.remove(je),s||this._queueCallback((()=>{i.overflowY=""}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),i=e>0;(!i&&t&&!b()||i&&!t&&b())&&(this._element.style.paddingLeft=`${e}px`),(i&&!t&&!b()||!i&&t&&b())&&(this._element.style.paddingRight=`${e}px`)}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each((function(){const i=He.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t](e)}}))}}H.on(document,"click.coreui.modal.data-api",'[data-coreui-toggle="modal"]',(function(t){const e=r(this);["A","AREA"].includes(this.tagName)&&t.preventDefault(),H.one(e,Se,(t=>{t.defaultPrevented||H.one(e,Oe,(()=>{d(this)&&this.focus()}))}));const i=Y.findOne(".modal.show");i&&He.getInstance(i).hide(),He.getOrCreateInstance(e).toggle(this)})),q(He),v(He);const Be="navigation",ze="coreui.navigation",Re=`.${ze}`,qe={activeLinksExact:!0,groupsAutoCollapse:!0},We={activeLinksExact:"boolean",groupsAutoCollapse:"(string|boolean)"},Fe="active",Ue="show",Ve="nav-group-toggle",Ke=`click${Re}.data-api`,Qe=`load${Re}.data-api`,Ye=".nav-group",Xe=".nav-group-items",Ge=".nav-group-toggle";class Ze extends R{constructor(t,e){super(t),this._config=this._getConfig(e),this._setActiveLink(),this._addEventListeners(),z.set(t,ze,this)}static get Default(){return qe}static get DATA_KEY(){return ze}static get DefaultType(){return We}static get NAME(){return Be}_getConfig(t){return t={...qe,...Q.getDataAttributes(this._element),..."object"==typeof t?t:{}},h(Be,t,We),t}_setActiveLink(){Array.from(this._element.querySelectorAll(".nav-link")).forEach((t=>{if(t.classList.contains(Ve))return;let e=String(window.location);(/\?.*=/.test(e)||/\?./.test(e))&&(e=e.split("?")[0]),/#./.test(e)&&(e=e.split("#")[0]),this._config.activeLinksExact&&t.href===e&&(t.classList.add(Fe),Array.from(this._getParents(t,Ye)).forEach((t=>{t.classList.add(Ue),t.setAttribute("aria-expanded",!0)}))),!this._config.activeLinksExact&&t.href.startsWith(e)&&(t.classList.add(Fe),Array.from(this._getParents(t,Ye)).forEach((t=>{t.classList.add(Ue),t.setAttribute("aria-expanded",!0)})))}))}_getParents(t,e){const i=[];for(;t&&t!==document;t=t.parentNode)e?t.matches(e)&&i.push(t):i.push(t);return i}_getAllSiblings(t,e){const i=[];t=t.parentNode.firstChild;do{3!==t.nodeType&&8!==t.nodeType&&(e&&!e(t)||i.push(t))}while(t=t.nextSibling);return i}_getChildren(t,e){const i=[];for(;t;t=t.nextSibling)1===t.nodeType&&t!==e&&i.push(t);return i}_getSiblings(t,e){return this._getChildren(t.parentNode.firstChild,t).filter(e)}_slideDown(t){t.style.height="auto";const e=t.clientHeight;t.style.height="0px",setTimeout((()=>{t.style.height=`${e}px`}),0),this._queueCallback((()=>{t.style.height="auto"}),t,!0)}_slideUp(t,e){const i=t.clientHeight;t.style.height=`${i}px`,setTimeout((()=>{t.style.height="0px"}),0),this._queueCallback((()=>{"function"==typeof e&&e()}),t,!0)}_toggleGroupItems(t){let e=t.target;e.classList.contains(Ve)||(e=e.closest(Ge));!0===this._config.groupsAutoCollapse&&this._getSiblings(e.parentNode,(t=>Boolean(t.classList.contains("nav-group")&&t.classList.contains(Ue)))).forEach((t=>{this._slideUp(Y.findOne(Xe,t),(()=>{t.classList.remove(Ue),t.setAttribute("aria-expanded",!1)}))})),e.parentNode.classList.contains(Ue)?this._slideUp(Y.findOne(Xe,e.parentNode),(()=>{e.parentNode.classList.remove(Ue),e.parentNode.setAttribute("aria-expanded",!1)})):(e.parentNode.classList.add(Ue),e.parentNode.setAttribute("aria-expanded",!0),this._slideDown(Y.findOne(Xe,e.parentNode)))}_addEventListeners(){H.on(this._element,Ke,Ge,(t=>{t.preventDefault(),this._toggleGroupItems(t,this)}))}static navigationInterface(t,e){const i=Ze.getOrCreateInstance(t,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}static jQueryInterface(t){return this.each((function(){Ze.navigationInterface(this,t)}))}}H.on(window,Qe,(()=>{Array.from(document.querySelectorAll('[data-coreui="navigation"]')).forEach((t=>{Ze.navigationInterface(t)}))})),v(Ze);const Je="offcanvas",ti=".coreui.offcanvas",ei=`load${ti}.data-api`,ii={backdrop:!0,keyboard:!0,scroll:!1},si={backdrop:"boolean",keyboard:"boolean",scroll:"boolean"},ni="show",oi=".offcanvas.show",ri=`show${ti}`,ai=`shown${ti}`,li=`hide${ti}`,ci=`hidden${ti}`,hi=`click${ti}.data-api`,di=`keydown.dismiss${ti}`;class ui extends R{constructor(t,e){super(t),this._config=this._getConfig(e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get NAME(){return Je}static get Default(){return ii}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||H.trigger(this._element,ri,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._element.style.visibility="visible",this._backdrop.show(),this._config.scroll||(new ue).hide(),this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(ni),this._queueCallback((()=>{this._config.scroll||this._focustrap.activate(),H.trigger(this._element,ai,{relatedTarget:t})}),this._element,!0))}hide(){this._isShown&&(H.trigger(this._element,li).defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.remove(ni),this._backdrop.hide(),this._queueCallback((()=>{this._element.setAttribute("aria-hidden",!0),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._element.style.visibility="hidden",this._config.scroll||(new ue).reset(),H.trigger(this._element,ci)}),this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_getConfig(t){return t={...ii,...Q.getDataAttributes(this._element),..."object"==typeof t?t:{}},h(Je,t,si),t}_initializeBackDrop(){return new pe({className:"offcanvas-backdrop",isVisible:this._config.backdrop,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_initializeFocusTrap(){return new Ce({trapElement:this._element})}_addEventListeners(){H.on(this._element,di,(t=>{this._config.keyboard&&"Escape"===t.key&&this.hide()}))}static jQueryInterface(t){return this.each((function(){const e=ui.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}H.on(document,hi,'[data-coreui-toggle="offcanvas"]',(function(t){const e=r(this);if(["A","AREA"].includes(this.tagName)&&t.preventDefault(),u(this))return;H.one(e,ci,(()=>{d(this)&&this.focus()}));const i=Y.findOne(oi);i&&i!==e&&ui.getInstance(i).hide(),ui.getOrCreateInstance(e).toggle(this)})),H.on(window,ei,(()=>Y.find(oi).forEach((t=>ui.getOrCreateInstance(t).show())))),q(ui),v(ui);const gi=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),_i=/^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i,fi=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i,mi=(t,e)=>{const i=t.nodeName.toLowerCase();if(e.includes(i))return!gi.has(i)||Boolean(_i.test(t.nodeValue)||fi.test(t.nodeValue));const s=e.filter((t=>t instanceof RegExp));for(let t=0,e=s.length;t<e;t++)if(s[t].test(i))return!0;return!1};function pi(t,e,i){if(!t.length)return t;if(i&&"function"==typeof i)return i(t);const s=(new window.DOMParser).parseFromString(t,"text/html"),n=[].concat(...s.body.querySelectorAll("*"));for(let t=0,i=n.length;t<i;t++){const i=n[t],s=i.nodeName.toLowerCase();if(!Object.keys(e).includes(s)){i.remove();continue}const o=[].concat(...i.attributes),r=[].concat(e["*"]||[],e[s]||[]);o.forEach((t=>{mi(t,r)||i.removeAttribute(t.nodeName)}))}return s.body.innerHTML}const bi="tooltip",vi=".coreui.tooltip",yi=new Set(["sanitize","allowList","sanitizeFn"]),wi={animation:"boolean",template:"string",title:"(string|element|function)",trigger:"string",delay:"(number|object)",html:"boolean",selector:"(string|boolean)",placement:"(string|function)",offset:"(array|string|function)",container:"(string|element|boolean)",fallbackPlacements:"array",boundary:"(string|element)",customClass:"(string|function)",sanitize:"boolean",sanitizeFn:"(null|function)",allowList:"object",popperConfig:"(null|object|function)"},Ei={AUTO:"auto",TOP:"top",RIGHT:b()?"left":"right",BOTTOM:"bottom",LEFT:b()?"right":"left"},Ai={animation:!0,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,selector:!1,placement:"top",offset:[0,0],container:!1,fallbackPlacements:["top","right","bottom","left"],boundary:"clippingParents",customClass:"",sanitize:!0,sanitizeFn:null,allowList:{"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],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:[]},popperConfig:null},Ci={HIDE:`hide${vi}`,HIDDEN:`hidden${vi}`,SHOW:`show${vi}`,SHOWN:`shown${vi}`,INSERTED:`inserted${vi}`,CLICK:`click${vi}`,FOCUSIN:`focusin${vi}`,FOCUSOUT:`focusout${vi}`,MOUSEENTER:`mouseenter${vi}`,MOUSELEAVE:`mouseleave${vi}`},Ti="fade",Li="show",ki="show",Ni="out",Oi=".tooltip-inner",Si=".modal",Di="hide.coreui.modal",Ii="hover",$i="focus";class xi extends R{constructor(t,e){if(void 0===i)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t),this._isEnabled=!0,this._timeout=0,this._hoverState="",this._activeTrigger={},this._popper=null,this._config=this._getConfig(e),this.tip=null,this._setListeners()}static get Default(){return Ai}static get NAME(){return bi}static get Event(){return Ci}static get DefaultType(){return wi}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(t){if(this._isEnabled)if(t){const e=this._initializeOnDelegatedTarget(t);e._activeTrigger.click=!e._activeTrigger.click,e._isWithActiveTrigger()?e._enter(null,e):e._leave(null,e)}else{if(this.getTipElement().classList.contains(Li))return void this._leave(null,this);this._enter(null,this)}}dispose(){clearTimeout(this._timeout),H.off(this._element.closest(Si),Di,this._hideModalHandler),this.tip&&this.tip.remove(),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 t=H.trigger(this._element,this.constructor.Event.SHOW),e=g(this._element),s=null===e?this._element.ownerDocument.documentElement.contains(this._element):e.contains(this._element);if(t.defaultPrevented||!s)return;"tooltip"===this.constructor.NAME&&this.tip&&this.getTitle()!==this.tip.querySelector(Oi).innerHTML&&(this._disposePopper(),this.tip.remove(),this.tip=null);const n=this.getTipElement(),o=(t=>{do{t+=Math.floor(1e6*Math.random())}while(document.getElementById(t));return t})(this.constructor.NAME);n.setAttribute("id",o),this._element.setAttribute("aria-describedby",o),this._config.animation&&n.classList.add(Ti);const r="function"==typeof this._config.placement?this._config.placement.call(this,n,this._element):this._config.placement,a=this._getAttachment(r);this._addAttachmentClass(a);const{container:l}=this._config;z.set(n,this.constructor.DATA_KEY,this),this._element.ownerDocument.documentElement.contains(this.tip)||(l.append(n),H.trigger(this._element,this.constructor.Event.INSERTED)),this._popper?this._popper.update():this._popper=i.createPopper(this._element,n,this._getPopperConfig(a)),n.classList.add(Li);const c=this._resolvePossibleFunction(this._config.customClass);c&&n.classList.add(...c.split(" ")),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>{H.on(t,"mouseover",_)}));const h=this.tip.classList.contains(Ti);this._queueCallback((()=>{const t=this._hoverState;this._hoverState=null,H.trigger(this._element,this.constructor.Event.SHOWN),t===Ni&&this._leave(null,this)}),this.tip,h)}hide(){if(!this._popper)return;const t=this.getTipElement();if(H.trigger(this._element,this.constructor.Event.HIDE).defaultPrevented)return;t.classList.remove(Li),"ontouchstart"in document.documentElement&&[].concat(...document.body.children).forEach((t=>H.off(t,"mouseover",_))),this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1;const e=this.tip.classList.contains(Ti);this._queueCallback((()=>{this._isWithActiveTrigger()||(this._hoverState!==ki&&t.remove(),this._cleanTipClass(),this._element.removeAttribute("aria-describedby"),H.trigger(this._element,this.constructor.Event.HIDDEN),this._disposePopper())}),this.tip,e),this._hoverState=""}update(){null!==this._popper&&this._popper.update()}isWithContent(){return Boolean(this.getTitle())}getTipElement(){if(this.tip)return this.tip;const t=document.createElement("div");t.innerHTML=this._config.template;const e=t.children[0];return this.setContent(e),e.classList.remove(Ti,Li),this.tip=e,this.tip}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),Oi)}_sanitizeAndSetContent(t,e,i){const s=Y.findOne(i,t);e||!s?this.setElementContent(s,e):s.remove()}setElementContent(t,e){if(null!==t)return l(e)?(e=c(e),void(this._config.html?e.parentNode!==t&&(t.innerHTML="",t.append(e)):t.textContent=e.textContent)):void(this._config.html?(this._config.sanitize&&(e=pi(e,this._config.allowList,this._config.sanitizeFn)),t.innerHTML=e):t.textContent=e)}getTitle(){const t=this._element.getAttribute("data-coreui-original-title")||this._config.title;return this._resolvePossibleFunction(t)}updateAttachment(t){return"right"===t?"end":"left"===t?"start":t}_initializeOnDelegatedTarget(t,e){return e||this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_resolvePossibleFunction(t){return"function"==typeof t?t.call(this._element):t}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"onChange",enabled:!0,phase:"afterWrite",fn:t=>this._handlePopperPlacementChange(t)}],onFirstUpdate:t=>{t.options.placement!==t.placement&&this._handlePopperPlacementChange(t)}};return{...e,..."function"==typeof this._config.popperConfig?this._config.popperConfig(e):this._config.popperConfig}}_addAttachmentClass(t){this.getTipElement().classList.add(`${this._getBasicClassPrefix()}-${this.updateAttachment(t)}`)}_getAttachment(t){return Ei[t.toUpperCase()]}_setListeners(){this._config.trigger.split(" ").forEach((t=>{if("click"===t)H.on(this._element,this.constructor.Event.CLICK,this._config.selector,(t=>this.toggle(t)));else if("manual"!==t){const e=t===Ii?this.constructor.Event.MOUSEENTER:this.constructor.Event.FOCUSIN,i=t===Ii?this.constructor.Event.MOUSELEAVE:this.constructor.Event.FOCUSOUT;H.on(this._element,e,this._config.selector,(t=>this._enter(t))),H.on(this._element,i,this._config.selector,(t=>this._leave(t)))}})),this._hideModalHandler=()=>{this._element&&this.hide()},H.on(this._element.closest(Si),Di,this._hideModalHandler),this._config.selector?this._config={...this._config,trigger:"manual",selector:""}:this._fixTitle()}_fixTitle(){const t=this._element.getAttribute("title"),e=typeof this._element.getAttribute("data-coreui-original-title");(t||"string"!==e)&&(this._element.setAttribute("data-coreui-original-title",t||""),!t||this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),this._element.setAttribute("title",""))}_enter(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusin"===t.type?$i:Ii]=!0),e.getTipElement().classList.contains(Li)||e._hoverState===ki?e._hoverState=ki:(clearTimeout(e._timeout),e._hoverState=ki,e._config.delay&&e._config.delay.show?e._timeout=setTimeout((()=>{e._hoverState===ki&&e.show()}),e._config.delay.show):e.show())}_leave(t,e){e=this._initializeOnDelegatedTarget(t,e),t&&(e._activeTrigger["focusout"===t.type?$i:Ii]=e._element.contains(t.relatedTarget)),e._isWithActiveTrigger()||(clearTimeout(e._timeout),e._hoverState=Ni,e._config.delay&&e._config.delay.hide?e._timeout=setTimeout((()=>{e._hoverState===Ni&&e.hide()}),e._config.delay.hide):e.hide())}_isWithActiveTrigger(){for(const t in this._activeTrigger)if(this._activeTrigger[t])return!0;return!1}_getConfig(t){const e=Q.getDataAttributes(this._element);return Object.keys(e).forEach((t=>{yi.has(t)&&delete e[t]})),(t={...this.constructor.Default,...e,..."object"==typeof t&&t?t:{}}).container=!1===t.container?document.body:c(t.container),"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),h(bi,t,this.constructor.DefaultType),t.sanitize&&(t.template=pi(t.template,t.allowList,t.sanitizeFn)),t}_getDelegateConfig(){const t={};for(const e in this._config)this.constructor.Default[e]!==this._config[e]&&(t[e]=this._config[e]);return t}_cleanTipClass(){const t=this.getTipElement(),e=new RegExp(`(^|\\s)${this._getBasicClassPrefix()}\\S+`,"g"),i=t.getAttribute("class").match(e);null!==i&&i.length>0&&i.map((t=>t.trim())).forEach((e=>t.classList.remove(e)))}_getBasicClassPrefix(){return"bs-tooltip"}_handlePopperPlacementChange(t){const{state:e}=t;e&&(this.tip=e.elements.popper,this._cleanTipClass(),this._addAttachmentClass(this._getAttachment(e.placement)))}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null)}static jQueryInterface(t){return this.each((function(){const e=xi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}v(xi);const Mi=".coreui.popover",Pi={...xi.Default,placement:"right",offset:[0,8],trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="popover-arrow"></div><h3 class="popover-header"></h3><div class="popover-body"></div></div>'},ji={...xi.DefaultType,content:"(string|element|function)"},Hi={HIDE:`hide${Mi}`,HIDDEN:`hidden${Mi}`,SHOW:`show${Mi}`,SHOWN:`shown${Mi}`,INSERTED:`inserted${Mi}`,CLICK:`click${Mi}`,FOCUSIN:`focusin${Mi}`,FOCUSOUT:`focusout${Mi}`,MOUSEENTER:`mouseenter${Mi}`,MOUSELEAVE:`mouseleave${Mi}`};class Bi extends xi{static get Default(){return Pi}static get NAME(){return"popover"}static get Event(){return Hi}static get DefaultType(){return ji}isWithContent(){return this.getTitle()||this._getContent()}setContent(t){this._sanitizeAndSetContent(t,this.getTitle(),".popover-header"),this._sanitizeAndSetContent(t,this._getContent(),".popover-body")}_getContent(){return this._resolvePossibleFunction(this._config.content)}_getBasicClassPrefix(){return"bs-popover"}static jQueryInterface(t){return this.each((function(){const e=Bi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}v(Bi);const zi="scrollspy",Ri=".coreui.scrollspy",qi={offset:10,method:"auto",target:""},Wi={offset:"number",method:"string",target:"(string|element)"},Fi=`activate${Ri}`,Ui=`scroll${Ri}`,Vi=`load${Ri}.data-api`,Ki="active",Qi=".nav-link, .list-group-item, .dropdown-item",Yi="position";class Xi extends R{constructor(t,e){super(t),this._scrollElement="BODY"===this._element.tagName?window:this._element,this._config=this._getConfig(e),this._offsets=[],this._targets=[],this._activeTarget=null,this._scrollHeight=0,H.on(this._scrollElement,Ui,(()=>this._process())),this.refresh(),this._process()}static get Default(){return qi}static get NAME(){return zi}refresh(){const t=this._scrollElement===this._scrollElement.window?"offset":Yi,e="auto"===this._config.method?t:this._config.method,i=e===Yi?this._getScrollTop():0;this._offsets=[],this._targets=[],this._scrollHeight=this._getScrollHeight(),Y.find(Qi,this._config.target).map((t=>{const s=o(t),n=s?Y.findOne(s):null;if(n){const t=n.getBoundingClientRect();if(t.width||t.height)return[Q[e](n).top+i,s]}return null})).filter((t=>t)).sort(((t,e)=>t[0]-e[0])).forEach((t=>{this._offsets.push(t[0]),this._targets.push(t[1])}))}dispose(){H.off(this._scrollElement,Ri),super.dispose()}_getConfig(t){return(t={...qi,...Q.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}}).target=c(t.target)||document.documentElement,h(zi,t,Wi),t}_getScrollTop(){return this._scrollElement===window?this._scrollElement.pageYOffset:this._scrollElement.scrollTop}_getScrollHeight(){return this._scrollElement.scrollHeight||Math.max(document.body.scrollHeight,document.documentElement.scrollHeight)}_getOffsetHeight(){return this._scrollElement===window?window.innerHeight:this._scrollElement.getBoundingClientRect().height}_process(){const t=this._getScrollTop()+this._config.offset,e=this._getScrollHeight(),i=this._config.offset+e-this._getOffsetHeight();if(this._scrollHeight!==e&&this.refresh(),t>=i){const t=this._targets[this._targets.length-1];this._activeTarget!==t&&this._activate(t)}else{if(this._activeTarget&&t<this._offsets[0]&&this._offsets[0]>0)return this._activeTarget=null,void this._clear();for(let e=this._offsets.length;e--;)this._activeTarget!==this._targets[e]&&t>=this._offsets[e]&&(void 0===this._offsets[e+1]||t<this._offsets[e+1])&&this._activate(this._targets[e])}}_activate(t){this._activeTarget=t,this._clear();const e=Qi.split(",").map((e=>`${e}[data-coreui-target="${t}"],${e}[href="${t}"]`)),i=Y.findOne(e.join(","),this._config.target);i.classList.add(Ki),i.classList.contains("dropdown-item")?Y.findOne(".dropdown-toggle",i.closest(".dropdown")).classList.add(Ki):Y.parents(i,".nav, .list-group").forEach((t=>{Y.prev(t,".nav-link, .list-group-item").forEach((t=>t.classList.add(Ki))),Y.prev(t,".nav-item").forEach((t=>{Y.children(t,".nav-link").forEach((t=>t.classList.add(Ki)))}))})),H.trigger(this._scrollElement,Fi,{relatedTarget:t})}_clear(){Y.find(Qi,this._config.target).filter((t=>t.classList.contains(Ki))).forEach((t=>t.classList.remove(Ki)))}static jQueryInterface(t){return this.each((function(){const e=Xi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}H.on(window,Vi,(()=>{Y.find('[data-coreui-spy="scroll"]').forEach((t=>new Xi(t)))})),v(Xi);const Gi="sidebar",Zi=".coreui.sidebar",Ji={},ts={},es="hide",is="show",ss="sidebar-narrow",ns="sidebar-narrow-unfoldable",os=`hide${Zi}`,rs=`hidden${Zi}`,as=`show${Zi}`,ls=`shown${Zi}`,cs=`click${Zi}.data-api`,hs=`load${Zi}.data-api`,ds=".sidebar";class us extends R{constructor(t,e){super(t),this._config=this._getConfig(e),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 Ji}static get DefaultType(){return ts}static get NAME(){return Gi}show(){H.trigger(this._element,as),this._element.classList.contains(es)&&this._element.classList.remove(es),this._isMobile()&&(this._element.classList.add(is),this._backdrop.show(),(new ue).hide()),this._queueCallback((()=>{!0===this._isVisible()&&(this._show=!0,(this._isMobile()||this._isOverlaid())&&this._addClickOutListener(),H.trigger(this._element,ls))}),this._element,!0)}hide(){H.trigger(this._element,os),this._element.classList.contains(is)&&this._element.classList.remove(is),this._isMobile()?(this._backdrop.hide(),(new ue).reset()):this._element.classList.add(es),this._queueCallback((()=>{!1===this._isVisible()&&(this._show=!1,(this._isMobile()||this._isOverlaid())&&this._removeClickOutListener(),H.trigger(this._element,rs))}),this._element,!0)}toggle(){this._isVisible()?this.hide():this.show()}narrow(){this._isMobile()||(this._addClassName(ss),this._narrow=!0)}unfoldable(){this._isMobile()||(this._addClassName(ns),this._unfoldable=!0)}reset(){this._isMobile()||(this._narrow&&(this._element.classList.remove(ss),this._narrow=!1),this._unfoldable&&(this._element.classList.remove(ns),this._unfoldable=!1))}toggleNarrow(){this._narrow?this.reset():this.narrow()}toggleUnfoldable(){this._unfoldable?this.reset():this.unfoldable()}_getConfig(t){return t={...Ji,...Q.getDataAttributes(this._element),..."object"==typeof t?t:{}},h(Gi,t,ts),t}_initializeBackDrop(){return new pe({className:"sidebar-backdrop",isVisible:this._isMobile(),isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_isMobile(){return Boolean(window.getComputedStyle(this._element,null).getPropertyValue("--cui-is-mobile"))}_isNarrow(){return this._element.classList.contains(ss)}_isOverlaid(){return this._element.classList.contains("sidebar-overlaid")}_isUnfoldable(){return this._element.classList.contains(ns)}_isVisible(){const t=this._element.getBoundingClientRect();return t.top>=0&&t.left>=0&&Math.floor(t.bottom)<=(window.innerHeight||document.documentElement.clientHeight)&&Math.floor(t.right)<=(window.innerWidth||document.documentElement.clientWidth)}_addClassName(t){this._element.classList.add(t)}_clickOutListener(t,e){null===t.target.closest(ds)&&(t.preventDefault(),t.stopPropagation(),e.hide())}_addClickOutListener(){H.on(document,cs,(t=>{this._clickOutListener(t,this)}))}_removeClickOutListener(){H.off(document,cs)}_addEventListeners(){this._mobile&&this._show&&this._addClickOutListener(),this._overlaid&&this._show&&this._addClickOutListener(),H.on(this._element,cs,"[data-coreui-toggle]",(t=>{t.preventDefault();const e=Q.getDataAttribute(t.target,"toggle");"narrow"===e&&this.toggleNarrow(),"unfoldable"===e&&this.toggleUnfoldable()})),H.on(this._element,cs,'[data-coreui-close="sidebar"]',(t=>{t.preventDefault(),this.hide()})),H.on(window,"resize",(()=>{this._isMobile()&&this._isVisible()&&(this.hide(),this._backdrop=this._initializeBackDrop())}))}static sidebarInterface(t,e){const i=us.getOrCreateInstance(t,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}static jQueryInterface(t){return this.each((function(){us.sidebarInterface(this,t)}))}}H.on(window,hs,(()=>{Array.from(document.querySelectorAll(ds)).forEach((t=>{us.sidebarInterface(t)}))})),v(us);const gs="active",_s="fade",fs="show",ms=".active",ps=":scope > li > .active";class bs extends R{static get NAME(){return"tab"}show(){if(this._element.parentNode&&this._element.parentNode.nodeType===Node.ELEMENT_NODE&&this._element.classList.contains(gs))return;let t;const e=r(this._element),i=this._element.closest(".nav, .list-group");if(i){const e="UL"===i.nodeName||"OL"===i.nodeName?ps:ms;t=Y.find(e,i),t=t[t.length-1]}const s=t?H.trigger(t,"hide.coreui.tab",{relatedTarget:this._element}):null;if(H.trigger(this._element,"show.coreui.tab",{relatedTarget:t}).defaultPrevented||null!==s&&s.defaultPrevented)return;this._activate(this._element,i);const n=()=>{H.trigger(t,"hidden.coreui.tab",{relatedTarget:this._element}),H.trigger(this._element,"shown.coreui.tab",{relatedTarget:t})};e?this._activate(e,e.parentNode,n):n()}_activate(t,e,i){const s=(!e||"UL"!==e.nodeName&&"OL"!==e.nodeName?Y.children(e,ms):Y.find(ps,e))[0],n=i&&s&&s.classList.contains(_s),o=()=>this._transitionComplete(t,s,i);s&&n?(s.classList.remove(fs),this._queueCallback(o,t,!0)):o()}_transitionComplete(t,e,i){if(e){e.classList.remove(gs);const t=Y.findOne(":scope > .dropdown-menu .active",e.parentNode);t&&t.classList.remove(gs),"tab"===e.getAttribute("role")&&e.setAttribute("aria-selected",!1)}t.classList.add(gs),"tab"===t.getAttribute("role")&&t.setAttribute("aria-selected",!0),f(t),t.classList.contains(_s)&&t.classList.add(fs);let s=t.parentNode;if(s&&"LI"===s.nodeName&&(s=s.parentNode),s&&s.classList.contains("dropdown-menu")){const e=t.closest(".dropdown");e&&Y.find(".dropdown-toggle",e).forEach((t=>t.classList.add(gs))),t.setAttribute("aria-expanded",!0)}i&&i()}static jQueryInterface(t){return this.each((function(){const e=bs.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}H.on(document,"click.coreui.tab.data-api",'[data-coreui-toggle="tab"], [data-coreui-toggle="pill"], [data-coreui-toggle="list"]',(function(t){["A","AREA"].includes(this.tagName)&&t.preventDefault(),u(this)||bs.getOrCreateInstance(this).show()})),v(bs);const vs="toast",ys=".coreui.toast",ws=`mouseover${ys}`,Es=`mouseout${ys}`,As=`focusin${ys}`,Cs=`focusout${ys}`,Ts=`hide${ys}`,Ls=`hidden${ys}`,ks=`show${ys}`,Ns=`shown${ys}`,Os="hide",Ss="show",Ds="showing",Is={animation:"boolean",autohide:"boolean",delay:"number"},$s={animation:!0,autohide:!0,delay:5e3};class xs extends R{constructor(t,e){super(t),this._config=this._getConfig(e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get DefaultType(){return Is}static get Default(){return $s}static get NAME(){return vs}show(){H.trigger(this._element,ks).defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove(Os),f(this._element),this._element.classList.add(Ss),this._element.classList.add(Ds),this._queueCallback((()=>{this._element.classList.remove(Ds),H.trigger(this._element,Ns),this._maybeScheduleHide()}),this._element,this._config.animation))}hide(){this._element.classList.contains(Ss)&&(H.trigger(this._element,Ts).defaultPrevented||(this._element.classList.add(Ds),this._queueCallback((()=>{this._element.classList.add(Os),this._element.classList.remove(Ds),this._element.classList.remove(Ss),H.trigger(this._element,Ls)}),this._element,this._config.animation)))}dispose(){this._clearTimeout(),this._element.classList.contains(Ss)&&this._element.classList.remove(Ss),super.dispose()}_getConfig(t){return t={...$s,...Q.getDataAttributes(this._element),..."object"==typeof t&&t?t:{}},h(vs,t,this.constructor.DefaultType),t}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const i=t.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){H.on(this._element,ws,(t=>this._onInteraction(t,!0))),H.on(this._element,Es,(t=>this._onInteraction(t,!1))),H.on(this._element,As,(t=>this._onInteraction(t,!0))),H.on(this._element,Cs,(t=>this._onInteraction(t,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each((function(){const e=xs.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}return q(xs),v(xs),{Alert:W,Button:U,Carousel:yt,Collapse:jt,Dropdown:ce,Modal:He,Navigation:Ze,OffCanvas:ui,Popover:Bi,ScrollSpy:Xi,Sidebar:us,Tab:bs,Toast:xs,Tooltip:xi}}));
|
|
6
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@popperjs/core")):"function"==typeof define&&define.amd?define(["@popperjs/core"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).coreui=e(t.Popper)}(this,(function(t){"use strict";function e(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const i in t)if("default"!==i){const s=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>t[i]})}return e.default=t,Object.freeze(e)}const i=e(t),s="transitionend",n=t=>{let e=t.getAttribute("data-coreui-target");if(!e||"#"===e){let i=t.getAttribute("href");if(!i||!i.includes("#")&&!i.startsWith("."))return null;i.includes("#")&&!i.startsWith("#")&&(i=`#${i.split("#")[1]}`),e=i&&"#"!==i?i.trim():null}return e},o=t=>{const e=n(t);return e&&document.querySelector(e)?e:null},r=t=>{const e=n(t);return e?document.querySelector(e):null},a=t=>{t.dispatchEvent(new Event(s))},l=t=>!(!t||"object"!=typeof t)&&(void 0!==t.jquery&&(t=t[0]),void 0!==t.nodeType),c=t=>l(t)?t.jquery?t[0]:t:"string"==typeof t&&t.length>0?document.querySelector(t):null,h=t=>{if(!l(t)||0===t.getClientRects().length)return!1;const e="visible"===getComputedStyle(t).getPropertyValue("visibility"),i=t.closest("details:not([open])");if(!i)return e;if(i!==t){const e=t.closest("summary");if(e&&e.parentNode!==i)return!1;if(null===e)return!1}return e},d=t=>!t||t.nodeType!==Node.ELEMENT_NODE||!!t.classList.contains("disabled")||(void 0!==t.disabled?t.disabled:t.hasAttribute("disabled")&&"false"!==t.getAttribute("disabled")),u=t=>{if(!document.documentElement.attachShadow)return null;if("function"==typeof t.getRootNode){const e=t.getRootNode();return e instanceof ShadowRoot?e:null}return t instanceof ShadowRoot?t:t.parentNode?u(t.parentNode):null},_=()=>{},g=t=>{t.offsetHeight},f=()=>window.jQuery&&!document.body.hasAttribute("data-coreui-no-jquery")?window.jQuery:null,p=[],m=()=>"rtl"===document.documentElement.dir,b=t=>{var e;e=()=>{const e=f();if(e){const i=t.NAME,s=e.fn[i];e.fn[i]=t.jQueryInterface,e.fn[i].Constructor=t,e.fn[i].noConflict=()=>(e.fn[i]=s,t.jQueryInterface)}},"loading"===document.readyState?(p.length||document.addEventListener("DOMContentLoaded",(()=>{for(const t of p)t()})),p.push(e)):e()},v=t=>{"function"==typeof t&&t()},y=(t,e,i=!0)=>{if(!i)return void v(t);const n=(t=>{if(!t)return 0;let{transitionDuration:e,transitionDelay:i}=window.getComputedStyle(t);const s=Number.parseFloat(e),n=Number.parseFloat(i);return s||n?(e=e.split(",")[0],i=i.split(",")[0],1e3*(Number.parseFloat(e)+Number.parseFloat(i))):0})(e)+5;let o=!1;const r=({target:i})=>{i===e&&(o=!0,e.removeEventListener(s,r),v(t))};e.addEventListener(s,r),setTimeout((()=>{o||a(e)}),n)},w=(t,e,i,s)=>{const n=t.length;let o=t.indexOf(e);return-1===o?!i&&s?t[n-1]:t[0]:(o+=i?1:-1,s&&(o=(o+n)%n),t[Math.max(0,Math.min(o,n-1))])},A=/[^.]*(?=\..*)\.|.*/,C=/\..*/,E=/::\d+$/,T={};let k=1;const L={mouseenter:"mouseover",mouseleave:"mouseout"},O=new Set(["click","dblclick","mouseup","mousedown","contextmenu","mousewheel","DOMMouseScroll","mouseover","mouseout","mousemove","selectstart","selectend","keydown","keypress","keyup","orientationchange","touchstart","touchmove","touchend","touchcancel","pointerdown","pointermove","pointerup","pointerleave","pointercancel","gesturestart","gesturechange","gestureend","focus","blur","change","reset","select","submit","focusin","focusout","load","unload","beforeunload","resize","move","DOMContentLoaded","readystatechange","error","abort","scroll"]);function N(t,e){return e&&`${e}::${k++}`||t.uidEvent||k++}function I(t){const e=N(t);return t.uidEvent=e,T[e]=T[e]||{},T[e]}function D(t,e,i=null){return Object.values(t).find((t=>t.callable===e&&t.delegationSelector===i))}function S(t,e,i){const s="string"==typeof e,n=s?i:e||i;let o=P(t);return O.has(o)||(o=t),[s,n,o]}function $(t,e,i,s,n){if("string"!=typeof e||!t)return;let[o,r,a]=S(e,i,s);if(e in L){const t=t=>function(e){if(!e.relatedTarget||e.relatedTarget!==e.delegateTarget&&!e.delegateTarget.contains(e.relatedTarget))return t.call(this,e)};r=t(r)}const l=I(t),c=l[a]||(l[a]={}),h=D(c,r,o?i:null);if(h)return void(h.oneOff=h.oneOff&&n);const d=N(r,e.replace(A,"")),u=o?function(t,e,i){return function s(n){const o=t.querySelectorAll(e);for(let{target:r}=n;r&&r!==this;r=r.parentNode)for(const a of o)if(a===r)return n.delegateTarget=r,s.oneOff&&j.off(t,n.type,e,i),i.apply(r,[n])}}(t,i,r):function(t,e){return function i(s){return s.delegateTarget=t,i.oneOff&&j.off(t,s.type,e),e.apply(t,[s])}}(t,r);u.delegationSelector=o?i:null,u.callable=r,u.oneOff=n,u.uidEvent=d,c[d]=u,t.addEventListener(a,u,o)}function x(t,e,i,s,n){const o=D(e[i],s,n);o&&(t.removeEventListener(i,o,Boolean(n)),delete e[i][o.uidEvent])}function M(t,e,i,s){const n=e[i]||{};for(const o of Object.keys(n))if(o.includes(s)){const s=n[o];x(t,e,i,s.callable,s.delegationSelector)}}function P(t){return t=t.replace(C,""),L[t]||t}const j={on(t,e,i,s){$(t,e,i,s,!1)},one(t,e,i,s){$(t,e,i,s,!0)},off(t,e,i,s){if("string"!=typeof e||!t)return;const[n,o,r]=S(e,i,s),a=r!==e,l=I(t),c=l[r]||{},h=e.startsWith(".");if(void 0===o){if(h)for(const i of Object.keys(l))M(t,l,i,e.slice(1));for(const i of Object.keys(c)){const s=i.replace(E,"");if(!a||e.includes(s)){const e=c[i];x(t,l,r,e.callable,e.delegationSelector)}}}else{if(!Object.keys(c).length)return;x(t,l,r,o,n?i:null)}},trigger(t,e,i){if("string"!=typeof e||!t)return null;const s=f();let n=null,o=!0,r=!0,a=!1;e!==P(e)&&s&&(n=s.Event(e,i),s(t).trigger(n),o=!n.isPropagationStopped(),r=!n.isImmediatePropagationStopped(),a=n.isDefaultPrevented());let l=new Event(e,{bubbles:o,cancelable:!0});return l=function(t,e){for(const[i,s]of Object.entries(e||{}))Object.defineProperty(t,i,{get:()=>s});return t}(l,i),a&&l.preventDefault(),r&&t.dispatchEvent(l),l.defaultPrevented&&n&&n.preventDefault(),l}},z=new Map,F={set(t,e,i){z.has(t)||z.set(t,new Map);const s=z.get(t);s.has(e)||0===s.size?s.set(e,i):console.error(`Bootstrap doesn't allow more than one instance per element. Bound instance: ${Array.from(s.keys())[0]}.`)},get:(t,e)=>z.has(t)&&z.get(t).get(e)||null,remove(t,e){if(!z.has(t))return;const i=z.get(t);i.delete(e),0===i.size&&z.delete(t)}};function H(t){if("true"===t)return!0;if("false"===t)return!1;if(t===Number(t).toString())return Number(t);if(""===t||"null"===t)return null;if("string"!=typeof t)return t;try{return JSON.parse(decodeURIComponent(t))}catch(e){return t}}function q(t){return t.replace(/[A-Z]/g,(t=>`-${t.toLowerCase()}`))}const B={setDataAttribute(t,e,i){t.setAttribute(`data-coreui-${q(e)}`,i)},removeDataAttribute(t,e){t.removeAttribute(`data-coreui-${q(e)}`)},getDataAttributes(t){if(!t)return{};const e={},i=Object.keys(t.dataset).filter((t=>t.startsWith("coreui")&&!t.startsWith("coreuiConfig")));for(const s of i){let i=s.replace(/^coreui/,"");i=i.charAt(0).toLowerCase()+i.slice(1,i.length),e[i]=H(t.dataset[s])}return e},getDataAttribute:(t,e)=>H(t.getAttribute(`data-coreui-${q(e)}`))};class W{static get Default(){return{}}static get DefaultType(){return{}}static get NAME(){throw new Error('You have to implement the static method "NAME", for each component!')}_getConfig(t){return t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t}_mergeConfigObj(t,e){const i=l(e)?B.getDataAttribute(e,"config"):{};return{...this.constructor.Default,..."object"==typeof i?i:{},...l(e)?B.getDataAttributes(e):{},..."object"==typeof t?t:{}}}_typeCheckConfig(t,e=this.constructor.DefaultType){for(const s of Object.keys(e)){const n=e[s],o=t[s],r=l(o)?"element":null==(i=o)?`${i}`:Object.prototype.toString.call(i).match(/\s([a-z]+)/i)[1].toLowerCase();if(!new RegExp(n).test(r))throw new TypeError(`${this.constructor.NAME.toUpperCase()}: Option "${s}" provided type "${r}" but expected type "${n}".`)}var i}}class V extends W{constructor(t,e){super(),(t=c(t))&&(this._element=t,this._config=this._getConfig(e),F.set(this._element,this.constructor.DATA_KEY,this))}dispose(){F.remove(this._element,this.constructor.DATA_KEY),j.off(this._element,this.constructor.EVENT_KEY);for(const t of Object.getOwnPropertyNames(this))this[t]=null}_queueCallback(t,e,i=!0){y(t,e,i)}_getConfig(t){return t=this._mergeConfigObj(t,this._element),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}static getInstance(t){return F.get(c(t),this.DATA_KEY)}static getOrCreateInstance(t,e={}){return this.getInstance(t)||new this(t,"object"==typeof e?e:null)}static get VERSION(){return"4.2.2"}static get DATA_KEY(){return`coreui.${this.NAME}`}static get EVENT_KEY(){return`.${this.DATA_KEY}`}static eventName(t){return`${t}${this.EVENT_KEY}`}}const R=(t,e="hide")=>{const i=`click.dismiss${t.EVENT_KEY}`,s=t.NAME;j.on(document,i,`[data-coreui-dismiss="${s}"]`,(function(i){if(["A","AREA"].includes(this.tagName)&&i.preventDefault(),d(this))return;const n=r(this)||this.closest(`.${s}`);t.getOrCreateInstance(n)[e]()}))};class K extends V{static get NAME(){return"alert"}close(){if(j.trigger(this._element,"close.coreui.alert").defaultPrevented)return;this._element.classList.remove("show");const t=this._element.classList.contains("fade");this._queueCallback((()=>this._destroyElement()),this._element,t)}_destroyElement(){this._element.remove(),j.trigger(this._element,"closed.coreui.alert"),this.dispose()}static jQueryInterface(t){return this.each((function(){const e=K.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}R(K,"close"),b(K);const Q='[data-coreui-toggle="button"]';class U extends V{static get NAME(){return"button"}toggle(){this._element.setAttribute("aria-pressed",this._element.classList.toggle("active"))}static jQueryInterface(t){return this.each((function(){const e=U.getOrCreateInstance(this);"toggle"===t&&e[t]()}))}}j.on(document,"click.coreui.button.data-api",Q,(t=>{t.preventDefault();const e=t.target.closest(Q);U.getOrCreateInstance(e).toggle()})),b(U);const Y={find:(t,e=document.documentElement)=>[].concat(...Element.prototype.querySelectorAll.call(e,t)),findOne:(t,e=document.documentElement)=>Element.prototype.querySelector.call(e,t),children:(t,e)=>[].concat(...t.children).filter((t=>t.matches(e))),parents(t,e){const i=[];let s=t.parentNode.closest(e);for(;s;)i.push(s),s=s.parentNode.closest(e);return i},prev(t,e){let i=t.previousElementSibling;for(;i;){if(i.matches(e))return[i];i=i.previousElementSibling}return[]},next(t,e){let i=t.nextElementSibling;for(;i;){if(i.matches(e))return[i];i=i.nextElementSibling}return[]},focusableChildren(t){const e=["a","button","input","textarea","select","details","[tabindex]",'[contenteditable="true"]'].map((t=>`${t}:not([tabindex^="-"])`)).join(",");return this.find(e,t).filter((t=>!d(t)&&h(t)))}},X={endCallback:null,leftCallback:null,rightCallback:null},G={endCallback:"(function|null)",leftCallback:"(function|null)",rightCallback:"(function|null)"};class J extends W{constructor(t,e){super(),this._element=t,t&&J.isSupported()&&(this._config=this._getConfig(e),this._deltaX=0,this._supportPointerEvents=Boolean(window.PointerEvent),this._initEvents())}static get Default(){return X}static get DefaultType(){return G}static get NAME(){return"swipe"}dispose(){j.off(this._element,".coreui.swipe")}_start(t){this._supportPointerEvents?this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX):this._deltaX=t.touches[0].clientX}_end(t){this._eventIsPointerPenTouch(t)&&(this._deltaX=t.clientX-this._deltaX),this._handleSwipe(),v(this._config.endCallback)}_move(t){this._deltaX=t.touches&&t.touches.length>1?0:t.touches[0].clientX-this._deltaX}_handleSwipe(){const t=Math.abs(this._deltaX);if(t<=40)return;const e=t/this._deltaX;this._deltaX=0,e&&v(e>0?this._config.rightCallback:this._config.leftCallback)}_initEvents(){this._supportPointerEvents?(j.on(this._element,"pointerdown.coreui.swipe",(t=>this._start(t))),j.on(this._element,"pointerup.coreui.swipe",(t=>this._end(t))),this._element.classList.add("pointer-event")):(j.on(this._element,"touchstart.coreui.swipe",(t=>this._start(t))),j.on(this._element,"touchmove.coreui.swipe",(t=>this._move(t))),j.on(this._element,"touchend.coreui.swipe",(t=>this._end(t))))}_eventIsPointerPenTouch(t){return this._supportPointerEvents&&("pen"===t.pointerType||"touch"===t.pointerType)}static isSupported(){return"ontouchstart"in document.documentElement||navigator.maxTouchPoints>0}}const Z=".coreui.carousel",tt="next",et="prev",it="left",st="right",nt=`slide${Z}`,ot=`slid${Z}`,rt=`keydown${Z}`,at=`mouseenter${Z}`,lt=`mouseleave${Z}`,ct=`dragstart${Z}`,ht=`load${Z}.data-api`,dt=`click${Z}.data-api`,ut="carousel",_t="active",gt={ArrowLeft:st,ArrowRight:it},ft={interval:5e3,keyboard:!0,pause:"hover",ride:!1,touch:!0,wrap:!0},pt={interval:"(number|boolean)",keyboard:"boolean",pause:"(string|boolean)",ride:"(boolean|string)",touch:"boolean",wrap:"boolean"};class mt extends V{constructor(t,e){super(t,e),this._interval=null,this._activeElement=null,this._isSliding=!1,this.touchTimeout=null,this._swipeHelper=null,this._indicatorsElement=Y.findOne(".carousel-indicators",this._element),this._addEventListeners(),this._config.ride===ut&&this.cycle()}static get Default(){return ft}static get DefaultType(){return pt}static get NAME(){return"carousel"}next(){this._slide(tt)}nextWhenVisible(){!document.hidden&&h(this._element)&&this.next()}prev(){this._slide(et)}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?j.one(this._element,ot,(()=>this.cycle())):this.cycle())}to(t){const e=this._getItems();if(t>e.length-1||t<0)return;if(this._isSliding)return void j.one(this._element,ot,(()=>this.to(t)));const i=this._getItemIndex(this._getActive());if(i===t)return;const s=t>i?tt:et;this._slide(s,e[t])}dispose(){this._swipeHelper&&this._swipeHelper.dispose(),super.dispose()}_configAfterMerge(t){return t.defaultInterval=t.interval,t}_addEventListeners(){this._config.keyboard&&j.on(this._element,rt,(t=>this._keydown(t))),"hover"===this._config.pause&&(j.on(this._element,at,(()=>this.pause())),j.on(this._element,lt,(()=>this._maybeEnableCycle()))),this._config.touch&&J.isSupported()&&this._addTouchEventListeners()}_addTouchEventListeners(){for(const t of Y.find(".carousel-item img",this._element))j.on(t,ct,(t=>t.preventDefault()));const t={leftCallback:()=>this._slide(this._directionToOrder(it)),rightCallback:()=>this._slide(this._directionToOrder(st)),endCallback:()=>{"hover"===this._config.pause&&(this.pause(),this.touchTimeout&&clearTimeout(this.touchTimeout),this.touchTimeout=setTimeout((()=>this._maybeEnableCycle()),500+this._config.interval))}};this._swipeHelper=new J(this._element,t)}_keydown(t){if(/input|textarea/i.test(t.target.tagName))return;const e=gt[t.key];e&&(t.preventDefault(),this._slide(this._directionToOrder(e)))}_getItemIndex(t){return this._getItems().indexOf(t)}_setActiveIndicatorElement(t){if(!this._indicatorsElement)return;const e=Y.findOne(".active",this._indicatorsElement);e.classList.remove(_t),e.removeAttribute("aria-current");const i=Y.findOne(`[data-coreui-slide-to="${t}"]`,this._indicatorsElement);i&&(i.classList.add(_t),i.setAttribute("aria-current","true"))}_updateInterval(){const t=this._activeElement||this._getActive();if(!t)return;const e=Number.parseInt(t.getAttribute("data-coreui-interval"),10);this._config.interval=e||this._config.defaultInterval}_slide(t,e=null){if(this._isSliding)return;const i=this._getActive(),s=t===tt,n=e||w(this._getItems(),i,s,this._config.wrap);if(n===i)return;const o=this._getItemIndex(n),r=e=>j.trigger(this._element,e,{relatedTarget:n,direction:this._orderToDirection(t),from:this._getItemIndex(i),to:o});if(r(nt).defaultPrevented)return;if(!i||!n)return;const a=Boolean(this._interval);this.pause(),this._isSliding=!0,this._setActiveIndicatorElement(o),this._activeElement=n;const l=s?"carousel-item-start":"carousel-item-end",c=s?"carousel-item-next":"carousel-item-prev";n.classList.add(c),g(n),i.classList.add(l),n.classList.add(l),this._queueCallback((()=>{n.classList.remove(l,c),n.classList.add(_t),i.classList.remove(_t,c,l),this._isSliding=!1,r(ot)}),i,this._isAnimated()),a&&this.cycle()}_isAnimated(){return this._element.classList.contains("slide")}_getActive(){return Y.findOne(".active.carousel-item",this._element)}_getItems(){return Y.find(".carousel-item",this._element)}_clearInterval(){this._interval&&(clearInterval(this._interval),this._interval=null)}_directionToOrder(t){return m()?t===it?et:tt:t===it?tt:et}_orderToDirection(t){return m()?t===et?it:st:t===et?st:it}static jQueryInterface(t){return this.each((function(){const e=mt.getOrCreateInstance(this,t);if("number"!=typeof t){if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}}else e.to(t)}))}}j.on(document,dt,"[data-coreui-slide], [data-coreui-slide-to]",(function(t){const e=r(this);if(!e||!e.classList.contains(ut))return;t.preventDefault();const i=mt.getOrCreateInstance(e),s=this.getAttribute("data-coreui-slide-to");return s?(i.to(s),void i._maybeEnableCycle()):"next"===B.getDataAttribute(this,"slide")?(i.next(),void i._maybeEnableCycle()):(i.prev(),void i._maybeEnableCycle())})),j.on(window,ht,(()=>{const t=Y.find('[data-coreui-ride="carousel"]');for(const e of t)mt.getOrCreateInstance(e)})),b(mt);const bt=".coreui.collapse",vt=`show${bt}`,yt=`shown${bt}`,wt=`hide${bt}`,At=`hidden${bt}`,Ct=`click${bt}.data-api`,Et="show",Tt="collapse",kt="collapsing",Lt='[data-coreui-toggle="collapse"]',Ot={parent:null,toggle:!0},Nt={parent:"(null|element)",toggle:"boolean"};class It extends V{constructor(t,e){super(t,e),this._isTransitioning=!1,this._triggerArray=[];const i=Y.find(Lt);for(const t of i){const e=o(t),i=Y.find(e).filter((t=>t===this._element));null!==e&&i.length&&this._triggerArray.push(t)}this._initializeChildren(),this._config.parent||this._addAriaAndCollapsedClass(this._triggerArray,this._isShown()),this._config.toggle&&this.toggle()}static get Default(){return Ot}static get DefaultType(){return Nt}static get NAME(){return"collapse"}toggle(){this._isShown()?this.hide():this.show()}show(){if(this._isTransitioning||this._isShown())return;let t=[];if(this._config.parent&&(t=this._getFirstLevelChildren(".collapse.show, .collapse.collapsing").filter((t=>t!==this._element)).map((t=>It.getOrCreateInstance(t,{toggle:!1})))),t.length&&t[0]._isTransitioning)return;if(j.trigger(this._element,vt).defaultPrevented)return;for(const e of t)e.hide();const e=this._getDimension();this._element.classList.remove(Tt),this._element.classList.add(kt),this._element.style[e]=0,this._addAriaAndCollapsedClass(this._triggerArray,!0),this._isTransitioning=!0;const i=`scroll${e[0].toUpperCase()+e.slice(1)}`;this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(kt),this._element.classList.add(Tt,Et),this._element.style[e]="",j.trigger(this._element,yt)}),this._element,!0),this._element.style[e]=`${this._element[i]}px`}hide(){if(this._isTransitioning||!this._isShown())return;if(j.trigger(this._element,wt).defaultPrevented)return;const t=this._getDimension();this._element.style[t]=`${this._element.getBoundingClientRect()[t]}px`,g(this._element),this._element.classList.add(kt),this._element.classList.remove(Tt,Et);for(const t of this._triggerArray){const e=r(t);e&&!this._isShown(e)&&this._addAriaAndCollapsedClass([t],!1)}this._isTransitioning=!0,this._element.style[t]="",this._queueCallback((()=>{this._isTransitioning=!1,this._element.classList.remove(kt),this._element.classList.add(Tt),j.trigger(this._element,At)}),this._element,!0)}_isShown(t=this._element){return t.classList.contains(Et)}_configAfterMerge(t){return t.toggle=Boolean(t.toggle),t.parent=c(t.parent),t}_getDimension(){return this._element.classList.contains("collapse-horizontal")?"width":"height"}_initializeChildren(){if(!this._config.parent)return;const t=this._getFirstLevelChildren(Lt);for(const e of t){const t=r(e);t&&this._addAriaAndCollapsedClass([e],this._isShown(t))}}_getFirstLevelChildren(t){const e=Y.find(":scope .collapse .collapse",this._config.parent);return Y.find(t,this._config.parent).filter((t=>!e.includes(t)))}_addAriaAndCollapsedClass(t,e){if(t.length)for(const i of t)i.classList.toggle("collapsed",!e),i.setAttribute("aria-expanded",e)}static jQueryInterface(t){const e={};return"string"==typeof t&&/show|hide/.test(t)&&(e.toggle=!1),this.each((function(){const i=It.getOrCreateInstance(this,e);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t]()}}))}}j.on(document,Ct,Lt,(function(t){("A"===t.target.tagName||t.delegateTarget&&"A"===t.delegateTarget.tagName)&&t.preventDefault();const e=o(this),i=Y.find(e);for(const t of i)It.getOrCreateInstance(t,{toggle:!1}).toggle()})),b(It);const Dt="dropdown",St=".coreui.dropdown",$t="ArrowUp",xt="ArrowDown",Mt=`hide${St}`,Pt=`hidden${St}`,jt=`show${St}`,zt=`shown${St}`,Ft=`click${St}.data-api`,Ht=`keydown${St}.data-api`,qt=`keyup${St}.data-api`,Bt="show",Wt='[data-coreui-toggle="dropdown"]:not(.disabled):not(:disabled)',Vt=`${Wt}.show`,Rt=".dropdown-menu",Kt=m()?"top-end":"top-start",Qt=m()?"top-start":"top-end",Ut=m()?"bottom-end":"bottom-start",Yt=m()?"bottom-start":"bottom-end",Xt=m()?"left-start":"right-start",Gt=m()?"right-start":"left-start",Jt={autoClose:!0,boundary:"clippingParents",display:"dynamic",offset:[0,2],popperConfig:null,reference:"toggle"},Zt={autoClose:"(boolean|string)",boundary:"(string|element)",display:"string",offset:"(array|string|function)",popperConfig:"(null|object|function)",reference:"(string|element|object)"};class te extends V{constructor(t,e){super(t,e),this._popper=null,this._parent=this._element.parentNode,this._menu=Y.findOne(Rt,this._parent),this._inNavbar=this._detectNavbar()}static get Default(){return Jt}static get DefaultType(){return Zt}static get NAME(){return Dt}toggle(){return this._isShown()?this.hide():this.show()}show(){if(d(this._element)||this._isShown())return;const t={relatedTarget:this._element};if(!j.trigger(this._element,jt,t).defaultPrevented){if(this._createPopper(),"ontouchstart"in document.documentElement&&!this._parent.closest(".navbar-nav"))for(const t of[].concat(...document.body.children))j.on(t,"mouseover",_);this._element.focus(),this._element.setAttribute("aria-expanded",!0),this._menu.classList.add(Bt),this._element.classList.add(Bt),j.trigger(this._element,zt,t)}}hide(){if(d(this._element)||!this._isShown())return;const t={relatedTarget:this._element};this._completeHide(t)}dispose(){this._popper&&this._popper.destroy(),super.dispose()}update(){this._inNavbar=this._detectNavbar(),this._popper&&this._popper.update()}_completeHide(t){if(!j.trigger(this._element,Mt,t).defaultPrevented){if("ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))j.off(t,"mouseover",_);this._popper&&this._popper.destroy(),this._menu.classList.remove(Bt),this._element.classList.remove(Bt),this._element.setAttribute("aria-expanded","false"),B.removeDataAttribute(this._menu,"popper"),j.trigger(this._element,Pt,t)}}_getConfig(t){if("object"==typeof(t=super._getConfig(t)).reference&&!l(t.reference)&&"function"!=typeof t.reference.getBoundingClientRect)throw new TypeError(`${Dt.toUpperCase()}: Option "reference" provided type "object" without a required "getBoundingClientRect" method.`);return t}_createPopper(){if(void 0===i)throw new TypeError("Bootstrap's dropdowns require Popper (https://popper.js.org)");let t=this._element;"parent"===this._config.reference?t=this._parent:l(this._config.reference)?t=c(this._config.reference):"object"==typeof this._config.reference&&(t=this._config.reference);const e=this._getPopperConfig();this._popper=i.createPopper(t,this._menu,e)}_isShown(){return this._menu.classList.contains(Bt)}_getPlacement(){const t=this._parent;if(t.classList.contains("dropend"))return Xt;if(t.classList.contains("dropstart"))return Gt;if(t.classList.contains("dropup-center"))return"top";if(t.classList.contains("dropdown-center"))return"bottom";const e="end"===getComputedStyle(this._menu).getPropertyValue("--cui-position").trim();return t.classList.contains("dropup")?e?Qt:Kt:e?Yt:Ut}_detectNavbar(){return null!==this._element.closest(".navbar")}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_getPopperConfig(){const t={placement:this._getPlacement(),modifiers:[{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"offset",options:{offset:this._getOffset()}}]};return(this._inNavbar||"static"===this._config.display)&&(B.setDataAttribute(this._menu,"popper","static"),t.modifiers=[{name:"applyStyles",enabled:!1}]),{...t,..."function"==typeof this._config.popperConfig?this._config.popperConfig(t):this._config.popperConfig}}_selectMenuItem({key:t,target:e}){const i=Y.find(".dropdown-menu .dropdown-item:not(.disabled):not(:disabled)",this._menu).filter((t=>h(t)));i.length&&w(i,e,t===xt,!i.includes(e)).focus()}static jQueryInterface(t){return this.each((function(){const e=te.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}static clearMenus(t){if(2===t.button||"keyup"===t.type&&"Tab"!==t.key)return;const e=Y.find(Vt);for(const i of e){const e=te.getInstance(i);if(!e||!1===e._config.autoClose)continue;const s=t.composedPath(),n=s.includes(e._menu);if(s.includes(e._element)||"inside"===e._config.autoClose&&!n||"outside"===e._config.autoClose&&n)continue;if(e._menu.contains(t.target)&&("keyup"===t.type&&"Tab"===t.key||/input|select|option|textarea|form/i.test(t.target.tagName)))continue;const o={relatedTarget:e._element};"click"===t.type&&(o.clickEvent=t),e._completeHide(o)}}static dataApiKeydownHandler(t){const e=/input|textarea/i.test(t.target.tagName),i="Escape"===t.key,s=[$t,xt].includes(t.key);if(!s&&!i)return;if(e&&!i)return;t.preventDefault();const n=Y.findOne(Wt,t.delegateTarget.parentNode),o=te.getOrCreateInstance(n);if(s)return t.stopPropagation(),o.show(),void o._selectMenuItem(t);o._isShown()&&(t.stopPropagation(),o.hide(),n.focus())}}j.on(document,Ht,Wt,te.dataApiKeydownHandler),j.on(document,Ht,Rt,te.dataApiKeydownHandler),j.on(document,Ft,te.clearMenus),j.on(document,qt,te.clearMenus),j.on(document,Ft,Wt,(function(t){t.preventDefault(),te.getOrCreateInstance(this).toggle()})),b(te);const ee=".fixed-top, .fixed-bottom, .is-fixed, .sticky-top",ie=".sticky-top",se="padding-right",ne="margin-right";class oe{constructor(){this._element=document.body}getWidth(){const t=document.documentElement.clientWidth;return Math.abs(window.innerWidth-t)}hide(){const t=this.getWidth();this._disableOverFlow(),this._setElementAttributes(this._element,se,(e=>e+t)),this._setElementAttributes(ee,se,(e=>e+t)),this._setElementAttributes(ie,ne,(e=>e-t))}reset(){this._resetElementAttributes(this._element,"overflow"),this._resetElementAttributes(this._element,se),this._resetElementAttributes(ee,se),this._resetElementAttributes(ie,ne)}isOverflowing(){return this.getWidth()>0}_disableOverFlow(){this._saveInitialAttribute(this._element,"overflow"),this._element.style.overflow="hidden"}_setElementAttributes(t,e,i){const s=this.getWidth();this._applyManipulationCallback(t,(t=>{if(t!==this._element&&window.innerWidth>t.clientWidth+s)return;this._saveInitialAttribute(t,e);const n=window.getComputedStyle(t).getPropertyValue(e);t.style.setProperty(e,`${i(Number.parseFloat(n))}px`)}))}_saveInitialAttribute(t,e){const i=t.style.getPropertyValue(e);i&&B.setDataAttribute(t,e,i)}_resetElementAttributes(t,e){this._applyManipulationCallback(t,(t=>{const i=B.getDataAttribute(t,e);null!==i?(B.removeDataAttribute(t,e),t.style.setProperty(e,i)):t.style.removeProperty(e)}))}_applyManipulationCallback(t,e){if(l(t))e(t);else for(const i of Y.find(t,this._element))e(i)}}const re="show",ae="mousedown.coreui.backdrop",le={className:"modal-backdrop",clickCallback:null,isAnimated:!1,isVisible:!0,rootElement:"body"},ce={className:"string",clickCallback:"(function|null)",isAnimated:"boolean",isVisible:"boolean",rootElement:"(element|string)"};class he extends W{constructor(t){super(),this._config=this._getConfig(t),this._isAppended=!1,this._element=null}static get Default(){return le}static get DefaultType(){return ce}static get NAME(){return"backdrop"}show(t){if(!this._config.isVisible)return void v(t);this._append();const e=this._getElement();this._config.isAnimated&&g(e),e.classList.add(re),this._emulateAnimation((()=>{v(t)}))}hide(t){this._config.isVisible?(this._getElement().classList.remove(re),this._emulateAnimation((()=>{this.dispose(),v(t)}))):v(t)}dispose(){this._isAppended&&(j.off(this._element,ae),this._element.remove(),this._isAppended=!1)}_getElement(){if(!this._element){const t=document.createElement("div");t.className=this._config.className,this._config.isAnimated&&t.classList.add("fade"),this._element=t}return this._element}_configAfterMerge(t){return t.rootElement=c(t.rootElement),t}_append(){if(this._isAppended)return;const t=this._getElement();this._config.rootElement.append(t),j.on(t,ae,(()=>{v(this._config.clickCallback)})),this._isAppended=!0}_emulateAnimation(t){y(t,this._getElement(),this._config.isAnimated)}}const de=".coreui.focustrap",ue=`focusin${de}`,_e=`keydown.tab${de}`,ge="backward",fe={autofocus:!0,trapElement:null},pe={autofocus:"boolean",trapElement:"element"};class me extends W{constructor(t){super(),this._config=this._getConfig(t),this._isActive=!1,this._lastTabNavDirection=null}static get Default(){return fe}static get DefaultType(){return pe}static get NAME(){return"focustrap"}activate(){this._isActive||(this._config.autofocus&&this._config.trapElement.focus(),j.off(document,de),j.on(document,ue,(t=>this._handleFocusin(t))),j.on(document,_e,(t=>this._handleKeydown(t))),this._isActive=!0)}deactivate(){this._isActive&&(this._isActive=!1,j.off(document,de))}_handleFocusin(t){const{trapElement:e}=this._config;if(t.target===document||t.target===e||e.contains(t.target))return;const i=Y.focusableChildren(e);0===i.length?e.focus():this._lastTabNavDirection===ge?i[i.length-1].focus():i[0].focus()}_handleKeydown(t){"Tab"===t.key&&(this._lastTabNavDirection=t.shiftKey?ge:"forward")}}const be="hidden.coreui.modal",ve="show.coreui.modal",ye="modal-open",we="show",Ae="modal-static",Ce={backdrop:!0,focus:!0,keyboard:!0},Ee={backdrop:"(boolean|string)",focus:"boolean",keyboard:"boolean"};class Te extends V{constructor(t,e){super(t,e),this._dialog=Y.findOne(".modal-dialog",this._element),this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._isShown=!1,this._isTransitioning=!1,this._scrollBar=new oe,this._addEventListeners()}static get Default(){return Ce}static get DefaultType(){return Ee}static get NAME(){return"modal"}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||this._isTransitioning||j.trigger(this._element,ve,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._isTransitioning=!0,this._scrollBar.hide(),document.body.classList.add(ye),this._adjustDialog(),this._backdrop.show((()=>this._showElement(t))))}hide(){this._isShown&&!this._isTransitioning&&(j.trigger(this._element,"hide.coreui.modal").defaultPrevented||(this._isShown=!1,this._isTransitioning=!0,this._focustrap.deactivate(),this._element.classList.remove(we),this._queueCallback((()=>this._hideModal()),this._element,this._isAnimated())))}dispose(){for(const t of[window,this._dialog])j.off(t,".coreui.modal");this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}handleUpdate(){this._adjustDialog()}_initializeBackDrop(){return new he({isVisible:Boolean(this._config.backdrop),isAnimated:this._isAnimated()})}_initializeFocusTrap(){return new me({trapElement:this._element})}_showElement(t){document.body.contains(this._element)||document.body.append(this._element),this._element.style.display="block",this._element.removeAttribute("aria-hidden"),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.scrollTop=0;const e=Y.findOne(".modal-body",this._dialog);e&&(e.scrollTop=0),g(this._element),this._element.classList.add(we),this._queueCallback((()=>{this._config.focus&&this._focustrap.activate(),this._isTransitioning=!1,j.trigger(this._element,"shown.coreui.modal",{relatedTarget:t})}),this._dialog,this._isAnimated())}_addEventListeners(){j.on(this._element,"keydown.dismiss.coreui.modal",(t=>{if("Escape"===t.key)return this._config.keyboard?(t.preventDefault(),void this.hide()):void this._triggerBackdropTransition()})),j.on(window,"resize.coreui.modal",(()=>{this._isShown&&!this._isTransitioning&&this._adjustDialog()})),j.on(this._element,"mousedown.dismiss.coreui.modal",(t=>{t.target===t.currentTarget&&("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(ye),this._resetAdjustments(),this._scrollBar.reset(),j.trigger(this._element,be)}))}_isAnimated(){return this._element.classList.contains("fade")}_triggerBackdropTransition(){if(j.trigger(this._element,"hidePrevented.coreui.modal").defaultPrevented)return;const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._element.style.overflowY;"hidden"===e||this._element.classList.contains(Ae)||(t||(this._element.style.overflowY="hidden"),this._element.classList.add(Ae),this._queueCallback((()=>{this._element.classList.remove(Ae),this._queueCallback((()=>{this._element.style.overflowY=e}),this._dialog)}),this._dialog),this._element.focus())}_adjustDialog(){const t=this._element.scrollHeight>document.documentElement.clientHeight,e=this._scrollBar.getWidth(),i=e>0;if(i&&!t){const t=m()?"paddingLeft":"paddingRight";this._element.style[t]=`${e}px`}if(!i&&t){const t=m()?"paddingRight":"paddingLeft";this._element.style[t]=`${e}px`}}_resetAdjustments(){this._element.style.paddingLeft="",this._element.style.paddingRight=""}static jQueryInterface(t,e){return this.each((function(){const i=Te.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===i[t])throw new TypeError(`No method named "${t}"`);i[t](e)}}))}}j.on(document,"click.coreui.modal.data-api",'[data-coreui-toggle="modal"]',(function(t){const e=r(this);["A","AREA"].includes(this.tagName)&&t.preventDefault(),j.one(e,ve,(t=>{t.defaultPrevented||j.one(e,be,(()=>{h(this)&&this.focus()}))}));const i=Y.findOne(".modal.show");i&&Te.getInstance(i).hide(),Te.getOrCreateInstance(e).toggle(this)})),R(Te),b(Te);const ke="coreui.navigation",Le=`.${ke}`,Oe={activeLinksExact:!0,groupsAutoCollapse:!0},Ne={activeLinksExact:"boolean",groupsAutoCollapse:"(string|boolean)"},Ie="active",De="show",Se="nav-group-toggle",$e=`click${Le}.data-api`,xe=`load${Le}.data-api`,Me=".nav-group",Pe=".nav-group-items",je=".nav-group-toggle";class ze extends V{constructor(t,e){super(t),this._config=this._getConfig(e),this._setActiveLink(),this._addEventListeners(),F.set(t,ke,this)}static get Default(){return Oe}static get DATA_KEY(){return ke}static get DefaultType(){return Ne}static get NAME(){return"navigation"}_getConfig(t){return{...Oe,...B.getDataAttributes(this._element),..."object"==typeof t?t:{}}}_setActiveLink(){for(const t of Array.from(this._element.querySelectorAll(".nav-link"))){if(t.classList.contains(Se))continue;let e=String(window.location);const i=/\?./,s=/#./;(/\?.*=/.test(e)||i.test(e))&&(e=e.split("?")[0]),s.test(e)&&(e=e.split("#")[0]),this._config.activeLinksExact&&t.href===e&&(t.classList.add(Ie),Array.from(this._getParents(t,Me)).forEach((t=>{t.classList.add(De),t.setAttribute("aria-expanded",!0)}))),!this._config.activeLinksExact&&t.href.startsWith(e)&&(t.classList.add(Ie),Array.from(this._getParents(t,Me)).forEach((t=>{t.classList.add(De),t.setAttribute("aria-expanded",!0)})))}}_getParents(t,e){const i=[];for(;t&&t!==document;t=t.parentNode)e?t.matches(e)&&i.push(t):i.push(t);return i}_getAllSiblings(t,e){const i=[];t=t.parentNode.firstChild;do{3!==t.nodeType&&8!==t.nodeType&&(e&&!e(t)||i.push(t))}while(t=t.nextSibling);return i}_getChildren(t,e){const i=[];for(;t;t=t.nextSibling)1===t.nodeType&&t!==e&&i.push(t);return i}_getSiblings(t,e){return this._getChildren(t.parentNode.firstChild,t).filter(e)}_slideDown(t){t.style.height="auto";const e=t.clientHeight;t.style.height="0px",setTimeout((()=>{t.style.height=`${e}px`}),0),this._queueCallback((()=>{t.style.height="auto"}),t,!0)}_slideUp(t,e){const i=t.clientHeight;t.style.height=`${i}px`,setTimeout((()=>{t.style.height="0px"}),0),this._queueCallback((()=>{"function"==typeof e&&e()}),t,!0)}_toggleGroupItems(t){let e=t.target;e.classList.contains(Se)||(e=e.closest(je));const i=t=>Boolean(t.classList.contains("nav-group")&&t.classList.contains(De));if(!0===this._config.groupsAutoCollapse)for(const t of this._getSiblings(e.parentNode,i))this._slideUp(Y.findOne(Pe,t),(()=>{t.classList.remove(De),t.setAttribute("aria-expanded",!1)}));e.parentNode.classList.contains(De)?this._slideUp(Y.findOne(Pe,e.parentNode),(()=>{e.parentNode.classList.remove(De),e.parentNode.setAttribute("aria-expanded",!1)})):(e.parentNode.classList.add(De),e.parentNode.setAttribute("aria-expanded",!0),this._slideDown(Y.findOne(Pe,e.parentNode)))}_addEventListeners(){j.on(this._element,$e,je,(t=>{t.preventDefault(),this._toggleGroupItems(t,this)}))}static navigationInterface(t,e){const i=ze.getOrCreateInstance(t,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}static jQueryInterface(t){return this.each((function(){ze.navigationInterface(this,t)}))}}j.on(window,xe,(()=>{for(const t of Array.from(document.querySelectorAll('[data-coreui="navigation"]')))ze.navigationInterface(t)})),b(ze);const Fe=".coreui.offcanvas",He=`load${Fe}.data-api`,qe="show",Be="showing",We="hiding",Ve=".offcanvas.show",Re=`show${Fe}`,Ke=`shown${Fe}`,Qe=`hide${Fe}`,Ue=`hidePrevented${Fe}`,Ye=`hidden${Fe}`,Xe=`resize${Fe}`,Ge=`click${Fe}.data-api`,Je=`keydown.dismiss${Fe}`,Ze={backdrop:!0,keyboard:!0,scroll:!1},ti={backdrop:"(boolean|string)",keyboard:"boolean",scroll:"boolean"};class ei extends V{constructor(t,e){super(t,e),this._isShown=!1,this._backdrop=this._initializeBackDrop(),this._focustrap=this._initializeFocusTrap(),this._addEventListeners()}static get Default(){return Ze}static get DefaultType(){return ti}static get NAME(){return"offcanvas"}toggle(t){return this._isShown?this.hide():this.show(t)}show(t){this._isShown||j.trigger(this._element,Re,{relatedTarget:t}).defaultPrevented||(this._isShown=!0,this._backdrop.show(),this._config.scroll||(new oe).hide(),this._element.setAttribute("aria-modal",!0),this._element.setAttribute("role","dialog"),this._element.classList.add(Be),this._queueCallback((()=>{this._config.scroll||this._focustrap.activate(),this._element.classList.add(qe),this._element.classList.remove(Be),j.trigger(this._element,Ke,{relatedTarget:t})}),this._element,!0))}hide(){this._isShown&&(j.trigger(this._element,Qe).defaultPrevented||(this._focustrap.deactivate(),this._element.blur(),this._isShown=!1,this._element.classList.add(We),this._backdrop.hide(),this._queueCallback((()=>{this._element.classList.remove(qe,We),this._element.removeAttribute("aria-modal"),this._element.removeAttribute("role"),this._config.scroll||(new oe).reset(),j.trigger(this._element,Ye)}),this._element,!0)))}dispose(){this._backdrop.dispose(),this._focustrap.deactivate(),super.dispose()}_initializeBackDrop(){const t=Boolean(this._config.backdrop);return new he({className:"offcanvas-backdrop",isVisible:t,isAnimated:!0,rootElement:this._element.parentNode,clickCallback:t?()=>{"static"!==this._config.backdrop?this.hide():j.trigger(this._element,Ue)}:null})}_initializeFocusTrap(){return new me({trapElement:this._element})}_addEventListeners(){j.on(this._element,Je,(t=>{"Escape"===t.key&&(this._config.keyboard?this.hide():j.trigger(this._element,Ue))}))}static jQueryInterface(t){return this.each((function(){const e=ei.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}j.on(document,Ge,'[data-coreui-toggle="offcanvas"]',(function(t){const e=r(this);if(["A","AREA"].includes(this.tagName)&&t.preventDefault(),d(this))return;j.one(e,Ye,(()=>{h(this)&&this.focus()}));const i=Y.findOne(Ve);i&&i!==e&&ei.getInstance(i).hide(),ei.getOrCreateInstance(e).toggle(this)})),j.on(window,He,(()=>{for(const t of Y.find(Ve))ei.getOrCreateInstance(t).show()})),j.on(window,Xe,(()=>{for(const t of Y.find("[aria-modal][class*=show][class*=offcanvas-]"))"fixed"!==getComputedStyle(t).position&&ei.getOrCreateInstance(t).hide()})),R(ei),b(ei);const ii=new Set(["background","cite","href","itemtype","longdesc","poster","src","xlink:href"]),si=/^(?:(?:https?|mailto|ftp|tel|file|sms):|[^#&/:?]*(?:[#/?]|$))/i,ni=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[\d+/a-z]+=*$/i,oi=(t,e)=>{const i=t.nodeName.toLowerCase();return e.includes(i)?!ii.has(i)||Boolean(si.test(t.nodeValue)||ni.test(t.nodeValue)):e.filter((t=>t instanceof RegExp)).some((t=>t.test(i)))},ri={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],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:[]},ai={allowList:ri,content:{},extraClass:"",html:!1,sanitize:!0,sanitizeFn:null,template:"<div></div>"},li={allowList:"object",content:"object",extraClass:"(string|function)",html:"boolean",sanitize:"boolean",sanitizeFn:"(null|function)",template:"string"},ci={entry:"(string|element|function|null)",selector:"(string|element)"};class hi extends W{constructor(t){super(),this._config=this._getConfig(t)}static get Default(){return ai}static get DefaultType(){return li}static get NAME(){return"TemplateFactory"}getContent(){return Object.values(this._config.content).map((t=>this._resolvePossibleFunction(t))).filter(Boolean)}hasContent(){return this.getContent().length>0}changeContent(t){return this._checkContent(t),this._config.content={...this._config.content,...t},this}toHtml(){const t=document.createElement("div");t.innerHTML=this._maybeSanitize(this._config.template);for(const[e,i]of Object.entries(this._config.content))this._setContent(t,i,e);const e=t.children[0],i=this._resolvePossibleFunction(this._config.extraClass);return i&&e.classList.add(...i.split(" ")),e}_typeCheckConfig(t){super._typeCheckConfig(t),this._checkContent(t.content)}_checkContent(t){for(const[e,i]of Object.entries(t))super._typeCheckConfig({selector:e,entry:i},ci)}_setContent(t,e,i){const s=Y.findOne(i,t);s&&((e=this._resolvePossibleFunction(e))?l(e)?this._putElementInTemplate(c(e),s):this._config.html?s.innerHTML=this._maybeSanitize(e):s.textContent=e:s.remove())}_maybeSanitize(t){return this._config.sanitize?function(t,e,i){if(!t.length)return t;if(i&&"function"==typeof i)return i(t);const s=(new window.DOMParser).parseFromString(t,"text/html"),n=[].concat(...s.body.querySelectorAll("*"));for(const t of n){const i=t.nodeName.toLowerCase();if(!Object.keys(e).includes(i)){t.remove();continue}const s=[].concat(...t.attributes),n=[].concat(e["*"]||[],e[i]||[]);for(const e of s)oi(e,n)||t.removeAttribute(e.nodeName)}return s.body.innerHTML}(t,this._config.allowList,this._config.sanitizeFn):t}_resolvePossibleFunction(t){return"function"==typeof t?t(this):t}_putElementInTemplate(t,e){if(this._config.html)return e.innerHTML="",void e.append(t);e.textContent=t.textContent}}const di=new Set(["sanitize","allowList","sanitizeFn"]),ui="fade",_i="show",gi=".modal",fi="hide.coreui.modal",pi="hover",mi="focus",bi={AUTO:"auto",TOP:"top",RIGHT:m()?"left":"right",BOTTOM:"bottom",LEFT:m()?"right":"left"},vi={allowList:ri,animation:!0,boundary:"clippingParents",container:!1,customClass:"",delay:0,fallbackPlacements:["top","right","bottom","left"],html:!1,offset:[0,0],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"},yi={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 wi extends V{constructor(t,e){if(void 0===i)throw new TypeError("Bootstrap's tooltips require Popper (https://popper.js.org)");super(t,e),this._isEnabled=!0,this._timeout=0,this._isHovered=!1,this._activeTrigger={},this._popper=null,this._templateFactory=null,this.tip=null,this._setListeners()}static get Default(){return vi}static get DefaultType(){return yi}static get NAME(){return"tooltip"}enable(){this._isEnabled=!0}disable(){this._isEnabled=!1}toggleEnabled(){this._isEnabled=!this._isEnabled}toggle(t){if(this._isEnabled){if(t){const e=this._initializeOnDelegatedTarget(t);return e._activeTrigger.click=!e._activeTrigger.click,void(e._isWithActiveTrigger()?e._enter():e._leave())}this._isShown()?this._leave():this._enter()}}dispose(){clearTimeout(this._timeout),j.off(this._element.closest(gi),fi,this._hideModalHandler),this.tip&&this.tip.remove(),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 t=j.trigger(this._element,this.constructor.eventName("show")),e=(u(this._element)||this._element.ownerDocument.documentElement).contains(this._element);if(t.defaultPrevented||!e)return;const i=this._getTipElement();this._element.setAttribute("aria-describedby",i.getAttribute("id"));const{container:s}=this._config;if(this._element.ownerDocument.documentElement.contains(this.tip)||(s.append(i),j.trigger(this._element,this.constructor.eventName("inserted"))),this._popper?this._popper.update():this._createPopper(i),i.classList.add(_i),"ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))j.on(t,"mouseover",_);this._queueCallback((()=>{const t=this._isHovered;this._isHovered=!1,j.trigger(this._element,this.constructor.eventName("shown")),t&&this._leave()}),this.tip,this._isAnimated())}hide(){if(!this._isShown())return;if(j.trigger(this._element,this.constructor.eventName("hide")).defaultPrevented)return;const t=this._getTipElement();if(t.classList.remove(_i),"ontouchstart"in document.documentElement)for(const t of[].concat(...document.body.children))j.off(t,"mouseover",_);this._activeTrigger.click=!1,this._activeTrigger.focus=!1,this._activeTrigger.hover=!1,this._isHovered=!1,this._queueCallback((()=>{this._isWithActiveTrigger()||(this._isHovered||t.remove(),this._element.removeAttribute("aria-describedby"),j.trigger(this._element,this.constructor.eventName("hidden")),this._disposePopper())}),this.tip,this._isAnimated())}update(){this._popper&&this._popper.update()}_isWithContent(){return Boolean(this._getTitle())}_getTipElement(){return this.tip||(this.tip=this._createTipElement(this._getContentForTemplate())),this.tip}_createTipElement(t){const e=this._getTemplateFactory(t).toHtml();if(!e)return null;e.classList.remove(ui,_i),e.classList.add(`bs-${this.constructor.NAME}-auto`);const i=(t=>{do{t+=Math.floor(1e6*Math.random())}while(document.getElementById(t));return t})(this.constructor.NAME).toString();return e.setAttribute("id",i),this._isAnimated()&&e.classList.add(ui),e}setContent(t){let e=!1;this.tip&&(e=this._isShown(),this.tip.remove(),this.tip=null),this._disposePopper(),this.tip=this._createTipElement(t),e&&this.show()}_getTemplateFactory(t){return this._templateFactory?this._templateFactory.changeContent(t):this._templateFactory=new hi({...this._config,content:t,extraClass:this._resolvePossibleFunction(this._config.customClass)}),this._templateFactory}_getContentForTemplate(){return{".tooltip-inner":this._getTitle()}}_getTitle(){return this._config.title}_initializeOnDelegatedTarget(t){return this.constructor.getOrCreateInstance(t.delegateTarget,this._getDelegateConfig())}_isAnimated(){return this._config.animation||this.tip&&this.tip.classList.contains(ui)}_isShown(){return this.tip&&this.tip.classList.contains(_i)}_createPopper(t){const e="function"==typeof this._config.placement?this._config.placement.call(this,t,this._element):this._config.placement,s=bi[e.toUpperCase()];this._popper=i.createPopper(this._element,t,this._getPopperConfig(s))}_getOffset(){const{offset:t}=this._config;return"string"==typeof t?t.split(",").map((t=>Number.parseInt(t,10))):"function"==typeof t?e=>t(e,this._element):t}_resolvePossibleFunction(t){return"function"==typeof t?t.call(this._element):t}_getPopperConfig(t){const e={placement:t,modifiers:[{name:"flip",options:{fallbackPlacements:this._config.fallbackPlacements}},{name:"offset",options:{offset:this._getOffset()}},{name:"preventOverflow",options:{boundary:this._config.boundary}},{name:"arrow",options:{element:`.${this.constructor.NAME}-arrow`}},{name:"preSetPlacement",enabled:!0,phase:"beforeMain",fn:t=>{this._getTipElement().setAttribute("data-popper-placement",t.state.placement)}}]};return{...e,..."function"==typeof this._config.popperConfig?this._config.popperConfig(e):this._config.popperConfig}}_setListeners(){const t=this._config.trigger.split(" ");for(const e of t)if("click"===e)j.on(this._element,this.constructor.eventName("click"),this._config.selector,(t=>this.toggle(t)));else if("manual"!==e){const t=e===pi?this.constructor.eventName("mouseenter"):this.constructor.eventName("focusin"),i=e===pi?this.constructor.eventName("mouseleave"):this.constructor.eventName("focusout");j.on(this._element,t,this._config.selector,(t=>{const e=this._initializeOnDelegatedTarget(t);e._activeTrigger["focusin"===t.type?mi:pi]=!0,e._enter()})),j.on(this._element,i,this._config.selector,(t=>{const e=this._initializeOnDelegatedTarget(t);e._activeTrigger["focusout"===t.type?mi:pi]=e._element.contains(t.relatedTarget),e._leave()}))}this._hideModalHandler=()=>{this._element&&this.hide()},j.on(this._element.closest(gi),fi,this._hideModalHandler),this._config.selector?this._config={...this._config,trigger:"manual",selector:""}:this._fixTitle()}_fixTitle(){const t=this._config.originalTitle;t&&(this._element.getAttribute("aria-label")||this._element.textContent||this._element.setAttribute("aria-label",t),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(t,e){clearTimeout(this._timeout),this._timeout=setTimeout(t,e)}_isWithActiveTrigger(){return Object.values(this._activeTrigger).includes(!0)}_getConfig(t){const e=B.getDataAttributes(this._element);for(const t of Object.keys(e))di.has(t)&&delete e[t];return t={...e,..."object"==typeof t&&t?t:{}},t=this._mergeConfigObj(t),t=this._configAfterMerge(t),this._typeCheckConfig(t),t}_configAfterMerge(t){return t.container=!1===t.container?document.body:c(t.container),"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t.originalTitle=this._element.getAttribute("title")||"",t.title=this._resolvePossibleFunction(t.title)||t.originalTitle,"number"==typeof t.title&&(t.title=t.title.toString()),"number"==typeof t.content&&(t.content=t.content.toString()),t}_getDelegateConfig(){const t={};for(const e in this._config)this.constructor.Default[e]!==this._config[e]&&(t[e]=this._config[e]);return t}_disposePopper(){this._popper&&(this._popper.destroy(),this._popper=null)}static jQueryInterface(t){return this.each((function(){const e=wi.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}b(wi);const Ai={...wi.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"},Ci={...wi.DefaultType,content:"(null|string|element|function)"};class Ei extends wi{static get Default(){return Ai}static get DefaultType(){return Ci}static get NAME(){return"popover"}_isWithContent(){return this._getTitle()||this._getContent()}_getContentForTemplate(){return{".popover-header":this._getTitle(),".popover-body":this._getContent()}}_getContent(){return this._resolvePossibleFunction(this._config.content)}static jQueryInterface(t){return this.each((function(){const e=Ei.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t]()}}))}}b(Ei);const Ti=".coreui.scrollspy",ki=`activate${Ti}`,Li=`click${Ti}`,Oi=`load${Ti}.data-api`,Ni="active",Ii="[href]",Di={offset:null,rootMargin:"0px 0px -25%",smoothScroll:!1,target:null},Si={offset:"(number|null)",rootMargin:"string",smoothScroll:"boolean",target:"element"};class $i extends V{constructor(t,e){super(t,e),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 Di}static get DefaultType(){return Si}static get NAME(){return"scrollspy"}refresh(){this._initializeTargetsAndObservables(),this._maybeEnableSmoothScroll(),this._observer?this._observer.disconnect():this._observer=this._getNewObserver();for(const t of this._observableSections.values())this._observer.observe(t)}dispose(){this._observer.disconnect(),super.dispose()}_configAfterMerge(t){return t.target=c(t.target)||document.body,t}_maybeEnableSmoothScroll(){this._config.smoothScroll&&(j.off(this._config.target,Li),j.on(this._config.target,Li,Ii,(t=>{const e=this._observableSections.get(t.target.hash);if(e){t.preventDefault();const i=this._rootElement||window,s=e.offsetTop-this._element.offsetTop;if(i.scrollTo)return void i.scrollTo({top:s,behavior:"smooth"});i.scrollTop=s}})))}_getNewObserver(){const t={root:this._rootElement,threshold:[.1,.5,1],rootMargin:this._getRootMargin()};return new IntersectionObserver((t=>this._observerCallback(t)),t)}_observerCallback(t){const e=t=>this._targetLinks.get(`#${t.target.id}`),i=t=>{this._previousScrollData.visibleEntryTop=t.target.offsetTop,this._process(e(t))},s=(this._rootElement||document.documentElement).scrollTop,n=s>=this._previousScrollData.parentScrollTop;this._previousScrollData.parentScrollTop=s;for(const o of t){if(!o.isIntersecting){this._activeTarget=null,this._clearActiveClass(e(o));continue}const t=o.target.offsetTop>=this._previousScrollData.visibleEntryTop;if(n&&t){if(i(o),!s)return}else n||t||i(o)}}_getRootMargin(){return this._config.offset?`${this._config.offset}px 0px -30%`:this._config.rootMargin}_initializeTargetsAndObservables(){this._targetLinks=new Map,this._observableSections=new Map;const t=Y.find(Ii,this._config.target);for(const e of t){if(!e.hash||d(e))continue;const t=Y.findOne(e.hash,this._element);h(t)&&(this._targetLinks.set(e.hash,e),this._observableSections.set(e.hash,t))}}_process(t){this._activeTarget!==t&&(this._clearActiveClass(this._config.target),this._activeTarget=t,t.classList.add(Ni),this._activateParents(t),j.trigger(this._element,ki,{relatedTarget:t}))}_activateParents(t){if(t.classList.contains("dropdown-item"))Y.findOne(".dropdown-toggle",t.closest(".dropdown")).classList.add(Ni);else for(const e of Y.parents(t,".nav, .list-group"))for(const t of Y.prev(e,".nav-link, .nav-item > .nav-link, .list-group-item"))t.classList.add(Ni)}_clearActiveClass(t){t.classList.remove(Ni);const e=Y.find("[href].active",t);for(const t of e)t.classList.remove(Ni)}static jQueryInterface(t){return this.each((function(){const e=$i.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}}))}}j.on(window,Oi,(()=>{for(const t of Y.find('[data-coreui-spy="scroll"]'))$i.getOrCreateInstance(t)})),b($i);const xi=".coreui.sidebar",Mi={},Pi={},ji="hide",zi="show",Fi="sidebar-narrow",Hi="sidebar-narrow-unfoldable",qi=`hide${xi}`,Bi=`hidden${xi}`,Wi=`show${xi}`,Vi=`shown${xi}`,Ri=`click${xi}.data-api`,Ki=`load${xi}.data-api`,Qi=".sidebar";class Ui extends V{constructor(t,e){super(t),this._config=this._getConfig(e),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 Mi}static get DefaultType(){return Pi}static get NAME(){return"sidebar"}show(){j.trigger(this._element,Wi),this._element.classList.contains(ji)&&this._element.classList.remove(ji),this._isMobile()&&(this._element.classList.add(zi),this._backdrop.show(),(new oe).hide()),this._queueCallback((()=>{!0===this._isVisible()&&(this._show=!0,(this._isMobile()||this._isOverlaid())&&this._addClickOutListener(),j.trigger(this._element,Vi))}),this._element,!0)}hide(){j.trigger(this._element,qi),this._element.classList.contains(zi)&&this._element.classList.remove(zi),this._isMobile()?(this._backdrop.hide(),(new oe).reset()):this._element.classList.add(ji),this._queueCallback((()=>{!1===this._isVisible()&&(this._show=!1,(this._isMobile()||this._isOverlaid())&&this._removeClickOutListener(),j.trigger(this._element,Bi))}),this._element,!0)}toggle(){this._isVisible()?this.hide():this.show()}narrow(){this._isMobile()||(this._addClassName(Fi),this._narrow=!0)}unfoldable(){this._isMobile()||(this._addClassName(Hi),this._unfoldable=!0)}reset(){this._isMobile()||(this._narrow&&(this._element.classList.remove(Fi),this._narrow=!1),this._unfoldable&&(this._element.classList.remove(Hi),this._unfoldable=!1))}toggleNarrow(){this._narrow?this.reset():this.narrow()}toggleUnfoldable(){this._unfoldable?this.reset():this.unfoldable()}_getConfig(t){return{...Mi,...B.getDataAttributes(this._element),..."object"==typeof t?t:{}}}_initializeBackDrop(){return new he({className:"sidebar-backdrop",isVisible:this._isMobile(),isAnimated:!0,rootElement:this._element.parentNode,clickCallback:()=>this.hide()})}_isMobile(){return Boolean(window.getComputedStyle(this._element,null).getPropertyValue("--cui-is-mobile"))}_isNarrow(){return this._element.classList.contains(Fi)}_isOverlaid(){return this._element.classList.contains("sidebar-overlaid")}_isUnfoldable(){return this._element.classList.contains(Hi)}_isVisible(){const t=this._element.getBoundingClientRect();return t.top>=0&&t.left>=0&&Math.floor(t.bottom)<=(window.innerHeight||document.documentElement.clientHeight)&&Math.floor(t.right)<=(window.innerWidth||document.documentElement.clientWidth)}_addClassName(t){this._element.classList.add(t)}_clickOutListener(t,e){null===t.target.closest(Qi)&&(t.preventDefault(),t.stopPropagation(),e.hide())}_addClickOutListener(){j.on(document,Ri,(t=>{this._clickOutListener(t,this)}))}_removeClickOutListener(){j.off(document,Ri)}_addEventListeners(){this._mobile&&this._show&&this._addClickOutListener(),this._overlaid&&this._show&&this._addClickOutListener(),j.on(this._element,Ri,"[data-coreui-toggle]",(t=>{t.preventDefault();const e=B.getDataAttribute(t.target,"toggle");"narrow"===e&&this.toggleNarrow(),"unfoldable"===e&&this.toggleUnfoldable()})),j.on(this._element,Ri,'[data-coreui-close="sidebar"]',(t=>{t.preventDefault(),this.hide()})),j.on(window,"resize",(()=>{this._isMobile()&&this._isVisible()&&(this.hide(),this._backdrop=this._initializeBackDrop())}))}static sidebarInterface(t,e){const i=Ui.getOrCreateInstance(t,e);if("string"==typeof e){if(void 0===i[e])throw new TypeError(`No method named "${e}"`);i[e]()}}static jQueryInterface(t){return this.each((function(){Ui.sidebarInterface(this,t)}))}}j.on(window,Ki,(()=>{for(const t of Array.from(document.querySelectorAll(Qi)))Ui.sidebarInterface(t)})),b(Ui);const Yi="ArrowLeft",Xi="ArrowRight",Gi="ArrowUp",Ji="ArrowDown",Zi="active",ts="fade",es="show",is='[data-coreui-toggle="tab"], [data-coreui-toggle="pill"], [data-coreui-toggle="list"]',ss=`.nav-link:not(.dropdown-toggle), .list-group-item:not(.dropdown-toggle), [role="tab"]:not(.dropdown-toggle), ${is}`;class ns extends V{constructor(t){super(t),this._parent=this._element.closest('.list-group, .nav, [role="tablist"]'),this._parent&&(this._setInitialAttributes(this._parent,this._getChildren()),j.on(this._element,"keydown.coreui.tab",(t=>this._keydown(t))))}static get NAME(){return"tab"}show(){const t=this._element;if(this._elemIsActive(t))return;const e=this._getActiveElem(),i=e?j.trigger(e,"hide.coreui.tab",{relatedTarget:t}):null;j.trigger(t,"show.coreui.tab",{relatedTarget:e}).defaultPrevented||i&&i.defaultPrevented||(this._deactivate(e,t),this._activate(t,e))}_activate(t,e){if(!t)return;t.classList.add(Zi),this._activate(r(t));const i=t.classList.contains(ts);this._queueCallback((()=>{i&&t.classList.add(es),"tab"===t.getAttribute("role")&&(t.focus(),t.removeAttribute("tabindex"),t.setAttribute("aria-selected",!0),this._toggleDropDown(t,!0),j.trigger(t,"shown.coreui.tab",{relatedTarget:e}))}),t,i)}_deactivate(t,e){if(!t)return;t.classList.remove(Zi),t.blur(),this._deactivate(r(t));const i=t.classList.contains(ts);this._queueCallback((()=>{i&&t.classList.remove(es),"tab"===t.getAttribute("role")&&(t.setAttribute("aria-selected",!1),t.setAttribute("tabindex","-1"),this._toggleDropDown(t,!1),j.trigger(t,"hidden.coreui.tab",{relatedTarget:e}))}),t,i)}_keydown(t){if(![Yi,Xi,Gi,Ji].includes(t.key))return;t.stopPropagation(),t.preventDefault();const e=[Xi,Ji].includes(t.key),i=w(this._getChildren().filter((t=>!d(t))),t.target,e,!0);i&&ns.getOrCreateInstance(i).show()}_getChildren(){return Y.find(ss,this._parent)}_getActiveElem(){return this._getChildren().find((t=>this._elemIsActive(t)))||null}_setInitialAttributes(t,e){this._setAttributeIfNotExists(t,"role","tablist");for(const t of e)this._setInitialAttributesOnChild(t)}_setInitialAttributesOnChild(t){t=this._getInnerElement(t);const e=this._elemIsActive(t),i=this._getOuterElement(t);t.setAttribute("aria-selected",e),i!==t&&this._setAttributeIfNotExists(i,"role","presentation"),e||t.setAttribute("tabindex","-1"),this._setAttributeIfNotExists(t,"role","tab"),this._setInitialAttributesOnTargetPanel(t)}_setInitialAttributesOnTargetPanel(t){const e=r(t);e&&(this._setAttributeIfNotExists(e,"role","tabpanel"),t.id&&this._setAttributeIfNotExists(e,"aria-labelledby",`#${t.id}`))}_toggleDropDown(t,e){const i=this._getOuterElement(t);if(!i.classList.contains("dropdown"))return;const s=(t,s)=>{const n=Y.findOne(t,i);n&&n.classList.toggle(s,e)};s(".dropdown-toggle",Zi),s(".dropdown-menu",es),s(".dropdown-item",Zi),i.setAttribute("aria-expanded",e)}_setAttributeIfNotExists(t,e,i){t.hasAttribute(e)||t.setAttribute(e,i)}_elemIsActive(t){return t.classList.contains(Zi)}_getInnerElement(t){return t.matches(ss)?t:Y.findOne(ss,t)}_getOuterElement(t){return t.closest(".nav-item, .list-group-item")||t}static jQueryInterface(t){return this.each((function(){const e=ns.getOrCreateInstance(this);if("string"==typeof t){if(void 0===e[t]||t.startsWith("_")||"constructor"===t)throw new TypeError(`No method named "${t}"`);e[t]()}}))}}j.on(document,"click.coreui.tab",is,(function(t){["A","AREA"].includes(this.tagName)&&t.preventDefault(),d(this)||ns.getOrCreateInstance(this).show()})),j.on(window,"load.coreui.tab",(()=>{for(const t of Y.find('.active[data-coreui-toggle="tab"], .active[data-coreui-toggle="pill"], .active[data-coreui-toggle="list"]'))ns.getOrCreateInstance(t)})),b(ns);const os=".coreui.toast",rs=`mouseover${os}`,as=`mouseout${os}`,ls=`focusin${os}`,cs=`focusout${os}`,hs=`hide${os}`,ds=`hidden${os}`,us=`show${os}`,_s=`shown${os}`,gs="hide",fs="show",ps="showing",ms={animation:"boolean",autohide:"boolean",delay:"number"},bs={animation:!0,autohide:!0,delay:5e3};class vs extends V{constructor(t,e){super(t,e),this._timeout=null,this._hasMouseInteraction=!1,this._hasKeyboardInteraction=!1,this._setListeners()}static get Default(){return bs}static get DefaultType(){return ms}static get NAME(){return"toast"}show(){j.trigger(this._element,us).defaultPrevented||(this._clearTimeout(),this._config.animation&&this._element.classList.add("fade"),this._element.classList.remove(gs),g(this._element),this._element.classList.add(fs,ps),this._queueCallback((()=>{this._element.classList.remove(ps),j.trigger(this._element,_s),this._maybeScheduleHide()}),this._element,this._config.animation))}hide(){this.isShown()&&(j.trigger(this._element,hs).defaultPrevented||(this._element.classList.add(ps),this._queueCallback((()=>{this._element.classList.add(gs),this._element.classList.remove(ps,fs),j.trigger(this._element,ds)}),this._element,this._config.animation)))}dispose(){this._clearTimeout(),this.isShown()&&this._element.classList.remove(fs),super.dispose()}isShown(){return this._element.classList.contains(fs)}_maybeScheduleHide(){this._config.autohide&&(this._hasMouseInteraction||this._hasKeyboardInteraction||(this._timeout=setTimeout((()=>{this.hide()}),this._config.delay)))}_onInteraction(t,e){switch(t.type){case"mouseover":case"mouseout":this._hasMouseInteraction=e;break;case"focusin":case"focusout":this._hasKeyboardInteraction=e}if(e)return void this._clearTimeout();const i=t.relatedTarget;this._element===i||this._element.contains(i)||this._maybeScheduleHide()}_setListeners(){j.on(this._element,rs,(t=>this._onInteraction(t,!0))),j.on(this._element,as,(t=>this._onInteraction(t,!1))),j.on(this._element,ls,(t=>this._onInteraction(t,!0))),j.on(this._element,cs,(t=>this._onInteraction(t,!1)))}_clearTimeout(){clearTimeout(this._timeout),this._timeout=null}static jQueryInterface(t){return this.each((function(){const e=vs.getOrCreateInstance(this,t);if("string"==typeof t){if(void 0===e[t])throw new TypeError(`No method named "${t}"`);e[t](this)}}))}}return R(vs),b(vs),{Alert:K,Button:U,Carousel:mt,Collapse:It,Dropdown:te,Modal:Te,Navigation:ze,OffCanvas:ei,Popover:Ei,ScrollSpy:$i,Sidebar:Ui,Tab:ns,Toast:vs,Tooltip:wi}}));
|
|
7
7
|
//# sourceMappingURL=coreui.min.js.map
|