diff --git a/public/css/app.css b/public/css/app.css index abcb454..85b5626 100644 --- a/public/css/app.css +++ b/public/css/app.css @@ -646,6 +646,10 @@ video { margin-bottom: 1rem; } +.mb-5 { + margin-bottom: 1.25rem; +} + .mb-8 { margin-bottom: 2rem; } @@ -734,6 +738,10 @@ video { max-width: 20rem; } +.max-w-sm { + max-width: 24rem; +} + .flex-grow { flex-grow: 1; } @@ -826,6 +834,10 @@ video { border-top-right-radius: 0.5rem; } +.border { + border-width: 1px; +} + .border-b-2 { border-bottom-width: 2px; } @@ -834,6 +846,11 @@ video { border-style: none; } +.border-gray-300 { + --tw-border-opacity: 1; + border-color: rgb(209 213 219 / var(--tw-border-opacity, 1)); +} + .bg-black { --tw-bg-opacity: 1; background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1)); @@ -849,6 +866,16 @@ video { background-color: rgb(37 99 235 / var(--tw-bg-opacity, 1)); } +.bg-blue-700 { + --tw-bg-opacity: 1; + background-color: rgb(29 78 216 / var(--tw-bg-opacity, 1)); +} + +.bg-gray-50 { + --tw-bg-opacity: 1; + background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1)); +} + .bg-gray-500 { --tw-bg-opacity: 1; background-color: rgb(107 114 128 / var(--tw-bg-opacity, 1)); @@ -869,6 +896,11 @@ video { background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1)); } +.bg-blue-300 { + --tw-bg-opacity: 1; + background-color: rgb(147 197 253 / var(--tw-bg-opacity, 1)); +} + .bg-opacity-40 { --tw-bg-opacity: 0.4; } @@ -898,6 +930,10 @@ video { padding: 0.5rem; } +.p-2\.5 { + padding: 0.625rem; +} + .p-3 { padding: 0.75rem; } @@ -925,6 +961,11 @@ video { padding-right: 1rem; } +.px-5 { + padding-left: 1.25rem; + padding-right: 1.25rem; +} + .px-6 { padding-left: 1.5rem; padding-right: 1.5rem; @@ -950,6 +991,11 @@ video { padding-bottom: 0.5rem; } +.py-2\.5 { + padding-top: 0.625rem; + padding-bottom: 0.625rem; +} + .py-5 { padding-top: 1.25rem; padding-bottom: 1.25rem; @@ -1014,6 +1060,10 @@ video { font-weight: 700; } +.font-medium { + font-weight: 500; +} + .font-normal { font-weight: 400; } @@ -1177,6 +1227,11 @@ video { background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1)); } +.hover\:bg-blue-500:hover { + --tw-bg-opacity: 1; + background-color: rgb(59 130 246 / var(--tw-bg-opacity, 1)); +} + .hover\:bg-opacity-80:hover { --tw-bg-opacity: 0.8; } @@ -1201,6 +1256,11 @@ video { color: rgb(255 255 255 / var(--tw-text-opacity, 1)); } +.focus\:border-blue-500:focus { + --tw-border-opacity: 1; + border-color: rgb(59 130 246 / var(--tw-border-opacity, 1)); +} + .focus\:bg-blue-50:focus { --tw-bg-opacity: 1; background-color: rgb(239 246 255 / var(--tw-bg-opacity, 1)); @@ -1215,6 +1275,27 @@ video { color: rgb(30 58 138 / var(--tw-text-opacity, 1)); } +.focus\:outline-none:focus { + outline: 2px solid transparent; + outline-offset: 2px; +} + +.focus\:ring-4:focus { + --tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color); + --tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(4px + var(--tw-ring-offset-width)) var(--tw-ring-color); + box-shadow: var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000); +} + +.focus\:ring-blue-300:focus { + --tw-ring-opacity: 1; + --tw-ring-color: rgb(147 197 253 / var(--tw-ring-opacity, 1)); +} + +.focus\:ring-blue-500:focus { + --tw-ring-opacity: 1; + --tw-ring-color: rgb(59 130 246 / var(--tw-ring-opacity, 1)); +} + .active\:bg-blue-50:active { --tw-bg-opacity: 1; background-color: rgb(239 246 255 / var(--tw-bg-opacity, 1)); @@ -1242,6 +1323,10 @@ video { } @media (min-width: 640px) { + .sm\:w-auto { + width: auto; + } + .sm\:max-w-lg { max-width: 32rem; } diff --git a/public/js/preline.js b/public/js/preline.js new file mode 100644 index 0000000..1f9a608 --- /dev/null +++ b/public/js/preline.js @@ -0,0 +1,236 @@ +/** + * Bundled by jsDelivr using Rollup v2.79.1 and Terser v5.19.2. + * Original file: /npm/preline@2.6.0/index.js + * + * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files + */ +var t={exports:{}};(function(t,e){!function(e,n){t.exports=n()}(self,(()=>(()=>{var t={170:(t,e,n)=>{n.r(e),n.d(e,{afterMain:()=>S,afterRead:()=>w,afterWrite:()=>I,applyStyles:()=>_,arrow:()=>Z,auto:()=>l,basePlacements:()=>a,beforeMain:()=>b,beforeRead:()=>g,beforeWrite:()=>L,bottom:()=>o,clippingParents:()=>d,computeStyles:()=>nt,createPopper:()=>_t,createPopperBase:()=>Pt,createPopperLite:()=>Bt,detectOverflow:()=>yt,end:()=>u,eventListeners:()=>ot,flip:()=>wt,hide:()=>St,left:()=>s,main:()=>C,modifierPhases:()=>E,offset:()=>Lt,placements:()=>m,popper:()=>p,popperGenerator:()=>At,popperOffsets:()=>xt,preventOverflow:()=>It,read:()=>y,reference:()=>f,right:()=>r,start:()=>c,top:()=>i,variationPlacements:()=>v,viewport:()=>h,write:()=>x});var i="top",o="bottom",r="right",s="left",l="auto",a=[i,o,r,s],c="start",u="end",d="clippingParents",h="viewport",p="popper",f="reference",v=a.reduce((function(t,e){return t.concat([e+"-"+c,e+"-"+u])}),[]),m=[].concat(a,[l]).reduce((function(t,e){return t.concat([e,e+"-"+c,e+"-"+u])}),[]),g="beforeRead",y="read",w="afterRead",b="beforeMain",C="main",S="afterMain",L="beforeWrite",x="write",I="afterWrite",E=[g,y,w,b,C,S,L,x,I];function T(t){return t?(t.nodeName||"").toLowerCase():null}function k(t){if(null==t)return window;if("[object Window]"!==t.toString()){var e=t.ownerDocument;return e&&e.defaultView||window}return t}function O(t){return t instanceof k(t).Element||t instanceof Element}function A(t){return t instanceof k(t).HTMLElement||t instanceof HTMLElement}function P(t){return"undefined"!=typeof ShadowRoot&&(t instanceof k(t).ShadowRoot||t instanceof ShadowRoot)}const _={name:"applyStyles",enabled:!0,phase:"write",fn:function(t){var e=t.state;Object.keys(e.elements).forEach((function(t){var n=e.styles[t]||{},i=e.attributes[t]||{},o=e.elements[t];A(o)&&T(o)&&(Object.assign(o.style,n),Object.keys(i).forEach((function(t){var e=i[t];!1===e?o.removeAttribute(t):o.setAttribute(t,!0===e?"":e)})))}))},effect:function(t){var e=t.state,n={popper:{position:e.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(e.elements.popper.style,n.popper),e.styles=n,e.elements.arrow&&Object.assign(e.elements.arrow.style,n.arrow),function(){Object.keys(e.elements).forEach((function(t){var i=e.elements[t],o=e.attributes[t]||{},r=Object.keys(e.styles.hasOwnProperty(t)?e.styles[t]:n[t]).reduce((function(t,e){return t[e]="",t}),{});A(i)&&T(i)&&(Object.assign(i.style,r),Object.keys(o).forEach((function(t){i.removeAttribute(t)})))}))}},requires:["computeStyles"]};function B(t){return t.split("-")[0]}var D=Math.max,M=Math.min,$=Math.round;function q(){var t=navigator.userAgentData;return null!=t&&t.brands&&Array.isArray(t.brands)?t.brands.map((function(t){return t.brand+"/"+t.version})).join(" "):navigator.userAgent}function H(){return!/^((?!chrome|android).)*safari/i.test(q())}function N(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!1);var i=t.getBoundingClientRect(),o=1,r=1;e&&A(t)&&(o=t.offsetWidth>0&&$(i.width)/t.offsetWidth||1,r=t.offsetHeight>0&&$(i.height)/t.offsetHeight||1);var s=(O(t)?k(t):window).visualViewport,l=!H()&&n,a=(i.left+(l&&s?s.offsetLeft:0))/o,c=(i.top+(l&&s?s.offsetTop:0))/r,u=i.width/o,d=i.height/r;return{width:u,height:d,top:c,right:a+u,bottom:c+d,left:a,x:a,y:c}}function j(t){var e=N(t),n=t.offsetWidth,i=t.offsetHeight;return Math.abs(e.width-n)<=1&&(n=e.width),Math.abs(e.height-i)<=1&&(i=e.height),{x:t.offsetLeft,y:t.offsetTop,width:n,height:i}}function F(t,e){var n=e.getRootNode&&e.getRootNode();if(t.contains(e))return!0;if(n&&P(n)){var i=e;do{if(i&&t.isSameNode(i))return!0;i=i.parentNode||i.host}while(i)}return!1}function V(t){return k(t).getComputedStyle(t)}function R(t){return["table","td","th"].indexOf(T(t))>=0}function z(t){return((O(t)?t.ownerDocument:t.document)||window.document).documentElement}function W(t){return"html"===T(t)?t:t.assignedSlot||t.parentNode||(P(t)?t.host:null)||z(t)}function U(t){return A(t)&&"fixed"!==V(t).position?t.offsetParent:null}function Q(t){for(var e=k(t),n=U(t);n&&R(n)&&"static"===V(n).position;)n=U(n);return n&&("html"===T(n)||"body"===T(n)&&"static"===V(n).position)?e:n||function(t){var e=/firefox/i.test(q());if(/Trident/i.test(q())&&A(t)&&"fixed"===V(t).position)return null;var n=W(t);for(P(n)&&(n=n.host);A(n)&&["html","body"].indexOf(T(n))<0;){var i=V(n);if("none"!==i.transform||"none"!==i.perspective||"paint"===i.contain||-1!==["transform","perspective"].indexOf(i.willChange)||e&&"filter"===i.willChange||e&&i.filter&&"none"!==i.filter)return n;n=n.parentNode}return null}(t)||e}function J(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function K(t,e,n){return D(t,M(e,n))}function X(t){return Object.assign({},{top:0,right:0,bottom:0,left:0},t)}function Y(t,e){return e.reduce((function(e,n){return e[n]=t,e}),{})}const Z={name:"arrow",enabled:!0,phase:"main",fn:function(t){var e,n=t.state,l=t.name,c=t.options,u=n.elements.arrow,d=n.modifiersData.popperOffsets,h=B(n.placement),p=J(h),f=[s,r].indexOf(h)>=0?"height":"width";if(u&&d){var v=function(t,e){return X("number"!=typeof(t="function"==typeof t?t(Object.assign({},e.rects,{placement:e.placement})):t)?t:Y(t,a))}(c.padding,n),m=j(u),g="y"===p?i:s,y="y"===p?o:r,w=n.rects.reference[f]+n.rects.reference[p]-d[p]-n.rects.popper[f],b=d[p]-n.rects.reference[p],C=Q(u),S=C?"y"===p?C.clientHeight||0:C.clientWidth||0:0,L=w/2-b/2,x=v[g],I=S-m[f]-v[y],E=S/2-m[f]/2+L,T=K(x,E,I),k=p;n.modifiersData[l]=((e={})[k]=T,e.centerOffset=T-E,e)}},effect:function(t){var e=t.state,n=t.options.element,i=void 0===n?"[data-popper-arrow]":n;null!=i&&("string"!=typeof i||(i=e.elements.popper.querySelector(i)))&&F(e.elements.popper,i)&&(e.elements.arrow=i)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function G(t){return t.split("-")[1]}var tt={top:"auto",right:"auto",bottom:"auto",left:"auto"};function et(t){var e,n=t.popper,l=t.popperRect,a=t.placement,c=t.variation,d=t.offsets,h=t.position,p=t.gpuAcceleration,f=t.adaptive,v=t.roundOffsets,m=t.isFixed,g=d.x,y=void 0===g?0:g,w=d.y,b=void 0===w?0:w,C="function"==typeof v?v({x:y,y:b}):{x:y,y:b};y=C.x,b=C.y;var S=d.hasOwnProperty("x"),L=d.hasOwnProperty("y"),x=s,I=i,E=window;if(f){var T=Q(n),O="clientHeight",A="clientWidth";if(T===k(n)&&"static"!==V(T=z(n)).position&&"absolute"===h&&(O="scrollHeight",A="scrollWidth"),a===i||(a===s||a===r)&&c===u)I=o,b-=(m&&T===E&&E.visualViewport?E.visualViewport.height:T[O])-l.height,b*=p?1:-1;if(a===s||(a===i||a===o)&&c===u)x=r,y-=(m&&T===E&&E.visualViewport?E.visualViewport.width:T[A])-l.width,y*=p?1:-1}var P,_=Object.assign({position:h},f&&tt),B=!0===v?function(t,e){var n=t.x,i=t.y,o=e.devicePixelRatio||1;return{x:$(n*o)/o||0,y:$(i*o)/o||0}}({x:y,y:b},k(n)):{x:y,y:b};return y=B.x,b=B.y,p?Object.assign({},_,((P={})[I]=L?"0":"",P[x]=S?"0":"",P.transform=(E.devicePixelRatio||1)<=1?"translate("+y+"px, "+b+"px)":"translate3d("+y+"px, "+b+"px, 0)",P)):Object.assign({},_,((e={})[I]=L?b+"px":"",e[x]=S?y+"px":"",e.transform="",e))}const nt={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(t){var e=t.state,n=t.options,i=n.gpuAcceleration,o=void 0===i||i,r=n.adaptive,s=void 0===r||r,l=n.roundOffsets,a=void 0===l||l,c={placement:B(e.placement),variation:G(e.placement),popper:e.elements.popper,popperRect:e.rects.popper,gpuAcceleration:o,isFixed:"fixed"===e.options.strategy};null!=e.modifiersData.popperOffsets&&(e.styles.popper=Object.assign({},e.styles.popper,et(Object.assign({},c,{offsets:e.modifiersData.popperOffsets,position:e.options.strategy,adaptive:s,roundOffsets:a})))),null!=e.modifiersData.arrow&&(e.styles.arrow=Object.assign({},e.styles.arrow,et(Object.assign({},c,{offsets:e.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:a})))),e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-placement":e.placement})},data:{}};var it={passive:!0};const ot={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(t){var e=t.state,n=t.instance,i=t.options,o=i.scroll,r=void 0===o||o,s=i.resize,l=void 0===s||s,a=k(e.elements.popper),c=[].concat(e.scrollParents.reference,e.scrollParents.popper);return r&&c.forEach((function(t){t.addEventListener("scroll",n.update,it)})),l&&a.addEventListener("resize",n.update,it),function(){r&&c.forEach((function(t){t.removeEventListener("scroll",n.update,it)})),l&&a.removeEventListener("resize",n.update,it)}},data:{}};var rt={left:"right",right:"left",bottom:"top",top:"bottom"};function st(t){return t.replace(/left|right|bottom|top/g,(function(t){return rt[t]}))}var lt={start:"end",end:"start"};function at(t){return t.replace(/start|end/g,(function(t){return lt[t]}))}function ct(t){var e=k(t);return{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function ut(t){return N(z(t)).left+ct(t).scrollLeft}function dt(t){var e=V(t),n=e.overflow,i=e.overflowX,o=e.overflowY;return/auto|scroll|overlay|hidden/.test(n+o+i)}function ht(t){return["html","body","#document"].indexOf(T(t))>=0?t.ownerDocument.body:A(t)&&dt(t)?t:ht(W(t))}function pt(t,e){var n;void 0===e&&(e=[]);var i=ht(t),o=i===(null==(n=t.ownerDocument)?void 0:n.body),r=k(i),s=o?[r].concat(r.visualViewport||[],dt(i)?i:[]):i,l=e.concat(s);return o?l:l.concat(pt(W(s)))}function ft(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function vt(t,e,n){return e===h?ft(function(t,e){var n=k(t),i=z(t),o=n.visualViewport,r=i.clientWidth,s=i.clientHeight,l=0,a=0;if(o){r=o.width,s=o.height;var c=H();(c||!c&&"fixed"===e)&&(l=o.offsetLeft,a=o.offsetTop)}return{width:r,height:s,x:l+ut(t),y:a}}(t,n)):O(e)?function(t,e){var n=N(t,!1,"fixed"===e);return n.top=n.top+t.clientTop,n.left=n.left+t.clientLeft,n.bottom=n.top+t.clientHeight,n.right=n.left+t.clientWidth,n.width=t.clientWidth,n.height=t.clientHeight,n.x=n.left,n.y=n.top,n}(e,n):ft(function(t){var e,n=z(t),i=ct(t),o=null==(e=t.ownerDocument)?void 0:e.body,r=D(n.scrollWidth,n.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),s=D(n.scrollHeight,n.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),l=-i.scrollLeft+ut(t),a=-i.scrollTop;return"rtl"===V(o||n).direction&&(l+=D(n.clientWidth,o?o.clientWidth:0)-r),{width:r,height:s,x:l,y:a}}(z(t)))}function mt(t,e,n,i){var o="clippingParents"===e?function(t){var e=pt(W(t)),n=["absolute","fixed"].indexOf(V(t).position)>=0&&A(t)?Q(t):t;return O(n)?e.filter((function(t){return O(t)&&F(t,n)&&"body"!==T(t)})):[]}(t):[].concat(e),r=[].concat(o,[n]),s=r[0],l=r.reduce((function(e,n){var o=vt(t,n,i);return e.top=D(o.top,e.top),e.right=M(o.right,e.right),e.bottom=M(o.bottom,e.bottom),e.left=D(o.left,e.left),e}),vt(t,s,i));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function gt(t){var e,n=t.reference,l=t.element,a=t.placement,d=a?B(a):null,h=a?G(a):null,p=n.x+n.width/2-l.width/2,f=n.y+n.height/2-l.height/2;switch(d){case i:e={x:p,y:n.y-l.height};break;case o:e={x:p,y:n.y+n.height};break;case r:e={x:n.x+n.width,y:f};break;case s:e={x:n.x-l.width,y:f};break;default:e={x:n.x,y:n.y}}var v=d?J(d):null;if(null!=v){var m="y"===v?"height":"width";switch(h){case c:e[v]=e[v]-(n[m]/2-l[m]/2);break;case u:e[v]=e[v]+(n[m]/2-l[m]/2)}}return e}function yt(t,e){void 0===e&&(e={});var n=e,s=n.placement,l=void 0===s?t.placement:s,c=n.strategy,u=void 0===c?t.strategy:c,v=n.boundary,m=void 0===v?d:v,g=n.rootBoundary,y=void 0===g?h:g,w=n.elementContext,b=void 0===w?p:w,C=n.altBoundary,S=void 0!==C&&C,L=n.padding,x=void 0===L?0:L,I=X("number"!=typeof x?x:Y(x,a)),E=b===p?f:p,T=t.rects.popper,k=t.elements[S?E:b],A=mt(O(k)?k:k.contextElement||z(t.elements.popper),m,y,u),P=N(t.elements.reference),_=gt({reference:P,element:T,strategy:"absolute",placement:l}),B=ft(Object.assign({},T,_)),D=b===p?B:P,M={top:A.top-D.top+I.top,bottom:D.bottom-A.bottom+I.bottom,left:A.left-D.left+I.left,right:D.right-A.right+I.right},$=t.modifiersData.offset;if(b===p&&$){var q=$[l];Object.keys(M).forEach((function(t){var e=[r,o].indexOf(t)>=0?1:-1,n=[i,o].indexOf(t)>=0?"y":"x";M[t]+=q[n]*e}))}return M}const wt={name:"flip",enabled:!0,phase:"main",fn:function(t){var e=t.state,n=t.options,u=t.name;if(!e.modifiersData[u]._skip){for(var d=n.mainAxis,h=void 0===d||d,p=n.altAxis,f=void 0===p||p,g=n.fallbackPlacements,y=n.padding,w=n.boundary,b=n.rootBoundary,C=n.altBoundary,S=n.flipVariations,L=void 0===S||S,x=n.allowedAutoPlacements,I=e.options.placement,E=B(I),T=g||(E===I||!L?[st(I)]:function(t){if(B(t)===l)return[];var e=st(t);return[at(t),e,at(e)]}(I)),k=[I].concat(T).reduce((function(t,n){return t.concat(B(n)===l?function(t,e){void 0===e&&(e={});var n=e,i=n.placement,o=n.boundary,r=n.rootBoundary,s=n.padding,l=n.flipVariations,c=n.allowedAutoPlacements,u=void 0===c?m:c,d=G(i),h=d?l?v:v.filter((function(t){return G(t)===d})):a,p=h.filter((function(t){return u.indexOf(t)>=0}));0===p.length&&(p=h);var f=p.reduce((function(e,n){return e[n]=yt(t,{placement:n,boundary:o,rootBoundary:r,padding:s})[B(n)],e}),{});return Object.keys(f).sort((function(t,e){return f[t]-f[e]}))}(e,{placement:n,boundary:w,rootBoundary:b,padding:y,flipVariations:L,allowedAutoPlacements:x}):n)}),[]),O=e.rects.reference,A=e.rects.popper,P=new Map,_=!0,D=k[0],M=0;M=0,j=N?"width":"height",F=yt(e,{placement:$,boundary:w,rootBoundary:b,altBoundary:C,padding:y}),V=N?H?r:s:H?o:i;O[j]>A[j]&&(V=st(V));var R=st(V),z=[];if(h&&z.push(F[q]<=0),f&&z.push(F[V]<=0,F[R]<=0),z.every((function(t){return t}))){D=$,_=!1;break}P.set($,z)}if(_)for(var W=function(t){var e=k.find((function(e){var n=P.get(e);if(n)return n.slice(0,t).every((function(t){return t}))}));if(e)return D=e,"break"},U=L?3:1;U>0;U--){if("break"===W(U))break}e.placement!==D&&(e.modifiersData[u]._skip=!0,e.placement=D,e.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function bt(t,e,n){return void 0===n&&(n={x:0,y:0}),{top:t.top-e.height-n.y,right:t.right-e.width+n.x,bottom:t.bottom-e.height+n.y,left:t.left-e.width-n.x}}function Ct(t){return[i,r,o,s].some((function(e){return t[e]>=0}))}const St={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(t){var e=t.state,n=t.name,i=e.rects.reference,o=e.rects.popper,r=e.modifiersData.preventOverflow,s=yt(e,{elementContext:"reference"}),l=yt(e,{altBoundary:!0}),a=bt(s,i),c=bt(l,o,r),u=Ct(a),d=Ct(c);e.modifiersData[n]={referenceClippingOffsets:a,popperEscapeOffsets:c,isReferenceHidden:u,hasPopperEscaped:d},e.attributes.popper=Object.assign({},e.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":d})}};const Lt={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(t){var e=t.state,n=t.options,o=t.name,l=n.offset,a=void 0===l?[0,0]:l,c=m.reduce((function(t,n){return t[n]=function(t,e,n){var o=B(t),l=[s,i].indexOf(o)>=0?-1:1,a="function"==typeof n?n(Object.assign({},e,{placement:t})):n,c=a[0],u=a[1];return c=c||0,u=(u||0)*l,[s,r].indexOf(o)>=0?{x:u,y:c}:{x:c,y:u}}(n,e.rects,a),t}),{}),u=c[e.placement],d=u.x,h=u.y;null!=e.modifiersData.popperOffsets&&(e.modifiersData.popperOffsets.x+=d,e.modifiersData.popperOffsets.y+=h),e.modifiersData[o]=c}};const xt={name:"popperOffsets",enabled:!0,phase:"read",fn:function(t){var e=t.state,n=t.name;e.modifiersData[n]=gt({reference:e.rects.reference,element:e.rects.popper,strategy:"absolute",placement:e.placement})},data:{}};const It={name:"preventOverflow",enabled:!0,phase:"main",fn:function(t){var e=t.state,n=t.options,l=t.name,a=n.mainAxis,u=void 0===a||a,d=n.altAxis,h=void 0!==d&&d,p=n.boundary,f=n.rootBoundary,v=n.altBoundary,m=n.padding,g=n.tether,y=void 0===g||g,w=n.tetherOffset,b=void 0===w?0:w,C=yt(e,{boundary:p,rootBoundary:f,padding:m,altBoundary:v}),S=B(e.placement),L=G(e.placement),x=!L,I=J(S),E="x"===I?"y":"x",T=e.modifiersData.popperOffsets,k=e.rects.reference,O=e.rects.popper,A="function"==typeof b?b(Object.assign({},e.rects,{placement:e.placement})):b,P="number"==typeof A?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),_=e.modifiersData.offset?e.modifiersData.offset[e.placement]:null,$={x:0,y:0};if(T){if(u){var q,H="y"===I?i:s,N="y"===I?o:r,F="y"===I?"height":"width",V=T[I],R=V+C[H],z=V-C[N],W=y?-O[F]/2:0,U=L===c?k[F]:O[F],X=L===c?-O[F]:-k[F],Y=e.elements.arrow,Z=y&&Y?j(Y):{width:0,height:0},tt=e.modifiersData["arrow#persistent"]?e.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},et=tt[H],nt=tt[N],it=K(0,k[F],Z[F]),ot=x?k[F]/2-W-it-et-P.mainAxis:U-it-et-P.mainAxis,rt=x?-k[F]/2+W+it+nt+P.mainAxis:X+it+nt+P.mainAxis,st=e.elements.arrow&&Q(e.elements.arrow),lt=st?"y"===I?st.clientTop||0:st.clientLeft||0:0,at=null!=(q=null==_?void 0:_[I])?q:0,ct=V+rt-at,ut=K(y?M(R,V+ot-at-lt):R,V,y?D(z,ct):z);T[I]=ut,$[I]=ut-V}if(h){var dt,ht="x"===I?i:s,pt="x"===I?o:r,ft=T[E],vt="y"===E?"height":"width",mt=ft+C[ht],gt=ft-C[pt],wt=-1!==[i,s].indexOf(S),bt=null!=(dt=null==_?void 0:_[E])?dt:0,Ct=wt?mt:ft-k[vt]-O[vt]-bt+P.altAxis,St=wt?ft+k[vt]+O[vt]-bt-P.altAxis:gt,Lt=y&&wt?function(t,e,n){var i=K(t,e,n);return i>n?n:i}(Ct,ft,St):K(y?Ct:mt,ft,y?St:gt);T[E]=Lt,$[E]=Lt-ft}e.modifiersData[l]=$}},requiresIfExists:["offset"]};function Et(t,e,n){void 0===n&&(n=!1);var i,o,r=A(e),s=A(e)&&function(t){var e=t.getBoundingClientRect(),n=$(e.width)/t.offsetWidth||1,i=$(e.height)/t.offsetHeight||1;return 1!==n||1!==i}(e),l=z(e),a=N(t,s,n),c={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(r||!r&&!n)&&(("body"!==T(e)||dt(l))&&(c=(i=e)!==k(i)&&A(i)?{scrollLeft:(o=i).scrollLeft,scrollTop:o.scrollTop}:ct(i)),A(e)?((u=N(e,!0)).x+=e.clientLeft,u.y+=e.clientTop):l&&(u.x=ut(l))),{x:a.left+c.scrollLeft-u.x,y:a.top+c.scrollTop-u.y,width:a.width,height:a.height}}function Tt(t){var e=new Map,n=new Set,i=[];function o(t){n.add(t.name),[].concat(t.requires||[],t.requiresIfExists||[]).forEach((function(t){if(!n.has(t)){var i=e.get(t);i&&o(i)}})),i.push(t)}return t.forEach((function(t){e.set(t.name,t)})),t.forEach((function(t){n.has(t.name)||o(t)})),i}var kt={placement:"bottom",modifiers:[],strategy:"absolute"};function Ot(){for(var t=arguments.length,e=new Array(t),n=0;n{Object.defineProperty(e,"__esModule",{value:!0}),e.BREAKPOINTS=e.COMBO_BOX_ACCESSIBILITY_KEY_SET=e.SELECT_ACCESSIBILITY_KEY_SET=e.TABS_ACCESSIBILITY_KEY_SET=e.OVERLAY_ACCESSIBILITY_KEY_SET=e.DROPDOWN_ACCESSIBILITY_KEY_SET=e.POSITIONS=void 0,e.POSITIONS={auto:"auto","auto-start":"auto-start","auto-end":"auto-end",top:"top","top-left":"top-start","top-right":"top-end",bottom:"bottom","bottom-left":"bottom-start","bottom-right":"bottom-end",right:"right","right-start":"right-start","right-end":"right-end",left:"left","left-start":"left-start","left-end":"left-end"},e.DROPDOWN_ACCESSIBILITY_KEY_SET=["Escape","ArrowUp","ArrowDown","ArrowRight","ArrowLeft","Home","End","Enter"],e.OVERLAY_ACCESSIBILITY_KEY_SET=["Escape","Tab"],e.TABS_ACCESSIBILITY_KEY_SET=["ArrowUp","ArrowLeft","ArrowDown","ArrowRight","Home","End"],e.SELECT_ACCESSIBILITY_KEY_SET=["ArrowUp","ArrowLeft","ArrowDown","ArrowRight","Home","End","Escape","Enter","Space","Tab"],e.COMBO_BOX_ACCESSIBILITY_KEY_SET=["ArrowUp","ArrowLeft","ArrowDown","ArrowRight","Home","End","Escape","Enter"],e.BREAKPOINTS={xs:0,sm:640,md:768,lg:1024,xl:1280,"2xl":1536}},158:function(t,e,n){ + /* + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.HSRangeSlider=e.HSFileUpload=e.HSDataTable=e.HSStaticMethods=e.HSTreeView=e.HSTooltip=e.HSTogglePassword=e.HSToggleCount=e.HSThemeSwitch=e.HSTextareaAutoHeight=e.HSTabs=e.HSStrongPassword=e.HSStepper=e.HSSelect=e.HSScrollspy=e.HSRemoveElement=e.HSPinInput=e.HSOverlay=e.HSLayoutSplitter=e.HSInputNumber=e.HSDropdown=e.HSComboBox=e.HSCollapse=e.HSCarousel=e.HSAccordion=e.HSCopyMarkup=void 0;var o=n(406);Object.defineProperty(e,"HSCopyMarkup",{enumerable:!0,get:function(){return i(o).default}});var r=n(740);Object.defineProperty(e,"HSAccordion",{enumerable:!0,get:function(){return i(r).default}});var s=n(268);Object.defineProperty(e,"HSCarousel",{enumerable:!0,get:function(){return i(s).default}});var l=n(485);Object.defineProperty(e,"HSCollapse",{enumerable:!0,get:function(){return i(l).default}});var a=n(809);Object.defineProperty(e,"HSComboBox",{enumerable:!0,get:function(){return i(a).default}});var c=n(891);Object.defineProperty(e,"HSDropdown",{enumerable:!0,get:function(){return i(c).default}});var u=n(332);Object.defineProperty(e,"HSInputNumber",{enumerable:!0,get:function(){return i(u).default}});var d=n(812);Object.defineProperty(e,"HSLayoutSplitter",{enumerable:!0,get:function(){return i(d).default}});var h=n(850);Object.defineProperty(e,"HSOverlay",{enumerable:!0,get:function(){return i(h).default}});var p=n(60);Object.defineProperty(e,"HSPinInput",{enumerable:!0,get:function(){return i(p).default}});var f=n(911);Object.defineProperty(e,"HSRemoveElement",{enumerable:!0,get:function(){return i(f).default}});var v=n(751);Object.defineProperty(e,"HSScrollspy",{enumerable:!0,get:function(){return i(v).default}});var m=n(442);Object.defineProperty(e,"HSSelect",{enumerable:!0,get:function(){return i(m).default}});var g=n(887);Object.defineProperty(e,"HSStepper",{enumerable:!0,get:function(){return i(g).default}});var y=n(97);Object.defineProperty(e,"HSStrongPassword",{enumerable:!0,get:function(){return i(y).default}});var w=n(166);Object.defineProperty(e,"HSTabs",{enumerable:!0,get:function(){return i(w).default}});var b=n(144);Object.defineProperty(e,"HSTextareaAutoHeight",{enumerable:!0,get:function(){return i(b).default}});var C=n(502);Object.defineProperty(e,"HSThemeSwitch",{enumerable:!0,get:function(){return i(C).default}});var S=n(684);Object.defineProperty(e,"HSToggleCount",{enumerable:!0,get:function(){return i(S).default}});var L=n(100);Object.defineProperty(e,"HSTogglePassword",{enumerable:!0,get:function(){return i(L).default}});var x=n(969);Object.defineProperty(e,"HSTooltip",{enumerable:!0,get:function(){return i(x).default}});var I=n(772);Object.defineProperty(e,"HSTreeView",{enumerable:!0,get:function(){return i(I).default}});var E=n(957);Object.defineProperty(e,"HSStaticMethods",{enumerable:!0,get:function(){return i(E).default}}),"undefined"!=typeof DataTable&&"undefined"!=typeof jQuery?e.HSDataTable=n(814).default:e.HSDataTable=null,"undefined"!=typeof _&&"undefined"!=typeof Dropzone?e.HSFileUpload=n(234).default:e.HSFileUpload=null,"undefined"!=typeof noUiSlider?e.HSRangeSlider=n(347).default:e.HSRangeSlider=null},740:function(t,e,n){ + /* + * HSAccordion + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n .hs-accordion.active")&&this.group.querySelector(":scope > .hs-accordion.active")!==this.el&&window.$hsAccordionCollection.find((function(t){return t.element.el===e.group.querySelector(":scope > .hs-accordion.active")})).element.hide();if(this.el.classList.contains("active"))return!1;this.el.classList.add("active"),(null===(t=null==this?void 0:this.toggle)||void 0===t?void 0:t.ariaExpanded)&&(this.toggle.ariaExpanded="true"),this.content.style.display="block",this.content.style.height="0",setTimeout((function(){e.content.style.height="".concat(e.content.scrollHeight,"px"),(0,l.afterTransition)(e.content,(function(){e.content.style.display="block",e.content.style.height="",e.fireEvent("open",e.el),(0,l.dispatch)("open.hs.accordion",e.el,e.el)}))}))},e.prototype.hide=function(){var t,e=this;if(!this.el.classList.contains("active"))return!1;this.el.classList.remove("active"),(null===(t=null==this?void 0:this.toggle)||void 0===t?void 0:t.ariaExpanded)&&(this.toggle.ariaExpanded="false"),this.content.style.height="".concat(this.content.scrollHeight,"px"),setTimeout((function(){e.content.style.height="0"})),(0,l.afterTransition)(this.content,(function(){e.content.style.display="",e.content.style.height="0",e.fireEvent("close",e.el),(0,l.dispatch)("close.hs.accordion",e.el,e.el)}))},e.prototype.update=function(){var t=this;if(this.group=this.el.closest(".hs-accordion-group")||null,!this.group)return!1;this.isAlwaysOpened=this.group.hasAttribute("data-hs-accordion-always-open")||!1,window.$hsAccordionCollection.map((function(e){return e.id===t.el.id&&(e.element.group=t.group,e.element.isAlwaysOpened=t.isAlwaysOpened),e}))},e.prototype.destroy=function(){var t,n=this;(null===(t=null==e?void 0:e.selectable)||void 0===t?void 0:t.length)&&e.selectable.forEach((function(t){t.listeners.forEach((function(t){var e=t.el,n=t.listener;e.removeEventListener("click",n)}))})),this.onToggleClickListener&&this.toggle.removeEventListener("click",this.onToggleClickListener),this.toggle=null,this.content=null,this.group=null,this.onToggleClickListener=null,window.$hsAccordionCollection=window.$hsAccordionCollection.filter((function(t){return t.element.el!==n.el}))},e.getInstance=function(t,e){var n=window.$hsAccordionCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.show=function(t){var e=window.$hsAccordionCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&"block"!==e.element.content.style.display&&e.element.show()},e.hide=function(t){var e=window.$hsAccordionCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&"block"===e.element.content.style.display&&e.element.hide()},e.autoInit=function(){window.$hsAccordionCollection||(window.$hsAccordionCollection=[]),window.$hsAccordionCollection&&(window.$hsAccordionCollection=window.$hsAccordionCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll(".hs-accordion:not(.--prevent-on-load-init)").forEach((function(t){window.$hsAccordionCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e.treeView=function(){var t=this;if(!document.querySelectorAll(".hs-accordion-treeview-root").length)return!1;this.selectable=[],document.querySelectorAll(".hs-accordion-treeview-root").forEach((function(e){var n=null==e?void 0:e.getAttribute("data-hs-accordion-options"),i=n?JSON.parse(n):{};t.selectable.push({el:e,options:r({},i),listeners:[]})})),this.selectable.length&&this.selectable.forEach((function(e){e.el.querySelectorAll(".hs-accordion-selectable").forEach((function(n){var i=function(i){return t.onSelectableClick(i,e,n)};n.addEventListener("click",i),e.listeners.push({el:n,listener:i})}))}))},e.toggleSelected=function(t,e){e.classList.contains("selected")?e.classList.remove("selected"):(t.el.querySelectorAll(".hs-accordion-selectable").forEach((function(t){return t.classList.remove("selected")})),e.classList.add("selected"))},e.on=function(t,e,n){var i=window.$hsAccordionCollection.find((function(t){return t.element.el===("string"==typeof e?document.querySelector(e):e)}));i&&(i.element.events[t]=n)},e.onSelectableClick=function(t,n,i){t.stopPropagation(),e.toggleSelected(n,i)},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit(),document.querySelectorAll(".hs-accordion-treeview-root").length&&a.treeView()})),"undefined"!=typeof window&&(window.HSAccordion=a),e.default=a},961:(t,e)=>{Object.defineProperty(e,"__esModule",{value:!0});var n=function(){function t(t,e,n){this.el=t,this.options=e,this.events=n,this.el=t,this.options=e,this.events={}}return t.prototype.createCollection=function(t,e){var n;t.push({id:(null===(n=null==e?void 0:e.el)||void 0===n?void 0:n.id)||t.length+1,element:e})},t.prototype.fireEvent=function(t,e){if(void 0===e&&(e=null),this.events.hasOwnProperty(t))return this.events[t](e)},t.prototype.on=function(t,e){this.events[t]=e},t}();e.default=n},268:function(t,e,n){ + /* + * HSCarousel + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;nt?s:-i:i>r?r:i<-t?s:i}())}},e.prototype.handleDragEnd=function(){var t=this;if(this.isDragging){this.isDragging=!1;var e=this.sliderWidth/this.getCurrentSlidesQty(),n=this.getTranslateXValue(),i=Math.round(n/e);this.isRTL&&(i=Math.round(n/e)),this.inner.classList.remove("dragging"),setTimeout((function(){t.calculateTransform(i),t.dots&&t.setCurrentDot(),t.dragStartX=null,t.initialTranslateX=null,t.inner.querySelectorAll("a.prevented-click").forEach((function(e){e.classList.remove("prevented-click"),e.removeEventListener("click",t.removeClickEventWhileDragging)}))}))}},e.prototype.getEventX=function(t){return t instanceof MouseEvent?t.clientX:t.touches[0].clientX},e.prototype.getCurrentSlidesQty=function(){var t=this;if("object"==typeof this.slidesQty){var e=document.body.clientWidth,n=0;return Object.keys(this.slidesQty).forEach((function(i){e>=(typeof i+1=="number"?t.slidesQty[i]:c.BREAKPOINTS[i])&&(n=t.slidesQty[i])})),n}return this.slidesQty},e.prototype.buildSnapSpacers=function(){var t=this.inner.querySelector(".hs-snap-before"),e=this.inner.querySelector(".hs-snap-after");t&&t.remove(),e&&e.remove();var n=this.sliderWidth,i=n/2-n/this.getCurrentSlidesQty()/2,o=(0,l.htmlToElement)('
')),r=(0,l.htmlToElement)('
'));this.inner.prepend(o),this.inner.appendChild(r)},e.prototype.initDots=function(){this.el.querySelectorAll(".hs-carousel-pagination-item").length?this.setDots():this.buildDots(),this.dots&&this.setCurrentDot()},e.prototype.buildDots=function(){this.dots.innerHTML="";for(var t=!this.isCentered&&this.slidesQty?this.slides.length-(this.getCurrentSlidesQty()-1):this.slides.length,e=0;en+o)&&(h=c-o),(ui+r)&&(p=d-r),t.scrollTo({left:h,top:p,behavior:"smooth"})},e.prototype.buildInfo=function(){this.infoTotal&&this.setInfoTotal(),this.infoCurrent&&this.setInfoCurrent()},e.prototype.setInfoTotal=function(){this.infoTotal.innerText="".concat(this.slides.length)},e.prototype.setInfoCurrent=function(){this.infoCurrent.innerText="".concat(this.currentIndex+1)},e.prototype.buildSingleDot=function(t){var e=(0,l.htmlToElement)("");return this.dotsItemClasses&&(0,l.classToClassList)(this.dotsItemClasses,e),this.singleDotEvents(e,t),e},e.prototype.singleDotEvents=function(t,e){var n=this;this.onDotClickListener=function(){return n.dotClick(e)},t.addEventListener("click",this.onDotClickListener)},e.prototype.observeResize=function(){var t=this;new ResizeObserver((0,l.debounce)((function(e){for(var n=0,i=e;n=this.currentIndex-e?i.classList.add("active"):i.classList.remove("active")}else{var o=this.isCentered?this.currentIndex+this.getCurrentSlidesQty()+(this.getCurrentSlidesQty()-1):this.currentIndex+this.getCurrentSlidesQty();this.slides.forEach((function(e,n){n>=t.currentIndex&&n *").forEach((function(t,n){return e(t,n)}))},e.prototype.setElementToDisabled=function(t){t.classList.add("disabled"),"BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.setAttribute("disabled","disabled")},e.prototype.unsetElementToDisabled=function(t){t.classList.remove("disabled"),"BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.removeAttribute("disabled")},e.prototype.addDisabledClass=function(){if(!this.prev||!this.next)return!1;var t=getComputedStyle(this.inner).getPropertyValue("gap"),e=Math.floor(this.getCurrentSlidesQty()/2),n=0,i=0,o=!1,r=!1;this.isSnap?(n=this.currentIndex,i=this.hasSnapSpacers?this.slides.length-1:this.slides.length-e-1,o=this.hasSnapSpacers?0===n:this.getCurrentSlidesQty()%2==0?n-e<0:n-e==0,r=n>=i&&this.container.scrollLeft+this.container.clientWidth+(parseFloat(t)||0)>=this.container.scrollWidth):(o=0===(n=this.currentIndex),r=n>=(i=this.isCentered?this.slides.length-this.getCurrentSlidesQty()+(this.getCurrentSlidesQty()-1):this.slides.length-this.getCurrentSlidesQty())),o?(this.unsetElementToDisabled(this.next),this.setElementToDisabled(this.prev)):r?(this.unsetElementToDisabled(this.prev),this.setElementToDisabled(this.next)):(this.unsetElementToDisabled(this.prev),this.unsetElementToDisabled(this.next))},e.prototype.autoPlay=function(){this.setTimer()},e.prototype.setTimer=function(){var t=this;this.timer=setInterval((function(){t.currentIndex===t.slides.length-1?t.goTo(0):t.goToNext()}),this.speed)},e.prototype.resetTimer=function(){clearInterval(this.timer)},e.prototype.detectDirection=function(){var t=this.touchX,e=t.start,n=t.end;ne&&this.goToPrev()},e.prototype.calculateTransform=function(t){void 0!==t&&(this.currentIndex=t),this.currentIndex>this.slides.length-this.getCurrentSlidesQty()&&!this.isCentered&&(this.currentIndex=this.slides.length-this.getCurrentSlidesQty());var e=this.sliderWidth,n=e/this.getCurrentSlidesQty(),i=this.currentIndex*n;if(this.isSnap&&!this.isCentered&&this.container.scrollLefte&&(this.container.scrollLeft=this.container.scrollWidth),this.isCentered&&!this.isSnap){var o=(e-n)/2;if(0===this.currentIndex)i=-o;else if(this.currentIndex>=this.slides.length-this.getCurrentSlidesQty()+(this.getCurrentSlidesQty()-1)){i=this.slides.length*n-e+o}else i=this.currentIndex*n-o}this.isSnap||(this.inner.style.transform=this.isRTL?"translate(".concat(i,"px, 0px)"):"translate(".concat(-i,"px, 0px)")),this.isAutoHeight&&(this.inner.style.height="".concat(this.slides[this.currentIndex].clientHeight,"px")),this.dotsItems&&this.goToCurrentDot(),this.addCurrentClass(),this.isInfiniteLoop||this.addDisabledClass(),this.isSnap&&this.hasSnapSpacers&&this.buildSnapSpacers(),this.infoCurrent&&this.setInfoCurrent()},e.prototype.setTranslate=function(t){this.inner.style.transform=this.isRTL?"translate(".concat(-t,"px, 0px)"):"translate(".concat(t,"px, 0px)")},e.prototype.setIndex=function(t){this.currentIndex=t,this.addCurrentClass(),this.isInfiniteLoop||this.addDisabledClass()},e.prototype.recalculateWidth=function(){this.sliderWidth=this.inner.parentElement.getBoundingClientRect().width,this.calculateWidth(),this.sliderWidth!==this.inner.parentElement.getBoundingClientRect().width&&this.recalculateWidth()},e.prototype.goToPrev=function(){if(this.currentIndex>0?this.currentIndex--:this.currentIndex=this.slides.length-this.getCurrentSlidesQty(),this.isSnap){var t=this.sliderWidth/this.getCurrentSlidesQty();this.container.scrollBy({left:Math.max(-this.container.scrollLeft,-t),behavior:"smooth"}),this.addCurrentClass(),this.isInfiniteLoop||this.addDisabledClass()}else this.calculateTransform();this.dots&&this.setCurrentDot()},e.prototype.goToNext=function(){var t=this.isCentered?this.slides.length-this.getCurrentSlidesQty()+(this.getCurrentSlidesQty()-1):this.slides.length-this.getCurrentSlidesQty();if(this.currentIndexthis.currentIndex?e-this.currentIndex:this.currentIndex-e,o=e>this.currentIndex?-n*i:n*i;this.container.scrollBy({left:o,behavior:"smooth"}),this.addCurrentClass(),this.isInfiniteLoop||this.addDisabledClass()}else this.calculateTransform();this.dots&&this.setCurrentDot()},e.prototype.destroy=function(){var t,e,n,i=this;(this.loadingClassesAdd&&("string"==typeof this.loadingClassesAdd?this.inner.classList.remove(this.loadingClassesAdd):(t=this.inner.classList).remove.apply(t,this.loadingClassesAdd)),this.inner&&this.afterLoadingClassesAdd&&setTimeout((function(){var t;"string"==typeof i.afterLoadingClassesAdd?i.inner.classList.remove(i.afterLoadingClassesAdd):(t=i.inner.classList).remove.apply(t,i.afterLoadingClassesAdd)})),this.el.classList.remove("init"),this.inner.classList.remove("dragging"),this.slides.forEach((function(t){return t.classList.remove("active")})),(null===(e=null==this?void 0:this.dotsItems)||void 0===e?void 0:e.length)&&this.dotsItems.forEach((function(t){return t.classList.remove("active")})),this.prev.classList.remove("disabled"),this.next.classList.remove("disabled"),this.inner.style.width="",this.slides.forEach((function(t){return t.style.width=""})),this.isSnap||(this.inner.style.transform=""),this.isAutoHeight&&(this.inner.style.height=""),this.prev.removeEventListener("click",this.onPrevClickListener),this.next.removeEventListener("click",this.onNextClickListener),this.container.removeEventListener("scroll",this.onContainerScrollListener),this.el.removeEventListener("touchstart",this.onElementTouchStartListener),this.el.removeEventListener("touchend",this.onElementTouchEndListener),this.inner.removeEventListener("mousedown",this.onInnerMouseDownListener),this.inner.removeEventListener("touchstart",this.onInnerTouchStartListener),document.removeEventListener("mousemove",this.onDocumentMouseMoveListener),document.removeEventListener("touchmove",this.onDocumentTouchMoveListener),document.removeEventListener("mouseup",this.onDocumentMouseUpListener),document.removeEventListener("touchend",this.onDocumentTouchEndListener),this.inner.querySelectorAll("a:not(.prevented-click)").forEach((function(t){t.classList.remove("prevented-click"),t.removeEventListener("click",i.removeClickEventWhileDragging)})),(null===(n=null==this?void 0:this.dotsItems)||void 0===n?void 0:n.length)||this.dots.querySelectorAll(":scope > *").length)&&(((null==this?void 0:this.dotsItems)||this.dots.querySelectorAll(":scope > *")).forEach((function(t){return t.removeEventListener("click",i.onDotClickListener)})),this.dots.innerHTML=null);this.inner.querySelector(".hs-snap-before").remove(),this.inner.querySelector(".hs-snap-after").remove(),this.dotsItems=null,this.isDragging=!1,this.dragStartX=null,this.initialTranslateX=null,window.$hsCarouselCollection=window.$hsCarouselCollection.filter((function(t){return t.element.el!==i.el}))},e.getInstance=function(t,e){var n=window.$hsCarouselCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsCarouselCollection||(window.$hsCarouselCollection=[]),window.$hsCarouselCollection&&(window.$hsCarouselCollection=window.$hsCarouselCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-carousel]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsCarouselCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(a.default);window.addEventListener("load",(function(){u.autoInit()})),"undefined"!=typeof window&&(window.HSCarousel=u),e.default=u},485:function(t,e,n){ + /* + * HSCollapse + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0});var s=n(292),l=function(t){function e(e,n,i){var o=t.call(this,e,n,i)||this;return o.contentId=o.el.dataset.hsCollapse,o.content=document.querySelector(o.contentId),o.animationInProcess=!1,o.content&&o.init(),o}return o(e,t),e.prototype.elementClick=function(){this.content.classList.contains("open")?this.hide():this.show()},e.prototype.init=function(){var t,e=this;this.createCollection(window.$hsCollapseCollection,this),this.onElementClickListener=function(){return e.elementClick()},(null===(t=null==this?void 0:this.el)||void 0===t?void 0:t.ariaExpanded)&&(this.el.classList.contains("open")?this.el.ariaExpanded="true":this.el.ariaExpanded="false"),this.el.addEventListener("click",this.onElementClickListener)},e.prototype.hideAllMegaMenuItems=function(){this.content.querySelectorAll(".hs-mega-menu-content.block").forEach((function(t){t.classList.remove("block"),t.classList.add("hidden")}))},e.prototype.show=function(){var t,e=this;if(this.animationInProcess||this.el.classList.contains("open"))return!1;this.animationInProcess=!0,this.el.classList.add("open"),(null===(t=null==this?void 0:this.el)||void 0===t?void 0:t.ariaExpanded)&&(this.el.ariaExpanded="true"),this.content.classList.add("open"),this.content.classList.remove("hidden"),this.content.style.height="0",setTimeout((function(){e.content.style.height="".concat(e.content.scrollHeight,"px"),e.fireEvent("beforeOpen",e.el),(0,s.dispatch)("beforeOpen.hs.collapse",e.el,e.el)})),(0,s.afterTransition)(this.content,(function(){e.content.style.height="",e.fireEvent("open",e.el),(0,s.dispatch)("open.hs.collapse",e.el,e.el),e.animationInProcess=!1}))},e.prototype.hide=function(){var t,e=this;if(this.animationInProcess||!this.el.classList.contains("open"))return!1;this.animationInProcess=!0,this.el.classList.remove("open"),(null===(t=null==this?void 0:this.el)||void 0===t?void 0:t.ariaExpanded)&&(this.el.ariaExpanded="false"),this.content.style.height="".concat(this.content.scrollHeight,"px"),setTimeout((function(){e.content.style.height="0"})),this.content.classList.remove("open"),(0,s.afterTransition)(this.content,(function(){e.content.classList.add("hidden"),e.content.style.height="",e.fireEvent("hide",e.el),(0,s.dispatch)("hide.hs.collapse",e.el,e.el),e.animationInProcess=!1})),this.content.querySelectorAll(".hs-mega-menu-content.block").length&&this.hideAllMegaMenuItems()},e.prototype.destroy=function(){var t=this;this.el.removeEventListener("click",this.onElementClickListener),this.content=null,this.animationInProcess=!1,window.$hsCollapseCollection=window.$hsCollapseCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){void 0===e&&(e=!1);var n=window.$hsCollapseCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.autoInit=function(){window.$hsCollapseCollection||(window.$hsCollapseCollection=[]),window.$hsCollapseCollection&&(window.$hsCollapseCollection=window.$hsCollapseCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll(".hs-collapse-toggle:not(.--prevent-on-load-init)").forEach((function(t){window.$hsCollapseCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e.show=function(t){var e=window.$hsCollapseCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&e.element.content.classList.contains("hidden")&&e.element.show()},e.hide=function(t){var e=window.$hsCollapseCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&!e.element.content.classList.contains("hidden")&&e.element.hide()},e.on=function(t,e,n){var i=window.$hsCollapseCollection.find((function(t){return t.element.el===("string"==typeof e?document.querySelector(e):e)}));i&&(i.element.events[t]=n)},e}(r(n(961)).default);window.addEventListener("load",(function(){l.autoInit()})),"undefined"!=typeof window&&(window.HSCollapse=l),e.default=l},809:function(t,e,n){ + /* + * HSComboBox + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0&&o[o.length-1])||6!==l[0]&&2!==l[0])){s=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t',_.outputEmptyTemplate=null!==(m=null==M?void 0:M.outputEmptyTemplate)&&void 0!==m?m:'
Nothing found...
',_.outputLoaderTemplate=null!==(g=null==M?void 0:M.outputLoaderTemplate)&&void 0!==g?g:'
\n\t\t\t\t
\n\t\t\t\t\tLoading...\n\t\t\t\t
\n\t\t\t
',_.groupingType=null!==(y=null==M?void 0:M.groupingType)&&void 0!==y?y:null,_.groupingTitleTemplate=null!==(w=null==M?void 0:M.groupingTitleTemplate)&&void 0!==w?w:"default"===_.groupingType?'
':'',_.tabsWrapperTemplate=null!==(b=null==M?void 0:M.tabsWrapperTemplate)&&void 0!==b?b:'
',_.preventSelection=null!==(C=null==M?void 0:M.preventSelection)&&void 0!==C&&C,_.preventAutoPosition=null!==(S=null==M?void 0:M.preventAutoPosition)&&void 0!==S&&S,_.isOpenOnFocus=null!==(L=null==M?void 0:M.isOpenOnFocus)&&void 0!==L&&L,_.input=null!==(x=_.el.querySelector("[data-hs-combo-box-input]"))&&void 0!==x?x:null,_.output=null!==(I=_.el.querySelector("[data-hs-combo-box-output]"))&&void 0!==I?I:null,_.itemsWrapper=null!==(E=_.el.querySelector("[data-hs-combo-box-output-items-wrapper]"))&&void 0!==E?E:null,_.items=null!==(T=Array.from(_.el.querySelectorAll("[data-hs-combo-box-output-item]")))&&void 0!==T?T:[],_.tabs=[],_.toggle=null!==(k=_.el.querySelector("[data-hs-combo-box-toggle]"))&&void 0!==k?k:null,_.toggleClose=null!==(O=_.el.querySelector("[data-hs-combo-box-close]"))&&void 0!==O?O:null,_.toggleOpen=null!==(A=_.el.querySelector("[data-hs-combo-box-open]"))&&void 0!==A?A:null,_.outputPlaceholder=null,_.selected=_.value=null!==(P=_.el.querySelector("[data-hs-combo-box-input]").value)&&void 0!==P?P:"",_.currentData=null,_.isOpened=!1,_.isCurrent=!1,_.animationInProcess=!1,_.selectedGroup="all",_.init(),_}return o(e,t),e.prototype.inputFocus=function(){this.isOpened||(this.setResultAndRender(),this.open())},e.prototype.inputInput=function(t){this.setResultAndRender(t.target.value),""!==this.input.value?this.el.classList.add("has-value"):this.el.classList.remove("has-value"),this.isOpened||this.open()},e.prototype.toggleClick=function(){this.isOpened?this.close():this.open(this.toggle.getAttribute("data-hs-combo-box-toggle"))},e.prototype.toggleCloseClick=function(){this.close()},e.prototype.toggleOpenClick=function(){this.open()},e.prototype.init=function(){this.createCollection(window.$hsComboBoxCollection,this),this.build()},e.prototype.build=function(){this.buildInput(),this.groupingType&&this.setGroups(),this.buildItems(),this.preventVisibility&&(this.preventAutoPosition||this.recalculateDirection()),this.toggle&&this.buildToggle(),this.toggleClose&&this.buildToggleClose(),this.toggleOpen&&this.buildToggleOpen()},e.prototype.getNestedProperty=function(t,e){return e.split(".").reduce((function(t,e){return t&&t[e]}),t)},e.prototype.setValue=function(t,e){void 0===e&&(e=null),this.selected=t,this.value=t,this.input.value=t,e&&(this.currentData=e),this.fireEvent("select",this.currentData),(0,u.dispatch)("select.hs.combobox",this.el,this.currentData)},e.prototype.setValueAndOpen=function(t){this.value=t,this.items.length&&this.setItemsVisibility()},e.prototype.setValueAndClear=function(t,e){void 0===e&&(e=null),t?this.setValue(t,e):this.setValue(this.selected,e),this.outputPlaceholder&&this.destroyOutputPlaceholder()},e.prototype.setSelectedByValue=function(t){var e=this;this.items.forEach((function(n){e.isTextExists(n,t)?n.classList.add("selected"):n.classList.remove("selected")}))},e.prototype.setResultAndRender=function(t){void 0===t&&(t="");var e=this.preventVisibility?this.input.value:t;this.setResults(e),(this.apiSearchQuery||this.apiSearchPath||this.apiSearchDefaultPath)&&this.itemsFromJson()},e.prototype.setResults=function(t){this.value=t,this.resultItems(),this.hasVisibleItems()?this.destroyOutputPlaceholder():this.buildOutputPlaceholder()},e.prototype.setGroups=function(){var t=[];this.items.forEach((function(e){var n=JSON.parse(e.getAttribute("data-hs-combo-box-output-item")).group;t.some((function(t){return(null==t?void 0:t.name)===n.name}))||t.push(n)})),this.groups=t},e.prototype.setApiGroups=function(t){var e=this,n=[];t.forEach((function(t){var i=t[e.apiGroupField];n.some((function(t){return t.name===i}))||n.push({name:i,title:i})})),this.groups=n},e.prototype.setItemsVisibility=function(){var t=this;"tabs"===this.groupingType&&"all"!==this.selectedGroup&&this.items.forEach((function(t){t.style.display="none"}));var e="tabs"===this.groupingType?"all"===this.selectedGroup?this.items:this.items.filter((function(e){return JSON.parse(e.getAttribute("data-hs-combo-box-output-item")).group.name===t.selectedGroup})):this.items;"tabs"===this.groupingType&&"all"!==this.selectedGroup&&e.forEach((function(t){t.style.display="block"})),e.forEach((function(e){t.isTextExistsAny(e,t.value)?e.style.display="block":e.style.display="none"})),"default"===this.groupingType&&this.output.querySelectorAll("[data-hs-combo-box-group-title]").forEach((function(e){var n=e.getAttribute("data-hs-combo-box-group-title");t.items.filter((function(t){return JSON.parse(t.getAttribute("data-hs-combo-box-output-item")).group.name===n&&"block"===t.style.display})).length?e.style.display="block":e.style.display="none"}))},e.prototype.isTextExists=function(t,e){var n=e.map((function(t){return t.toLowerCase()}));return Array.from(t.querySelectorAll("[data-hs-combo-box-search-text]")).some((function(t){return n.includes(t.getAttribute("data-hs-combo-box-search-text").toLowerCase())}))},e.prototype.isTextExistsAny=function(t,e){return Array.from(t.querySelectorAll("[data-hs-combo-box-search-text]")).some((function(t){return t.getAttribute("data-hs-combo-box-search-text").toLowerCase().includes(e.toLowerCase())}))},e.prototype.hasVisibleItems=function(){return!!this.items.length&&this.items.some((function(t){return"block"===t.style.display}))},e.prototype.valuesBySelector=function(t){return Array.from(t.querySelectorAll("[data-hs-combo-box-search-text]")).reduce((function(t,e){return a(a([],t,!0),[e.getAttribute("data-hs-combo-box-search-text")],!1)}),[])},e.prototype.sortItems=function(){return this.items.sort((function(t,e){var n=t.querySelector("[data-hs-combo-box-value]").getAttribute("data-hs-combo-box-search-text"),i=e.querySelector("[data-hs-combo-box-value]").getAttribute("data-hs-combo-box-search-text");return ni?1:0}))},e.prototype.buildInput=function(){var t=this;this.isOpenOnFocus&&(this.onInputFocusListener=function(){return t.inputFocus()},this.input.addEventListener("focus",this.onInputFocusListener)),this.onInputInputListener=(0,u.debounce)((function(e){return t.inputInput(e)})),this.input.addEventListener("input",this.onInputInputListener)},e.prototype.buildItems=function(){return s(this,void 0,void 0,(function(){return l(this,(function(t){switch(t.label){case 0:return this.output.role="listbox",this.output.tabIndex=-1,this.output.ariaOrientation="vertical",this.apiUrl?[4,this.itemsFromJson()]:[3,2];case 1:return t.sent(),[3,3];case 2:this.itemsWrapper?this.itemsWrapper.innerHTML="":this.output.innerHTML="",this.itemsFromHtml(),t.label=3;case 3:return this.items[0].classList.contains("selected")&&(this.currentData=JSON.parse(this.items[0].getAttribute("data-hs-combo-box-item-stored-data"))),[2]}}))}))},e.prototype.buildOutputLoader=function(){if(this.outputLoader)return!1;this.outputLoader=(0,u.htmlToElement)(this.outputLoaderTemplate),this.items.length||this.outputPlaceholder?(this.outputLoader.style.position="absolute",this.outputLoader.style.top="0",this.outputLoader.style.bottom="0",this.outputLoader.style.left="0",this.outputLoader.style.right="0",this.outputLoader.style.zIndex="2"):(this.outputLoader.style.position="",this.outputLoader.style.top="",this.outputLoader.style.bottom="",this.outputLoader.style.left="",this.outputLoader.style.right="",this.outputLoader.style.zIndex="",this.outputLoader.style.height="30px"),this.output.append(this.outputLoader)},e.prototype.buildToggle=function(){var t,e,n,i,o=this;this.isOpened?((null===(t=null==this?void 0:this.toggle)||void 0===t?void 0:t.ariaExpanded)&&(this.toggle.ariaExpanded="true"),(null===(e=null==this?void 0:this.input)||void 0===e?void 0:e.ariaExpanded)&&(this.input.ariaExpanded="true")):((null===(n=null==this?void 0:this.toggle)||void 0===n?void 0:n.ariaExpanded)&&(this.toggle.ariaExpanded="false"),(null===(i=null==this?void 0:this.input)||void 0===i?void 0:i.ariaExpanded)&&(this.input.ariaExpanded="false")),this.onToggleClickListener=function(){return o.toggleClick()},this.toggle.addEventListener("click",this.onToggleClickListener)},e.prototype.buildToggleClose=function(){var t=this;this.onToggleCloseClickListener=function(){return t.toggleCloseClick()},this.toggleClose.addEventListener("click",this.onToggleCloseClickListener)},e.prototype.buildToggleOpen=function(){var t=this;this.onToggleOpenClickListener=function(){return t.toggleOpenClick()},this.toggleOpen.addEventListener("click",this.onToggleOpenClickListener)},e.prototype.buildOutputPlaceholder=function(){this.outputPlaceholder||(this.outputPlaceholder=(0,u.htmlToElement)(this.outputEmptyTemplate)),this.appendItemsToWrapper(this.outputPlaceholder)},e.prototype.destroyOutputLoader=function(){this.outputLoader&&this.outputLoader.remove(),this.outputLoader=null},e.prototype.itemRender=function(t){var e,n=this,i=t.querySelector("[data-hs-combo-box-value]").getAttribute("data-hs-combo-box-search-text"),o=null!==(e=JSON.parse(t.getAttribute("data-hs-combo-box-item-stored-data")))&&void 0!==e?e:null;this.itemsWrapper?this.itemsWrapper.append(t):this.output.append(t),this.preventSelection||t.addEventListener("click",(function(){n.close(i,o),n.setSelectedByValue(n.valuesBySelector(t))}))},e.prototype.plainRender=function(t){var e=this;t.forEach((function(t){e.itemRender(t)}))},e.prototype.jsonItemsRender=function(t){var e=this;t.forEach((function(t,n){var i=(0,u.htmlToElement)(e.outputItemTemplate);i.setAttribute("data-hs-combo-box-item-stored-data",JSON.stringify(t)),i.querySelectorAll("[data-hs-combo-box-output-item-field]").forEach((function(n){var i=e.getNestedProperty(t,n.getAttribute("data-hs-combo-box-output-item-field")),o=n.hasAttribute("data-hs-combo-box-output-item-hide-if-empty");n.textContent=null!=i?i:"",!i&&o&&(n.style.display="none")})),i.querySelectorAll("[data-hs-combo-box-search-text]").forEach((function(n){var i=e.getNestedProperty(t,n.getAttribute("data-hs-combo-box-output-item-field"));n.setAttribute("data-hs-combo-box-search-text",null!=i?i:"")})),i.querySelectorAll("[data-hs-combo-box-output-item-attr]").forEach((function(e){JSON.parse(e.getAttribute("data-hs-combo-box-output-item-attr")).forEach((function(n){e.setAttribute(n.attr,t[n.valueFrom])}))})),i.setAttribute("tabIndex","".concat(n)),"tabs"!==e.groupingType&&"default"!==e.groupingType||i.setAttribute("data-hs-combo-box-output-item",'{"group": {"name": "'.concat(t[e.apiGroupField],'", "title": "').concat(t[e.apiGroupField],'"}}')),e.items=a(a([],e.items,!0),[i],!1),e.preventSelection||i.addEventListener("click",(function(){e.close(i.querySelector("[data-hs-combo-box-value]").getAttribute("data-hs-combo-box-search-text"),JSON.parse(i.getAttribute("data-hs-combo-box-item-stored-data"))),e.setSelectedByValue(e.valuesBySelector(i))})),e.appendItemsToWrapper(i)}))},e.prototype.groupDefaultRender=function(){var t=this;this.groups.forEach((function(e){var n=(0,u.htmlToElement)(t.groupingTitleTemplate);n.setAttribute("data-hs-combo-box-group-title",e.name),n.classList.add("--exclude-accessibility"),n.innerText=e.title,t.itemsWrapper?t.itemsWrapper.append(n):t.output.append(n);var i=t.sortItems().filter((function(t){return JSON.parse(t.getAttribute("data-hs-combo-box-output-item")).group.name===e.name}));t.plainRender(i)}))},e.prototype.groupTabsRender=function(){var t=this,e=(0,u.htmlToElement)(this.tabsWrapperTemplate),n=(0,u.htmlToElement)('
');e.append(n),this.output.insertBefore(e,this.output.firstChild);var i=(0,u.htmlToElement)(this.groupingTitleTemplate);i.setAttribute("data-hs-combo-box-group-title","all"),i.classList.add("--exclude-accessibility","active"),i.innerText="All",this.tabs=a(a([],this.tabs,!0),[i],!1),n.append(i),i.addEventListener("click",(function(){t.selectedGroup="all";var e=t.tabs.find((function(e){return e.getAttribute("data-hs-combo-box-group-title")===t.selectedGroup}));t.tabs.forEach((function(t){return t.classList.remove("active")})),e.classList.add("active"),t.setItemsVisibility()})),this.groups.forEach((function(e){var i=(0,u.htmlToElement)(t.groupingTitleTemplate);i.setAttribute("data-hs-combo-box-group-title",e.name),i.classList.add("--exclude-accessibility"),i.innerText=e.title,t.tabs=a(a([],t.tabs,!0),[i],!1),n.append(i),i.addEventListener("click",(function(){t.selectedGroup=e.name;var n=t.tabs.find((function(e){return e.getAttribute("data-hs-combo-box-group-title")===t.selectedGroup}));t.tabs.forEach((function(t){return t.classList.remove("active")})),n.classList.add("active"),t.setItemsVisibility()}))}))},e.prototype.itemsFromHtml=function(){if("default"===this.groupingType)this.groupDefaultRender();else if("tabs"===this.groupingType){var t=this.sortItems();this.groupTabsRender(),this.plainRender(t)}else{t=this.sortItems();this.plainRender(t)}this.setResults(this.input.value)},e.prototype.itemsFromJson=function(){return s(this,void 0,void 0,(function(){var t,e,n,i,o,r,s=this;return l(this,(function(l){switch(l.label){case 0:this.buildOutputLoader(),l.label=1;case 1:return l.trys.push([1,4,,5]),t="".concat(this.apiQuery),e=void 0,n=void 0,i=this.apiUrl,!this.apiSearchQuery&&this.apiSearchPath?(n=this.apiSearchDefaultPath&&""===this.value?"/".concat(this.apiSearchDefaultPath):"/".concat(this.apiSearchPath,"/").concat(this.value.toLowerCase()),(this.apiSearchPath||this.apiSearchDefaultPath)&&(i+=n)):(e="".concat(this.apiSearchQuery,"=").concat(this.value.toLowerCase()),this.apiQuery&&this.apiSearchQuery?i+="?".concat(e,"&").concat(t):this.apiQuery?i+="?".concat(t):this.apiSearchQuery&&(i+="?".concat(e))),[4,fetch(i,this.apiHeaders)];case 2:return[4,l.sent().json()];case 3:return o=l.sent(),this.apiDataPart&&(o=o[this.apiDataPart]),(this.apiSearchQuery||this.apiSearchPath)&&(this.items=[]),this.itemsWrapper?this.itemsWrapper.innerHTML="":this.output.innerHTML="","tabs"===this.groupingType?(this.setApiGroups(o),this.groupTabsRender(),this.jsonItemsRender(o)):"default"===this.groupingType?(this.setApiGroups(o),this.groups.forEach((function(t){var e=(0,u.htmlToElement)(s.groupingTitleTemplate);e.setAttribute("data-hs-combo-box-group-title",t.name),e.classList.add("--exclude-accessibility"),e.innerText=t.title;var n=o.filter((function(e){return e[s.apiGroupField]===t.name}));s.itemsWrapper?s.itemsWrapper.append(e):s.output.append(e),s.jsonItemsRender(n)}))):this.jsonItemsRender(o),this.setResults(this.input.value),[3,5];case 4:return r=l.sent(),console.error(r),this.buildOutputPlaceholder(),[3,5];case 5:return this.destroyOutputLoader(),[2]}}))}))},e.prototype.appendItemsToWrapper=function(t){this.itemsWrapper?this.itemsWrapper.append(t):this.output.append(t)},e.prototype.resultItems=function(){if(!this.items.length)return!1;this.setItemsVisibility(),this.setSelectedByValue([this.selected])},e.prototype.destroyOutputPlaceholder=function(){this.outputPlaceholder&&this.outputPlaceholder.remove(),this.outputPlaceholder=null},e.prototype.getCurrentData=function(){return this.currentData},e.prototype.setCurrent=function(){window.$hsComboBoxCollection.length&&(window.$hsComboBoxCollection.map((function(t){return t.element.isCurrent=!1})),this.isCurrent=!0)},e.prototype.open=function(t){var e=this;return!this.animationInProcess&&(void 0!==t&&this.setValueAndOpen(t),!this.preventVisibility&&(this.animationInProcess=!0,this.output.style.display="block",this.preventAutoPosition||this.recalculateDirection(),setTimeout((function(){var t,n;(null===(t=null==e?void 0:e.input)||void 0===t?void 0:t.ariaExpanded)&&(e.input.ariaExpanded="true"),(null===(n=null==e?void 0:e.toggle)||void 0===n?void 0:n.ariaExpanded)&&(e.toggle.ariaExpanded="true"),e.el.classList.add("active"),e.animationInProcess=!1})),void(this.isOpened=!0)))},e.prototype.close=function(t,e){var n,i,o=this;return void 0===e&&(e=null),!this.animationInProcess&&(this.preventVisibility?(this.setValueAndClear(t,e),""!==this.input.value?this.el.classList.add("has-value"):this.el.classList.remove("has-value"),!1):(this.animationInProcess=!0,(null===(n=null==this?void 0:this.input)||void 0===n?void 0:n.ariaExpanded)&&(this.input.ariaExpanded="false"),(null===(i=null==this?void 0:this.toggle)||void 0===i?void 0:i.ariaExpanded)&&(this.toggle.ariaExpanded="false"),this.el.classList.remove("active"),this.preventAutoPosition||(this.output.classList.remove("bottom-full","top-full"),this.output.style.marginTop="",this.output.style.marginBottom=""),(0,u.afterTransition)(this.output,(function(){o.output.style.display="none",o.setValueAndClear(t,e||null),o.animationInProcess=!1})),""!==this.input.value?this.el.classList.add("has-value"):this.el.classList.remove("has-value"),void(this.isOpened=!1)))},e.prototype.recalculateDirection=function(){(0,u.isEnoughSpace)(this.output,this.input,"bottom",this.gap,this.viewport)?(this.output.classList.remove("bottom-full"),this.output.style.marginBottom="",this.output.classList.add("top-full"),this.output.style.marginTop="".concat(this.gap,"px")):(this.output.classList.remove("top-full"),this.output.style.marginTop="",this.output.classList.add("bottom-full"),this.output.style.marginBottom="".concat(this.gap,"px"))},e.prototype.destroy=function(){var t=this;this.input.removeEventListener("focus",this.onInputFocusListener),this.input.removeEventListener("input",this.onInputInputListener),this.toggle.removeEventListener("click",this.onToggleClickListener),this.toggleClose&&this.toggleClose.removeEventListener("click",this.onToggleCloseClickListener),this.toggleOpen&&this.toggleOpen.removeEventListener("click",this.onToggleOpenClickListener),this.el.classList.remove("has-value","active"),this.items.length&&this.items.forEach((function(t){t.classList.remove("selected"),t.style.display=""})),this.output.removeAttribute("role"),this.output.removeAttribute("tabindex"),this.output.removeAttribute("aria-orientation"),this.outputLoader&&(this.outputLoader.remove(),this.outputLoader=null),this.outputPlaceholder&&(this.outputPlaceholder.remove(),this.outputPlaceholder=null),this.apiUrl&&(this.output.innerHTML=""),this.items=[],window.$hsComboBoxCollection=window.$hsComboBoxCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsComboBoxCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsComboBoxCollection||(window.$hsComboBoxCollection=[],window.addEventListener("click",(function(t){var n=t.target;e.closeCurrentlyOpened(n)})),document.addEventListener("keydown",(function(t){return e.accessibility(t)}))),window.$hsComboBoxCollection&&(window.$hsComboBoxCollection=window.$hsComboBoxCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-combo-box]:not(.--prevent-on-load-init)").forEach((function(t){if(!window.$hsComboBoxCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))){var n=t.getAttribute("data-hs-combo-box"),i=n?JSON.parse(n):{};new e(t,i)}}))},e.close=function(t){var e=window.$hsComboBoxCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&e.element.isOpened&&e.element.close()},e.closeCurrentlyOpened=function(t){if(void 0===t&&(t=null),!t.closest("[data-hs-combo-box].active")){var e=window.$hsComboBoxCollection.filter((function(t){return t.element.isOpened}))||null;e&&e.forEach((function(t){t.element.close()}))}},e.getPreparedItems=function(t,e){return void 0===t&&(t=!1),e?(t?Array.from(e.querySelectorAll(":scope > *:not(.--exclude-accessibility)")).filter((function(t){return"none"!==t.style.display})).reverse():Array.from(e.querySelectorAll(":scope > *:not(.--exclude-accessibility)")).filter((function(t){return"none"!==t.style.display}))).filter((function(t){return!t.classList.contains("disabled")})):null},e.setHighlighted=function(t,e,n){e.focus(),n.value=e.querySelector("[data-hs-combo-box-value]").getAttribute("data-hs-combo-box-search-text"),t&&t.classList.remove("hs-combo-box-output-item-highlighted"),e.classList.add("hs-combo-box-output-item-highlighted")},e.accessibility=function(t){if(window.$hsComboBoxCollection.find((function(t){return t.element.preventVisibility?t.element.isCurrent:t.element.isOpened}))&&h.COMBO_BOX_ACCESSIBILITY_KEY_SET.includes(t.code)&&!t.metaKey)switch(t.code){case"Escape":t.preventDefault(),this.onEscape();break;case"ArrowUp":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow();break;case"ArrowDown":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow(!1);break;case"Home":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd();break;case"End":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd(!1);break;case"Enter":t.preventDefault(),this.onEnter(t)}},e.onEscape=function(){var t=window.$hsComboBoxCollection.find((function(t){return!t.element.preventVisibility&&t.element.isOpened}));t&&(t.element.close(),t.element.input.blur())},e.onArrow=function(t){var n;void 0===t&&(t=!0);var i=window.$hsComboBoxCollection.find((function(t){return t.element.preventVisibility?t.element.isCurrent:t.element.isOpened}));if(i){var o=null!==(n=i.element.itemsWrapper)&&void 0!==n?n:i.element.output;if(!o)return!1;var r,s=e.getPreparedItems(t,o),l=o.querySelector(".hs-combo-box-output-item-highlighted");l||s[0].classList.add("hs-combo-box-output-item-highlighted");var a=s.findIndex((function(t){return t===l}));a+1=this.limit)return!1;this.el.hasAttribute("disabled")&&this.el.setAttribute("disabled","");var t=this.target.cloneNode(!0);this.addToItems(t),this.limit&&this.items.length>=this.limit&&this.el.setAttribute("disabled","disabled"),this.fireEvent("copy",t),(0,l.dispatch)("copy.hs.copyMarkup",t,t)},e.prototype.addPredefinedItems=function(){var t=this;Array.from(this.wrapper.children).filter((function(t){return!t.classList.contains("[--ignore-for-count]")})).forEach((function(e){t.addToItems(e)})),this.limit&&this.items.length>=this.limit&&this.el.setAttribute("disabled","disabled")},e.prototype.setTarget=function(){var t="string"==typeof this.targetSelector?document.querySelector(this.targetSelector).cloneNode(!0):this.targetSelector.cloneNode(!0);t.removeAttribute("id"),this.target=t},e.prototype.setWrapper=function(){this.wrapper="string"==typeof this.wrapperSelector?document.querySelector(this.wrapperSelector):this.wrapperSelector},e.prototype.addToItems=function(t){var e=this,n=t.querySelector("[data-hs-copy-markup-delete-item]");this.wrapper?this.wrapper.append(t):this.el.before(t),n&&(this.onDeleteItemButtonClickListener=function(){return e.deleteItemButtonClick(t)},n.addEventListener("click",this.onDeleteItemButtonClickListener)),this.items.push(t)},e.prototype.delete=function(t){var e=this.items.indexOf(t);-1!==e&&this.items.splice(e,1),t.remove(),this.fireEvent("delete",t),(0,l.dispatch)("delete.hs.copyMarkup",t,t)},e.prototype.destroy=function(){var t=this,e=this.wrapper.querySelectorAll("[data-hs-copy-markup-delete-item]");this.el.removeEventListener("click",this.onElementClickListener),e.length&&e.forEach((function(e){return e.removeEventListener("click",t.onDeleteItemButtonClickListener)})),this.el.removeAttribute("disabled"),this.target=null,this.wrapper=null,this.items=null,window.$hsCopyMarkupCollection=window.$hsCopyMarkupCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsCopyMarkupCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsCopyMarkupCollection||(window.$hsCopyMarkupCollection=[]),window.$hsCopyMarkupCollection&&(window.$hsCopyMarkupCollection=window.$hsCopyMarkupCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-copy-markup]:not(.--prevent-on-load-init)").forEach((function(t){if(!window.$hsCopyMarkupCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))){var n=t.getAttribute("data-hs-copy-markup"),i=n?JSON.parse(n):{};new e(t,i)}}))},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSCopyMarkup=a),e.default=a},814:function(t,e,n){ + /* + * HSDataTable + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n1&&(this.buildPagingPage(1),l>2&&this.pagingPages.appendChild((0,a.htmlToElement)('...')));for(var u=l;u<=c;u++)this.buildPagingPage(u);c...')),this.buildPagingPage(r)),this.disablePagingArrow(this.pagingPrev,0===e),this.disablePagingArrow(this.pagingNext,e===n-1),this.hidePagingIfSinglePage()},e.prototype.buildPagingPage=function(t){var e=this,n=this.dataTable.page.info().page,i=(0,a.htmlToElement)('');i.innerText="".concat(t),i.setAttribute("data-page","".concat(t)),this.pageBtnClasses&&(0,a.classToClassList)(this.pageBtnClasses,i),n===t-1&&i.classList.add("active"),this.onSinglePagingClickListener.push({id:t,fn:function(){return e.singlePagingClick(t)}}),i.addEventListener("click",this.onSinglePagingClickListener.find((function(e){return e.id===t})).fn),this.pagingPages.append(i)},e.prototype.onPageClick=function(t){this.dataTable.page(t-1).draw("page")},e.prototype.initRowSelecting=function(){var t=this;this.onRowSelectingAllChangeListener=function(){return t.rowSelectingAllChange()},this.rowSelectingAll.addEventListener("change",this.onRowSelectingAllChangeListener)},e.prototype.triggerChangeEventToRow=function(){var t=this;this.table.querySelectorAll("tbody ".concat(this.rowSelectingIndividual)).forEach((function(e){e.addEventListener("change",(function(){t.updateSelectAllCheckbox()}))}))},e.prototype.onSelectAllChange=function(){var t=this,e=this.rowSelectingAll.checked;Array.from(this.dataTable.rows({page:"current",search:"applied"}).nodes()).forEach((function(n){var i=n.querySelector(t.rowSelectingIndividual);i&&(i.checked=e)})),this.updateSelectAllCheckbox()},e.prototype.updateSelectAllCheckbox=function(){var t=this;if(!this.dataTable.rows({search:"applied"}).count())return this.rowSelectingAll.checked=!1,!1;var e=!0;Array.from(this.dataTable.rows({page:"current",search:"applied"}).nodes()).forEach((function(n){var i=n.querySelector(t.rowSelectingIndividual);if(i&&!i.checked)return e=!1,!1})),this.rowSelectingAll.checked=e},e.getInstance=function(t,e){var n=window.$hsDataTableCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.autoInit=function(){window.$hsDataTableCollection||(window.$hsDataTableCollection=[]),window.$hsDataTableCollection&&(window.$hsDataTableCollection=window.$hsDataTableCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-datatable]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsDataTableCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(l(n(961)).default);window.addEventListener("load",(function(){document.querySelectorAll("[data-hs-datatable]:not(.--prevent-on-load-init)").length&&("undefined"==typeof jQuery&&console.error("HSDataTable: jQuery is not available, please add it to the page."),"undefined"==typeof DataTable&&console.error("HSDataTable: DataTable is not available, please add it to the page.")),"undefined"!=typeof DataTable&&"undefined"!=typeof jQuery&&c.autoInit()})),"undefined"!=typeof window&&(window.HSDataTable=c),e.default=c},891:function(t,e,n){ + /* + * HSDropdown + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__spreadArray||function(t,e,n){if(n||2===arguments.length)for(var i,o=0,r=e.length;o .hs-dropdown-toggle")||o.el.querySelector(":scope > .hs-dropdown-toggle-wrapper > .hs-dropdown-toggle")||o.el.children[0],o.closers=Array.from(o.el.querySelectorAll(":scope .hs-dropdown-close"))||null,o.menu=o.el.querySelector(":scope > .hs-dropdown-menu"),o.eventMode=(0,l.getClassProperty)(o.el,"--trigger","click"),o.closeMode=(0,l.getClassProperty)(o.el,"--auto-close","true"),o.hasAutofocus=(0,l.stringToBoolean)((0,l.getClassProperty)(o.el,"--has-autofocus","true")||"true"),o.animationInProcess=!1,o.onCloserClickListener=[],o.toggle&&o.menu&&o.init(),o}return o(e,t),e.prototype.elementMouseEnter=function(){this.onMouseEnterHandler()},e.prototype.elementMouseLeave=function(){this.onMouseLeaveHandler()},e.prototype.toggleClick=function(t){this.onClickHandler(t)},e.prototype.toggleContextMenu=function(t){t.preventDefault(),this.onContextMenuHandler(t)},e.prototype.closerClick=function(){this.close()},e.prototype.init=function(){var t=this;if(this.createCollection(window.$hsDropdownCollection,this),this.toggle.disabled)return!1;this.toggle&&this.buildToggle(),this.menu&&this.buildMenu(),this.closers&&this.buildClosers(),(0,l.isIOS)()||(0,l.isIpadOS)()||(this.onElementMouseEnterListener=function(){return t.elementMouseEnter()},this.onElementMouseLeaveListener=function(){return t.elementMouseLeave()},this.el.addEventListener("mouseenter",this.onElementMouseEnterListener),this.el.addEventListener("mouseleave",this.onElementMouseLeaveListener))},e.prototype.resizeHandler=function(){this.eventMode=(0,l.getClassProperty)(this.el,"--trigger","click"),this.closeMode=(0,l.getClassProperty)(this.el,"--auto-close","true")},e.prototype.buildToggle=function(){var t,e=this;(null===(t=null==this?void 0:this.toggle)||void 0===t?void 0:t.ariaExpanded)&&(this.el.classList.contains("open")?this.toggle.ariaExpanded="true":this.toggle.ariaExpanded="false"),"contextmenu"===this.eventMode?(this.onToggleContextMenuListener=function(t){return e.toggleContextMenu(t)},this.toggle.addEventListener("contextmenu",this.onToggleContextMenuListener)):(this.onToggleClickListener=function(t){return e.toggleClick(t)},this.toggle.addEventListener("click",this.onToggleClickListener))},e.prototype.buildMenu=function(){var t=this;this.menu.role=this.menu.getAttribute("role")||"menu";var e=this.menu.querySelectorAll('[role="menuitemcheckbox"]'),n=this.menu.querySelectorAll('[role="menuitemradio"]');e.forEach((function(e){return e.addEventListener("click",(function(){return t.selectCheckbox(e)}))})),n.forEach((function(e){return e.addEventListener("click",(function(){return t.selectRadio(e)}))}))},e.prototype.buildClosers=function(){var t=this;this.closers.forEach((function(e){t.onCloserClickListener.push({el:e,fn:function(){return t.closerClick()}}),e.addEventListener("click",t.onCloserClickListener.find((function(t){return t.el===e})).fn)}))},e.prototype.getScrollbarSize=function(){var t=document.createElement("div");t.style.overflow="scroll",t.style.width="100px",t.style.height="100px",document.body.appendChild(t);var e=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),e},e.prototype.onContextMenuHandler=function(t){var n={getBoundingClientRect:function(){return new DOMRect(t.clientX,t.clientY,0,0)}};e.closeCurrentlyOpened(),this.el.classList.contains("open")&&!this.menu.classList.contains("hidden")?(this.close(),document.body.style.overflow="",document.body.style.paddingRight=""):(document.body.style.overflow="hidden",document.body.style.paddingRight="".concat(this.getScrollbarSize(),"px"),this.open(n))},e.prototype.onClickHandler=function(t){this.el.classList.contains("open")&&!this.menu.classList.contains("hidden")?this.close():this.open()},e.prototype.onMouseEnterHandler=function(){if("hover"!==this.eventMode)return!1;this.el._popper&&this.forceClearState(),!this.el.classList.contains("open")&&this.menu.classList.contains("hidden")&&this.open()},e.prototype.onMouseLeaveHandler=function(){if("hover"!==this.eventMode)return!1;this.el.classList.contains("open")&&!this.menu.classList.contains("hidden")&&this.close()},e.prototype.destroyPopper=function(){var t=(window.getComputedStyle(this.el).getPropertyValue("--scope")||"").replace(" ","");this.menu.classList.remove("block"),this.menu.classList.add("hidden"),this.menu.style.inset=null,this.menu.style.position=null,this.el&&this.el._popper&&this.el._popper.destroy(),"window"===t&&this.el.appendChild(this.menu),this.animationInProcess=!1},e.prototype.absoluteStrategyModifiers=function(){var t=this;return[{name:"applyStyles",fn:function(e){var n=(window.getComputedStyle(t.el).getPropertyValue("--strategy")||"absolute").replace(" ",""),i=(window.getComputedStyle(t.el).getPropertyValue("--adaptive")||"adaptive").replace(" ","");e.state.elements.popper.style.position=n,e.state.elements.popper.style.transform="adaptive"===i?e.state.styles.popper.transform:null,e.state.elements.popper.style.top=null,e.state.elements.popper.style.bottom=null,e.state.elements.popper.style.left=null,e.state.elements.popper.style.right=null,e.state.elements.popper.style.margin=0}}]},e.prototype.focusElement=function(){var t=this.menu.querySelector("[autofocus]");if(!t)return!1;t.focus()},e.prototype.setupPopper=function(t){var e=t||this.el,n=(window.getComputedStyle(this.el).getPropertyValue("--placement")||"").replace(" ",""),i=(window.getComputedStyle(this.el).getPropertyValue("--flip")||"true").replace(" ",""),o=(window.getComputedStyle(this.el).getPropertyValue("--strategy")||"fixed").replace(" ",""),s=parseInt((window.getComputedStyle(this.el).getPropertyValue("--offset")||"10").replace(" ","")),l=(window.getComputedStyle(this.el).getPropertyValue("--gpu-acceleration")||"true").replace(" ","");return(0,a.createPopper)(e,this.menu,{placement:u.POSITIONS[n]||"bottom-start",strategy:o,modifiers:r(r([],"fixed"!==o?this.absoluteStrategyModifiers():[],!0),[{name:"flip",enabled:"true"===i},{name:"offset",options:{offset:[0,s]}},{name:"computeStyles",options:{adaptive:"fixed"===o,gpuAcceleration:"true"===l}}],!1)})},e.prototype.selectCheckbox=function(t){t.ariaChecked="true"===t.ariaChecked?"false":"true"},e.prototype.selectRadio=function(t){if("true"===t.ariaChecked)return!1;var e=t.closest(".group").querySelectorAll('[role="menuitemradio"]');Array.from(e).filter((function(e){return e!==t})).forEach((function(t){t.ariaChecked="false"})),t.ariaChecked="true"},e.prototype.calculatePopperPosition=function(t){var e=this.setupPopper(t);e.forceUpdate();var n=e.state.placement;return e.destroy(),n},e.prototype.open=function(t){var e=this;if(this.el.classList.contains("open")||this.animationInProcess)return!1;var n=t||this.el;this.animationInProcess=!0;var i=(window.getComputedStyle(this.el).getPropertyValue("--scope")||"").replace(" ",""),o=(window.getComputedStyle(this.el).getPropertyValue("--placement")||"").replace(" ",""),s=(window.getComputedStyle(this.el).getPropertyValue("--flip")||"true").replace(" ",""),c=(window.getComputedStyle(this.el).getPropertyValue("--strategy")||"fixed").replace(" ",""),d=parseInt((window.getComputedStyle(this.el).getPropertyValue("--offset")||"10").replace(" ","")),h=(window.getComputedStyle(this.el).getPropertyValue("--gpu-acceleration")||"true").replace(" ","");"window"===i&&document.body.appendChild(this.menu),"static"!==c&&(this.el._popper=(0,a.createPopper)(n,this.menu,{placement:u.POSITIONS[o]||"bottom-start",strategy:c,modifiers:r(r([],"fixed"!==c?this.absoluteStrategyModifiers():[],!0),[{name:"flip",enabled:"true"===s},{name:"offset",options:{offset:[0,d]}},{name:"computeStyles",options:{adaptive:"fixed"===c,gpuAcceleration:"true"===h}}],!1)})),this.menu.style.margin=null,this.menu.classList.remove("hidden"),this.menu.classList.add("block"),setTimeout((function(){var t;(null===(t=null==e?void 0:e.toggle)||void 0===t?void 0:t.ariaExpanded)&&(e.toggle.ariaExpanded="true"),e.el.classList.add("open"),"window"===i&&e.menu.classList.add("open"),e.animationInProcess=!1,e.hasAutofocus&&e.focusElement()})),this.fireEvent("open",this.el),(0,l.dispatch)("open.hs.dropdown",this.el,this.el)},e.prototype.close=function(t){var e=this;if(void 0===t&&(t=!0),this.animationInProcess||!this.el.classList.contains("open"))return!1;var n,i=(window.getComputedStyle(this.el).getPropertyValue("--scope")||"").replace(" ","");if(this.animationInProcess=!0,"window"===i&&this.menu.classList.remove("open"),t){var o=this.el.querySelector("[data-hs-dropdown-transition]")||this.menu;(0,l.afterTransition)(o,(function(){return e.destroyPopper()}))}else this.destroyPopper();e.menu.style.margin=null,(null===(n=null==e?void 0:e.toggle)||void 0===n?void 0:n.ariaExpanded)&&(e.toggle.ariaExpanded="false"),e.el.classList.remove("open"),e.fireEvent("close",e.el),(0,l.dispatch)("close.hs.dropdown",e.el,e.el)},e.prototype.forceClearState=function(){this.destroyPopper(),this.menu.style.margin=null,this.el.classList.remove("open")},e.prototype.destroy=function(){var t=this;(0,l.isIOS)()||(0,l.isIpadOS)()||(this.el.removeEventListener("mouseenter",this.onElementMouseEnterListener),this.el.removeEventListener("mouseleave",(function(){return t.onElementMouseLeaveListener})),this.onElementMouseEnterListener=null,this.onElementMouseLeaveListener=null),this.toggle.removeEventListener("click",this.onToggleClickListener),this.onToggleClickListener=null,this.closers.length&&(this.closers.forEach((function(e){e.removeEventListener("click",t.onCloserClickListener.find((function(t){return t.el===e})).fn)})),this.onCloserClickListener=null),this.el.classList.remove("open"),this.destroyPopper(),window.$hsDropdownCollection=window.$hsDropdownCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsDropdownCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.autoInit=function(){if(!window.$hsDropdownCollection){window.$hsDropdownCollection=[],document.addEventListener("keydown",(function(t){return e.accessibility(t)})),window.addEventListener("click",(function(t){var n=t.target;e.closeCurrentlyOpened(n)}));var t=window.innerWidth;window.addEventListener("resize",(function(){window.innerWidth!==t&&(t=innerWidth,e.closeCurrentlyOpened(null,!1))}))}window.$hsDropdownCollection&&(window.$hsDropdownCollection=window.$hsDropdownCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll(".hs-dropdown:not(.--prevent-on-load-init)").forEach((function(t){window.$hsDropdownCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e.open=function(t){var e=window.$hsDropdownCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&e.element.menu.classList.contains("hidden")&&e.element.open()},e.close=function(t){var e=window.$hsDropdownCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&!e.element.menu.classList.contains("hidden")&&e.element.close()},e.accessibility=function(t){this.history=l.menuSearchHistory;var e=window.$hsDropdownCollection.find((function(t){return t.element.el.classList.contains("open")}));if(e&&(u.DROPDOWN_ACCESSIBILITY_KEY_SET.includes(t.code)||4===t.code.length&&t.code[t.code.length-1].match(/^[A-Z]*$/))&&!t.metaKey&&!e.element.menu.querySelector("input:focus")&&!e.element.menu.querySelector("textarea:focus"))switch(t.code){case"Escape":e.element.menu.querySelector(".hs-select.active")||(t.preventDefault(),this.onEscape(t));break;case"Enter":e.element.menu.querySelector(".hs-select button:focus")||e.element.menu.querySelector(".hs-collapse-toggle:focus")||this.onEnter(t);break;case"ArrowUp":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow();break;case"ArrowDown":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow(!1);break;case"ArrowRight":t.preventDefault(),t.stopImmediatePropagation(),this.onArrowX(t,"right");break;case"ArrowLeft":t.preventDefault(),t.stopImmediatePropagation(),this.onArrowX(t,"left");break;case"Home":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd();break;case"End":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd(!1);break;default:t.preventDefault(),this.onFirstLetter(t.key)}},e.onEscape=function(t){var e=t.target.closest(".hs-dropdown.open");if(window.$hsDropdownCollection.find((function(t){return t.element.el===e}))){var n=window.$hsDropdownCollection.find((function(t){return t.element.el===e}));n&&(n.element.close(),n.element.toggle.focus())}else this.closeCurrentlyOpened()},e.onEnter=function(t){var e,n=t.target,i=(null!==(e=window.$hsDropdownCollection.find((function(t){return t.element.el===n.closest(".hs-dropdown")})))&&void 0!==e?e:null).element;if(i&&n.classList.contains("hs-dropdown-toggle"))t.preventDefault(),i.open();else if(i&&"menuitemcheckbox"===n.getAttribute("role"))i.selectCheckbox(n),i.close();else{if(!i||"menuitemradio"!==n.getAttribute("role"))return!1;i.selectRadio(n),i.close()}},e.onArrow=function(t){void 0===t&&(t=!0);var e=window.$hsDropdownCollection.find((function(t){return t.element.el.classList.contains("open")}));if(e){var n=e.element.menu;if(!n)return!1;var i=t?Array.from(n.querySelectorAll('a:not([hidden]), .hs-dropdown > button:not([hidden]), [role="button"]:not([hidden]), [role^="menuitem"]:not([hidden])')).reverse():Array.from(n.querySelectorAll('a:not([hidden]), .hs-dropdown > button:not([hidden]), [role="button"]:not([hidden]), [role^="menuitem"]:not([hidden])')),o=Array.from(i).filter((function(t){var e=t;return null===e.closest("[hidden]")&&null!==e.offsetParent})).filter((function(t){return!t.classList.contains("disabled")})),r=n.querySelector('a:focus, button:focus, [role="button"]:focus, [role^="menuitem"]:focus'),s=o.findIndex((function(t){return t===r}));s+1\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t\t
\n\t\t\t\t\t\t

\n\t\t\t\t\t\t\t.\n\t\t\t\t\t\t

\n\t\t\t\t\t\t

\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t\t\t0%\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t',s.extensions=_.merge({default:{icon:'',class:"size-5"},xls:{icon:'',class:"size-5"},doc:{icon:'',class:"size-5"},zip:{icon:'',class:"size-5"}},a.extensions),s.singleton=a.singleton,s.concatOptions=r(r({clickable:s.el.querySelector("[data-hs-file-upload-trigger]"),previewsContainer:s.el.querySelector("[data-hs-file-upload-previews]"),addRemoveLinks:!1,previewTemplate:s.previewTemplate,autoHideTrigger:!1},a),n),s.onReloadButtonClickListener=[],s.onTempFileInputChangeListener=[],s.init(),s}return o(e,t),e.prototype.tempFileInputChange=function(t,e){var n,i=null===(n=t.target.files)||void 0===n?void 0:n[0];if(i){var o=i;o.status=Dropzone.ADDED,o.accepted=!0,o.previewElement=e.previewElement,o.previewTemplate=e.previewTemplate,o.previewsContainer=e.previewsContainer,this.dropzone.removeFile(e),this.dropzone.addFile(o)}},e.prototype.reloadButtonClick=function(t,e){var n=this;t.preventDefault(),t.stopPropagation();var i=document.createElement("input");i.type="file",this.onTempFileInputChangeListener.push({el:i,fn:function(t){return n.tempFileInputChange(t,e)}}),i.click(),i.addEventListener("change",this.onTempFileInputChangeListener.find((function(t){return t.el===i})).fn)},e.prototype.init=function(){this.createCollection(window.$hsFileUploadCollection,this),this.initDropzone()},e.prototype.initDropzone=function(){var t=this,e=this.el.querySelector("[data-hs-file-upload-clear]"),n=Array.from(this.el.querySelectorAll("[data-hs-file-upload-pseudo-trigger]"));this.dropzone=new Dropzone(this.el,this.concatOptions),this.dropzone.on("addedfile",(function(e){return t.onAddFile(e)})),this.dropzone.on("removedfile",(function(){return t.onRemoveFile()})),this.dropzone.on("uploadprogress",(function(e,n){return t.onUploadProgress(e,n)})),this.dropzone.on("complete",(function(e){return t.onComplete(e)})),e&&(e.onclick=function(){t.dropzone.files.length&&t.dropzone.removeAllFiles(!0)}),n.length&&n.forEach((function(e){e.onclick=function(){var e,n;(null===(e=t.concatOptions)||void 0===e?void 0:e.clickable)&&(null===(n=t.concatOptions)||void 0===n?void 0:n.clickable).click()}}))},e.prototype.destroy=function(){var t=this;this.onTempFileInputChangeListener.forEach((function(t){t.el.removeEventListener("change",t.fn)})),this.onTempFileInputChangeListener=null,this.onReloadButtonClickListener.forEach((function(t){t.el.removeEventListener("click",t.fn)})),this.onReloadButtonClickListener=null,this.dropzone.destroy(),window.$hsFileUploadCollection=window.$hsFileUploadCollection.filter((function(e){return e.element.el!==t.el}))},e.prototype.onAddFile=function(t){var e=this,n=t.previewElement,i=t.previewElement.querySelector("[data-hs-file-upload-reload]");if(!n)return!1;this.singleton&&this.dropzone.files.length>1&&this.dropzone.removeFile(this.dropzone.files[0]),i&&(this.onReloadButtonClickListener.push({el:i,fn:function(n){return e.reloadButtonClick(n,t)}}),i.addEventListener("click",this.onReloadButtonClickListener.find((function(t){return t.el===i})).fn)),this.previewAccepted(t)},e.prototype.previewAccepted=function(t){var e=this,n=t.previewElement,i=this.splitFileName(t.name),o=n.querySelector("[data-hs-file-upload-file-name]"),r=n.querySelector("[data-hs-file-upload-file-ext]"),s=n.querySelector("[data-hs-file-upload-file-size]"),l=n.querySelector("[data-hs-file-upload-file-icon]"),a=this.el.querySelector("[data-hs-file-upload-trigger]"),c=n.querySelector("[data-dz-thumbnail]"),u=n.querySelector("[data-hs-file-upload-remove]");o&&(o.textContent=i.name),r&&(r.textContent=i.extension),s&&(s.textContent=this.formatFileSize(t.size)),c&&(t.type.includes("image/")?c.classList.remove("hidden"):this.setIcon(i.extension,l)),this.dropzone.files.length>0&&this.concatOptions.autoHideTrigger&&(a.style.display="none"),u&&(u.onclick=function(){return e.dropzone.removeFile(t)})},e.prototype.onRemoveFile=function(){var t=this.el.querySelector("[data-hs-file-upload-trigger]");0===this.dropzone.files.length&&this.concatOptions.autoHideTrigger&&(t.style.display="")},e.prototype.onUploadProgress=function(t,e){var n=t.previewElement;if(!n)return!1;var i=n.querySelector("[data-hs-file-upload-progress-bar]"),o=n.querySelector("[data-hs-file-upload-progress-bar-pane]"),r=n.querySelector("[data-hs-file-upload-progress-bar-value]"),s=Math.floor(e);i&&i.setAttribute("aria-valuenow","".concat(s)),o&&(o.style.width="".concat(s,"%")),r&&(r.innerText="".concat(s))},e.prototype.onComplete=function(t){var e=t.previewElement;if(!e)return!1;e.classList.add("complete")},e.prototype.setIcon=function(t,e){var n=this.createIcon(t);e.append(n)},e.prototype.createIcon=function(t){var e,n,i=(null===(e=this.extensions[t])||void 0===e?void 0:e.icon)?(0,l.htmlToElement)(this.extensions[t].icon):(0,l.htmlToElement)(this.extensions.default.icon);return(0,l.classToClassList)((null===(n=this.extensions[t])||void 0===n?void 0:n.class)?this.extensions[t].class:this.extensions.default.class,i),i},e.prototype.formatFileSize=function(t){return t<1024?t.toFixed(2)+" B":t<1048576?(t/1024).toFixed(2)+" KB":t<1073741824?(t/1048576).toFixed(2)+" MB":t<1099511627776?(t/1073741824).toFixed(2)+" GB":(t/1099511627776).toFixed(2)+" TB"},e.prototype.splitFileName=function(t){var e=t.lastIndexOf(".");return-1==e?{name:t,extension:""}:{name:t.substring(0,e),extension:t.substring(e+1)}},e.getInstance=function(t,e){var n=window.$hsFileUploadCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.autoInit=function(){window.$hsFileUploadCollection||(window.$hsFileUploadCollection=[]),window.$hsFileUploadCollection&&(window.$hsFileUploadCollection=window.$hsFileUploadCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-file-upload]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsFileUploadCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(a.default);window.addEventListener("load",(function(){document.querySelectorAll("[data-hs-file-upload]:not(.--prevent-on-load-init)").length&&("undefined"==typeof _&&console.error("HSFileUpload: Lodash is not available, please add it to the page."),"undefined"==typeof Dropzone&&console.error("HSFileUpload: Dropzone is not available, please add it to the page.")),"undefined"!=typeof _&&"undefined"!=typeof Dropzone&&c.autoInit()})),"undefined"!=typeof window&&(window.HSFileUpload=c),e.default=c},332:function(t,e,n){ + /* + * HSInputNumber + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0?l.step:1,i.init(),i}return o(e,t),e.prototype.inputInput=function(){this.changeValue()},e.prototype.incrementClick=function(){this.changeValue("increment")},e.prototype.decrementClick=function(){this.changeValue("decrement")},e.prototype.init=function(){this.createCollection(window.$hsInputNumberCollection,this),this.input&&this.increment&&this.build()},e.prototype.checkIsNumberAndConvert=function(){var t=this.input.value.trim(),e=this.cleanAndExtractNumber(t);null!==e?(this.inputValue=e,this.input.value=e.toString()):(this.inputValue=0,this.input.value="0")},e.prototype.cleanAndExtractNumber=function(t){var e=[],n=!1;t.split("").forEach((function(t){t>="0"&&t<="9"?e.push(t):"."!==t||n||(e.push(t),n=!0)}));var i=e.join(""),o=parseFloat(i);return isNaN(o)?null:o},e.prototype.build=function(){this.input&&this.buildInput(),this.increment&&this.buildIncrement(),this.decrement&&this.buildDecrement(),this.inputValue<=this.minInputValue&&(this.inputValue=this.minInputValue,this.input.value="".concat(this.minInputValue)),this.inputValue<=this.minInputValue&&this.changeValue(),this.input.hasAttribute("disabled")&&this.disableButtons()},e.prototype.buildInput=function(){var t=this;this.onInputInputListener=function(){return t.inputInput()},this.input.addEventListener("input",this.onInputInputListener)},e.prototype.buildIncrement=function(){var t=this;this.onIncrementClickListener=function(){return t.incrementClick()},this.increment.addEventListener("click",this.onIncrementClickListener)},e.prototype.buildDecrement=function(){var t=this;this.onDecrementClickListener=function(){return t.decrementClick()},this.decrement.addEventListener("click",this.onDecrementClickListener)},e.prototype.changeValue=function(t){var e,n;void 0===t&&(t="none");var i={inputValue:this.inputValue},o=null!==(e=this.minInputValue)&&void 0!==e?e:Number.MIN_SAFE_INTEGER,r=null!==(n=this.maxInputValue)&&void 0!==n?n:Number.MAX_SAFE_INTEGER;switch(this.inputValue=isNaN(this.inputValue)?0:this.inputValue,t){case"increment":var s=this.inputValue+this.step;this.inputValue=s>=o&&s<=r?s:r,this.input.value=this.inputValue.toString();break;case"decrement":var a=this.inputValue-this.step;this.inputValue=a>=o&&a<=r?a:o,this.input.value=this.inputValue.toString();break;default:var c=isNaN(parseInt(this.input.value))?0:parseInt(this.input.value);this.inputValue=c>=r?r:c<=o?o:c,this.inputValue<=o&&(this.input.value=this.inputValue.toString())}i.inputValue=this.inputValue,this.inputValue===o?(this.el.classList.add("disabled"),this.decrement&&this.disableButtons("decrement")):(this.el.classList.remove("disabled"),this.decrement&&this.enableButtons("decrement")),this.inputValue===r?(this.el.classList.add("disabled"),this.increment&&this.disableButtons("increment")):(this.el.classList.remove("disabled"),this.increment&&this.enableButtons("increment")),this.fireEvent("change",i),(0,l.dispatch)("change.hs.inputNumber",this.el,i)},e.prototype.disableButtons=function(t){void 0===t&&(t="all"),"all"===t?("BUTTON"!==this.increment.tagName&&"INPUT"!==this.increment.tagName||this.increment.setAttribute("disabled","disabled"),"BUTTON"!==this.decrement.tagName&&"INPUT"!==this.decrement.tagName||this.decrement.setAttribute("disabled","disabled")):"increment"===t?"BUTTON"!==this.increment.tagName&&"INPUT"!==this.increment.tagName||this.increment.setAttribute("disabled","disabled"):"decrement"===t&&("BUTTON"!==this.decrement.tagName&&"INPUT"!==this.decrement.tagName||this.decrement.setAttribute("disabled","disabled"))},e.prototype.enableButtons=function(t){void 0===t&&(t="all"),"all"===t?("BUTTON"!==this.increment.tagName&&"INPUT"!==this.increment.tagName||this.increment.removeAttribute("disabled"),"BUTTON"!==this.decrement.tagName&&"INPUT"!==this.decrement.tagName||this.decrement.removeAttribute("disabled")):"increment"===t?"BUTTON"!==this.increment.tagName&&"INPUT"!==this.increment.tagName||this.increment.removeAttribute("disabled"):"decrement"===t&&("BUTTON"!==this.decrement.tagName&&"INPUT"!==this.decrement.tagName||this.decrement.removeAttribute("disabled"))},e.prototype.destroy=function(){var t=this;this.el.classList.remove("disabled"),this.increment.removeAttribute("disabled"),this.decrement.removeAttribute("disabled"),this.input.removeEventListener("input",this.onInputInputListener),this.increment.removeEventListener("click",this.onIncrementClickListener),this.decrement.removeEventListener("click",this.onDecrementClickListener),window.$hsInputNumberCollection=window.$hsInputNumberCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsInputNumberCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsInputNumberCollection||(window.$hsInputNumberCollection=[]),window.$hsInputNumberCollection&&(window.$hsInputNumberCollection=window.$hsInputNumberCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-input-number]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsInputNumberCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSInputNumber=a),e.default=a},812:function(t,e,n){var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n",o.verticalSplitterClasses=(null==a?void 0:a.verticalSplitterClasses)||null,o.verticalSplitterTemplate=(null==a?void 0:a.verticalSplitterTemplate)||"
",o.isSplittersAddedManually=null!==(i=null==a?void 0:a.isSplittersAddedManually)&&void 0!==i&&i,o.horizontalSplitters=[],o.horizontalControls=[],o.verticalSplitters=[],o.verticalControls=[],o.isDragging=!1,o.activeSplitter=null,o.onControlPointerDownListener=[],o.init(),o}return o(e,t),e.prototype.controlPointerDown=function(t){this.isDragging=!0,this.activeSplitter=t,this.onPointerDownHandler(t)},e.prototype.controlPointerUp=function(){this.isDragging=!1,this.activeSplitter=null,this.onPointerUpHandler()},e.prototype.init=function(){this.createCollection(window.$hsLayoutSplitterCollection,this),this.buildSplitters(),e.isListenersInitialized||(document.addEventListener("pointermove",e.onDocumentPointerMove),document.addEventListener("pointerup",e.onDocumentPointerUp),e.isListenersInitialized=!0)},e.prototype.buildSplitters=function(){this.buildHorizontalSplitters(),this.buildVerticalSplitters()},e.prototype.buildHorizontalSplitters=function(){var t=this,e=this.el.querySelectorAll("[data-hs-layout-splitter-horizontal-group]");e.length&&(e.forEach((function(e){t.horizontalSplitters.push({el:e,items:Array.from(e.querySelectorAll(":scope > [data-hs-layout-splitter-item]"))})})),this.updateHorizontalSplitter())},e.prototype.buildVerticalSplitters=function(){var t=this,e=this.el.querySelectorAll("[data-hs-layout-splitter-vertical-group]");e.length&&(e.forEach((function(e){t.verticalSplitters.push({el:e,items:Array.from(e.querySelectorAll(":scope > [data-hs-layout-splitter-item]"))})})),this.updateVerticalSplitter())},e.prototype.buildControl=function(t,e,n){var i;if(void 0===n&&(n="horizontal"),this.isSplittersAddedManually){if(!(i=null==e?void 0:e.previousElementSibling))return!1;i.style.display=""}else i=(0,l.htmlToElement)("horizontal"===n?this.horizontalSplitterTemplate:this.verticalSplitterTemplate),(0,l.classToClassList)("horizontal"===n?this.horizontalSplitterClasses:this.verticalSplitterClasses,i),i.classList.add("hs-layout-splitter-control");var o={el:i,direction:n,prev:t,next:e};"horizontal"===n?this.horizontalControls.push(o):this.verticalControls.push(o),this.bindListeners(o),e&&!this.isSplittersAddedManually&&t.insertAdjacentElement("afterend",i)},e.prototype.getSplitterItemParsedParam=function(t){var e=t.getAttribute("data-hs-layout-splitter-item");return(0,l.isJson)(e)?JSON.parse(e):e},e.prototype.getContainerSize=function(t,e){return e?t.getBoundingClientRect().width:t.getBoundingClientRect().height},e.prototype.getMaxFlexSize=function(t,e,n){var i=this.getSplitterItemSingleParam(t,e);return"number"==typeof i?i/100*n:0},e.prototype.updateHorizontalSplitter=function(){var t=this;this.horizontalSplitters.forEach((function(e){var n=e.items;n.forEach((function(e){t.updateSingleSplitter(e)})),n.forEach((function(e,i){i>=n.length-1?t.buildControl(e,null):t.buildControl(e,n[i+1])}))}))},e.prototype.updateSingleSplitter=function(t){var e=t.getAttribute("data-hs-layout-splitter-item"),n=(0,l.isJson)(e)?JSON.parse(e):e,i=(0,l.isJson)(e)?n.dynamicSize:e;t.style.flex="".concat(i," 1 0")},e.prototype.updateVerticalSplitter=function(){var t=this;this.verticalSplitters.forEach((function(e){var n=e.items;n.forEach((function(e){t.updateSingleSplitter(e)})),n.forEach((function(e,i){i>=n.length-1?t.buildControl(e,null,"vertical"):t.buildControl(e,n[i+1],"vertical")}))}))},e.prototype.updateSplitterItemParam=function(t,e){var n=this.getSplitterItemParsedParam(t),i=e.toFixed(1),o="object"==typeof n?JSON.stringify(r(r({},n),{dynamicSize:+i})):i;t.setAttribute("data-hs-layout-splitter-item",o)},e.prototype.onPointerDownHandler=function(t){var e=t.el,n=t.prev,i=t.next;e.classList.add("dragging"),n.classList.add("dragging"),i.classList.add("dragging"),document.body.style.userSelect="none"},e.prototype.onPointerUpHandler=function(){document.body.style.userSelect=""},e.prototype.onPointerMoveHandler=function(t,e,n){var i=e.prev,o=e.next,r=e.el.closest("horizontal"===n?"[data-hs-layout-splitter-horizontal-group]":"[data-hs-layout-splitter-vertical-group]"),s="horizontal"===n,l=this.getContainerSize(r,s),a=this.calculateAvailableSize(r,i,o,s,l),c=this.calculateResizedSizes(t,i,a,s),u=this.enforceLimits(c,i,o,l,a);this.applySizes(i,o,u,l)},e.prototype.bindListeners=function(t){var e=this,n=t.el;this.onControlPointerDownListener.push({el:n,fn:function(){return e.controlPointerDown(t)}}),n.addEventListener("pointerdown",this.onControlPointerDownListener.find((function(t){return t.el===n})).fn)},e.prototype.calculateAvailableSize=function(t,e,n,i,o){var r=t.querySelectorAll(":scope > [data-hs-layout-splitter-item]");return o-Array.from(r).reduce((function(t,o){if(o===e||o===n)return t;var r=o.getBoundingClientRect();return t+("fixed"===window.getComputedStyle(o).position?0:i?r.width:r.height)}),0)},e.prototype.calculateResizedSizes=function(t,e,n,i){var o=i?e.getBoundingClientRect().left:e.getBoundingClientRect().top,r=Math.max(0,Math.min((i?t.clientX:t.clientY)-o,n));return{previousSize:r,nextSize:n-r}},e.prototype.enforceLimits=function(t,e,n,i,o){var r=this.getMaxFlexSize(e,"minSize",i),s=this.getMaxFlexSize(n,"minSize",i),a=this.getMaxFlexSize(e,"preLimitSize",i),c=this.getMaxFlexSize(n,"preLimitSize",i),u=t.previousSize,d=t.nextSize;d=0;n--)if(i>=e[n])return t[e[n]];return 0}(r);e.updateSplitterItemParam(s,l),s.style.flex="".concat(l.toFixed(1)," 1 0"),n+=l}})),100!==n){var o=100/n;t.forEach((function(t){var n=t.id,i=document.getElementById(n);if(i){var r=parseFloat(i.style.flex.split(" ")[0])*o;e.updateSplitterItemParam(i,r),i.style.flex="".concat(r.toFixed(1)," 1 0")}}))}},e.prototype.destroy=function(){var t=this;this.onControlPointerDownListener&&(this.onControlPointerDownListener.forEach((function(t){var e=t.el,n=t.fn;e.removeEventListener("pointerdown",n)})),this.onControlPointerDownListener=null),this.horizontalSplitters.forEach((function(t){t.items.forEach((function(t){t.style.flex=""}))})),this.verticalSplitters.forEach((function(t){t.items.forEach((function(t){t.style.flex=""}))})),this.horizontalControls.forEach((function(e){var n=e.el;t.isSplittersAddedManually?n.style.display="none":n.remove()})),this.verticalControls.forEach((function(e){var n=e.el;t.isSplittersAddedManually?n.style.display="none":n.remove()})),this.horizontalControls=[],this.verticalControls=[],window.$hsLayoutSplitterCollection=window.$hsLayoutSplitterCollection.filter((function(e){return e.element.el!==t.el})),0===window.$hsLayoutSplitterCollection.length&&e.isListenersInitialized&&(document.removeEventListener("pointermove",e.onDocumentPointerMove),document.removeEventListener("pointerup",e.onDocumentPointerUp),e.isListenersInitialized=!1)},e.autoInit=function(){window.$hsLayoutSplitterCollection||(window.$hsLayoutSplitterCollection=[],window.addEventListener("pointerup",(function(){if(!window.$hsLayoutSplitterCollection)return!1;var t=document.querySelector(".hs-layout-splitter-control.dragging"),n=document.querySelectorAll("[data-hs-layout-splitter-item].dragging");if(!t)return!1;var i=e.getInstance(t.closest("[data-hs-layout-splitter]"),!0);t.classList.remove("dragging"),n.forEach((function(t){return t.classList.remove("dragging")})),i.element.isDragging=!1}))),window.$hsLayoutSplitterCollection&&(window.$hsLayoutSplitterCollection=window.$hsLayoutSplitterCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-layout-splitter]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsLayoutSplitterCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e.getInstance=function(t,e){var n=window.$hsLayoutSplitterCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.on=function(t,e,n){var i=window.$hsLayoutSplitterCollection.find((function(t){return t.element.el===("string"==typeof e?document.querySelector(e):e)}));i&&(i.element.events[t]=n)},e.isListenersInitialized=!1,e.onDocumentPointerMove=function(t){var n=document.querySelector(".hs-layout-splitter-control.dragging");if(n){var i=e.getInstance(n.closest("[data-hs-layout-splitter]"),!0);if(i&&i.element.isDragging){var o=i.element.activeSplitter;o&&("vertical"===o.direction?i.element.onPointerMoveHandler(t,o,"vertical"):i.element.onPointerMoveHandler(t,o,"horizontal"))}}},e.onDocumentPointerUp=function(){var t=document.querySelector(".hs-layout-splitter-control.dragging");if(t){var n=e.getInstance(t.closest("[data-hs-layout-splitter]"),!0);n&&n.element.controlPointerUp()}},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSLayoutSplitter=a),e.default=a},850:function(t,e,n){ + /* + * HSOverlay + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n=t?(document.body.classList.add("hs-overlay-body-open"),e.element.overlay.classList.add("opened")):e.element.close(!0)},e.accessibility=function(t){var e,n,i=window.$hsOverlayCollection.filter((function(t){return t.element.overlay.classList.contains("open")})),o=i[i.length-1],r=null===(n=null===(e=null==o?void 0:o.element)||void 0===e?void 0:e.overlay)||void 0===n?void 0:n.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'),s=[];(null==r?void 0:r.length)&&r.forEach((function(t){(0,l.isParentOrElementHidden)(t)||s.push(t)}));var a=o&&!t.metaKey;if(a&&!o.element.isTabAccessibilityLimited&&"Tab"===t.code)return!1;a&&s.length&&"Tab"===t.code&&(t.preventDefault(),this.onTab(o)),a&&"Escape"===t.code&&(t.preventDefault(),this.onEscape(o))},e.onEscape=function(t){t&&t.element.hasAbilityToCloseOnBackdropClick&&t.element.close()},e.onTab=function(t){var e=t.element.overlay,n=Array.from(e.querySelectorAll('button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])'));if(0===n.length)return!1;var i=e.querySelector(":focus");if(i){for(var o=!1,r=0,s=n;re&&!n.contains(o)&&n.appendChild(o)}))};window.addEventListener("load",(function(){c.autoInit(),u()})),window.addEventListener("resize",(function(){!function(){if(!window.$hsOverlayCollection.length||!window.$hsOverlayCollection.find((function(t){return t.element.autoClose})))return!1;window.$hsOverlayCollection.filter((function(t){return t.element.autoClose})).forEach((function(t){var e=t.element,n=e.autoCloseEqualityType,i=e.autoClose;("less-than"===n?document.body.clientWidth<=i:document.body.clientWidth>=i)&&t.element.close(!0)}))}(),u(),function(){if(!window.$hsOverlayCollection.length||!window.$hsOverlayCollection.find((function(t){return t.element.autoClose})))return!1;window.$hsOverlayCollection.filter((function(t){return t.element.autoClose})).forEach((function(t){var e=t.element,n=e.autoCloseEqualityType,i=e.autoClose;("less-than"===n?document.body.clientWidth<=i:document.body.clientWidth>=i)&&t.element.close(!0)}))}(),function(){if(!window.$hsOverlayCollection.length||!window.$hsOverlayCollection.find((function(t){return t.element.overlay.classList.contains("opened")})))return!1;window.$hsOverlayCollection.filter((function(t){return t.element.overlay.classList.contains("opened")})).forEach((function(t){var e=parseInt(window.getComputedStyle(t.element.overlay).getPropertyValue("z-index")),n=document.querySelector("#".concat(t.element.overlay.id,"-backdrop"));if(e===parseInt(window.getComputedStyle(n).getPropertyValue("z-index"))+1)return!1;"style"in n&&(n.style.zIndex="".concat(e-1)),document.body.classList.add("hs-overlay-body-open")}))}()})),"undefined"!=typeof window&&(window.HSOverlay=c),e.default=c},60:function(t,e,n){ + /* + * HSPinInput + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0&&this.items[e-1].focus()},e.prototype.onKeydown=function(t,e){"Backspace"===t.key&&e>0&&(""===this.items[e].value?(this.items[e-1].value="",this.items[e-1].focus()):this.items[e].value=""),this.setCurrentValue(),this.toggleCompleted()},e.prototype.onFocusIn=function(t){this.items[t].setAttribute("placeholder","")},e.prototype.onFocusOut=function(t){this.items[t].setAttribute("placeholder",this.placeholders[t])},e.prototype.onPaste=function(t){var e=this;t.preventDefault(),this.items.forEach((function(n){document.activeElement===n&&e.autoFillAll(t.clipboardData.getData("text"))}))},e.prototype.destroy=function(){var t=this;this.el.classList.remove("active"),this.items.length&&this.items.forEach((function(e){e.removeEventListener("input",t.onElementInputListener.find((function(t){return t.el===e})).fn),e.removeEventListener("paste",t.onElementPasteListener.find((function(t){return t.el===e})).fn),e.removeEventListener("keydown",t.onElementKeydownListener.find((function(t){return t.el===e})).fn),e.removeEventListener("focusin",t.onElementFocusinListener.find((function(t){return t.el===e})).fn),e.removeEventListener("focusout",t.onElementFocusoutListener.find((function(t){return t.el===e})).fn)})),this.items=null,this.currentItem=null,this.currentValue=null,window.$hsPinInputCollection=window.$hsPinInputCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsPinInputCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsPinInputCollection||(window.$hsPinInputCollection=[]),window.$hsPinInputCollection&&(window.$hsPinInputCollection=window.$hsPinInputCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-pin-input]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsPinInputCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSPinInput=a),e.default=a},347:function(t,e,n){ + /* + * HSRangeSlider + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0){if(this.activeSection===e)return!1;this.links.forEach((function(t){t.classList.remove("active")}));var a=this.el.querySelector('[href="#'.concat(e.getAttribute("id"),'"]'));if(a){a.classList.add("active");var c=a.closest("[data-hs-scrollspy-group]");if(c){var u=c.querySelector("[href]");u&&u.classList.add("active")}}this.activeSection=e}},e.prototype.scrollTo=function(t){var e=t.getAttribute("href"),n=document.querySelector(e),i=parseInt((0,s.getClassProperty)(this.el,"--scrollspy-offset","0")),o=parseInt((0,s.getClassProperty)(n,"--scrollspy-offset"))||i,r=this.scrollable===document?0:this.scrollable.offsetTop,l=n.offsetTop-o-r,a=this.scrollable===document?window:this.scrollable,c=function(){window.history.replaceState(null,null,t.getAttribute("href")),"scrollTo"in a&&a.scrollTo({top:l,left:0,behavior:"smooth"})},u=this.fireEvent("beforeScroll",this.el);(0,s.dispatch)("beforeScroll.hs.scrollspy",this.el,this.el),u instanceof Promise?u.then((function(){return c()})):c()},e.prototype.destroy=function(){var t=this;this.el.querySelector("[href].active").classList.remove("active"),this.scrollable.removeEventListener("scroll",this.onScrollableScrollListener),this.onLinkClickListener.length&&this.onLinkClickListener.forEach((function(t){var e=t.el,n=t.fn;e.removeEventListener("click",n)})),window.$hsScrollspyCollection=window.$hsScrollspyCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){void 0===e&&(e=!1);var n=window.$hsScrollspyCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element.el:null},e.autoInit=function(){window.$hsScrollspyCollection||(window.$hsScrollspyCollection=[]),window.$hsScrollspyCollection&&(window.$hsScrollspyCollection=window.$hsScrollspyCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-scrollspy]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsScrollspyCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(r(n(961)).default);window.addEventListener("load",(function(){l.autoInit()})),"undefined"!=typeof window&&(window.HSScrollspy=l),e.default=l},442:function(t,e,n){ + /* + * HSSelect + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0&&o[o.length-1])||6!==l[0]&&2!==l[0])){s=0;continue}if(3===l[0]&&(!o||l[1]>o[0]&&l[1]",l.searchNoResultText=(null==u?void 0:u.searchNoResultText)||"No results found",l.searchNoResultClasses=(null==u?void 0:u.searchNoResultClasses)||"px-4 text-sm text-gray-800 dark:text-neutral-200",l.optionTemplate=(null==u?void 0:u.optionTemplate)||null,l.optionTag=(null==u?void 0:u.optionTag)||null,l.optionClasses=(null==u?void 0:u.optionClasses)||null,l.extraMarkup=(null==u?void 0:u.extraMarkup)||null,l.descriptionClasses=(null==u?void 0:u.descriptionClasses)||null,l.iconClasses=(null==u?void 0:u.iconClasses)||null,l.isAddTagOnEnter=null===(s=null==u?void 0:u.isAddTagOnEnter)||void 0===s||s,l.animationInProcess=!1,l.selectOptions=[],l.remoteOptions=[],l.tagsInputHelper=null,l.init(),l}return o(e,t),e.prototype.wrapperClick=function(t){t.target.closest("[data-hs-select-dropdown]")||t.target.closest("[data-tag-value]")||this.tagsInput.focus()},e.prototype.toggleClick=function(){if(this.isDisabled)return!1;this.toggleFn()},e.prototype.tagsInputFocus=function(){this.isOpened||this.open()},e.prototype.tagsInputInput=function(){this.calculateInputWidth()},e.prototype.tagsInputInputSecond=function(t){this.searchOptions(t.target.value)},e.prototype.tagsInputKeydown=function(t){if("Enter"===t.key&&this.isAddTagOnEnter){var e=t.target.value;if(this.selectOptions.find((function(t){return t.val===e})))return!1;this.addSelectOption(e,e),this.buildOption(e,e),this.dropdown.querySelector('[data-value="'.concat(e,'"]')).click(),this.resetTagsInputField()}},e.prototype.searchInput=function(t){this.apiUrl?this.remoteSearch(t.target.value):this.searchOptions(t.target.value)},e.prototype.setValue=function(t){this.value=t,this.clearSelections(),Array.isArray(t)?(this.toggleTextWrapper.innerHTML=this.value.length?this.stringFromValue():this.placeholder,this.unselectMultipleItems(),this.selectMultipleItems()):(this.setToggleTitle(),this.toggle.querySelector("[data-icon]")&&this.setToggleIcon(),this.toggle.querySelector("[data-title]")&&this.setToggleTitle(),this.selectSingleItem())},e.prototype.init=function(){this.createCollection(window.$hsSelectCollection,this),this.build()},e.prototype.build=function(){var t=this;if(this.el.style.display="none",this.el.children&&Array.from(this.el.children).filter((function(t){return t.value&&""!==t.value})).forEach((function(e){var n=e.getAttribute("data-hs-select-option");t.selectOptions=a(a([],t.selectOptions,!0),[{title:e.textContent,val:e.value,disabled:e.disabled,options:"undefined"!==n?JSON.parse(n):null}],!1)})),this.isMultiple){var e=Array.from(this.el.children).filter((function(t){return t.selected}));if(e){var n=[];e.forEach((function(t){n.push(t.value)})),this.value=n}}this.buildWrapper(),"tags"===this.mode?this.buildTags():this.buildToggle(),this.buildDropdown(),this.extraMarkup&&this.buildExtraMarkup()},e.prototype.buildWrapper=function(){var t=this;this.wrapper=document.createElement("div"),this.wrapper.classList.add("hs-select","relative"),"tags"===this.mode&&(this.onWrapperClickListener=function(e){return t.wrapperClick(e)},this.wrapper.addEventListener("click",this.onWrapperClickListener)),this.wrapperClasses&&(0,u.classToClassList)(this.wrapperClasses,this.wrapper),this.el.before(this.wrapper),this.wrapper.append(this.el)},e.prototype.buildExtraMarkup=function(){var t=this,e=function(e){var n=(0,u.htmlToElement)(e);return t.wrapper.append(n),n},n=function(e){e.classList.contains("--prevent-click")||e.addEventListener("click",(function(e){e.stopPropagation(),t.toggleFn()}))};if(Array.isArray(this.extraMarkup))this.extraMarkup.forEach((function(t){var i=e(t);n(i)}));else{var i=e(this.extraMarkup);n(i)}},e.prototype.buildToggle=function(){var t,e,n,i,o=this;this.toggleTextWrapper=document.createElement("span"),this.toggleTextWrapper.classList.add("truncate"),this.toggle=(0,u.htmlToElement)(this.toggleTag||"
"),n=this.toggle.querySelector("[data-icon]"),i=this.toggle.querySelector("[data-title]"),!this.isMultiple&&n&&this.setToggleIcon(),!this.isMultiple&&i&&this.setToggleTitle(),this.isMultiple?this.toggleTextWrapper.innerHTML=this.value.length?this.stringFromValue():this.placeholder:this.toggleTextWrapper.innerHTML=(null===(t=this.getItemByValue(this.value))||void 0===t?void 0:t.title)||this.placeholder,i||this.toggle.append(this.toggleTextWrapper),this.toggleClasses&&(0,u.classToClassList)(this.toggleClasses,this.toggle),this.isDisabled&&this.toggle.classList.add("disabled"),this.wrapper&&this.wrapper.append(this.toggle),(null===(e=this.toggle)||void 0===e?void 0:e.ariaExpanded)&&(this.isOpened?this.toggle.ariaExpanded="true":this.toggle.ariaExpanded="false"),this.onToggleClickListener=function(){return o.toggleClick()},this.toggle.addEventListener("click",this.onToggleClickListener)},e.prototype.setToggleIcon=function(){var t,e=this.getItemByValue(this.value),n=this.toggle.querySelector("[data-icon]");if(n){n.innerHTML="";var i=(0,u.htmlToElement)(this.apiUrl&&this.apiIconTag?this.apiIconTag||"":(null===(t=null==e?void 0:e.options)||void 0===t?void 0:t.icon)||"");this.value&&this.apiUrl&&this.apiIconTag&&e[this.apiFieldsMap.icon]&&(i.src=e[this.apiFieldsMap.icon]||""),n.append(i),i?n.classList.remove("hidden"):n.classList.add("hidden")}},e.prototype.setToggleTitle=function(){var t,e=this.toggle.querySelector("[data-title]");e&&(e.innerHTML=(null===(t=this.getItemByValue(this.value))||void 0===t?void 0:t.title)||this.placeholder,e.classList.add("truncate"),this.toggle.append(e))},e.prototype.buildTags=function(){this.isDisabled&&this.wrapper.classList.add("disabled"),this.buildTagsInput(),this.setTagsItems()},e.prototype.reassignTagsInputPlaceholder=function(t){this.tagsInput.placeholder=t,this.tagsInputHelper.innerHTML=t,this.calculateInputWidth()},e.prototype.buildTagsItem=function(t){var e,n,i,o,r,s,l,a,c=this,d=this.getItemByValue(t),h=document.createElement("div");if(h.setAttribute("data-tag-value",t),this.tagsItemClasses&&(0,u.classToClassList)(this.tagsItemClasses,h),this.tagsItemTemplate&&(r=(0,u.htmlToElement)(this.tagsItemTemplate),h.append(r)),(null===(e=null==d?void 0:d.options)||void 0===e?void 0:e.icon)||this.apiIconTag){var p=(0,u.htmlToElement)(this.apiUrl&&this.apiIconTag?this.apiIconTag:null===(n=null==d?void 0:d.options)||void 0===n?void 0:n.icon);this.apiUrl&&this.apiIconTag&&d[this.apiFieldsMap.icon]&&(p.src=d[this.apiFieldsMap.icon]||""),(a=r?r.querySelector("[data-icon]"):document.createElement("span")).append(p),r||h.append(a)}!r||!r.querySelector("[data-icon]")||(null===(i=null==d?void 0:d.options)||void 0===i?void 0:i.icon)||this.apiUrl||this.apiIconTag||d[null===(o=this.apiFieldsMap)||void 0===o?void 0:o.icon]||r.querySelector("[data-icon]").classList.add("hidden"),(s=r?r.querySelector("[data-title]"):document.createElement("span")).textContent=d.title||"",r||h.append(s),r?l=r.querySelector("[data-remove]"):((l=document.createElement("span")).textContent="X",h.append(l)),l.addEventListener("click",(function(){c.value=c.value.filter((function(e){return e!==t})),c.selectedItems=c.selectedItems.filter((function(e){return e!==t})),c.value.length||c.reassignTagsInputPlaceholder(c.placeholder),c.unselectMultipleItems(),c.selectMultipleItems(),h.remove(),c.triggerChangeEventForNativeSelect()})),this.wrapper.append(h)},e.prototype.getItemByValue=function(t){var e=this;return this.apiUrl?this.remoteOptions.find((function(n){return"".concat(n[e.apiFieldsMap.val])===t||n[e.apiFieldsMap.title]===t})):this.selectOptions.find((function(e){return e.val===t}))},e.prototype.setTagsItems=function(){var t=this;this.value&&this.value.forEach((function(e){t.selectedItems.includes(e)||t.buildTagsItem(e),t.selectedItems=t.selectedItems.includes(e)?t.selectedItems:a(a([],t.selectedItems,!0),[e],!1)}))},e.prototype.buildTagsInput=function(){var t=this;this.tagsInput=document.createElement("input"),this.tagsInputId&&(this.tagsInput.id=this.tagsInputId),this.tagsInputClasses&&(0,u.classToClassList)(this.tagsInputClasses,this.tagsInput),this.onTagsInputFocusListener=function(){return t.tagsInputFocus()},this.onTagsInputInputListener=function(){return t.tagsInputInput()},this.onTagsInputInputSecondListener=(0,u.debounce)((function(e){return t.tagsInputInputSecond(e)})),this.onTagsInputKeydownListener=function(e){return t.tagsInputKeydown(e)},this.tagsInput.addEventListener("focus",this.onTagsInputFocusListener),this.tagsInput.addEventListener("input",this.onTagsInputInputListener),this.tagsInput.addEventListener("input",this.onTagsInputInputSecondListener),this.tagsInput.addEventListener("keydown",this.onTagsInputKeydownListener),this.wrapper.append(this.tagsInput),setTimeout((function(){t.adjustInputWidth(),t.reassignTagsInputPlaceholder(t.value.length?"":t.placeholder)}))},e.prototype.buildDropdown=function(){var t=this;this.dropdown=(0,u.htmlToElement)(this.dropdownTag||"
"),this.dropdown.setAttribute("data-hs-select-dropdown",""),"parent"===this.dropdownScope&&(this.dropdown.classList.add("absolute"),this.dropdownVerticalFixedPlacement||this.dropdown.classList.add("top-full")),this.dropdown.role="listbox",this.dropdown.tabIndex=-1,this.dropdown.ariaOrientation="vertical",this.isOpened||this.dropdown.classList.add("hidden"),this.dropdownClasses&&(0,u.classToClassList)(this.dropdownClasses,this.dropdown),this.wrapper&&this.wrapper.append(this.dropdown),this.dropdown&&this.hasSearch&&this.buildSearch(),this.selectOptions&&this.selectOptions.forEach((function(e,n){return t.buildOption(e.title,e.val,e.disabled,e.selected,e.options,"".concat(n))})),this.apiUrl&&this.optionsFromRemoteData(),"window"===this.dropdownScope&&this.buildPopper()},e.prototype.buildPopper=function(){"undefined"!=typeof Popper&&Popper.createPopper&&(document.body.appendChild(this.dropdown),this.popperInstance=Popper.createPopper("tags"===this.mode?this.wrapper:this.toggle,this.dropdown,{placement:h.POSITIONS[this.dropdownPlacement]||"bottom",strategy:"fixed",modifiers:[{name:"offset",options:{offset:[0,5]}}]}))},e.prototype.updateDropdownWidth=function(){var t="tags"===this.mode?this.wrapper:this.toggle;this.dropdown.style.width="".concat(t.clientWidth,"px")},e.prototype.buildSearch=function(){var t,e=this;this.searchWrapper=(0,u.htmlToElement)(this.searchWrapperTemplate||"
"),this.searchWrapperClasses&&(0,u.classToClassList)(this.searchWrapperClasses,this.searchWrapper),t=this.searchWrapper.querySelector("[data-input]");var n=(0,u.htmlToElement)(this.searchTemplate||'');this.search="INPUT"===n.tagName?n:n.querySelector(":scope input"),this.search.placeholder=this.searchPlaceholder,this.searchClasses&&(0,u.classToClassList)(this.searchClasses,this.search),this.searchId&&(this.search.id=this.searchId),this.onSearchInputListener=(0,u.debounce)((function(t){return e.searchInput(t)})),this.search.addEventListener("input",this.onSearchInputListener),t?t.append(n):this.searchWrapper.append(n),this.dropdown.append(this.searchWrapper)},e.prototype.buildOption=function(t,e,n,i,o,r,s){var l,c=this;void 0===n&&(n=!1),void 0===i&&(i=!1),void 0===r&&(r="1");var d=null,h=null,p=(0,u.htmlToElement)(this.optionTag||"
");if(p.setAttribute("data-value",e),p.setAttribute("data-title-value",t),p.setAttribute("tabIndex",r),p.classList.add("cursor-pointer"),p.setAttribute("data-id",s||"".concat(this.optionId)),s||this.optionId++,n&&p.classList.add("disabled"),i&&(this.isMultiple?this.value=a(a([],this.value,!0),[e],!1):this.value=e),this.optionTemplate&&(d=(0,u.htmlToElement)(this.optionTemplate),p.append(d)),d?d.querySelector("[data-title]").textContent=t||"":p.textContent=t||"",o){if(o.icon){var f=(0,u.htmlToElement)(null!==(l=this.apiIconTag)&&void 0!==l?l:o.icon);if(f.classList.add("max-w-full"),this.apiUrl&&(f.setAttribute("alt",t),f.setAttribute("src",o.icon)),d)d.querySelector("[data-icon]").append(f);else{var v=(0,u.htmlToElement)("
");this.iconClasses&&(0,u.classToClassList)(this.iconClasses,v),v.append(f),p.append(v)}}if(o.description)if(d)(h=d.querySelector("[data-description]"))&&h.append(o.description);else{var m=(0,u.htmlToElement)("
");m.textContent=o.description,this.descriptionClasses&&(0,u.classToClassList)(this.descriptionClasses,m),p.append(m)}}d&&d.querySelector("[data-icon]")&&!o&&!(null==o?void 0:o.icon)&&d.querySelector("[data-icon]").classList.add("hidden"),this.value&&(this.isMultiple?this.value.includes(e):this.value===e)&&p.classList.add("selected"),n||p.addEventListener("click",(function(){return c.onSelectOption(e)})),this.optionClasses&&(0,u.classToClassList)(this.optionClasses,p),this.dropdown&&this.dropdown.append(p),i&&this.setNewValue()},e.prototype.buildOptionFromRemoteData=function(t,e,n,i,o,r,s){void 0===n&&(n=!1),void 0===i&&(i=!1),void 0===o&&(o="1"),o?this.buildOption(t,e,n,i,s,o,r):alert("ID parameter is required for generating remote options! Please check your API endpoint have it.")},e.prototype.buildOptionsFromRemoteData=function(t){var e=this;t.forEach((function(t,n){var i=null,o="",r="",s={id:"",val:"",title:"",icon:null,description:null,rest:{}};Object.keys(t).forEach((function(n){var l;t[e.apiFieldsMap.id]&&(i=t[e.apiFieldsMap.id]),(t[e.apiFieldsMap.val]||t[e.apiFieldsMap.title])&&(r=t[e.apiFieldsMap.val]||t[e.apiFieldsMap.title]),t[e.apiFieldsMap.title]&&(o=t[e.apiFieldsMap.title]),t[e.apiFieldsMap.icon]&&(s.icon=t[e.apiFieldsMap.icon]),t[null===(l=e.apiFieldsMap)||void 0===l?void 0:l.description]&&(s.description=t[e.apiFieldsMap.description]),s.rest[n]=t[n]})),e.buildOriginalOption(o,"".concat(r),i,!1,!1,s),e.buildOptionFromRemoteData(o,"".concat(r),!1,!1,"".concat(n),i,s)})),this.sortElements(this.el,"option"),this.sortElements(this.dropdown,"[data-value]")},e.prototype.optionsFromRemoteData=function(){return s(this,arguments,void 0,(function(t){var e;return void 0===t&&(t=""),l(this,(function(n){switch(n.label){case 0:return[4,this.apiRequest(t)];case 1:return e=n.sent(),this.remoteOptions=e,e.length?this.buildOptionsFromRemoteData(this.remoteOptions):console.log("There is no data were responded!"),[2]}}))}))},e.prototype.apiRequest=function(){return s(this,arguments,void 0,(function(t){var e,n,i,o,r,s;return void 0===t&&(t=""),l(this,(function(l){switch(l.label){case 0:return l.trys.push([0,3,,4]),e=this.apiUrl,n=this.apiSearchQueryKey?"".concat(this.apiSearchQueryKey,"=").concat(t.toLowerCase()):null,i="".concat(this.apiQuery),o=this.apiOptions||{},n&&(e+="?".concat(n)),this.apiQuery&&(e+="".concat(n?"&":"?").concat(i)),[4,fetch(e,o)];case 1:return[4,l.sent().json()];case 2:return r=l.sent(),[2,this.apiDataPart?r[this.apiDataPart]:r];case 3:return s=l.sent(),console.error(s),[3,4];case 4:return[2]}}))}))},e.prototype.sortElements=function(t,e){var n=Array.from(t.querySelectorAll(e));n.sort((function(t,e){var n=t.classList.contains("selected")||t.hasAttribute("selected"),i=e.classList.contains("selected")||e.hasAttribute("selected");return n&&!i?-1:!n&&i?1:0})),n.forEach((function(e){return t.appendChild(e)}))},e.prototype.remoteSearch=function(t){return s(this,void 0,void 0,(function(){var e,n,i,o,r=this;return l(this,(function(s){switch(s.label){case 0:return[4,this.apiRequest(t)];case 1:return e=s.sent(),this.remoteOptions=e,n=e.map((function(t){return"".concat(t.id)})),o=this.dropdown.querySelectorAll("[data-value]"),this.el.querySelectorAll("[data-hs-select-option]").forEach((function(t){var e,i=t.getAttribute("data-id");n.includes(i)||(null===(e=r.value)||void 0===e?void 0:e.includes(t.value))||r.destroyOriginalOption(t.value)})),o.forEach((function(t){var e,i=t.getAttribute("data-id");n.includes(i)||(null===(e=r.value)||void 0===e?void 0:e.includes(t.getAttribute("data-value")))?n=n.filter((function(t){return t!==i})):r.destroyOption(t.getAttribute("data-value"))})),(i=e.filter((function(t){return n.includes("".concat(t.id))}))).length?this.buildOptionsFromRemoteData(i):console.log("There is no data were responded!"),[2]}}))}))},e.prototype.destroyOption=function(t){var e=this.dropdown.querySelector('[data-value="'.concat(t,'"]'));if(!e)return!1;e.remove()},e.prototype.buildOriginalOption=function(t,e,n,i,o,r){var s=(0,u.htmlToElement)("");s.setAttribute("value",e),i&&s.setAttribute("disabled","disabled"),o&&s.setAttribute("selected","selected"),n&&s.setAttribute("data-id",n),s.setAttribute("data-hs-select-option",JSON.stringify(r)),s.innerText=t,this.el.append(s)},e.prototype.destroyOriginalOption=function(t){var e=this.el.querySelector('[value="'.concat(t,'"]'));if(!e)return!1;e.remove()},e.prototype.buildTagsInputHelper=function(){this.tagsInputHelper=document.createElement("span"),this.tagsInputHelper.style.fontSize=window.getComputedStyle(this.tagsInput).fontSize,this.tagsInputHelper.style.fontFamily=window.getComputedStyle(this.tagsInput).fontFamily,this.tagsInputHelper.style.fontWeight=window.getComputedStyle(this.tagsInput).fontWeight,this.tagsInputHelper.style.letterSpacing=window.getComputedStyle(this.tagsInput).letterSpacing,this.tagsInputHelper.style.visibility="hidden",this.tagsInputHelper.style.whiteSpace="pre",this.tagsInputHelper.style.position="absolute",this.wrapper.appendChild(this.tagsInputHelper)},e.prototype.calculateInputWidth=function(){this.tagsInputHelper.textContent=this.tagsInput.value||this.tagsInput.placeholder;var t=parseInt(window.getComputedStyle(this.tagsInput).paddingLeft)+parseInt(window.getComputedStyle(this.tagsInput).paddingRight),e=parseInt(window.getComputedStyle(this.tagsInput).borderLeftWidth)+parseInt(window.getComputedStyle(this.tagsInput).borderRightWidth),n=this.tagsInputHelper.offsetWidth+t+e,i=this.wrapper.offsetWidth-(parseInt(window.getComputedStyle(this.wrapper).paddingLeft)+parseInt(window.getComputedStyle(this.wrapper).paddingRight));this.tagsInput.style.width="".concat(Math.min(n,i)+2,"px")},e.prototype.adjustInputWidth=function(){this.buildTagsInputHelper(),this.calculateInputWidth()},e.prototype.onSelectOption=function(t){var e=this;if(this.clearSelections(),this.isMultiple?(this.value=this.value.includes(t)?Array.from(this.value).filter((function(e){return e!==t})):a(a([],Array.from(this.value),!0),[t],!1),this.selectMultipleItems(),this.setNewValue()):(this.value=t,this.selectSingleItem(),this.setNewValue()),this.fireEvent("change",this.value),"tags"===this.mode){var n=this.selectedItems.filter((function(t){return!e.value.includes(t)}));n.length&&n.forEach((function(t){e.selectedItems=e.selectedItems.filter((function(e){return e!==t})),e.wrapper.querySelector('[data-tag-value="'.concat(t,'"]')).remove()})),this.resetTagsInputField()}this.isMultiple||(this.toggle.querySelector("[data-icon]")&&this.setToggleIcon(),this.toggle.querySelector("[data-title]")&&this.setToggleTitle(),this.close(!0)),this.value.length||"tags"!==this.mode||this.reassignTagsInputPlaceholder(this.placeholder),this.isOpened&&"tags"===this.mode&&this.tagsInput&&this.tagsInput.focus(),this.triggerChangeEventForNativeSelect()},e.prototype.triggerChangeEventForNativeSelect=function(){var t=new Event("change",{bubbles:!0});this.el.dispatchEvent(t),(0,u.dispatch)("change.hs.select",this.el,this.value)},e.prototype.addSelectOption=function(t,e,n,i,o){this.selectOptions=a(a([],this.selectOptions,!0),[{title:t,val:e,disabled:n,selected:i,options:o}],!1)},e.prototype.removeSelectOption=function(t,e){if(void 0===e&&(e=!1),!!!this.selectOptions.some((function(e){return e.val===t})))return!1;this.selectOptions=this.selectOptions.filter((function(e){return e.val!==t})),this.value=e?this.value.filter((function(e){return e!==t})):t},e.prototype.resetTagsInputField=function(){this.tagsInput.value="",this.reassignTagsInputPlaceholder(""),this.searchOptions("")},e.prototype.clearSelections=function(){Array.from(this.dropdown.children).forEach((function(t){t.classList.contains("selected")&&t.classList.remove("selected")})),Array.from(this.el.children).forEach((function(t){t.selected&&(t.selected=!1)}))},e.prototype.setNewValue=function(){var t;"tags"===this.mode?this.setTagsItems():(null===(t=this.value)||void 0===t?void 0:t.length)?this.toggleTextWrapper.innerHTML=this.stringFromValue():this.toggleTextWrapper.innerHTML=this.placeholder},e.prototype.stringFromValueBasic=function(t){var e,n=this,i=[],o="";if(t.forEach((function(t){n.isMultiple?n.value.includes(t.val)&&i.push(t.title):n.value===t.val&&i.push(t.title)})),void 0!==this.toggleCountText&&null!==this.toggleCountText&&i.length>=this.toggleCountTextMinItems)if("nItemsAndCount"===this.toggleCountTextMode){var r=i.slice(0,this.toggleCountTextMinItems-1),s=[r.join(this.toggleSeparators.items)],l="".concat(i.length-r.length);if((null===(e=null==this?void 0:this.toggleSeparators)||void 0===e?void 0:e.betweenItemsAndCounter)&&s.push(this.toggleSeparators.betweenItemsAndCounter),this.toggleCountText)switch(this.toggleCountTextPlacement){case"postfix-no-space":s.push("".concat(l).concat(this.toggleCountText));break;case"prefix-no-space":s.push("".concat(this.toggleCountText).concat(l));break;case"prefix":s.push("".concat(this.toggleCountText," ").concat(l));break;default:s.push("".concat(l," ").concat(this.toggleCountText))}o=s.join(" ")}else o="".concat(i.length," ").concat(this.toggleCountText);else o=i.join(this.toggleSeparators.items);return o},e.prototype.stringFromValueRemoteData=function(){var t=this,e=this.dropdown.querySelectorAll("[data-title-value]"),n=[],i="";if(e.forEach((function(e){var i=e.getAttribute("data-value"),o=e.getAttribute("data-title-value");t.isMultiple?t.value.includes(i)&&n.push(o):t.value===i&&n.push(o)})),this.toggleCountText&&""!==this.toggleCountText&&n.length>=this.toggleCountTextMinItems)if("nItemsAndCount"===this.toggleCountTextMode){var o=n.slice(0,this.toggleCountTextMinItems-1);i="".concat(o.join(this.toggleSeparators.items)," ").concat(this.toggleSeparators.betweenItemsAndCounter," ").concat(n.length-o.length," ").concat(this.toggleCountText)}else i="".concat(n.length," ").concat(this.toggleCountText);else i=n.join(this.toggleSeparators.items);return i},e.prototype.stringFromValue=function(){return this.apiUrl?this.stringFromValueRemoteData():this.stringFromValueBasic(this.selectOptions)},e.prototype.selectSingleItem=function(){var t=this;Array.from(this.el.children).find((function(e){return t.value===e.value})).selected=!0;var e=Array.from(this.dropdown.children).find((function(e){return t.value===e.getAttribute("data-value")}));e&&e.classList.add("selected")},e.prototype.selectMultipleItems=function(){var t=this;Array.from(this.dropdown.children).filter((function(e){return t.value.includes(e.getAttribute("data-value"))})).forEach((function(t){return t.classList.add("selected")})),Array.from(this.el.children).filter((function(e){return t.value.includes(e.value)})).forEach((function(t){return t.selected=!0}))},e.prototype.unselectMultipleItems=function(){Array.from(this.dropdown.children).forEach((function(t){return t.classList.remove("selected")})),Array.from(this.el.children).forEach((function(t){return t.selected=!1}))},e.prototype.searchOptions=function(t){var e=this;this.searchNoResult&&(this.searchNoResult.remove(),this.searchNoResult=null),this.searchNoResult=(0,u.htmlToElement)(this.searchNoResultTemplate),this.searchNoResult.innerText=this.searchNoResultText,(0,u.classToClassList)(this.searchNoResultClasses,this.searchNoResult);var n,i=this.dropdown.querySelectorAll("[data-value]"),o=!1;this.searchLimit&&(n=0),i.forEach((function(i){var r=i.getAttribute("data-title-value").toLocaleLowerCase(),s=t?t.split("").map((function(t){return t.match(/\w/)?"".concat(t,"[\\W_]*"):"\\W*"})).join(""):"",l=new RegExp(s,"i"),a=e.isSearchDirectMatch,c=r.trim();(t?a?!c.toLowerCase().includes(t.toLowerCase())||n>=e.searchLimit:!l.test(c)||n>=e.searchLimit:!l.test(c))?i.classList.add("hidden"):(i.classList.remove("hidden"),o=!0,e.searchLimit&&n++)})),o||this.dropdown.append(this.searchNoResult)},e.prototype.eraseToggleIcon=function(){var t=this.toggle.querySelector("[data-icon]");t&&(t.innerHTML=null,t.classList.add("hidden"))},e.prototype.eraseToggleTitle=function(){var t=this.toggle.querySelector("[data-title]");t?t.innerHTML=this.placeholder:this.toggleTextWrapper.innerHTML=this.placeholder},e.prototype.toggleFn=function(){this.isOpened?this.close():this.open()},e.prototype.destroy=function(){this.wrapper&&this.wrapper.removeEventListener("click",this.onWrapperClickListener),this.toggle&&this.toggle.removeEventListener("click",this.onToggleClickListener),this.tagsInput&&(this.tagsInput.removeEventListener("focus",this.onTagsInputFocusListener),this.tagsInput.removeEventListener("input",this.onTagsInputInputListener),this.tagsInput.removeEventListener("input",this.onTagsInputInputSecondListener),this.tagsInput.removeEventListener("keydown",this.onTagsInputKeydownListener)),this.search&&this.search.removeEventListener("input",this.onSearchInputListener);var t=this.el.parentElement.parentElement;this.el.classList.remove("hidden"),this.el.style.display="",t.prepend(this.el),t.querySelector(".hs-select").remove(),this.wrapper=null},e.prototype.open=function(){var t,e=this,n=(null===(t=null===window||void 0===window?void 0:window.$hsSelectCollection)||void 0===t?void 0:t.find((function(t){return t.element.isOpened})))||null;if(n&&n.element.close(),this.animationInProcess)return!1;this.animationInProcess=!0,"window"===this.dropdownScope&&this.dropdown.classList.add("invisible"),this.dropdown.classList.remove("hidden"),this.recalculateDirection(),setTimeout((function(){var t;(null===(t=null==e?void 0:e.toggle)||void 0===t?void 0:t.ariaExpanded)&&(e.toggle.ariaExpanded="true"),e.wrapper.classList.add("active"),e.dropdown.classList.add("opened"),e.dropdown.classList.contains("w-full")&&"window"===e.dropdownScope&&e.updateDropdownWidth(),e.popperInstance&&"window"===e.dropdownScope&&(e.popperInstance.update(),e.dropdown.classList.remove("invisible")),e.hasSearch&&!e.preventSearchFocus&&e.search.focus(),e.animationInProcess=!1})),this.isOpened=!0},e.prototype.close=function(t){var e,n,i,o,r=this;if(void 0===t&&(t=!1),this.animationInProcess)return!1;this.animationInProcess=!0,(null===(e=null==this?void 0:this.toggle)||void 0===e?void 0:e.ariaExpanded)&&(this.toggle.ariaExpanded="false"),this.wrapper.classList.remove("active"),this.dropdown.classList.remove("opened","bottom-full","top-full"),(null===(n=this.dropdownDirectionClasses)||void 0===n?void 0:n.bottom)&&this.dropdown.classList.remove(this.dropdownDirectionClasses.bottom),(null===(i=this.dropdownDirectionClasses)||void 0===i?void 0:i.top)&&this.dropdown.classList.remove(this.dropdownDirectionClasses.top),this.dropdown.style.marginTop="",this.dropdown.style.marginBottom="",(0,u.afterTransition)(this.dropdown,(function(){r.dropdown.classList.add("hidden"),r.hasSearch&&(r.search.value="",r.search.dispatchEvent(new Event("input",{bubbles:!0})),r.search.blur()),t&&r.toggle.focus(),r.animationInProcess=!1})),null===(o=this.dropdown.querySelector(".hs-select-option-highlighted"))||void 0===o||o.classList.remove("hs-select-option-highlighted"),this.isOpened=!1},e.prototype.addOption=function(t){var e=this,n="".concat(this.selectOptions.length),i=function(t){var i=t.title,o=t.val,r=t.disabled,s=t.selected,l=t.options;!!e.selectOptions.some((function(t){return t.val===o}))||(e.addSelectOption(i,o,r,s,l),e.buildOption(i,o,r,s,l,n),e.buildOriginalOption(i,o,null,r,s,l),s&&!e.isMultiple&&e.onSelectOption(o))};Array.isArray(t)?t.forEach((function(t){i(t)})):i(t)},e.prototype.removeOption=function(t){var e=this,n=function(t,n){void 0===n&&(n=!1),!!e.selectOptions.some((function(e){return e.val===t}))&&(e.removeSelectOption(t,n),e.destroyOption(t),e.destroyOriginalOption(t),e.value===t&&(e.value=null,e.eraseToggleTitle(),e.eraseToggleIcon()))};Array.isArray(t)?t.forEach((function(t){n(t,e.isMultiple)})):n(t,this.isMultiple),this.setNewValue()},e.prototype.recalculateDirection=function(){var t,e,n,i;if((null==this?void 0:this.dropdownVerticalFixedPlacement)&&(this.dropdown.classList.contains("bottom-full")||this.dropdown.classList.contains("top-full")))return!1;"top"===(null==this?void 0:this.dropdownVerticalFixedPlacement)?(this.dropdown.classList.add("bottom-full"),this.dropdown.style.marginBottom="".concat(this.dropdownSpace,"px")):"bottom"===(null==this?void 0:this.dropdownVerticalFixedPlacement)?(this.dropdown.classList.add("top-full"),this.dropdown.style.marginTop="".concat(this.dropdownSpace,"px")):(0,u.isEnoughSpace)(this.dropdown,this.toggle||this.tagsInput,"bottom",this.dropdownSpace,this.viewport)?(this.dropdown.classList.remove("bottom-full"),(null===(t=this.dropdownDirectionClasses)||void 0===t?void 0:t.bottom)&&this.dropdown.classList.remove(this.dropdownDirectionClasses.bottom),this.dropdown.style.marginBottom="",this.dropdown.classList.add("top-full"),(null===(e=this.dropdownDirectionClasses)||void 0===e?void 0:e.top)&&this.dropdown.classList.add(this.dropdownDirectionClasses.top),this.dropdown.style.marginTop="".concat(this.dropdownSpace,"px")):(this.dropdown.classList.remove("top-full"),(null===(n=this.dropdownDirectionClasses)||void 0===n?void 0:n.top)&&this.dropdown.classList.remove(this.dropdownDirectionClasses.top),this.dropdown.style.marginTop="",this.dropdown.classList.add("bottom-full"),(null===(i=this.dropdownDirectionClasses)||void 0===i?void 0:i.bottom)&&this.dropdown.classList.add(this.dropdownDirectionClasses.bottom),this.dropdown.style.marginBottom="".concat(this.dropdownSpace,"px"))},e.getInstance=function(t,e){var n=window.$hsSelectCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsSelectCollection||(window.$hsSelectCollection=[],window.addEventListener("click",(function(t){var n=t.target;e.closeCurrentlyOpened(n)})),document.addEventListener("keydown",(function(t){return e.accessibility(t)}))),window.$hsSelectCollection&&(window.$hsSelectCollection=window.$hsSelectCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-select]:not(.--prevent-on-load-init)").forEach((function(t){if(!window.$hsSelectCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))){var n=t.getAttribute("data-hs-select"),i=n?JSON.parse(n):{};new e(t,i)}}))},e.open=function(t){var e=window.$hsSelectCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&!e.element.isOpened&&e.element.open()},e.close=function(t){var e=window.$hsSelectCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));e&&e.element.isOpened&&e.element.close()},e.closeCurrentlyOpened=function(t){if(void 0===t&&(t=null),!t.closest(".hs-select.active")&&!t.closest("[data-hs-select-dropdown].opened")){var e=window.$hsSelectCollection.filter((function(t){return t.element.isOpened}))||null;e&&e.forEach((function(t){t.element.close()}))}},e.accessibility=function(t){if(window.$hsSelectCollection.find((function(t){return t.element.isOpened}))&&h.SELECT_ACCESSIBILITY_KEY_SET.includes(t.code)&&!t.metaKey)switch(t.code){case"Escape":t.preventDefault(),this.onEscape();break;case"ArrowUp":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow();break;case"ArrowDown":t.preventDefault(),t.stopImmediatePropagation(),this.onArrow(!1);break;case"Tab":t.preventDefault(),t.stopImmediatePropagation(),this.onTab(t.shiftKey);break;case"Home":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd();break;case"End":t.preventDefault(),t.stopImmediatePropagation(),this.onStartEnd(!1);break;case"Enter":case"Space":t.preventDefault(),this.onEnter(t)}},e.onEscape=function(){var t=window.$hsSelectCollection.find((function(t){return t.element.isOpened}));t&&t.element.close()},e.onArrow=function(t){void 0===t&&(t=!0);var e=window.$hsSelectCollection.find((function(t){return t.element.isOpened}));if(e){var n=e.element.dropdown;if(!n)return!1;var i=(t?Array.from(n.querySelectorAll(":scope > *:not(.hidden)")).reverse():Array.from(n.querySelectorAll(":scope > *:not(.hidden)"))).filter((function(t){return!t.classList.contains("disabled")})),o=n.querySelector(".hs-select-option-highlighted")||n.querySelector(".selected");o||i[0].classList.add("hs-select-option-highlighted");var r=i.findIndex((function(t){return t===o}));r+1 *:not(.hidden)")).reverse():Array.from(n.querySelectorAll(":scope > *:not(.hidden)"))).filter((function(t){return!t.classList.contains("disabled")})),o=n.querySelector(".hs-select-option-highlighted")||n.querySelector(".selected");o||i[0].classList.add("hs-select-option-highlighted");var r=i.findIndex((function(t){return t===o}));if(!(r+1 *:not(.hidden)")):Array.from(n.querySelectorAll(":scope > *:not(.hidden)")).reverse()).filter((function(t){return!t.classList.contains("disabled")})),o=n.querySelector(".hs-select-option-highlighted");i.length&&(i[0].focus(),o&&o.classList.remove("hs-select-option-highlighted"),i[0].classList.add("hs-select-option-highlighted"))}},e.onEnter=function(t){var e=t.target.previousSibling;if(window.$hsSelectCollection.find((function(t){return t.element.el===e}))){var n=window.$hsSelectCollection.find((function(t){return t.element.isOpened})),i=window.$hsSelectCollection.find((function(t){return t.element.el===e}));n.element.close(),i.element.open()}else{(i=window.$hsSelectCollection.find((function(t){return t.element.isOpened})))&&i.element.onSelectOption(t.target.dataset.value||"")}},e}(d.default);window.addEventListener("load",(function(){p.autoInit()})),document.addEventListener("scroll",(function(){if(!window.$hsSelectCollection)return!1;var t=window.$hsSelectCollection.find((function(t){return t.element.isOpened}));t&&t.element.recalculateDirection()})),"undefined"!=typeof window&&(window.HSSelect=p),e.default=p},887:function(t,e,n){ + /* + * HSStepper + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;nt.totalSteps&&(t.totalSteps=n)}))},e.prototype.buildNav=function(){var t=this;this.el.querySelectorAll("[data-hs-stepper-nav-item]").forEach((function(e){return t.addNavItem(e)})),this.navItems.forEach((function(e){return t.buildNavItem(e)}))},e.prototype.buildNavItem=function(t){var e=this,n=t.index,i=t.isDisabled,o=t.el;n===this.currentIndex&&this.setCurrentNavItem(),("linear"!==this.mode||i)&&(this.onNavItemClickListener.push({el:o,fn:function(){return e.navItemClick(t)}}),o.addEventListener("click",this.onNavItemClickListener.find((function(t){return t.el===o})).fn))},e.prototype.addNavItem=function(t){var e=JSON.parse(t.getAttribute("data-hs-stepper-nav-item")),n=e.index,i=e.isFinal,o=void 0!==i&&i,r=e.isCompleted,s=void 0!==r&&r,l=e.isSkip,a=void 0!==l&&l,c=e.isOptional,u=void 0!==c&&c,d=e.isDisabled,h=void 0!==d&&d,p=e.isProcessed,f=void 0!==p&&p,v=e.hasError,m=void 0!==v&&v;s&&t.classList.add("success"),a&&t.classList.add("skipped"),h&&("BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.setAttribute("disabled","disabled"),t.classList.add("disabled")),m&&t.classList.add("error"),this.navItems.push({index:n,isFinal:o,isCompleted:s,isSkip:a,isOptional:u,isDisabled:h,isProcessed:f,hasError:m,el:t})},e.prototype.setCurrentNavItem=function(){var t=this;this.navItems.forEach((function(e){var n=e.index,i=e.el;n===t.currentIndex?t.setCurrentNavItemActions(i):t.unsetCurrentNavItemActions(i)}))},e.prototype.setCurrentNavItemActions=function(t){t.classList.add("active"),this.fireEvent("active",this.currentIndex),(0,l.dispatch)("active.hs.stepper",this.el,this.currentIndex)},e.prototype.getNavItem=function(t){return void 0===t&&(t=this.currentIndex),this.navItems.find((function(e){return e.index===t}))},e.prototype.setProcessedNavItemActions=function(t){t.isProcessed=!0,t.el.classList.add("processed")},e.prototype.setErrorNavItemActions=function(t){t.hasError=!0,t.el.classList.add("error")},e.prototype.unsetCurrentNavItemActions=function(t){t.classList.remove("active")},e.prototype.handleNavItemClick=function(t){var e=t.index;this.currentIndex=e,this.setCurrentNavItem(),this.setCurrentContentItem(),this.checkForTheFirstStep()},e.prototype.buildContent=function(){var t=this;this.el.querySelectorAll("[data-hs-stepper-content-item]").forEach((function(e){return t.addContentItem(e)})),this.navItems.forEach((function(e){return t.buildContentItem(e)}))},e.prototype.buildContentItem=function(t){t.index===this.currentIndex&&this.setCurrentContentItem()},e.prototype.addContentItem=function(t){var e=JSON.parse(t.getAttribute("data-hs-stepper-content-item")),n=e.index,i=e.isFinal,o=void 0!==i&&i,r=e.isCompleted,s=void 0!==r&&r,l=e.isSkip,a=void 0!==l&&l;s&&t.classList.add("success"),a&&t.classList.add("skipped"),this.contentItems.push({index:n,isFinal:o,isCompleted:s,isSkip:a,el:t})},e.prototype.setCurrentContentItem=function(){var t=this;if(this.isCompleted){var e=this.contentItems.find((function(t){return t.isFinal})),n=this.contentItems.filter((function(t){return!t.isFinal}));return e.el.style.display="",n.forEach((function(t){return t.el.style.display="none"})),!1}this.contentItems.forEach((function(e){var n=e.index,i=e.el;n===t.currentIndex?t.setCurrentContentItemActions(i):t.unsetCurrentContentItemActions(i)}))},e.prototype.hideAllContentItems=function(){this.contentItems.forEach((function(t){return t.el.style.display="none"}))},e.prototype.setCurrentContentItemActions=function(t){t.style.display=""},e.prototype.unsetCurrentContentItemActions=function(t){t.style.display="none"},e.prototype.disableAll=function(){var t=this.getNavItem(this.currentIndex);t.hasError=!1,t.isCompleted=!1,t.isDisabled=!1,t.el.classList.remove("error","success"),this.disableButtons()},e.prototype.disableNavItemActions=function(t){t.isDisabled=!0,t.el.classList.add("disabled")},e.prototype.enableNavItemActions=function(t){t.isDisabled=!1,t.el.classList.remove("disabled")},e.prototype.buildButtons=function(){this.backBtn=this.el.querySelector("[data-hs-stepper-back-btn]"),this.nextBtn=this.el.querySelector("[data-hs-stepper-next-btn]"),this.skipBtn=this.el.querySelector("[data-hs-stepper-skip-btn]"),this.completeStepBtn=this.el.querySelector("[data-hs-stepper-complete-step-btn]"),this.finishBtn=this.el.querySelector("[data-hs-stepper-finish-btn]"),this.resetBtn=this.el.querySelector("[data-hs-stepper-reset-btn]"),this.buildBackButton(),this.buildNextButton(),this.buildSkipButton(),this.buildCompleteStepButton(),this.buildFinishButton(),this.buildResetButton()},e.prototype.buildBackButton=function(){var t=this;this.backBtn&&(this.checkForTheFirstStep(),this.onBackClickListener=function(){return t.backClick()},this.backBtn.addEventListener("click",this.onBackClickListener))},e.prototype.handleBackButtonClick=function(){1!==this.currentIndex&&("linear"===this.mode&&this.removeOptionalClasses(),this.currentIndex--,"linear"===this.mode&&this.removeOptionalClasses(),this.setCurrentNavItem(),this.setCurrentContentItem(),this.checkForTheFirstStep(),this.completeStepBtn&&this.changeTextAndDisableCompleteButtonIfStepCompleted(),this.fireEvent("back",this.currentIndex),(0,l.dispatch)("back.hs.stepper",this.el,this.currentIndex))},e.prototype.checkForTheFirstStep=function(){1===this.currentIndex?this.setToDisabled(this.backBtn):this.setToNonDisabled(this.backBtn)},e.prototype.setToDisabled=function(t){"BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.setAttribute("disabled","disabled"),t.classList.add("disabled")},e.prototype.setToNonDisabled=function(t){"BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.removeAttribute("disabled"),t.classList.remove("disabled")},e.prototype.buildNextButton=function(){var t=this;this.nextBtn&&(this.onNextClickListener=function(){return t.nextClick()},this.nextBtn.addEventListener("click",this.onNextClickListener))},e.prototype.unsetProcessedNavItemActions=function(t){t.isProcessed=!1,t.el.classList.remove("processed")},e.prototype.handleNextButtonClick=function(t){if(void 0===t&&(t=!0),t)this.currentIndex===this.totalSteps?this.currentIndex=1:this.currentIndex++;else{var e=this.getUncompletedSteps();if(1===e.length){var n=e[0].index;this.currentIndex=n}else{if(this.currentIndex===this.totalSteps)return;this.currentIndex++}}"linear"===this.mode&&this.removeOptionalClasses(),this.setCurrentNavItem(),this.setCurrentContentItem(),this.checkForTheFirstStep(),this.completeStepBtn&&this.changeTextAndDisableCompleteButtonIfStepCompleted(),this.showSkipButton(),this.showFinishButton(),this.showCompleteStepButton(),this.fireEvent("next",this.currentIndex),(0,l.dispatch)("next.hs.stepper",this.el,this.currentIndex)},e.prototype.removeOptionalClasses=function(){var t=this,e=this.navItems.find((function(e){return e.index===t.currentIndex})),n=this.contentItems.find((function(e){return e.index===t.currentIndex}));e.isSkip=!1,e.hasError=!1,e.isDisabled=!1,n.isSkip=!1,e.el.classList.remove("skipped","success","error"),n.el.classList.remove("skipped","success","error")},e.prototype.buildSkipButton=function(){var t=this;this.skipBtn&&(this.showSkipButton(),this.onSkipClickListener=function(){return t.skipClick()},this.skipBtn.addEventListener("click",this.onSkipClickListener))},e.prototype.setSkipItem=function(t){var e=this,n=this.navItems.find((function(n){return n.index===(t||e.currentIndex)})),i=this.contentItems.find((function(n){return n.index===(t||e.currentIndex)}));n&&i&&(this.setSkipItemActions(n),this.setSkipItemActions(i))},e.prototype.setSkipItemActions=function(t){t.isSkip=!0,t.el.classList.add("skipped")},e.prototype.showSkipButton=function(){var t=this;if(this.skipBtn){var e=this.navItems.find((function(e){return e.index===t.currentIndex})).isOptional;this.skipBtn.style.display=e?"":"none"}},e.prototype.handleSkipButtonClick=function(){this.setSkipItem(),this.handleNextButtonClick(),this.fireEvent("skip",this.currentIndex),(0,l.dispatch)("skip.hs.stepper",this.el,this.currentIndex)},e.prototype.buildCompleteStepButton=function(){var t=this;this.completeStepBtn&&(this.completeStepBtnDefaultText=this.completeStepBtn.innerText,this.onCompleteStepBtnClickListener=function(){return t.completeStepBtnClick()},this.completeStepBtn.addEventListener("click",this.onCompleteStepBtnClickListener))},e.prototype.changeTextAndDisableCompleteButtonIfStepCompleted=function(){var t=this,e=this.navItems.find((function(e){return e.index===t.currentIndex})),n=JSON.parse(this.completeStepBtn.getAttribute("data-hs-stepper-complete-step-btn")).completedText;e&&(e.isCompleted?(this.completeStepBtn.innerText=n||this.completeStepBtnDefaultText,this.completeStepBtn.setAttribute("disabled","disabled"),this.completeStepBtn.classList.add("disabled")):(this.completeStepBtn.innerText=this.completeStepBtnDefaultText,this.completeStepBtn.removeAttribute("disabled"),this.completeStepBtn.classList.remove("disabled")))},e.prototype.setCompleteItem=function(t){var e=this,n=this.navItems.find((function(n){return n.index===(t||e.currentIndex)})),i=this.contentItems.find((function(n){return n.index===(t||e.currentIndex)}));n&&i&&(this.setCompleteItemActions(n),this.setCompleteItemActions(i))},e.prototype.setCompleteItemActions=function(t){t.isCompleted=!0,t.el.classList.add("success")},e.prototype.showCompleteStepButton=function(){this.completeStepBtn&&(1===this.getUncompletedSteps().length?this.completeStepBtn.style.display="none":this.completeStepBtn.style.display="")},e.prototype.handleCompleteStepButtonClick=function(){this.setCompleteItem(),this.fireEvent("complete",this.currentIndex),(0,l.dispatch)("complete.hs.stepper",this.el,this.currentIndex),this.handleNextButtonClick(!1),this.showFinishButton(),this.showCompleteStepButton(),this.checkForTheFirstStep(),this.completeStepBtn&&this.changeTextAndDisableCompleteButtonIfStepCompleted(),this.showSkipButton()},e.prototype.buildFinishButton=function(){var t=this;this.finishBtn&&(this.isCompleted&&this.setCompleted(),this.onFinishBtnClickListener=function(){return t.finishBtnClick()},this.finishBtn.addEventListener("click",this.onFinishBtnClickListener))},e.prototype.setCompleted=function(){this.el.classList.add("completed")},e.prototype.unsetCompleted=function(){this.el.classList.remove("completed")},e.prototype.showFinishButton=function(){this.finishBtn&&(1===this.getUncompletedSteps().length?this.finishBtn.style.display="":this.finishBtn.style.display="none")},e.prototype.handleFinishButtonClick=function(){var t=this,e=this.getUncompletedSteps(),n=this.getUncompletedSteps(!0),i=this.contentItems.find((function(t){return t.isFinal})).el;e.length&&e.forEach((function(e){var n=e.index;return t.setCompleteItem(n)})),this.currentIndex=this.totalSteps,this.setCurrentNavItem(),this.hideAllContentItems();var o=this.navItems.find((function(e){return e.index===t.currentIndex}));(o?o.el:null).classList.remove("active"),i.style.display="block",this.backBtn&&(this.backBtn.style.display="none"),this.nextBtn&&(this.nextBtn.style.display="none"),this.skipBtn&&(this.skipBtn.style.display="none"),this.completeStepBtn&&(this.completeStepBtn.style.display="none"),this.finishBtn&&(this.finishBtn.style.display="none"),this.resetBtn&&(this.resetBtn.style.display=""),n.length<=1&&(this.isCompleted=!0,this.setCompleted()),this.fireEvent("finish",this.currentIndex),(0,l.dispatch)("finish.hs.stepper",this.el,this.currentIndex)},e.prototype.buildResetButton=function(){var t=this;this.resetBtn&&(this.onResetBtnClickListener=function(){return t.resetBtnClick()},this.resetBtn.addEventListener("click",this.onResetBtnClickListener))},e.prototype.handleResetButtonClick=function(){var t=this;this.backBtn&&(this.backBtn.style.display=""),this.nextBtn&&(this.nextBtn.style.display=""),this.completeStepBtn&&(this.completeStepBtn.style.display="",this.completeStepBtn.innerText=this.completeStepBtnDefaultText,this.completeStepBtn.removeAttribute("disabled"),this.completeStepBtn.classList.remove("disabled")),this.resetBtn&&(this.resetBtn.style.display="none"),this.navItems.forEach((function(e){var n=e.el;e.isSkip=!1,e.isCompleted=!1,t.unsetCurrentNavItemActions(n),n.classList.remove("success","skipped")})),this.contentItems.forEach((function(e){var n=e.el;e.isSkip=!1,e.isCompleted=!1,t.unsetCurrentContentItemActions(n),n.classList.remove("success","skipped")})),this.currentIndex=1,this.unsetCompleted(),this.isCompleted=!1,this.setCurrentNavItem(),this.showFinishButton(),this.showCompleteStepButton(),this.checkForTheFirstStep(),this.fireEvent("reset",this.currentIndex),(0,l.dispatch)("reset.hs.stepper",this.el,this.currentIndex)},e.prototype.setProcessedNavItem=function(t){var e=this.getNavItem(t);e&&this.setProcessedNavItemActions(e)},e.prototype.unsetProcessedNavItem=function(t){var e=this.getNavItem(t);e&&this.unsetProcessedNavItemActions(e)},e.prototype.goToNext=function(){"linear"===this.mode&&this.setCompleteItem(),this.handleNextButtonClick("linear"!==this.mode),"linear"===this.mode&&this.currentIndex===this.totalSteps&&(this.nextBtn&&(this.nextBtn.style.display="none"),this.completeStepBtn&&(this.completeStepBtn.style.display="none"))},e.prototype.disableButtons=function(){this.backBtn&&this.setToDisabled(this.backBtn),this.nextBtn&&this.setToDisabled(this.nextBtn)},e.prototype.enableButtons=function(){this.backBtn&&this.setToNonDisabled(this.backBtn),this.nextBtn&&this.setToNonDisabled(this.nextBtn)},e.prototype.setErrorNavItem=function(t){var e=this.getNavItem(t);e&&this.setErrorNavItemActions(e)},e.prototype.destroy=function(){var t=this;this.el.classList.remove("completed"),this.el.querySelectorAll("[data-hs-stepper-nav-item]").forEach((function(t){t.classList.remove("active","success","skipped","disabled","error"),"BUTTON"!==t.tagName&&"INPUT"!==t.tagName||t.removeAttribute("disabled")})),this.el.querySelectorAll("[data-hs-stepper-content-item]").forEach((function(t){t.classList.remove("success","skipped")})),this.backBtn&&this.backBtn.classList.remove("disabled"),this.nextBtn&&this.nextBtn.classList.remove("disabled"),this.completeStepBtn&&this.completeStepBtn.classList.remove("disabled"),this.backBtn&&(this.backBtn.style.display=""),this.nextBtn&&(this.nextBtn.style.display=""),this.skipBtn&&(this.skipBtn.style.display=""),this.finishBtn&&(this.finishBtn.style.display="none"),this.resetBtn&&(this.resetBtn.style.display="none"),this.onNavItemClickListener.length&&this.onNavItemClickListener.forEach((function(t){var e=t.el,n=t.fn;e.removeEventListener("click",n)})),this.backBtn&&this.backBtn.removeEventListener("click",this.onBackClickListener),this.nextBtn&&this.nextBtn.removeEventListener("click",this.onNextClickListener),this.skipBtn&&this.skipBtn.removeEventListener("click",this.onSkipClickListener),this.completeStepBtn&&this.completeStepBtn.removeEventListener("click",this.onCompleteStepBtnClickListener),this.finishBtn&&this.finishBtn.removeEventListener("click",this.onFinishBtnClickListener),this.resetBtn&&this.resetBtn.removeEventListener("click",this.onResetBtnClickListener),window.$hsStepperCollection=window.$hsStepperCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsStepperCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsStepperCollection||(window.$hsStepperCollection=[]),window.$hsStepperCollection&&(window.$hsStepperCollection=window.$hsStepperCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-stepper]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsStepperCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSStepper=a),e.default=a},97:function(t,e,n){ + /* + * HSStrongPassword + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n?@[\\\\\\]^_`{|}~",i.target&&i.init(),i}return o(e,t),e.prototype.targetInput=function(t){this.setStrength(t.target.value)},e.prototype.targetFocus=function(){this.isOpened=!0,this.hints.classList.remove("hidden"),this.hints.classList.add("block"),this.recalculateDirection()},e.prototype.targetBlur=function(){this.isOpened=!1,this.hints.classList.remove("block","bottom-full","top-full"),this.hints.classList.add("hidden"),this.hints.style.marginTop="",this.hints.style.marginBottom=""},e.prototype.targetInputSecond=function(){this.setWeaknessText()},e.prototype.targetInputThird=function(){this.setRulesText()},e.prototype.init=function(){this.createCollection(window.$hsStrongPasswordCollection,this),this.availableChecks.length&&this.build()},e.prototype.build=function(){var t=this;this.buildStrips(),this.hints&&this.buildHints(),this.setStrength(this.target.value),this.onTargetInputListener=function(e){return t.targetInput(e)},this.target.addEventListener("input",this.onTargetInputListener)},e.prototype.buildStrips=function(){if(this.el.innerHTML="",this.stripClasses)for(var t=0;t");(0,l.classToClassList)(this.stripClasses,e),this.el.append(e)}},e.prototype.buildHints=function(){var t=this;this.weakness=this.hints.querySelector("[data-hs-strong-password-hints-weakness-text]")||null,this.rules=Array.from(this.hints.querySelectorAll("[data-hs-strong-password-hints-rule-text]"))||null,this.rules.forEach((function(e){var n,i=e.getAttribute("data-hs-strong-password-hints-rule-text");(null===(n=t.checksExclude)||void 0===n?void 0:n.includes(i))&&e.remove()})),this.weakness&&this.buildWeakness(),this.rules&&this.buildRules(),"popover"===this.mode&&(this.onTargetFocusListener=function(){return t.targetFocus()},this.onTargetBlurListener=function(){return t.targetBlur()},this.target.addEventListener("focus",this.onTargetFocusListener),this.target.addEventListener("blur",this.onTargetBlurListener))},e.prototype.buildWeakness=function(){var t=this;this.checkStrength(this.target.value),this.setWeaknessText(),this.onTargetInputSecondListener=function(){return setTimeout((function(){return t.targetInputSecond()}))},this.target.addEventListener("input",this.onTargetInputSecondListener)},e.prototype.buildRules=function(){var t=this;this.setRulesText(),this.onTargetInputThirdListener=function(){return setTimeout((function(){return t.targetInputThird()}))},this.target.addEventListener("input",this.onTargetInputThirdListener)},e.prototype.setWeaknessText=function(){var t=this.weakness.getAttribute("data-hs-strong-password-hints-weakness-text"),e=JSON.parse(t);this.weakness.textContent=e[this.strength]},e.prototype.setRulesText=function(){var t=this;this.rules.forEach((function(e){var n=e.getAttribute("data-hs-strong-password-hints-rule-text");t.checkIfPassed(e,t.passedRules.has(n))}))},e.prototype.togglePopover=function(){var t=this.el.querySelector(".popover");t&&t.classList.toggle("show")},e.prototype.checkStrength=function(t){var e=new Set,n={lowercase:/[a-z]+/,uppercase:/[A-Z]+/,numbers:/[0-9]+/,"special-characters":new RegExp("[".concat(this.specialCharactersSet,"]"))},i=0;return this.availableChecks.includes("lowercase")&&t.match(n.lowercase)&&(i+=1,e.add("lowercase")),this.availableChecks.includes("uppercase")&&t.match(n.uppercase)&&(i+=1,e.add("uppercase")),this.availableChecks.includes("numbers")&&t.match(n.numbers)&&(i+=1,e.add("numbers")),this.availableChecks.includes("special-characters")&&t.match(n["special-characters"])&&(i+=1,e.add("special-characters")),this.availableChecks.includes("min-length")&&t.length>=this.minLength&&(i+=1,e.add("min-length")),t.length||(i=0),i===this.availableChecks.length?this.el.classList.add("accepted"):this.el.classList.remove("accepted"),this.strength=i,this.passedRules=e,{strength:this.strength,rules:this.passedRules}},e.prototype.checkIfPassed=function(t,e){void 0===e&&(e=!1);var n=t.querySelector("[data-check]"),i=t.querySelector("[data-uncheck]");e?(t.classList.add("active"),n.classList.remove("hidden"),i.classList.add("hidden")):(t.classList.remove("active"),n.classList.add("hidden"),i.classList.remove("hidden"))},e.prototype.setStrength=function(t){var e=this.checkStrength(t),n=e.strength,i={strength:n,rules:e.rules};this.hideStrips(n),this.fireEvent("change",i),(0,l.dispatch)("change.hs.strongPassword",this.el,i)},e.prototype.hideStrips=function(t){Array.from(this.el.children).forEach((function(e,n){nt)},e.prototype.isParentHidden=function(){return this.el.closest(".hs-collapse")||this.el.closest(".hs-overlay")||this.el.closest('[role="tabpanel"]')},e.prototype.parentType=function(){return this.el.closest(".hs-collapse")?"collapse":this.el.closest(".hs-overlay")?"overlay":!!this.el.closest('[role="tabpanel"]')&&"tabs"},e.prototype.callbackAccordingToType=function(){var t,e=this;if("tabs"===this.parentType()){var n=null===(t=this.el.closest('[role="tabpanel"]'))||void 0===t?void 0:t.id,i=document.querySelector('[data-hs-tab="#'.concat(n,'"]')).closest('[role="tablist"]');(window.HSTabs.getInstance(i,!0)||null).element.on("change",(function(){if(!e.el)return!1;e.textareaSetHeight(3)}))}else if("collapse"===this.parentType()){var o=this.el.closest(".hs-collapse").id;window.HSCollapse.getInstance('[data-hs-collapse="#'.concat(o,'"]'),!0).element.on("beforeOpen",(function(){if(!e.el)return!1;e.textareaSetHeight(3)}))}else{if("overlay"!==this.parentType())return!1;window.HSOverlay.getInstance(this.el.closest(".hs-overlay"),!0).element.on("open",(function(){if(!e.el)return!1;e.textareaSetHeight(3)}))}},e.prototype.destroy=function(){var t=this;this.el.removeEventListener("input",this.onElementInputListener),window.$hsTextareaAutoHeightCollection=window.$hsTextareaAutoHeightCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsTextareaAutoHeightCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsTextareaAutoHeightCollection||(window.$hsTextareaAutoHeightCollection=[]),window.$hsTextareaAutoHeightCollection&&(window.$hsTextareaAutoHeightCollection=window.$hsTextareaAutoHeightCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-textarea-auto-height]:not(.--prevent-on-load-init)").forEach((function(t){if(!window.$hsTextareaAutoHeightCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))){var n=t.getAttribute("data-hs-textarea-auto-height"),i=n?JSON.parse(n):{};new e(t,i)}}))},e}(s(n(961)).default);window.addEventListener("load",(function(){l.autoInit()})),"undefined"!=typeof window&&(window.HSTextareaAutoHeight=l),e.default=l},502:function(t,e,n){ + /* + * HSThemeSwitch + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n1&&!!i.el.closest("[data-hs-toggle-password-group]"),i.target&&i.init(),i}return o(e,t),e.prototype.elementAction=function(){this.isShown?this.hide():this.show(),this.fireEvent("toggle",this.target),(0,l.dispatch)("toggle.hs.toggle-select",this.el,this.target)},e.prototype.init=function(){var t=this;this.createCollection(window.$hsTogglePasswordCollection,this),this.isShown?this.show():this.hide(),this.onElementActionListener=function(){return t.elementAction()},this.el.addEventListener(this.eventType,this.onElementActionListener)},e.prototype.getMultipleToggles=function(){var t=this.el.closest("[data-hs-toggle-password-group]").querySelectorAll("[data-hs-toggle-password]"),n=[];return t.forEach((function(t){n.push(e.getInstance(t))})),n},e.prototype.show=function(){this.isMultiple?(this.getMultipleToggles().forEach((function(t){return!!t&&(t.isShown=!0)})),this.el.closest("[data-hs-toggle-password-group]").classList.add("active")):(this.isShown=!0,this.el.classList.add("active"));this.target.forEach((function(t){t.type="text"}))},e.prototype.hide=function(){this.isMultiple?(this.getMultipleToggles().forEach((function(t){return!!t&&(t.isShown=!1)})),this.el.closest("[data-hs-toggle-password-group]").classList.remove("active")):(this.isShown=!1,this.el.classList.remove("active"));this.target.forEach((function(t){t.type="password"}))},e.prototype.destroy=function(){var t=this;this.isMultiple?this.el.closest("[data-hs-toggle-password-group]").classList.remove("active"):this.el.classList.remove("active"),this.target.forEach((function(t){t.type="password"})),this.el.removeEventListener(this.eventType,this.onElementActionListener),this.isShown=!1,window.$hsTogglePasswordCollection=window.$hsTogglePasswordCollection.filter((function(e){return e.element.el!==t.el}))},e.getInstance=function(t,e){var n=window.$hsTogglePasswordCollection.find((function(e){return e.element.el===("string"==typeof t?document.querySelector(t):t)}));return n?e?n:n.element:null},e.autoInit=function(){window.$hsTogglePasswordCollection||(window.$hsTogglePasswordCollection=[]),window.$hsTogglePasswordCollection&&(window.$hsTogglePasswordCollection=window.$hsTogglePasswordCollection.filter((function(t){var e=t.element;return document.contains(e.el)}))),document.querySelectorAll("[data-hs-toggle-password]:not(.--prevent-on-load-init)").forEach((function(t){window.$hsTogglePasswordCollection.find((function(e){var n;return(null===(n=null==e?void 0:e.element)||void 0===n?void 0:n.el)===t}))||new e(t)}))},e}(s(n(961)).default);window.addEventListener("load",(function(){a.autoInit()})),"undefined"!=typeof window&&(window.HSTogglePassword=a),e.default=a},969:function(t,e,n){ + /* + * HSTooltip + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var i,o=this&&this.__extends||(i=function(t,e){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n])},i(t,e)},function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}i(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}),r=this&&this.__assign||function(){return r=Object.assign||function(t){for(var e,n=1,i=arguments.length;n0&&a{ + /* + * HSStaticMethods + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + Object.defineProperty(e,"__esModule",{value:!0});var i=n(292),o=n(255),r={getClassProperty:i.getClassProperty,afterTransition:i.afterTransition,autoInit:function(t){void 0===t&&(t="all"),"all"===t?o.COLLECTIONS.forEach((function(t){var e=t.fn;null==e||e.autoInit()})):o.COLLECTIONS.forEach((function(e){var n=e.key,i=e.fn;t.includes(n)&&(null==i||i.autoInit())}))},cleanCollection:function(t){void 0===t&&(t="all"),"all"===t?o.COLLECTIONS.forEach((function(t){var e=t.collection;window[e]instanceof Array&&(window[e]=[])})):o.COLLECTIONS.forEach((function(e){var n=e.key,i=e.collection;t.includes(n)&&window[i]instanceof Array&&(window[i]=[])}))}};"undefined"!=typeof window&&(window.HSStaticMethods=r),e.default=r},292:function(t,e){ + /* + * @version: 2.6.0 + * @author: Preline Labs Ltd. + * @license: Licensed under MIT and Preline UI Fair Use License (https://preline.co/docs/license.html) + * Copyright 2024 Preline Labs Ltd. + */ + var n=this;Object.defineProperty(e,"__esModule",{value:!0}),e.menuSearchHistory=e.classToClassList=e.htmlToElement=e.afterTransition=e.dispatch=e.debounce=e.isJson=e.isDirectChild=e.isFormElement=e.isParentOrElementHidden=e.isEnoughSpace=e.isIpadOS=e.isIOS=e.getZIndex=e.getClassPropertyAlt=e.getClassProperty=e.stringToBoolean=void 0,e.getHighestZIndex=function(t){var e=Number.NEGATIVE_INFINITY;return t.forEach((function(t){var n=i(t);"auto"!==n&&(n=parseInt(n,10))>e&&(e=n)})),e};e.stringToBoolean=function(t){return"true"===t};e.getClassProperty=function(t,e,n){return void 0===n&&(n=""),(window.getComputedStyle(t).getPropertyValue(e)||n).replace(" ","")};e.getClassPropertyAlt=function(t,e,n){void 0===n&&(n="");var i="";return t.classList.forEach((function(t){t.includes(e)&&(i=t)})),i.match(/:(.*)]/)?i.match(/:(.*)]/)[1]:n};var i=function(t){return window.getComputedStyle(t).getPropertyValue("z-index")};e.getZIndex=i;e.isIOS=function(){return!!/iPad|iPhone|iPod/.test(navigator.platform)||navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/MacIntel/.test(navigator.platform)};e.isIpadOS=function(){return navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/MacIntel/.test(navigator.platform)};e.isDirectChild=function(t,e){for(var n=t.children,i=0;i=u:"top"===n?a>=u:a>=u||c>=u};e.isFormElement=function(t){return t instanceof HTMLInputElement||t instanceof HTMLTextAreaElement||t instanceof HTMLSelectElement};var o=function(t){return!!t&&("none"===window.getComputedStyle(t).display||o(t.parentElement))};e.isParentOrElementHidden=o;e.isJson=function(t){if("string"!=typeof t)return!1;var e=t.trim()[0],n=t.trim().slice(-1);if("{"===e&&"}"===n||"["===e&&"]"===n)try{return JSON.parse(t),!0}catch(t){return!1}return!1};e.debounce=function(t,e){var i;return void 0===e&&(e=200),function(){for(var o=[],r=0;r0?t.addEventListener("transitionend",n,!0):e()};e.htmlToElement=function(t){var e=document.createElement("template");return t=t.trim(),e.innerHTML=t,e.content.firstChild};e.classToClassList=function(t,e,n,i){void 0===n&&(n=" "),void 0===i&&(i="add"),t.split(n).forEach((function(t){return"add"===i?e.classList.add(t):e.classList.remove(t)}))};e.menuSearchHistory={historyIndex:-1,addHistory:function(t){this.historyIndex=t},existsInHistory:function(t){return t>this.historyIndex},clearHistory:function(){this.historyIndex=-1}}}},e={};function n(i){var o=e[i];if(void 0!==o)return o.exports;var r=e[i]={exports:{}};return t[i].call(r.exports,r,r.exports,n),r.exports}return n.d=(t,e)=>{for(var i in e)n.o(e,i)&&!n.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n(158)})()))})(t);var e=t.exports;export{e as default}; + //# sourceMappingURL=/sm/da56124dd0b83cee01be6b697adae119e3f7fef92ab6360c98d6ca610bdb42b4.map \ No newline at end of file diff --git a/src/modules/city/city.controller.js b/src/modules/city/city.controller.js index cb0a6eb..e71ee68 100644 --- a/src/modules/city/city.controller.js +++ b/src/modules/city/city.controller.js @@ -2,10 +2,13 @@ import axios from "axios"; export const index = async (req, res, next) => { try { - const response = await axios.get("https://airhopper-304285428031.asia-southeast1.run.app/api/v1/cities"); + const api = process.env.API_URL; + + const response = await axios.get(`${api}/api/v1/cities`); const cities = response.data.data; - res.edge("pages/city/index", { cities }); + + res.edge("pages/city/index", { cities, api }); } catch (error) { next(error); } diff --git a/src/resources/views/components/layout/app.edge b/src/resources/views/components/layout/app.edge index aa93138..a8f55fc 100644 --- a/src/resources/views/components/layout/app.edge +++ b/src/resources/views/components/layout/app.edge @@ -15,13 +15,21 @@ {{-- talwind and apline --}} - + + + + + + + +
@include('components/ui/sidebar') +
@@ -32,4 +40,30 @@
- \ No newline at end of file + + + + + diff --git a/src/resources/views/components/ui/city-modal.edge b/src/resources/views/components/ui/city-modal.edge index d4c0c77..e85dde3 100644 --- a/src/resources/views/components/ui/city-modal.edge +++ b/src/resources/views/components/ui/city-modal.edge @@ -1,7 +1,7 @@