@bikematrix/web-components 1.1.40 → 1.1.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bm_core.es.js +152 -144
- package/dist/bm_core.js +2 -2
- package/dist/bm_core.umd.js +2 -2
- package/package.json +1 -1
package/dist/bm_core.umd.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
(function(Sr,fe){typeof exports=="object"&&typeof module<"u"?module.exports=fe():typeof define=="function"&&define.amd?define(fe):(Sr=typeof globalThis<"u"?globalThis:Sr||self,Sr.BikeMatrix=fe())})(this,function(){"use strict";var Sr,fe,Gc,Qc,jn,qc,Vc,Is,Jc,_i={},Uc=[],i1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,eo=Array.isArray;function Mr(n,e){for(var t in e)n[t]=e[t];return n}function Kc(n){var e=n.parentNode;e&&e.removeChild(n)}function te(n,e,t){var r,i,o,l={};for(o in e)o=="key"?r=e[o]:o=="ref"?i=e[o]:l[o]=e[o];if(arguments.length>2&&(l.children=arguments.length>3?Sr.call(arguments,2):t),typeof n=="function"&&n.defaultProps!=null)for(o in n.defaultProps)l[o]===void 0&&(l[o]=n.defaultProps[o]);return $i(n,l,r,i,null)}function $i(n,e,t,r,i){var o={type:n,props:e,key:t,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:i??++Gc,__i:-1,__u:0};return i==null&&fe.vnode!=null&&fe.vnode(o),o}function a1(){return{current:null}}function ie(n){return n.children}function hr(n,e){this.props=n,this.context=e}function oi(n,e){if(e==null)return n.__?oi(n.__,n.__i+1):null;for(var t;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null)return t.__e;return typeof n.type=="function"?oi(n):null}function _c(n){var e,t;if((n=n.__)!=null&&n.__c!=null){for(n.__e=n.__c.base=null,e=0;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null){n.__e=n.__c.base=t.__e;break}return _c(n)}}function Ss(n){(!n.__d&&(n.__d=!0)&&jn.push(n)&&!to.__r++||qc!==fe.debounceRendering)&&((qc=fe.debounceRendering)||Vc)(to)}function to(){var n,e,t,r,i,o,l,u,c;for(jn.sort(Is);n=jn.shift();)n.__d&&(e=jn.length,r=void 0,o=(i=(t=n).__v).__e,u=[],c=[],(l=t.__P)&&((r=Mr({},i)).__v=i.__v+1,fe.vnode&&fe.vnode(r),Ms(l,r,i,t.__n,l.ownerSVGElement!==void 0,32&i.__u?[o]:null,u,o??oi(i),!!(32&i.__u),c),r.__v=i.__v,r.__.__k[r.__i]=r,id(u,r,c),r.__e!=o&&_c(r)),jn.length>e&&jn.sort(Is));to.__r=0}function $c(n,e,t,r,i,o,l,u,c,f,p){var h,b,m,k,x,H=r&&r.__k||Uc,C=e.length;for(t.__d=c,o1(t,e,H),c=t.__d,h=0;h<C;h++)(m=t.__k[h])!=null&&typeof m!="boolean"&&typeof m!="function"&&(b=m.__i===-1?_i:H[m.__i]||_i,m.__i=h,Ms(n,m,b,i,o,l,u,c,f,p),k=m.__e,m.ref&&b.ref!=m.ref&&(b.ref&&Ws(b.ref,null,m),p.push(m.ref,m.__c||k,m)),x==null&&k!=null&&(x=k),65536&m.__u||b.__k===m.__k?c=ed(m,c,n):typeof m.type=="function"&&m.__d!==void 0?c=m.__d:k&&(c=k.nextSibling),m.__d=void 0,m.__u&=-196609);t.__d=c,t.__e=x}function o1(n,e,t){var r,i,o,l,u,c=e.length,f=t.length,p=f,h=0;for(n.__k=[],r=0;r<c;r++)l=r+h,(i=n.__k[r]=(i=e[r])==null||typeof i=="boolean"||typeof i=="function"?null:typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?$i(null,i,null,null,null):eo(i)?$i(ie,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?$i(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)!=null?(i.__=n,i.__b=n.__b+1,u=s1(i,t,l,p),i.__i=u,o=null,u!==-1&&(p--,(o=t[u])&&(o.__u|=131072)),o==null||o.__v===null?(u==-1&&h--,typeof i.type!="function"&&(i.__u|=65536)):u!==l&&(u===l+1?h++:u>l?p>c-l?h+=u-l:h--:u<l?u==l-1&&(h=u-l):h=0,u!==r+h&&(i.__u|=65536))):(o=t[l])&&o.key==null&&o.__e&&!(131072&o.__u)&&(o.__e==n.__d&&(n.__d=oi(o)),Zs(o,o,!1),t[l]=null,p--);if(p)for(r=0;r<f;r++)(o=t[r])!=null&&!(131072&o.__u)&&(o.__e==n.__d&&(n.__d=oi(o)),Zs(o,o))}function ed(n,e,t){var r,i;if(typeof n.type=="function"){for(r=n.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=n,e=ed(r[i],e,t));return e}n.__e!=e&&(t.insertBefore(n.__e,e||null),e=n.__e);do e=e&&e.nextSibling;while(e!=null&&e.nodeType===8);return e}function Wr(n,e){return e=e||[],n==null||typeof n=="boolean"||(eo(n)?n.some(function(t){Wr(t,e)}):e.push(n)),e}function s1(n,e,t,r){var i=n.key,o=n.type,l=t-1,u=t+1,c=e[t];if(c===null||c&&i==c.key&&o===c.type&&!(131072&c.__u))return t;if(r>(c!=null&&!(131072&c.__u)?1:0))for(;l>=0||u<e.length;){if(l>=0){if((c=e[l])&&!(131072&c.__u)&&i==c.key&&o===c.type)return l;l--}if(u<e.length){if((c=e[u])&&!(131072&c.__u)&&i==c.key&&o===c.type)return u;u++}}return-1}function td(n,e,t){e[0]==="-"?n.setProperty(e,t??""):n[e]=t==null?"":typeof t!="number"||i1.test(e)?t:t+"px"}function ro(n,e,t,r,i){var o;e:if(e==="style")if(typeof t=="string")n.style.cssText=t;else{if(typeof r=="string"&&(n.style.cssText=r=""),r)for(e in r)t&&e in t||td(n.style,e,"");if(t)for(e in t)r&&t[e]===r[e]||td(n.style,e,t[e])}else if(e[0]==="o"&&e[1]==="n")o=e!==(e=e.replace(/(PointerCapture)$|Capture$/i,"$1")),e=e.toLowerCase()in n?e.toLowerCase().slice(2):e.slice(2),n.l||(n.l={}),n.l[e+o]=t,t?r?t.u=r.u:(t.u=Date.now(),n.addEventListener(e,o?nd:rd,o)):n.removeEventListener(e,o?nd:rd,o);else{if(i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!=="width"&&e!=="height"&&e!=="href"&&e!=="list"&&e!=="form"&&e!=="tabIndex"&&e!=="download"&&e!=="rowSpan"&&e!=="colSpan"&&e!=="role"&&e in n)try{n[e]=t??"";break e}catch{}typeof t=="function"||(t==null||t===!1&&e[4]!=="-"?n.removeAttribute(e):n.setAttribute(e,t))}}function rd(n){if(this.l){var e=this.l[n.type+!1];if(n.t){if(n.t<=e.u)return}else n.t=Date.now();return e(fe.event?fe.event(n):n)}}function nd(n){if(this.l)return this.l[n.type+!0](fe.event?fe.event(n):n)}function Ms(n,e,t,r,i,o,l,u,c,f){var p,h,b,m,k,x,H,C,w,P,D,O,j,L,T,X=e.type;if(e.constructor!==void 0)return null;128&t.__u&&(c=!!(32&t.__u),o=[u=e.__e=t.__e]),(p=fe.__b)&&p(e);e:if(typeof X=="function")try{if(C=e.props,w=(p=X.contextType)&&r[p.__c],P=p?w?w.props.value:p.__:r,t.__c?H=(h=e.__c=t.__c).__=h.__E:("prototype"in X&&X.prototype.render?e.__c=h=new X(C,P):(e.__c=h=new hr(C,P),h.constructor=X,h.render=u1),w&&w.sub(h),h.props=C,h.state||(h.state={}),h.context=P,h.__n=r,b=h.__d=!0,h.__h=[],h._sb=[]),h.__s==null&&(h.__s=h.state),X.getDerivedStateFromProps!=null&&(h.__s==h.state&&(h.__s=Mr({},h.__s)),Mr(h.__s,X.getDerivedStateFromProps(C,h.__s))),m=h.props,k=h.state,h.__v=e,b)X.getDerivedStateFromProps==null&&h.componentWillMount!=null&&h.componentWillMount(),h.componentDidMount!=null&&h.__h.push(h.componentDidMount);else{if(X.getDerivedStateFromProps==null&&C!==m&&h.componentWillReceiveProps!=null&&h.componentWillReceiveProps(C,P),!h.__e&&(h.shouldComponentUpdate!=null&&h.shouldComponentUpdate(C,h.__s,P)===!1||e.__v===t.__v)){for(e.__v!==t.__v&&(h.props=C,h.state=h.__s,h.__d=!1),e.__e=t.__e,e.__k=t.__k,e.__k.forEach(function(M){M&&(M.__=e)}),D=0;D<h._sb.length;D++)h.__h.push(h._sb[D]);h._sb=[],h.__h.length&&l.push(h);break e}h.componentWillUpdate!=null&&h.componentWillUpdate(C,h.__s,P),h.componentDidUpdate!=null&&h.__h.push(function(){h.componentDidUpdate(m,k,x)})}if(h.context=P,h.props=C,h.__P=n,h.__e=!1,O=fe.__r,j=0,"prototype"in X&&X.prototype.render){for(h.state=h.__s,h.__d=!1,O&&O(e),p=h.render(h.props,h.state,h.context),L=0;L<h._sb.length;L++)h.__h.push(h._sb[L]);h._sb=[]}else do h.__d=!1,O&&O(e),p=h.render(h.props,h.state,h.context),h.state=h.__s;while(h.__d&&++j<25);h.state=h.__s,h.getChildContext!=null&&(r=Mr(Mr({},r),h.getChildContext())),b||h.getSnapshotBeforeUpdate==null||(x=h.getSnapshotBeforeUpdate(m,k)),$c(n,eo(T=p!=null&&p.type===ie&&p.key==null?p.props.children:p)?T:[T],e,t,r,i,o,l,u,c,f),h.base=e.__e,e.__u&=-161,h.__h.length&&l.push(h),H&&(h.__E=h.__=null)}catch(M){e.__v=null,c||o!=null?(e.__e=u,e.__u|=c?160:32,o[o.indexOf(u)]=null):(e.__e=t.__e,e.__k=t.__k),fe.__e(M,e,t)}else o==null&&e.__v===t.__v?(e.__k=t.__k,e.__e=t.__e):e.__e=l1(t.__e,e,t,r,i,o,l,c,f);(p=fe.diffed)&&p(e)}function id(n,e,t){e.__d=void 0;for(var r=0;r<t.length;r++)Ws(t[r],t[++r],t[++r]);fe.__c&&fe.__c(e,n),n.some(function(i){try{n=i.__h,i.__h=[],n.some(function(o){o.call(i)})}catch(o){fe.__e(o,i.__v)}})}function l1(n,e,t,r,i,o,l,u,c){var f,p,h,b,m,k,x,H=t.props,C=e.props,w=e.type;if(w==="svg"&&(i=!0),o!=null){for(f=0;f<o.length;f++)if((m=o[f])&&"setAttribute"in m==!!w&&(w?m.localName===w:m.nodeType===3)){n=m,o[f]=null;break}}if(n==null){if(w===null)return document.createTextNode(C);n=i?document.createElementNS("http://www.w3.org/2000/svg",w):document.createElement(w,C.is&&C),o=null,u=!1}if(w===null)H===C||u&&n.data===C||(n.data=C);else{if(o=o&&Sr.call(n.childNodes),H=t.props||_i,!u&&o!=null)for(H={},f=0;f<n.attributes.length;f++)H[(m=n.attributes[f]).name]=m.value;for(f in H)m=H[f],f=="children"||(f=="dangerouslySetInnerHTML"?h=m:f==="key"||f in C||ro(n,f,null,m,i));for(f in C)m=C[f],f=="children"?b=m:f=="dangerouslySetInnerHTML"?p=m:f=="value"?k=m:f=="checked"?x=m:f==="key"||u&&typeof m!="function"||H[f]===m||ro(n,f,m,H[f],i);if(p)u||h&&(p.__html===h.__html||p.__html===n.innerHTML)||(n.innerHTML=p.__html),e.__k=[];else if(h&&(n.innerHTML=""),$c(n,eo(b)?b:[b],e,t,r,i&&w!=="foreignObject",o,l,o?o[0]:t.__k&&oi(t,0),u,c),o!=null)for(f=o.length;f--;)o[f]!=null&&Kc(o[f]);u||(f="value",k!==void 0&&(k!==n[f]||w==="progress"&&!k||w==="option"&&k!==H[f])&&ro(n,f,k,H[f],!1),f="checked",x!==void 0&&x!==n[f]&&ro(n,f,x,H[f],!1))}return n}function Ws(n,e,t){try{typeof n=="function"?n(e):n.current=e}catch(r){fe.__e(r,t)}}function Zs(n,e,t){var r,i;if(fe.unmount&&fe.unmount(n),(r=n.ref)&&(r.current&&r.current!==n.__e||Ws(r,null,e)),(r=n.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){fe.__e(o,e)}r.base=r.__P=null,n.__c=void 0}if(r=n.__k)for(i=0;i<r.length;i++)r[i]&&Zs(r[i],e,t||typeof n.type!="function");t||n.__e==null||Kc(n.__e),n.__=n.__e=n.__d=void 0}function u1(n,e,t){return this.constructor(n,t)}function ln(n,e,t){var r,i,o,l;fe.__&&fe.__(n,e),i=(r=typeof t=="function")?null:t&&t.__k||e.__k,o=[],l=[],Ms(e,n=(!r&&t||e).__k=te(ie,null,[n]),i||_i,_i,e.ownerSVGElement!==void 0,!r&&t?[t]:i?null:e.firstChild?Sr.call(e.childNodes):null,o,!r&&t?t:i?i.__e:e.firstChild,r,l),id(o,n,l)}function Ys(n,e){ln(n,e,Ys)}function Fs(n,e,t){var r,i,o,l,u=Mr({},n.props);for(o in n.type&&n.type.defaultProps&&(l=n.type.defaultProps),e)o=="key"?r=e[o]:o=="ref"?i=e[o]:u[o]=e[o]===void 0&&l!==void 0?l[o]:e[o];return arguments.length>2&&(u.children=arguments.length>3?Sr.call(arguments,2):t),$i(n.type,u,r||n.key,i||n.ref,null)}function ea(n,e){var t={__c:e="__cC"+Jc++,__:n,Consumer:function(r,i){return r.children(i)},Provider:function(r){var i,o;return this.getChildContext||(i=[],(o={})[e]=this,this.getChildContext=function(){return o},this.shouldComponentUpdate=function(l){this.props.value!==l.value&&i.some(function(u){u.__e=!0,Ss(u)})},this.sub=function(l){i.push(l);var u=l.componentWillUnmount;l.componentWillUnmount=function(){i.splice(i.indexOf(l),1),u&&u.call(l)}}),r.children}};return t.Provider.__=t.Consumer.contextType=t}Sr=Uc.slice,fe={__e:function(n,e,t,r){for(var i,o,l;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(n)),l=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(n,r||{}),l=i.__d),l)return i.__E=i}catch(u){n=u}throw n}},Gc=0,Qc=function(n){return n!=null&&n.constructor==null},hr.prototype.setState=function(n,e){var t;t=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=Mr({},this.state),typeof n=="function"&&(n=n(Mr({},t),this.props)),n&&Mr(t,n),n!=null&&this.__v&&(e&&this._sb.push(e),Ss(this))},hr.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),Ss(this))},hr.prototype.render=ie,jn=[],Vc=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Is=function(n,e){return n.__v.__b-e.__v.__b},to.__r=0,Jc=0;function Ns(){return(Ns=Object.assign?Object.assign.bind():function(n){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r])}return n}).apply(this,arguments)}var c1=["context","children"];function d1(n){this.getChildContext=function(){return n.context};var e=n.children,t=function(r,i){if(r==null)return{};var o,l,u={},c=Object.keys(r);for(l=0;l<c.length;l++)i.indexOf(o=c[l])>=0||(u[o]=r[o]);return u}(n,c1);return Fs(e,t)}function f1(){var n=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(n),this._vdom=te(d1,Ns({},this._props,{context:n.detail.context}),function e(t,r){if(t.nodeType===3)return t.data;if(t.nodeType!==1)return null;var i=[],o={},l=0,u=t.attributes,c=t.childNodes;for(l=u.length;l--;)u[l].name!=="slot"&&(o[u[l].name]=u[l].value,o[ad(u[l].name)]=u[l].value);for(l=c.length;l--;){var f=e(c[l],null),p=c[l].slot;p?o[p]=te(od,{name:p},f):i[l]=f}var h=r?te(od,null,i):i;return te(r||t.nodeName.toLowerCase(),o,h)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?Ys:ln)(this._vdom,this._root)}function ad(n){return n.replace(/-(\w)/g,function(e,t){return t?t.toUpperCase():""})}function p1(n,e,t){if(this._vdom){var r={};r[n]=t=t??void 0,r[ad(n)]=t,this._vdom=Fs(this._vdom,r),ln(this._vdom,this._root)}}function h1(){ln(this._vdom=null,this._root)}function od(n,e){var t=this;return te("slot",Ns({},n,{ref:function(r){r?(t.ref=r,t._listener||(t._listener=function(i){i.stopPropagation(),i.detail.context=e},r.addEventListener("_preact",t._listener))):t.ref.removeEventListener("_preact",t._listener)}}))}function v1(n,e,t,r){function i(){var o=Reflect.construct(HTMLElement,[],i);return o._vdomComponent=n,o._root=r&&r.shadow?o.attachShadow({mode:r.mode||"open"}):o,o}return(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=f1,i.prototype.attributeChangedCallback=p1,i.prototype.disconnectedCallback=h1,t=t||n.observedAttributes||Object.keys(n.propTypes||{}),i.observedAttributes=t,t.forEach(function(o){Object.defineProperty(i.prototype,o,{get:function(){return this._vdom.props[o]},set:function(l){this._vdom?this.attributeChangedCallback(o,null,l):(this._props||(this._props={}),this._props[o]=l,this.connectedCallback());var u=typeof l;l!=null&&u!=="string"&&u!=="boolean"&&u!=="number"||this.setAttribute(o,l)}})}),customElements.define(e||n.tagName||n.displayName||n.name,i)}var un,Ze,Rs,sd,si=0,ld=[],no=[],Qe=fe,ud=Qe.__b,cd=Qe.__r,dd=Qe.diffed,fd=Qe.__c,pd=Qe.unmount,hd=Qe.__;function li(n,e){Qe.__h&&Qe.__h(Ze,n,si||e),si=0;var t=Ze.__H||(Ze.__H={__:[],__h:[]});return n>=t.__.length&&t.__.push({__V:no}),t.__[n]}function $(n){return si=1,vd(md,n)}function vd(n,e,t){var r=li(un++,2);if(r.t=n,!r.__c&&(r.__=[t?t(e):md(void 0,e),function(u){var c=r.__N?r.__N[0]:r.__[0],f=r.t(c,u);c!==f&&(r.__N=[f,r.__[1]],r.__c.setState({}))}],r.__c=Ze,!Ze.u)){var i=function(u,c,f){if(!r.__c.__H)return!0;var p=r.__c.__H.__.filter(function(b){return!!b.__c});if(p.every(function(b){return!b.__N}))return!o||o.call(this,u,c,f);var h=!1;return p.forEach(function(b){if(b.__N){var m=b.__[0];b.__=b.__N,b.__N=void 0,m!==b.__[0]&&(h=!0)}}),!(!h&&r.__c.props===u)&&(!o||o.call(this,u,c,f))};Ze.u=!0;var o=Ze.shouldComponentUpdate,l=Ze.componentWillUpdate;Ze.componentWillUpdate=function(u,c,f){if(this.__e){var p=o;o=void 0,i(u,c,f),o=p}l&&l.call(this,u,c,f)},Ze.shouldComponentUpdate=i}return r.__N||r.__}function se(n,e){var t=li(un++,3);!Qe.__s&&qs(t.__H,e)&&(t.__=n,t.i=e,Ze.__H.__h.push(t))}function ui(n,e){var t=li(un++,4);!Qe.__s&&qs(t.__H,e)&&(t.__=n,t.i=e,Ze.__h.push(t))}function be(n){return si=5,kr(function(){return{current:n}},[])}function g1(n,e,t){si=6,ui(function(){return typeof n=="function"?(n(e()),function(){return n(null)}):n?(n.current=e(),function(){return n.current=null}):void 0},t==null?t:t.concat(n))}function kr(n,e){var t=li(un++,7);return qs(t.__H,e)?(t.__V=n(),t.i=e,t.__h=n,t.__V):t.__}function gd(n,e){return si=8,kr(function(){return n},e)}function Gs(n){var e=Ze.context[n.__c],t=li(un++,9);return t.c=n,e?(t.__==null&&(t.__=!0,e.sub(Ze)),e.props.value):n.__}function b1(n,e){Qe.useDebugValue&&Qe.useDebugValue(e?e(n):n)}function m1(){var n=li(un++,11);if(!n.__){for(var e=Ze.__v;e!==null&&!e.__m&&e.__!==null;)e=e.__;var t=e.__m||(e.__m=[0,0]);n.__="P"+t[0]+"-"+t[1]++}return n.__}function y1(){for(var n;n=ld.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(io),n.__H.__h.forEach(Qs),n.__H.__h=[]}catch(e){n.__H.__h=[],Qe.__e(e,n.__v)}}Qe.__b=function(n){Ze=null,ud&&ud(n)},Qe.__=function(n,e){n&&e.__k&&e.__k.__m&&(n.__m=e.__k.__m),hd&&hd(n,e)},Qe.__r=function(n){cd&&cd(n),un=0;var e=(Ze=n.__c).__H;e&&(Rs===Ze?(e.__h=[],Ze.__h=[],e.__.forEach(function(t){t.__N&&(t.__=t.__N),t.__V=no,t.__N=t.i=void 0})):(e.__h.forEach(io),e.__h.forEach(Qs),e.__h=[],un=0)),Rs=Ze},Qe.diffed=function(n){dd&&dd(n);var e=n.__c;e&&e.__H&&(e.__H.__h.length&&(ld.push(e)!==1&&sd===Qe.requestAnimationFrame||((sd=Qe.requestAnimationFrame)||w1)(y1)),e.__H.__.forEach(function(t){t.i&&(t.__H=t.i),t.__V!==no&&(t.__=t.__V),t.i=void 0,t.__V=no})),Rs=Ze=null},Qe.__c=function(n,e){e.some(function(t){try{t.__h.forEach(io),t.__h=t.__h.filter(function(r){return!r.__||Qs(r)})}catch(r){e.some(function(i){i.__h&&(i.__h=[])}),e=[],Qe.__e(r,t.__v)}}),fd&&fd(n,e)},Qe.unmount=function(n){pd&&pd(n);var e,t=n.__c;t&&t.__H&&(t.__H.__.forEach(function(r){try{io(r)}catch(i){e=i}}),t.__H=void 0,e&&Qe.__e(e,t.__v))};var bd=typeof requestAnimationFrame=="function";function w1(n){var e,t=function(){clearTimeout(r),bd&&cancelAnimationFrame(e),setTimeout(n)},r=setTimeout(t,100);bd&&(e=requestAnimationFrame(t))}function io(n){var e=Ze,t=n.__c;typeof t=="function"&&(n.__c=void 0,t()),Ze=e}function Qs(n){var e=Ze;n.__c=n.__(),Ze=e}function qs(n,e){return!n||n.length!==e.length||e.some(function(t,r){return t!==n[r]})}function md(n,e){return typeof e=="function"?e(n):e}function yd(n,e){for(var t in e)n[t]=e[t];return n}function Vs(n,e){for(var t in n)if(t!=="__source"&&!(t in e))return!0;for(var r in e)if(r!=="__source"&&n[r]!==e[r])return!0;return!1}function Js(n,e){this.props=n,this.context=e}function x1(n,e){function t(i){var o=this.props.ref,l=o==i.ref;return!l&&o&&(o.call?o(null):o.current=null),e?!e(this.props,i)||!l:Vs(this.props,i)}function r(i){return this.shouldComponentUpdate=t,te(n,i)}return r.displayName="Memo("+(n.displayName||n.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Js.prototype=new hr).isPureReactComponent=!0,Js.prototype.shouldComponentUpdate=function(n,e){return Vs(this.props,n)||Vs(this.state,e)};var wd=fe.__b;fe.__b=function(n){n.type&&n.type.__f&&n.ref&&(n.props.ref=n.ref,n.ref=null),wd&&wd(n)};var P1=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function Us(n){function e(t){var r=yd({},t);return delete r.ref,n(r,t.ref||null)}return e.$$typeof=P1,e.render=e,e.prototype.isReactComponent=e.__f=!0,e.displayName="ForwardRef("+(n.displayName||n.name)+")",e}var xd=function(n,e){return n==null?null:Wr(Wr(n).map(e))},k1={map:xd,forEach:xd,count:function(n){return n?Wr(n).length:0},only:function(n){var e=Wr(n);if(e.length!==1)throw"Children.only";return e[0]},toArray:Wr},z1=fe.__e;fe.__e=function(n,e,t,r){if(n.then){for(var i,o=e;o=o.__;)if((i=o.__c)&&i.__c)return e.__e==null&&(e.__e=t.__e,e.__k=t.__k),i.__c(n,e)}z1(n,e,t,r)};var Pd=fe.unmount;function kd(n,e,t){return n&&(n.__c&&n.__c.__H&&(n.__c.__H.__.forEach(function(r){typeof r.__c=="function"&&r.__c()}),n.__c.__H=null),(n=yd({},n)).__c!=null&&(n.__c.__P===t&&(n.__c.__P=e),n.__c=null),n.__k=n.__k&&n.__k.map(function(r){return kd(r,e,t)})),n}function zd(n,e,t){return n&&t&&(n.__v=null,n.__k=n.__k&&n.__k.map(function(r){return zd(r,e,t)}),n.__c&&n.__c.__P===e&&(n.__e&&t.appendChild(n.__e),n.__c.__e=!0,n.__c.__P=t)),n}function ao(){this.__u=0,this.t=null,this.__b=null}function Cd(n){var e=n.__.__c;return e&&e.__a&&e.__a(n)}function C1(n){var e,t,r;function i(o){if(e||(e=n()).then(function(l){t=l.default||l},function(l){r=l}),r)throw r;if(!t)throw e;return te(t,o)}return i.displayName="Lazy",i.__f=!0,i}function ta(){this.u=null,this.o=null}fe.unmount=function(n){var e=n.__c;e&&e.__R&&e.__R(),e&&32&n.__u&&(n.type=null),Pd&&Pd(n)},(ao.prototype=new hr).__c=function(n,e){var t=e.__c,r=this;r.t==null&&(r.t=[]),r.t.push(t);var i=Cd(r.__v),o=!1,l=function(){o||(o=!0,t.__R=null,i?i(u):u())};t.__R=l;var u=function(){if(!--r.__u){if(r.state.__a){var c=r.state.__a;r.__v.__k[0]=zd(c,c.__c.__P,c.__c.__O)}var f;for(r.setState({__a:r.__b=null});f=r.t.pop();)f.forceUpdate()}};r.__u++||32&e.__u||r.setState({__a:r.__b=r.__v.__k[0]}),n.then(l,l)},ao.prototype.componentWillUnmount=function(){this.t=[]},ao.prototype.render=function(n,e){if(this.__b){if(this.__v.__k){var t=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=kd(this.__b,t,r.__O=r.__P)}this.__b=null}var i=e.__a&&te(ie,null,n.fallback);return i&&(i.__u&=-33),[te(ie,null,e.__a?null:n.children),i]};var Hd=function(n,e,t){if(++t[1]===t[0]&&n.o.delete(e),n.props.revealOrder&&(n.props.revealOrder[0]!=="t"||!n.o.size))for(t=n.u;t;){for(;t.length>3;)t.pop()();if(t[1]<t[0])break;n.u=t=t[2]}};function H1(n){return this.getChildContext=function(){return n.context},n.children}function A1(n){var e=this,t=n.i;e.componentWillUnmount=function(){ln(null,e.l),e.l=null,e.i=null},e.i&&e.i!==t&&e.componentWillUnmount(),e.l||(e.i=t,e.l={nodeType:1,parentNode:t,childNodes:[],appendChild:function(r){this.childNodes.push(r),e.i.appendChild(r)},insertBefore:function(r,i){this.childNodes.push(r),e.i.appendChild(r)},removeChild:function(r){this.childNodes.splice(this.childNodes.indexOf(r)>>>1,1),e.i.removeChild(r)}}),ln(te(H1,{context:e.context},n.__v),e.l)}function D1(n,e){var t=te(A1,{__v:n,i:e});return t.containerInfo=e,t}(ta.prototype=new hr).__a=function(n){var e=this,t=Cd(e.__v),r=e.o.get(n);return r[0]++,function(i){var o=function(){e.props.revealOrder?(r.push(i),Hd(e,n,r)):i()};t?t(o):o()}},ta.prototype.render=function(n){this.u=null,this.o=new Map;var e=Wr(n.children);n.revealOrder&&n.revealOrder[0]==="b"&&e.reverse();for(var t=e.length;t--;)this.o.set(e[t],this.u=[1,0,this.u]);return n.children},ta.prototype.componentDidUpdate=ta.prototype.componentDidMount=function(){var n=this;this.o.forEach(function(e,t){Hd(n,t,e)})};var Ad=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,O1=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,X1=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,E1=/[A-Z0-9]/g,L1=typeof document<"u",B1=function(n){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(n)};function j1(n,e,t){return e.__k==null&&(e.textContent=""),ln(n,e),typeof t=="function"&&t(),n?n.__c:null}function T1(n,e,t){return Ys(n,e),typeof t=="function"&&t(),n?n.__c:null}hr.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(n){Object.defineProperty(hr.prototype,n,{configurable:!0,get:function(){return this["UNSAFE_"+n]},set:function(e){Object.defineProperty(this,n,{configurable:!0,writable:!0,value:e})}})});var Dd=fe.event;function I1(){}function S1(){return this.cancelBubble}function M1(){return this.defaultPrevented}fe.event=function(n){return Dd&&(n=Dd(n)),n.persist=I1,n.isPropagationStopped=S1,n.isDefaultPrevented=M1,n.nativeEvent=n};var Ks,W1={enumerable:!1,configurable:!0,get:function(){return this.class}},Od=fe.vnode;fe.vnode=function(n){typeof n.type=="string"&&function(e){var t=e.props,r=e.type,i={};for(var o in t){var l=t[o];if(!(o==="value"&&"defaultValue"in t&&l==null||L1&&o==="children"&&r==="noscript"||o==="class"||o==="className")){var u=o.toLowerCase();o==="defaultValue"&&"value"in t&&t.value==null?o="value":o==="download"&&l===!0?l="":u==="translate"&&l==="no"?l=!1:u==="ondoubleclick"?o="ondblclick":u!=="onchange"||r!=="input"&&r!=="textarea"||B1(t.type)?u==="onfocus"?o="onfocusin":u==="onblur"?o="onfocusout":X1.test(o)?o=u:r.indexOf("-")===-1&&O1.test(o)?o=o.replace(E1,"-$&").toLowerCase():l===null&&(l=void 0):u=o="oninput",u==="oninput"&&i[o=u]&&(o="oninputCapture"),i[o]=l}}r=="select"&&i.multiple&&Array.isArray(i.value)&&(i.value=Wr(t.children).forEach(function(c){c.props.selected=i.value.indexOf(c.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=Wr(t.children).forEach(function(c){c.props.selected=i.multiple?i.defaultValue.indexOf(c.props.value)!=-1:i.defaultValue==c.props.value})),t.class&&!t.className?(i.class=t.class,Object.defineProperty(i,"className",W1)):(t.className&&!t.class||t.class&&t.className)&&(i.class=i.className=t.className),e.props=i}(n),n.$$typeof=Ad,Od&&Od(n)};var Xd=fe.__r;fe.__r=function(n){Xd&&Xd(n),Ks=n.__c};var Ed=fe.diffed;fe.diffed=function(n){Ed&&Ed(n);var e=n.props,t=n.__e;t!=null&&n.type==="textarea"&&"value"in e&&e.value!==t.value&&(t.value=e.value==null?"":e.value),Ks=null};var Z1={ReactCurrentDispatcher:{current:{readContext:function(n){return Ks.__n[n.__c].props.value}}}};function Y1(n){return te.bind(null,n)}function oo(n){return!!n&&n.$$typeof===Ad}function F1(n){return oo(n)&&n.type===ie}function N1(n){return oo(n)?Fs.apply(null,arguments):n}function R1(n){return!!n.__k&&(ln(null,n),!0)}function G1(n){return n&&(n.base||n.nodeType===1&&n)||null}var Q1=function(n,e){return n(e)},q1=function(n,e){return n(e)},V1=ie;function Ld(n){n()}function J1(n){return n}function U1(){return[!1,Ld]}var K1=ui,_1=oo;function $1(n,e){var t=e(),r=$({h:{__:t,v:e}}),i=r[0].h,o=r[1];return ui(function(){i.__=t,i.v=e,_s(i)&&o({h:i})},[n,t,e]),se(function(){return _s(i)&&o({h:i}),n(function(){_s(i)&&o({h:i})})},[n]),t}function _s(n){var e,t,r=n.v,i=n.__;try{var o=r();return!((e=i)===(t=o)&&(e!==0||1/e==1/t)||e!=e&&t!=t)}catch{return!0}}var it={useState:$,useId:m1,useReducer:vd,useEffect:se,useLayoutEffect:ui,useInsertionEffect:K1,useTransition:U1,useDeferredValue:J1,useSyncExternalStore:$1,startTransition:Ld,useRef:be,useImperativeHandle:g1,useMemo:kr,useCallback:gd,useContext:Gs,useDebugValue:b1,version:"17.0.2",Children:k1,render:j1,hydrate:T1,unmountComponentAtNode:R1,createPortal:D1,createElement:te,createContext:ea,createFactory:Y1,cloneElement:N1,createRef:a1,Fragment:ie,isValidElement:oo,isElement:_1,isFragment:F1,findDOMNode:G1,Component:hr,PureComponent:Js,memo:x1,forwardRef:Us,flushSync:q1,unstable_batchedUpdates:Q1,StrictMode:V1,Suspense:ao,SuspenseList:ta,lazy:C1,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Z1},cn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function eg(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}const tg=(...n)=>{console!=null&&console.warn&&(Tn(n[0])&&(n[0]=`react-i18next:: ${n[0]}`),console.warn(...n))},Bd={},$s=(...n)=>{Tn(n[0])&&Bd[n[0]]||(Tn(n[0])&&(Bd[n[0]]=new Date),tg(...n))},jd=(n,e)=>()=>{if(n.isInitialized)e();else{const t=()=>{setTimeout(()=>{n.off("initialized",t)},0),e()};n.on("initialized",t)}},Td=(n,e,t)=>{n.loadNamespaces(e,jd(n,t))},Id=(n,e,t,r)=>{Tn(t)&&(t=[t]),t.forEach(i=>{n.options.ns.indexOf(i)<0&&n.options.ns.push(i)}),n.loadLanguages(e,jd(n,r))},rg=(n,e,t={})=>!e.languages||!e.languages.length?($s("i18n.languages were undefined or empty",e.languages),!0):e.hasLoadedNamespace(n,{lng:t.lng,precheck:(r,i)=>{var o;if(((o=t.bindI18n)==null?void 0:o.indexOf("languageChanging"))>-1&&r.services.backendConnector.backend&&r.isLanguageChangingTo&&!i(r.isLanguageChangingTo,n))return!1}}),Tn=n=>typeof n=="string",ng=n=>typeof n=="object"&&n!==null,ig=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,ag={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},og=n=>ag[n];let el={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:n=>n.replace(ig,og)};const sg=(n={})=>{el={...el,...n}},lg=()=>el;let Sd;const ug=n=>{Sd=n},ci=()=>Sd,cg={type:"3rdParty",init(n){sg(n.options.react),ug(n)}},dg=ea();class fg{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(t=>{this.usedNamespaces[t]||(this.usedNamespaces[t]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}const pg=(n,e)=>{const t=be();return se(()=>{t.current=e?t.current:n},[n,e]),t.current},Md=(n,e,t,r)=>n.getFixedT(e,t,r),hg=(n,e,t,r)=>gd(Md(n,e,t,r),[n,e,t,r]),Le=(n,e={})=>{var D,O,j,L;const{i18n:t}=e,{i18n:r,defaultNS:i}=Gs(dg)||{},o=t||r||ci();if(o&&!o.reportNamespaces&&(o.reportNamespaces=new fg),!o){$s("You will need to pass in an i18next instance by using initReactI18next");const T=(M,W)=>Tn(W)?W:ng(W)&&Tn(W.defaultValue)?W.defaultValue:Array.isArray(M)?M[M.length-1]:M,X=[T,{},!1];return X.t=T,X.i18n={},X.ready=!1,X}(D=o.options.react)!=null&&D.wait&&$s("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const l={...lg(),...o.options.react,...e},{useSuspense:u,keyPrefix:c}=l;let f=n||i||((O=o.options)==null?void 0:O.defaultNS);f=Tn(f)?[f]:f||["translation"],(L=(j=o.reportNamespaces).addUsedNamespaces)==null||L.call(j,f);const p=(o.isInitialized||o.initializedStoreOnce)&&f.every(T=>rg(T,o,l)),h=hg(o,e.lng||null,l.nsMode==="fallback"?f:f[0],c),b=()=>h,m=()=>Md(o,e.lng||null,l.nsMode==="fallback"?f:f[0],c),[k,x]=$(b);let H=f.join();e.lng&&(H=`${e.lng}${H}`);const C=pg(H),w=be(!0);se(()=>{const{bindI18n:T,bindI18nStore:X}=l;w.current=!0,!p&&!u&&(e.lng?Id(o,e.lng,f,()=>{w.current&&x(m)}):Td(o,f,()=>{w.current&&x(m)})),p&&C&&C!==H&&w.current&&x(m);const M=()=>{w.current&&x(m)};return T&&(o==null||o.on(T,M)),X&&(o==null||o.store.on(X,M)),()=>{w.current=!1,o&&(T==null||T.split(" ").forEach(W=>o.off(W,M))),X&&o&&X.split(" ").forEach(W=>o.store.off(W,M))}},[o,H]),se(()=>{w.current&&p&&x(b)},[o,c,p]);const P=[k,o,p];if(P.t=k,P.i18n=o,P.ready=p,p||!p&&!u)return P;throw new Promise(T=>{e.lng?Id(o,e.lng,f,()=>T()):Td(o,f,()=>T())})};var vg=Symbol.for("preact-signals");function so(){if(dn>1)dn--;else{for(var n,e=!1;ra!==void 0;){var t=ra;for(ra=void 0,tl++;t!==void 0;){var r=t.o;if(t.o=void 0,t.f&=-3,!(8&t.f)&&Zd(t))try{t.c()}catch(i){e||(n=i,e=!0)}t=r}}if(tl=0,dn--,e)throw n}}function gg(n){if(dn>0)return n();dn++;try{return n()}finally{so()}}var Be=void 0,ra=void 0,dn=0,tl=0,lo=0;function Wd(n){if(Be!==void 0){var e=n.n;if(e===void 0||e.t!==Be)return e={i:0,S:n,p:Be.s,n:void 0,t:Be,e:void 0,x:void 0,r:e},Be.s!==void 0&&(Be.s.n=e),Be.s=e,n.n=e,32&Be.f&&n.S(e),e;if(e.i===-1)return e.i=0,e.n!==void 0&&(e.n.p=e.p,e.p!==void 0&&(e.p.n=e.n),e.p=Be.s,e.n=void 0,Be.s.n=e,Be.s=e),e}}function ct(n){this.v=n,this.i=0,this.n=void 0,this.t=void 0}ct.prototype.brand=vg,ct.prototype.h=function(){return!0},ct.prototype.S=function(n){this.t!==n&&n.e===void 0&&(n.x=this.t,this.t!==void 0&&(this.t.e=n),this.t=n)},ct.prototype.U=function(n){if(this.t!==void 0){var e=n.e,t=n.x;e!==void 0&&(e.x=t,n.e=void 0),t!==void 0&&(t.e=e,n.x=void 0),n===this.t&&(this.t=t)}},ct.prototype.subscribe=function(n){var e=this;return nl(function(){var t=e.value,r=Be;Be=void 0;try{n(t)}finally{Be=r}})},ct.prototype.valueOf=function(){return this.value},ct.prototype.toString=function(){return this.value+""},ct.prototype.toJSON=function(){return this.value},ct.prototype.peek=function(){var n=Be;Be=void 0;try{return this.value}finally{Be=n}},Object.defineProperty(ct.prototype,"value",{get:function(){var n=Wd(this);return n!==void 0&&(n.i=this.i),this.v},set:function(n){if(n!==this.v){if(tl>100)throw new Error("Cycle detected");this.v=n,this.i++,lo++,dn++;try{for(var e=this.t;e!==void 0;e=e.x)e.t.N()}finally{so()}}}});function Ct(n){return new ct(n)}function Zd(n){for(var e=n.s;e!==void 0;e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function Yd(n){for(var e=n.s;e!==void 0;e=e.n){var t=e.S.n;if(t!==void 0&&(e.r=t),e.S.n=e,e.i=-1,e.n===void 0){n.s=e;break}}}function Fd(n){for(var e=n.s,t=void 0;e!==void 0;){var r=e.p;e.i===-1?(e.S.U(e),r!==void 0&&(r.n=e.n),e.n!==void 0&&(e.n.p=r)):t=e,e.S.n=e.r,e.r!==void 0&&(e.r=void 0),e=r}n.s=t}function di(n){ct.call(this,void 0),this.x=n,this.s=void 0,this.g=lo-1,this.f=4}(di.prototype=new ct).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===lo))return!0;if(this.g=lo,this.f|=1,this.i>0&&!Zd(this))return this.f&=-2,!0;var n=Be;try{Yd(this),Be=this;var e=this.x();(16&this.f||this.v!==e||this.i===0)&&(this.v=e,this.f&=-17,this.i++)}catch(t){this.v=t,this.f|=16,this.i++}return Be=n,Fd(this),this.f&=-2,!0},di.prototype.S=function(n){if(this.t===void 0){this.f|=36;for(var e=this.s;e!==void 0;e=e.n)e.S.S(e)}ct.prototype.S.call(this,n)},di.prototype.U=function(n){if(this.t!==void 0&&(ct.prototype.U.call(this,n),this.t===void 0)){this.f&=-33;for(var e=this.s;e!==void 0;e=e.n)e.S.U(e)}},di.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var n=this.t;n!==void 0;n=n.x)n.t.N()}},Object.defineProperty(di.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var n=Wd(this);if(this.h(),n!==void 0&&(n.i=this.i),16&this.f)throw this.v;return this.v}});function bg(n){return new di(n)}function Nd(n){var e=n.u;if(n.u=void 0,typeof e=="function"){dn++;var t=Be;Be=void 0;try{e()}catch(r){throw n.f&=-2,n.f|=8,rl(n),r}finally{Be=t,so()}}}function rl(n){for(var e=n.s;e!==void 0;e=e.n)e.S.U(e);n.x=void 0,n.s=void 0,Nd(n)}function mg(n){if(Be!==this)throw new Error("Out-of-order effect");Fd(this),Be=n,this.f&=-2,8&this.f&&rl(this),so()}function na(n){this.x=n,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}na.prototype.c=function(){var n=this.S();try{if(8&this.f||this.x===void 0)return;var e=this.x();typeof e=="function"&&(this.u=e)}finally{n()}},na.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,Nd(this),Yd(this),dn++;var n=Be;return Be=this,mg.bind(this,n)},na.prototype.N=function(){2&this.f||(this.f|=2,this.o=ra,ra=this)},na.prototype.d=function(){this.f|=8,1&this.f||rl(this)};function nl(n){var e=new na(n);try{e.c()}catch(t){throw e.d(),t}return e.d.bind(e)}var il;function fi(n,e){fe[n]=e.bind(null,fe[n]||function(){})}function uo(n){il&&il(),il=n&&n.S()}function Rd(n){var e=this,t=n.data,r=wg(t);r.value=t;var i=kr(function(){for(var o=e.__v;o=o.__;)if(o.__c){o.__c.__$f|=4;break}return e.__$u.c=function(){var l,u=e.__$u.S(),c=i.value;u(),Qc(c)||((l=e.base)==null?void 0:l.nodeType)!==3?(e.__$f|=1,e.setState({})):e.base.data=c},bg(function(){var l=r.value.value;return l===0?0:l===!0?"":l||""})},[]);return i.value}Rd.displayName="_st",Object.defineProperties(ct.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Rd},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),fi("__b",function(n,e){if(typeof e.type=="string"){var t,r=e.props;for(var i in r)if(i!=="children"){var o=r[i];o instanceof ct&&(t||(e.__np=t={}),t[i]=o,r[i]=o.peek())}}n(e)}),fi("__r",function(n,e){uo();var t,r=e.__c;r&&(r.__$f&=-2,(t=r.__$u)===void 0&&(r.__$u=t=function(i){var o;return nl(function(){o=this}),o.c=function(){r.__$f|=1,r.setState({})},o}())),uo(t),n(e)}),fi("__e",function(n,e,t,r){uo(),n(e,t,r)}),fi("diffed",function(n,e){uo();var t;if(typeof e.type=="string"&&(t=e.__e)){var r=e.__np,i=e.props;if(r){var o=t.U;if(o)for(var l in o){var u=o[l];u!==void 0&&!(l in r)&&(u.d(),o[l]=void 0)}else t.U=o={};for(var c in r){var f=o[c],p=r[c];f===void 0?(f=yg(t,c,p,i),o[c]=f):f.o(p,i)}}}n(e)});function yg(n,e,t,r){var i=e in n&&n.ownerSVGElement===void 0,o=Ct(t);return{o:function(l,u){o.value=l,r=u},d:nl(function(){var l=o.value.value;r[e]!==l&&(r[e]=l,i?n[e]=l:l?n.setAttribute(e,l):n.removeAttribute(e))})}}fi("unmount",function(n,e){if(typeof e.type=="string"){var t=e.__e;if(t){var r=t.U;if(r){t.U=void 0;for(var i in r){var o=r[i];o&&o.d()}}}}else{var l=e.__c;if(l){var u=l.__$u;u&&(l.__$u=void 0,u.d())}}n(e)}),fi("__h",function(n,e,t,r){(r<3||r===9)&&(e.__$f|=2),n(e,t,r)}),hr.prototype.shouldComponentUpdate=function(n,e){var t=this.__$u;if(!(t&&t.s!==void 0||4&this.__$f)||3&this.__$f)return!0;for(var r in e)return!0;for(var i in n)if(i!=="__source"&&n[i]!==this.props[i])return!0;for(var o in this.props)if(!(o in n))return!0;return!1};function wg(n){return kr(function(){return Ct(n)},[])}const al=Ct(!1),Ae=Ct(null),pi=Ct([]),Zt=Ct(!1),hi=Ct([]),rr=Ct(!1),co=Ct(null),ht=Ct(null),fo=Ct(!1),po=Ct(!0),xg=()=>{gg(()=>{Ae.value=null,pi.value=[],Zt.value=!1,hi.value=[],rr.value=!1,co.value=null,ht.value=null,fo.value=!1,po.value=!0})},ol="bm_currentBike",Pg="v2",kg="https://cdn.bikematrix.io",Gd={isShopify:!1,skuField:"sku",apiUrl:"https://api.bikematrix.io/proxy/v3/",apiKey:"",apiToken:"",currentCollectionHandle:"",categories:[],collections:[],pageType:"index",showHomePageCollection:!1,showSearchPageCollection:!1,designMode:!1,bikeSelectorBrands:"",productsCollections:{},isHomePage:!1,isSearchPage:!1,products:{},collectionUrl:"",compatiblityListCurrentPage:0,showCompatibleList:!0,sku:"",productCollections:[],logLevel:"none",virtualWorkshop:!0},In=function(n){return new URL(n,kg).toString()};function Qd(n){var e,t,r="";if(typeof n=="string"||typeof n=="number")r+=n;else if(typeof n=="object")if(Array.isArray(n)){var i=n.length;for(e=0;e<i;e++)n[e]&&(t=Qd(n[e]))&&(r&&(r+=" "),r+=t)}else for(t in n)n[t]&&(r&&(r+=" "),r+=t);return r}function zg(){for(var n,e,t=0,r="",i=arguments.length;t<i;t++)(n=arguments[t])&&(e=Qd(n))&&(r&&(r+=" "),r+=e);return r}const sl="-";function Cg(n){const e=Ag(n),{conflictingClassGroups:t,conflictingClassGroupModifiers:r}=n;function i(l){const u=l.split(sl);return u[0]===""&&u.length!==1&&u.shift(),qd(u,e)||Hg(l)}function o(l,u){const c=t[l]||[];return u&&r[l]?[...c,...r[l]]:c}return{getClassGroupId:i,getConflictingClassGroupIds:o}}function qd(n,e){var l;if(n.length===0)return e.classGroupId;const t=n[0],r=e.nextPart.get(t),i=r?qd(n.slice(1),r):void 0;if(i)return i;if(e.validators.length===0)return;const o=n.join(sl);return(l=e.validators.find(({validator:u})=>u(o)))==null?void 0:l.classGroupId}const Vd=/^\[(.+)\]$/;function Hg(n){if(Vd.test(n)){const e=Vd.exec(n)[1],t=e==null?void 0:e.substring(0,e.indexOf(":"));if(t)return"arbitrary.."+t}}function Ag(n){const{theme:e,prefix:t}=n,r={nextPart:new Map,validators:[]};return Og(Object.entries(n.classGroups),t).forEach(([o,l])=>{ll(l,r,o,e)}),r}function ll(n,e,t,r){n.forEach(i=>{if(typeof i=="string"){const o=i===""?e:Jd(e,i);o.classGroupId=t;return}if(typeof i=="function"){if(Dg(i)){ll(i(r),e,t,r);return}e.validators.push({validator:i,classGroupId:t});return}Object.entries(i).forEach(([o,l])=>{ll(l,Jd(e,o),t,r)})})}function Jd(n,e){let t=n;return e.split(sl).forEach(r=>{t.nextPart.has(r)||t.nextPart.set(r,{nextPart:new Map,validators:[]}),t=t.nextPart.get(r)}),t}function Dg(n){return n.isThemeGetter}function Og(n,e){return e?n.map(([t,r])=>{const i=r.map(o=>typeof o=="string"?e+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([l,u])=>[e+l,u])):o);return[t,i]}):n}function Xg(n){if(n<1)return{get:()=>{},set:()=>{}};let e=0,t=new Map,r=new Map;function i(o,l){t.set(o,l),e++,e>n&&(e=0,r=t,t=new Map)}return{get(o){let l=t.get(o);if(l!==void 0)return l;if((l=r.get(o))!==void 0)return i(o,l),l},set(o,l){t.has(o)?t.set(o,l):i(o,l)}}}const Ud="!";function Eg(n){const e=n.separator,t=e.length===1,r=e[0],i=e.length;return function(l){const u=[];let c=0,f=0,p;for(let x=0;x<l.length;x++){let H=l[x];if(c===0){if(H===r&&(t||l.slice(x,x+i)===e)){u.push(l.slice(f,x)),f=x+i;continue}if(H==="/"){p=x;continue}}H==="["?c++:H==="]"&&c--}const h=u.length===0?l:l.substring(f),b=h.startsWith(Ud),m=b?h.substring(1):h,k=p&&p>f?p-f:void 0;return{modifiers:u,hasImportantModifier:b,baseClassName:m,maybePostfixModifierPosition:k}}}function Lg(n){if(n.length<=1)return n;const e=[];let t=[];return n.forEach(r=>{r[0]==="["?(e.push(...t.sort(),r),t=[]):t.push(r)}),e.push(...t.sort()),e}function Bg(n){return{cache:Xg(n.cacheSize),splitModifiers:Eg(n),...Cg(n)}}const jg=/\s+/;function Tg(n,e){const{splitModifiers:t,getClassGroupId:r,getConflictingClassGroupIds:i}=e,o=new Set;return n.trim().split(jg).map(l=>{const{modifiers:u,hasImportantModifier:c,baseClassName:f,maybePostfixModifierPosition:p}=t(l);let h=r(p?f.substring(0,p):f),b=!!p;if(!h){if(!p)return{isTailwindClass:!1,originalClassName:l};if(h=r(f),!h)return{isTailwindClass:!1,originalClassName:l};b=!1}const m=Lg(u).join(":");return{isTailwindClass:!0,modifierId:c?m+Ud:m,classGroupId:h,originalClassName:l,hasPostfixModifier:b}}).reverse().filter(l=>{if(!l.isTailwindClass)return!0;const{modifierId:u,classGroupId:c,hasPostfixModifier:f}=l,p=u+c;return o.has(p)?!1:(o.add(p),i(c,f).forEach(h=>o.add(u+h)),!0)}).reverse().map(l=>l.originalClassName).join(" ")}function Ig(){let n=0,e,t,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=Kd(e))&&(r&&(r+=" "),r+=t);return r}function Kd(n){if(typeof n=="string")return n;let e,t="";for(let r=0;r<n.length;r++)n[r]&&(e=Kd(n[r]))&&(t&&(t+=" "),t+=e);return t}function Sg(n,...e){let t,r,i,o=l;function l(c){const f=e.reduce((p,h)=>h(p),n());return t=Bg(f),r=t.cache.get,i=t.cache.set,o=u,u(c)}function u(c){const f=r(c);if(f)return f;const p=Tg(c,t);return i(c,p),p}return function(){return o(Ig.apply(null,arguments))}}function Ye(n){const e=t=>t[n]||[];return e.isThemeGetter=!0,e}const _d=/^\[(?:([a-z-]+):)?(.+)\]$/i,Mg=/^\d+\/\d+$/,Wg=new Set(["px","full","screen"]),Zg=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Yg=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Fg=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Ng=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Rg=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;function Zr(n){return Sn(n)||Wg.has(n)||Mg.test(n)}function fn(n){return vi(n,"length",_g)}function Sn(n){return!!n&&!Number.isNaN(Number(n))}function ho(n){return vi(n,"number",Sn)}function ia(n){return!!n&&Number.isInteger(Number(n))}function Gg(n){return n.endsWith("%")&&Sn(n.slice(0,-1))}function me(n){return _d.test(n)}function pn(n){return Zg.test(n)}const Qg=new Set(["length","size","percentage"]);function qg(n){return vi(n,Qg,$d)}function Vg(n){return vi(n,"position",$d)}const Jg=new Set(["image","url"]);function Ug(n){return vi(n,Jg,e3)}function Kg(n){return vi(n,"",$g)}function aa(){return!0}function vi(n,e,t){const r=_d.exec(n);return r?r[1]?typeof e=="string"?r[1]===e:e.has(r[1]):t(r[2]):!1}function _g(n){return Yg.test(n)&&!Fg.test(n)}function $d(){return!1}function $g(n){return Ng.test(n)}function e3(n){return Rg.test(n)}function t3(){const n=Ye("colors"),e=Ye("spacing"),t=Ye("blur"),r=Ye("brightness"),i=Ye("borderColor"),o=Ye("borderRadius"),l=Ye("borderSpacing"),u=Ye("borderWidth"),c=Ye("contrast"),f=Ye("grayscale"),p=Ye("hueRotate"),h=Ye("invert"),b=Ye("gap"),m=Ye("gradientColorStops"),k=Ye("gradientColorStopPositions"),x=Ye("inset"),H=Ye("margin"),C=Ye("opacity"),w=Ye("padding"),P=Ye("saturate"),D=Ye("scale"),O=Ye("sepia"),j=Ye("skew"),L=Ye("space"),T=Ye("translate"),X=()=>["auto","contain","none"],M=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",me,e],N=()=>[me,e],q=()=>["",Zr,fn],J=()=>["auto",Sn,me],ee=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],K=()=>["solid","dashed","dotted","double","none"],ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"],Q=()=>["start","end","center","between","around","evenly","stretch"],Y=()=>["","0",me],_=()=>["auto","avoid","all","avoid-page","page","left","right","column"],le=()=>[Sn,ho],ve=()=>[Sn,me];return{cacheSize:500,separator:":",theme:{colors:[aa],spacing:[Zr,fn],blur:["none","",pn,me],brightness:le(),borderColor:[n],borderRadius:["none","","full",pn,me],borderSpacing:N(),borderWidth:q(),contrast:le(),grayscale:Y(),hueRotate:ve(),invert:Y(),gap:N(),gradientColorStops:[n],gradientColorStopPositions:[Gg,fn],inset:W(),margin:W(),opacity:le(),padding:N(),saturate:le(),scale:le(),sepia:Y(),skew:ve(),space:N(),translate:N()},classGroups:{aspect:[{aspect:["auto","square","video",me]}],container:["container"],columns:[{columns:[pn]}],"break-after":[{"break-after":_()}],"break-before":[{"break-before":_()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ee(),me]}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:X()}],"overscroll-x":[{"overscroll-x":X()}],"overscroll-y":[{"overscroll-y":X()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[x]}],"inset-x":[{"inset-x":[x]}],"inset-y":[{"inset-y":[x]}],start:[{start:[x]}],end:[{end:[x]}],top:[{top:[x]}],right:[{right:[x]}],bottom:[{bottom:[x]}],left:[{left:[x]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ia,me]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",me]}],grow:[{grow:Y()}],shrink:[{shrink:Y()}],order:[{order:["first","last","none",ia,me]}],"grid-cols":[{"grid-cols":[aa]}],"col-start-end":[{col:["auto",{span:["full",ia,me]},me]}],"col-start":[{"col-start":J()}],"col-end":[{"col-end":J()}],"grid-rows":[{"grid-rows":[aa]}],"row-start-end":[{row:["auto",{span:[ia,me]},me]}],"row-start":[{"row-start":J()}],"row-end":[{"row-end":J()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",me]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",me]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...Q()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Q(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Q(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[w]}],px:[{px:[w]}],py:[{py:[w]}],ps:[{ps:[w]}],pe:[{pe:[w]}],pt:[{pt:[w]}],pr:[{pr:[w]}],pb:[{pb:[w]}],pl:[{pl:[w]}],m:[{m:[H]}],mx:[{mx:[H]}],my:[{my:[H]}],ms:[{ms:[H]}],me:[{me:[H]}],mt:[{mt:[H]}],mr:[{mr:[H]}],mb:[{mb:[H]}],ml:[{ml:[H]}],"space-x":[{"space-x":[L]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[L]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",me,e]}],"min-w":[{"min-w":[me,e,"min","max","fit"]}],"max-w":[{"max-w":[me,e,"none","full","min","max","fit","prose",{screen:[pn]},pn]}],h:[{h:[me,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[me,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[me,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[me,e,"auto","min","max","fit"]}],"font-size":[{text:["base",pn,fn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ho]}],"font-family":[{font:[aa]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",me]}],"line-clamp":[{"line-clamp":["none",Sn,ho]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Zr,me]}],"list-image":[{"list-image":["none",me]}],"list-style-type":[{list:["none","disc","decimal",me]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[n]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[n]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...K(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Zr,fn]}],"underline-offset":[{"underline-offset":["auto",Zr,me]}],"text-decoration-color":[{decoration:[n]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:N()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",me]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",me]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[C]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ee(),Vg]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",qg]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Ug]}],"bg-color":[{bg:[n]}],"gradient-from-pos":[{from:[k]}],"gradient-via-pos":[{via:[k]}],"gradient-to-pos":[{to:[k]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[u]}],"border-w-x":[{"border-x":[u]}],"border-w-y":[{"border-y":[u]}],"border-w-s":[{"border-s":[u]}],"border-w-e":[{"border-e":[u]}],"border-w-t":[{"border-t":[u]}],"border-w-r":[{"border-r":[u]}],"border-w-b":[{"border-b":[u]}],"border-w-l":[{"border-l":[u]}],"border-opacity":[{"border-opacity":[C]}],"border-style":[{border:[...K(),"hidden"]}],"divide-x":[{"divide-x":[u]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[u]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[C]}],"divide-style":[{divide:K()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...K()]}],"outline-offset":[{"outline-offset":[Zr,me]}],"outline-w":[{outline:[Zr,fn]}],"outline-color":[{outline:[n]}],"ring-w":[{ring:q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[n]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[Zr,fn]}],"ring-offset-color":[{"ring-offset":[n]}],shadow:[{shadow:["","inner","none",pn,Kg]}],"shadow-color":[{shadow:[aa]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":ne()}],"bg-blend":[{"bg-blend":ne()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",pn,me]}],grayscale:[{grayscale:[f]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[h]}],saturate:[{saturate:[P]}],sepia:[{sepia:[O]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[f]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[h]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[P]}],"backdrop-sepia":[{"backdrop-sepia":[O]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",me]}],duration:[{duration:ve()}],ease:[{ease:["linear","in","out","in-out",me]}],delay:[{delay:ve()}],animate:[{animate:["none","spin","ping","pulse","bounce",me]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[D]}],"scale-x":[{"scale-x":[D]}],"scale-y":[{"scale-y":[D]}],rotate:[{rotate:[ia,me]}],"translate-x":[{"translate-x":[T]}],"translate-y":[{"translate-y":[T]}],"skew-x":[{"skew-x":[j]}],"skew-y":[{"skew-y":[j]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",me]}],accent:[{accent:["auto",n]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",me]}],"caret-color":[{caret:[n]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":N()}],"scroll-mx":[{"scroll-mx":N()}],"scroll-my":[{"scroll-my":N()}],"scroll-ms":[{"scroll-ms":N()}],"scroll-me":[{"scroll-me":N()}],"scroll-mt":[{"scroll-mt":N()}],"scroll-mr":[{"scroll-mr":N()}],"scroll-mb":[{"scroll-mb":N()}],"scroll-ml":[{"scroll-ml":N()}],"scroll-p":[{"scroll-p":N()}],"scroll-px":[{"scroll-px":N()}],"scroll-py":[{"scroll-py":N()}],"scroll-ps":[{"scroll-ps":N()}],"scroll-pe":[{"scroll-pe":N()}],"scroll-pt":[{"scroll-pt":N()}],"scroll-pr":[{"scroll-pr":N()}],"scroll-pb":[{"scroll-pb":N()}],"scroll-pl":[{"scroll-pl":N()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",me]}],fill:[{fill:[n,"none"]}],"stroke-w":[{stroke:[Zr,fn,ho]}],stroke:[{stroke:[n,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}const r3=Sg(t3);function xe(...n){return r3(zg(n))}const n3={shopify:{bikeBrands:"bike/brands",bikeModels:"bike/models",framesSeries:"bike/frameSeries",bikeSpecs:"bike/bikeSpecBikes",bikeSpecYears:"bike/bikeSpecYears",bikeSpecSizes:"bike/bikeSpecSizes",bikeBrandProductCategories:"bike/bikeBrandProductCategories",checkSku:"compatibility/checkSku",checkSkus:"compatibility/checkSkus",checkSkusWithResults:"compatibility/checkSkusWithResults",bikeBom:"workshop/bikeBom",customBike:"workshop/addCustomBike",addComponent:"workshop/addComponent",findProducts:"workshop/findProducts",removeComponent:"workshop/removeComponent",revertComponent:"workshop/revertComponent",saveCustomBike:"workshop/saveCustomBike",updateCustomBike:"workshop/updateCustomBike",updateCustomBikeName:"workshop/updateCustomBikeName"},bikematrix:{bikeBrands:"GetBikeBrands",bikeModels:"GetBikeModels",framesSeries:"GetBikeFrameSeries",bikeSpecs:"GetBikeSpecBikes",bikeSpecYears:"GetBikeSpecYears",bikeSpecSizes:"GetBikeSpecSizes",bikeBrandProductCategories:"GetBikeBrandProductCategories",checkSku:"Compatibility_CheckSku",checkSkus:"Compatibility_CheckSkus",checkSkusWithResults:"Compatibility_CheckSkusWithResults",bikeBom:"GetBikeBillOfMaterials",customBike:"AddCustomBike",addComponent:"AddComponent",findProducts:"FindProducts",removeComponent:"RemoveComponent",revertComponent:"RevertComponent",saveCustomBike:"SaveCustomBike",updateCustomBike:"UpdateCustomBike",updateCustomBikeName:"UpdateCustomBikeName"}};class Ht{constructor(e,t,r,i){this._apiUrl=i?window.location.origin+"/apps/proxy/api/":e,this._apiKey=t??"",this._apiToken=r??"",this._apiType=i?"shopify":"bikematrix"}getEndpoint(e){return n3[this._apiType][e]}async getBikeBrands(){const e=this.getEndpoint("bikeBrands"),t=await this.makeRequest(e);return t.success?t.data:(console.error(t.error),[])}async getBikeModels(e){if(!e)return console.log("No bike brand selected."),[];const t=this.getEndpoint("bikeModels"),r=await this.makeRequest(t,{params:{bikeBrandId:e}});return r.success?r.data:(console.error(r.error),[])}async getBikeFrameSeries(e){if(!e)return console.log("No bike model selected."),[];const t=this.getEndpoint("framesSeries"),r=await this.makeRequest(t,{params:{bikeModelId:e}});return r.success?r.data:(console.error(r.error),[])}async getBikeSpecs(e){if(!e)return console.log("No bike frame series selected."),[];const t=this.getEndpoint("bikeSpecs"),r=await this.makeRequest(t,{params:{bikeModelSpecId:e}});return r.success?r.data:(console.error(r.error),[])}async getYears(e){if(!e)return console.log("No bike frame series selected."),[];const t=this.getEndpoint("bikeSpecYears"),r=await this.makeRequest(t,{params:{bikeModelSpecId:e}});return r.success?r.data:(console.error(r.error),[])}async getFrameSizes(e,t,r){if(!e||!t)return console.log("No bike frame series or bike spec selected."),[];const i=this.getEndpoint("bikeSpecSizes"),o=await this.makeRequest(i,{params:{bikeModelSpecId:e,bikeSpec:t,year:r}});return o.success?o.data:(console.error(o.error),[])}async getBikes(e,t,r){if(e&&(t||r)){const i=this.getEndpoint("bikeSpecs"),o=await this.makeRequest(i,{params:{bikeModelSpecId:e,bikeSpec:t,year:r}});return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike frame series and bike spec or year selected."),[]}async getBrandProductCategories(e){if(e){const t=this.getEndpoint("bikeBrandProductCategories"),r=await this.makeRequest(t,{params:{bikeBrandId:e}});return r.success?{data:r.data,success:!0}:(console.error(r.error),{data:[],success:!1,error:r.error})}else return console.log("No brand selected."),{success:!1,error:"No brand selected"}}async checkSkuCompatibility(e,t,r){if(e&&t){const i=this.getEndpoint("checkSku")+`/${e}/${t}/${r}`,o=await this.makeRequest(i);return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike key and sku passed."),[]}async checkSkusCompatibility(e,t,r){if(e&&t){const i=this.getEndpoint("checkSkus")+`/${e}/${t}/${r}`,o=await this.makeRequest(i);return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike key and list of skus passed."),[]}async checkSkusCompatibilityWithResults(e,t,r,i={}){if(e&&t){const o=this.getEndpoint("checkSkusWithResults")+`/${e}/${r}`,l=await this.makeRequest(o,{body:JSON.stringify(t),method:"POST",headers:{"Content-Type":"application/json"},...i});return l.success?{data:l.data,success:l.success}:{success:l.success,error:"error_compatiblelist"}}else return console.log("No bike key and list of skus passed."),[]}async getActiveSubscription(e){if(this._apiType==="shopify"){e({activeSubscription:!0});return}var t="activeSubscription";const r=await this.makeRequest(t);if(!r.success){console.log(`getActiveSubscription Error: ${r.error}`);return}e(r.data)}async getBikeBom(e){if(!e)return{success:!1,error:"error_generic getBikeBom"};const t=this.getEndpoint("bikeBom"),r=await this.makeRequest(t,{params:{bikeKey:e}});return r.success?{data:r.data,success:r.success}:(console.error(r.error),{success:r.success,error:"error_get_bike_bom"})}async addCustomBike(e){if(!e)return{success:!1,error:"error_generic addCustomBike"};const t=this.getEndpoint("customBike"),r=await this.makeRequest(t,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e}});return r.success?{data:r.data,success:r.success}:(console.error(r.error),{success:r.success,error:"error_add_custom_bike"})}async findProducts(e,t){if(!e)return{success:!1,error:"error_generic findProducts"};const r=this.getEndpoint("findProducts"),i=await this.makeRequest(r,{params:{search:e,productCategoryId:t,recordCount:20}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_find_products"})}async addComponent(e,t,r,i){if(!e||!t||!r||!i)return{success:!1,error:"error_generic addComponent"};const o=this.getEndpoint("addComponent"),l=await this.makeRequest(o,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,productId:r,bikeFieldName:i}});return l.success?{data:l.data,success:l.success}:(console.error(l.error),{success:l.success,error:"error_add_component"})}async removeComponent(e,t,r){if(!e||!t||!r)return{success:!1,error:"error_generic removeComponent"};const i=this.getEndpoint("removeComponent"),o=await this.makeRequest(i,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,bikeFieldName:r}});return o.success?{data:o.data,success:o.success}:(console.error(o.error),{success:o.success,error:"error_remove_component"})}async revertComponent(e,t,r){if(!e||!t||!r)return{success:!1,error:"error_generic revertComponent"};const i=this.getEndpoint("revertComponent"),o=await this.makeRequest(i,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,bikeFieldName:r}});return o.success?{data:o.data,success:o.success}:(console.error(o.error),{success:o.success,error:"error_revert_component"})}async saveCustomBike(e,t){if(!e||!t)return{success:!1,error:"error_generic saveCustomBike"};const r=this.getEndpoint("saveCustomBike"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,email:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_save_custom_bike"})}async updateCustomBike(e,t){if(!e||!t)return{success:!1,error:"error_generic saveCustomBike"};const r=this.getEndpoint("updateCustomBike"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_update_custom_bike"})}async updateCustomBikeName(e,t){if(!e||!t)return{success:!1,error:"error_generic updateCustomBikeName"};const r=this.getEndpoint("updateCustomBikeName"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,name:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_update_custom_bike_name"})}async makeRequest(e,t={}){const r=new URL(e,this._apiUrl),i={"Cache-Control":"no-cache",...this._apiKey&&{"bm-subscription-key":this._apiKey},...this._apiToken&&{"bm-app-token":this._apiToken}};typeof t.params=="object"&&(Object.keys(t.params).forEach(l=>{t.params[l]&&r.searchParams.set(l,t.params[l])}),delete t.params);let o;try{const l={...i,...t.headers||{}},u={...t,headers:l};t.signal&&(u.signal=t.signal);const c=await fetch(r,u);o={success:!0,data:await c.json().catch(()=>{throw new Error("Request failed: "+(c.statusText||"Status"+c.status))})}}catch(l){o={success:!1,error:l.message}}return o}}async function ef(n){var b;const{categories:e,collections:t,apiUrl:r,apiKey:i,apiToken:o,isShopify:l,logLevel:u}=window.BikeMatrix.getConfig(),c=JSON.parse(sessionStorage.getItem("bm_categories")||"null"),f=JSON.parse(localStorage.getItem(ol)||"null"),p=new Ht(r,i,o,l);let h=[];if(u==="verbose"&&console.log("useCompatibleCollections sessionCollections",c),!c||!(c!=null&&c.collections)||!(c!=null&&c.collections.length)||(c==null?void 0:c.key)!==(f==null?void 0:f.key)){u==="verbose"&&console.log("useCompatibleCollections fetching new collections");const m=await p.getBrandProductCategories(n);u==="verbose"&&console.log("useCompatibleCollections bikeBrandProductCategories",m),((b=m.data)==null?void 0:b.length)>0&&(h=e.filter(x=>{var H;return!!x.collection&&((H=m==null?void 0:m.data)==null?void 0:H.some(C=>C.product_Category.toLowerCase()===x.title.toLowerCase()))}).map(x=>t.filter(C=>x.collection.split(",").map(w=>w.trim().toLowerCase()).includes(C.title.toLowerCase())).map(C=>({title:C.title,text_id:x.text_id,handle:C.handle,url:C.url}))).flat(),h=h==null?void 0:h.filter((x,H,C)=>H===C.findIndex(w=>w.title===x.title&&w.text_id===x.text_id&&w.handle===x.handle&&w.url===x.url))),sessionStorage.setItem("bm_categories",JSON.stringify({key:f==null?void 0:f.key,collections:h})),u==="verbose"&&console.log("useCompatibleCollections fetched collections",h)}else u==="verbose"&&console.log("useCompatibleCollections using session collections"),h=c.collections;return h}const tf=class $a{constructor(){this.initialized=!1,this.currentBike=null,this.activeSubscription=null,this.components=[],this.config=Gd}async initialize(e){this.components=[],this.initialized&&this.cleanup(),e&&(this.config={...this.config,...e}),this.initializeConfig(),this.service=new Ht(this.config.apiUrl,this.config.apiKey,this.config.apiToken,this.config.isShopify),this.initializeActiveSubscription(),localStorage.bm_currentBike&&(this.currentBike=JSON.parse(localStorage.bm_currentBike)),this.setupEventListeners(),this.registerComponents(),this.initialized=!0,al.value=!0;const t=new Event("BM:Initialized");document.dispatchEvent(t),this.config.logLevel==="verbose"&&(console.log("BikeMatrix WebComponent Version: 1.1.40"),console.log("BikeMatrixCore initialized"))}static getInstance(){return $a.instance||($a.instance=new $a),$a.instance}registerComponents(){const e=["bikematrix-bikeselector","bikematrix-productresult","bikematrix-collectionresult","bikematrix-compatibilitylabel","bikematrix-compatiblelist","bikematrix-bikeselectorbanner","bikematrix-variantselector"];this.components=[],e.forEach(t=>{const r=document.getElementsByTagName(t);Array.from(r).forEach(i=>{this.components.push(i)})}),this.config.logLevel==="verbose"&&console.log(`Registered ${this.components.length} components`)}resetComponents(){this.components.forEach(e=>{var t;try{const r=e.cloneNode(!1);e.querySelectorAll("template").forEach(o=>{r.appendChild(o.cloneNode(!0))}),(t=e.parentNode)==null||t.replaceChild(r,e)}catch{console.error("Error resetting component",e)}})}isInitialized(){return this.initialized}updateConfig(e){this.config={...this.config,...e},this.reload(!1)}cleanup(){this.removeEventListeners(),xg()}async destroy(){this.cleanup(),this.service=null,this.currentBike=null,this.activeSubscription=null,this.config={...Gd},this.initialized=!1,al.value=!1,this.resetComponents()}refresh(){this.ChangeBike()}reset(){this.destroy(),this.initialize()}reload(e=!0){e&&this.initializeConfig(),this.refresh(),this.registerComponents(),this.resetComponents()}initializeConfig(){const e=document.querySelectorAll('script[type="application/json"][data-bikematrix-config]'),t=JSON.parse(sessionStorage.getItem("bm_diagnostics"));e.forEach(r=>{if(r!=null&&r.textContent)try{this.config={...this.config,...JSON.parse(r.textContent)}}catch{console.error("Invalid BikeMatrix configuration"),console.log("configScript ",r.textContent)}}),t!=null&&t.includes("verbose")&&(this.config.logLevel="verbose"),t!=null&&t.includes("virtualWorkshop")&&(this.config.virtualWorkshop=!0),t!=null&&t.includes("subscribtion")&&(this.activeSubscription=!0),t!=null&&t.includes("all")&&(this.config.logLevel="verbose",this.config.virtualWorkshop=!0,this.activeSubscription=!0),this.config.logLevel==="verbose"&&console.log("initializeConfig ",JSON.stringify(this.config,null,2))}initializeActiveSubscription(){const e=sessionStorage.getItem("bm_activeSubscription");if(!this.config.isShopify){this.activeSubscription=!0;return}this.activeSubscription=this.config.designMode||e==="true",e||this.service.getActiveSubscription(this.updateActiveSubscription.bind(this))}setupEventListeners(){document.addEventListener("BikeMatrix:RefreshCompatibleSkus",e=>{this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}),document.addEventListener("on:facet-filters:updated",this.handleRefreshCompatibleSkus.bind(this)),document.addEventListener("BikeChanged",this.handleBikeChanged.bind(this))}removeEventListeners(){document.removeEventListener("BikeMatrix:RefreshCompatibleSkus",this.handleRefreshCompatibleSkus),document.removeEventListener("on:facet-filters:updated",this.handleRefreshCompatibleSkus),document.removeEventListener("BikeChanged",this.handleBikeChanged)}async handleRefreshCompatibleSkus(e){this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}async handleBikeChanged(e){this.config.logLevel==="verbose"&&console.log("Listener BikeChanged..."),this.ChangeBike()}getConfig(){return this.config}getActiveSubscription(){return this.activeSubscription}getCurrentBike(){return this.currentBike}updateSku(e){const t=document.querySelector("bikematrix-productresult[data-sku]"),r=document.querySelector("bikematrix-variantselector[data-sku]");t&&t.setAttribute("data-sku",e),r&&r.setAttribute("data-sku",e),this.config.sku=e}ResetSelectedBikeIndicator(){var e,t;this.currentBike===null?(e=window.bm_selectBikeButton)==null||e.classList.remove("show-selected"):(t=window.bm_selectBikeButton)==null||t.classList.add("show-selected")}ChangeBike(){this.config.logLevel==="verbose"&&console.log("ChangeBike() Method Called"),!(Zt.value===!0||rr.value===!0)&&(Zt.value=!0,rr.value=!0,pi.value=[],hi.value=[],this.config.logLevel==="verbose"&&console.log("ChangeBike updateBikeSignal..."),this.updateBikeSignal().then(()=>{this.config.logLevel==="verbose"&&console.log("Bike Signal Updated: ",JSON.stringify(Ae.value,null,2)),this.ResetSelectedBikeIndicator(),this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}))}async RefreshCompatibleSkus(){var t,r;const e=`${(t=Ae.value)==null?void 0:t.key}:${this.config.currentCollectionHandle}:${Pg}`;switch(this.config.pageType){case"collection":const i=!!Ae.value&&((r=Ae.value.compatibleCollections)==null?void 0:r.find(o=>o.handle===this.config.currentCollectionHandle));this.config.logLevel==="verbose"&&console.log("Refresh Compatible SKUs. hasCompatibleCollection: ",i),i?(await this.RefreshCollectionPageSkus(e),await this.RefreshCollectionListSkus(e)):(Zt.value=!1,rr.value=!1);break;case"search":case"index":Zt.value=!1,this.config.pageType==="index"&&this.config.showHomePageCollection||this.config.pageType==="search"&&this.config.showSearchPageCollection?await this.RefreshCollectionPageSkus(e):rr.value=!1;break;default:Zt.value=!1,rr.value=!1;break}}async RefreshCollectionPageSkus(e){var l,u,c;let t=document.getElementsByTagName("bikematrix-collectionresult"),i=Array.from(t).map(f=>{const p=this.config.skuField==="barcode"?f.getAttribute("data-product-barcodes"):this.config.skuField==="metafield"?f.getAttribute("data-product-metafields"):f.getAttribute("data-product-skus")||"";return p==null?void 0:p.split(",").filter(h=>!!h)}).flat();this.config.logLevel==="verbose"&&console.log("Refresh Collection Page SKUs. SKUs: ",JSON.stringify(i),null,2);var o=((l=ci())==null?void 0:l.language)||"en-GB";if(i){const f=await this.service.checkSkusCompatibilityWithResults((u=Ae.value)==null?void 0:u.key,i,o);(c=f.data)!=null&&c.error?(fo.value=!0,this.config.logLevel==="verbose"&&console.log("Compatible List Error: ",f.data.errors)):hi.value=f.data}else hi.value=[];rr.value=!1}async RefreshCollectionListSkus(e){var i,o,l;var t=JSON.parse(sessionStorage.getItem(e));if(t)this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from Session: ",JSON.stringify(t),null,2),pi.value=t;else{const u=Object.values(this.config.products||{}).map(h=>h.skus).flat();this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from API. SKUs: ",JSON.stringify(u),null,2);var r=((i=ci())==null?void 0:i.language)||"en-GB";const c=new AbortController,f=c.signal,p=()=>c.abort();window.addEventListener("beforeunload",p);try{if(!((o=Ae.value)!=null&&o.key))throw new Error("BikeSignal key is undefined");const h=await this.service.checkSkusCompatibilityWithResults(Ae.value.key,u,r,{signal:f});if(this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from API. SKUs: ",JSON.stringify(h)),f.aborted){this.config.logLevel==="verbose"&&console.log("function RefreshCompatibleSkus() operation aborted");return}(l=h.data)!=null&&l.errors?(fo.value=!0,this.config.logLevel==="verbose"&&console.log("Compatible List Error: ",h.data.errors)):(sessionStorage.setItem(e,JSON.stringify(h.data)),pi.value=h.data)}catch(h){h.name==="AbortError"?console.log("function RefreshCompatibleSkus() fetch aborted"):console.error("function RefreshCompatibleSkus() fetch error",h)}finally{window.removeEventListener("beforeunload",p)}}Zt.value=!1}updateActiveSubscription(e){const t=!!(e!=null&&e.activeSubscription);sessionStorage.setItem("bm_activeSubscription",JSON.stringify(t)),this.activeSubscription=t}async updateBikeSignal(){const e=localStorage.getItem(ol)||"null",t=JSON.parse(e);if(this.currentBike=t,t==null){Ae.value=null;return}const r=await ef(t==null?void 0:t.brandId);t.compatibleCollections=r,Ae.value=t,this.config.logLevel==="verbose"&&console.log("Bike Changed: ",JSON.stringify(Ae.value,null,2))}};tf.instance=null;let i3=tf;const oa=n=>te("svg",{width:10,height:10,viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M1.53553 8.60658L5.07107 5.07104M5.07107 5.07104L8.6066 1.53551M5.07107 5.07104L8.6066 8.60658M5.07107 5.07104L1.53553 1.53551",stroke:"currentColor",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}));var a3=0;function g(n,e,t,r,i,o){var l,u,c={};for(u in e)u=="ref"?l=e[u]:c[u]=e[u];var f={type:n,props:c,key:t,ref:l,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--a3,__i:-1,__u:0,__source:i,__self:o};if(typeof n=="function"&&(l=n.defaultProps))for(u in l)c[u]===void 0&&(c[u]=l[u]);return fe.vnode&&fe.vnode(f),f}function gi(){document.dispatchEvent(new Event("BmToggleModal"))}function o3({children:n}){return se(()=>{var o;const e=document.body,t=document.getElementById("bm_selectBikeButton"),r=(o=document.getElementsByTagName("bikematrix-bikeselector"))==null?void 0:o[0],i=l=>{l.preventDefault(),e.classList.toggle("bm-modal-active"),r.classList.toggle("active")};return document.addEventListener("BmToggleModal",i),t==null||t.addEventListener("click",i),()=>{document.removeEventListener("BmToggleModal",i),t==null||t.removeEventListener("click",i)}},[]),g(ie,{children:[g("div",{onClick:()=>{gi()},class:xe("overlay","fixed cursor-pointer inset-0 z-[2147483645] bg-black/40 transition-all duration-500 sm:duration-200")}),g("div",{className:xe("modal","fixed pointer-events-none inset-0 mx-auto justify-end z-[2147483646] flex flex-col items-center outline-none transition-all duration-500 sm:duration-200 ease-in-out","sm:justify-center"),children:g("div",{className:"flex sm:px-2 pointer-events-auto max-sm:max-h-[96%] sm:max-h-[90%] max-sm:h-[89vh] max-w-lg sm:max-w-[640px] flex-col items-center max-sm:flex-1 w-full bg-white rounded-t-3xl sm:rounded-xl shadow-[0px_-2px_10px_0px_rgba(0,0,0,0.04),0px_0px_0px_1px_rgba(0,0,0,0.06)]",children:[g("div",{className:"sm:hidden mx-auto mt-4 h-[6px] w-[100px] rounded-full bg-gray-400/50",onClick:gi}),g("div",{className:"sm:hidden h-[10px]"}),g("div",{className:"relative flex flex-col w-full sm:h-full max-sm:flex-none max-sm:grow",children:g("div",{class:"modal-content max-sm:absolute sm:h-full max-sm:inset-0 overflow-x-hidden overflow-y-auto px-8 sm:px-6",children:n})})]})})]})}const vr=n=>te("svg",{width:7,height:12,viewBox:"0 0 7 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M1 11L6 6L1 1",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})),s3=n=>te("svg",{width:31,height:31,viewBox:"0 0 31 31",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("circle",{cx:15.5,cy:15.5,r:15.5,fill:"#030712"}),te("path",{d:"M10.1974 17.1317L13.9955 20.4461L20.8639 10.8909",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})),l3=n=>te("svg",{width:31,height:31,viewBox:"0 0 31 31",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("g",{clipPath:"url(#clip0_64_2)"},te("path",{d:"M30.5 15.5C30.5 23.7843 23.7843 30.5 15.5 30.5C7.21573 30.5 0.5 23.7843 0.5 15.5C0.5 7.21573 7.21573 0.5 15.5 0.5C23.7843 0.5 30.5 7.21573 30.5 15.5Z",fill:"white",stroke:"#D1D5DB"})),te("path",{d:"M23.983 11.132C23.9699 10.9806 23.8699 10.8506 23.727 10.7988C23.5837 10.7466 23.4233 10.7822 23.3155 10.8894L21.1098 13.0866L18.6647 12.3153L17.8905 9.87937L20.0961 7.68201C20.2041 7.57458 20.2393 7.41475 20.1873 7.27224C20.1348 7.12945 20.0046 7.02999 19.8524 7.01688C18.5129 6.9019 17.2004 7.37836 16.2514 8.32387C14.9518 9.61873 14.6076 11.5096 15.217 13.1213C15.1504 13.1773 15.0847 13.2365 15.0199 13.3004L7.65736 20.2216C7.65476 20.2241 7.6522 20.2268 7.64939 20.2293C6.78354 21.092 6.78354 22.4955 7.64939 23.3583C8.51539 24.2209 9.91396 24.2104 10.7797 23.3477C10.7834 23.3443 10.7868 23.3408 10.7902 23.3369L17.677 15.945C17.7398 15.8822 17.798 15.8165 17.853 15.749C19.4713 16.3573 21.3705 16.0152 22.6713 14.7195C23.62 13.7739 24.0986 12.4663 23.983 11.132ZM9.67019 22.4264C9.35113 22.7442 8.83439 22.744 8.51536 22.4264C8.19644 22.1089 8.19644 21.5937 8.51536 21.2761C8.83439 20.9585 9.35113 20.9585 9.67019 21.2761C9.98911 21.5937 9.98911 22.1089 9.67019 22.4264Z",fill:"black"}),te("defs",null,te("clipPath",{id:"clip0_64_2"},te("rect",{width:31,height:31,fill:"white"})))),u3=n=>te("svg",{width:31,height:31,viewBox:"0 0 46 46",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M2 24.0437V22.6518C4.30404 21.9559 5.82929 20.347 6.17596 18.244C6.45967 16.523 5.87584 14.7802 4.66788 13.505L5.50401 12.1672C6.3441 12.2632 7.12499 12.2938 7.83019 12.2273C8.91308 12.1253 10.0603 11.7686 10.8965 10.814C11.7162 9.87828 11.9364 8.70751 11.9455 7.65019C11.9509 7.01984 11.882 6.33439 11.7615 5.60532L13.1089 4.93163C14.6862 6.27858 16.5967 7.00972 18.5085 6.50659C20.496 5.98355 21.7104 4.35171 22.2287 2.32023L23.4959 2.17943C23.7105 2.84427 23.9686 3.45839 24.2803 4.0055C24.8609 5.02453 25.7009 5.93317 26.8959 6.37534C28.1054 6.8229 29.35 6.6716 30.4872 6.21488C31.2478 5.9094 32.0092 5.4502 32.771 4.87155L33.84 5.40607C33.3102 7.17682 33.6407 8.97473 34.9205 10.3525C36.2854 11.8219 38.3837 12.4206 40.6053 12.1884L41.4091 13.3137C40.1484 14.904 39.5422 16.7943 40.0082 18.6621C40.4975 20.623 42.0098 21.9631 44 22.6091V23.6937C42.0295 24.646 40.407 25.9295 39.9934 27.9032C39.7449 29.089 40.0083 30.2272 40.4663 31.2395C40.7549 31.8775 41.1444 32.5183 41.6038 33.1622L41.0881 34.0648C39.1096 33.5569 37.1545 33.7409 35.7252 35.1442C34.3293 36.5148 34.0136 38.5186 34.2755 40.5318L32.7931 41.4583C31.191 40.0523 29.3504 39.2822 27.3831 40.0414C26.2841 40.4655 25.451 41.2846 24.816 42.1501C24.4114 42.7016 24.0463 43.3278 23.7127 44H22.6585C22.1786 42.2318 21.2165 40.6691 19.4091 40.0247C17.4936 39.3418 15.3888 40.0023 13.3765 41.2022L11.9877 40.5078C12.4255 38.6858 12.158 36.865 10.7918 35.5311C9.4171 34.1889 7.44044 33.8741 5.42929 34.2133L4.6584 32.9799C6.03869 31.6871 6.93069 30.0087 6.40539 28.071C6.07607 26.8563 5.24467 25.9088 4.25062 25.2068C3.60737 24.7526 2.85005 24.3664 2 24.0437Z",stroke:"black",strokeWidth:4}),te("circle",{cx:23,cy:23,r:12,stroke:"black",strokeWidth:4}),te("path",{d:"M23 39.75C32.2508 39.75 39.75 32.2508 39.75 23C39.75 13.7492 32.2508 6.25 23 6.25C13.7492 6.25 6.25 13.7492 6.25 23C6.25 32.2508 13.7492 39.75 23 39.75Z",stroke:"black",strokeWidth:3.5})),c3=`.shared-icon{background-color:#fba157;padding:5px 10px;border-radius:8px;font-size:12px;display:flex;justify-content:center;align-items:center;color:#fff}
|
|
1
|
+
(function(Sr,fe){typeof exports=="object"&&typeof module<"u"?module.exports=fe():typeof define=="function"&&define.amd?define(fe):(Sr=typeof globalThis<"u"?globalThis:Sr||self,Sr.BikeMatrix=fe())})(this,function(){"use strict";var Sr,fe,Gc,Qc,jn,qc,Vc,Is,Jc,_i={},Uc=[],i1=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,eo=Array.isArray;function Mr(n,e){for(var t in e)n[t]=e[t];return n}function Kc(n){var e=n.parentNode;e&&e.removeChild(n)}function te(n,e,t){var r,i,o,l={};for(o in e)o=="key"?r=e[o]:o=="ref"?i=e[o]:l[o]=e[o];if(arguments.length>2&&(l.children=arguments.length>3?Sr.call(arguments,2):t),typeof n=="function"&&n.defaultProps!=null)for(o in n.defaultProps)l[o]===void 0&&(l[o]=n.defaultProps[o]);return $i(n,l,r,i,null)}function $i(n,e,t,r,i){var o={type:n,props:e,key:t,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:i??++Gc,__i:-1,__u:0};return i==null&&fe.vnode!=null&&fe.vnode(o),o}function a1(){return{current:null}}function ie(n){return n.children}function hr(n,e){this.props=n,this.context=e}function oi(n,e){if(e==null)return n.__?oi(n.__,n.__i+1):null;for(var t;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null)return t.__e;return typeof n.type=="function"?oi(n):null}function _c(n){var e,t;if((n=n.__)!=null&&n.__c!=null){for(n.__e=n.__c.base=null,e=0;e<n.__k.length;e++)if((t=n.__k[e])!=null&&t.__e!=null){n.__e=n.__c.base=t.__e;break}return _c(n)}}function Ss(n){(!n.__d&&(n.__d=!0)&&jn.push(n)&&!to.__r++||qc!==fe.debounceRendering)&&((qc=fe.debounceRendering)||Vc)(to)}function to(){var n,e,t,r,i,o,l,u,c;for(jn.sort(Is);n=jn.shift();)n.__d&&(e=jn.length,r=void 0,o=(i=(t=n).__v).__e,u=[],c=[],(l=t.__P)&&((r=Mr({},i)).__v=i.__v+1,fe.vnode&&fe.vnode(r),Ms(l,r,i,t.__n,l.ownerSVGElement!==void 0,32&i.__u?[o]:null,u,o??oi(i),!!(32&i.__u),c),r.__v=i.__v,r.__.__k[r.__i]=r,id(u,r,c),r.__e!=o&&_c(r)),jn.length>e&&jn.sort(Is));to.__r=0}function $c(n,e,t,r,i,o,l,u,c,f,p){var h,b,m,k,x,H=r&&r.__k||Uc,C=e.length;for(t.__d=c,o1(t,e,H),c=t.__d,h=0;h<C;h++)(m=t.__k[h])!=null&&typeof m!="boolean"&&typeof m!="function"&&(b=m.__i===-1?_i:H[m.__i]||_i,m.__i=h,Ms(n,m,b,i,o,l,u,c,f,p),k=m.__e,m.ref&&b.ref!=m.ref&&(b.ref&&Ws(b.ref,null,m),p.push(m.ref,m.__c||k,m)),x==null&&k!=null&&(x=k),65536&m.__u||b.__k===m.__k?c=ed(m,c,n):typeof m.type=="function"&&m.__d!==void 0?c=m.__d:k&&(c=k.nextSibling),m.__d=void 0,m.__u&=-196609);t.__d=c,t.__e=x}function o1(n,e,t){var r,i,o,l,u,c=e.length,f=t.length,p=f,h=0;for(n.__k=[],r=0;r<c;r++)l=r+h,(i=n.__k[r]=(i=e[r])==null||typeof i=="boolean"||typeof i=="function"?null:typeof i=="string"||typeof i=="number"||typeof i=="bigint"||i.constructor==String?$i(null,i,null,null,null):eo(i)?$i(ie,{children:i},null,null,null):i.constructor===void 0&&i.__b>0?$i(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)!=null?(i.__=n,i.__b=n.__b+1,u=s1(i,t,l,p),i.__i=u,o=null,u!==-1&&(p--,(o=t[u])&&(o.__u|=131072)),o==null||o.__v===null?(u==-1&&h--,typeof i.type!="function"&&(i.__u|=65536)):u!==l&&(u===l+1?h++:u>l?p>c-l?h+=u-l:h--:u<l?u==l-1&&(h=u-l):h=0,u!==r+h&&(i.__u|=65536))):(o=t[l])&&o.key==null&&o.__e&&!(131072&o.__u)&&(o.__e==n.__d&&(n.__d=oi(o)),Zs(o,o,!1),t[l]=null,p--);if(p)for(r=0;r<f;r++)(o=t[r])!=null&&!(131072&o.__u)&&(o.__e==n.__d&&(n.__d=oi(o)),Zs(o,o))}function ed(n,e,t){var r,i;if(typeof n.type=="function"){for(r=n.__k,i=0;r&&i<r.length;i++)r[i]&&(r[i].__=n,e=ed(r[i],e,t));return e}n.__e!=e&&(t.insertBefore(n.__e,e||null),e=n.__e);do e=e&&e.nextSibling;while(e!=null&&e.nodeType===8);return e}function Wr(n,e){return e=e||[],n==null||typeof n=="boolean"||(eo(n)?n.some(function(t){Wr(t,e)}):e.push(n)),e}function s1(n,e,t,r){var i=n.key,o=n.type,l=t-1,u=t+1,c=e[t];if(c===null||c&&i==c.key&&o===c.type&&!(131072&c.__u))return t;if(r>(c!=null&&!(131072&c.__u)?1:0))for(;l>=0||u<e.length;){if(l>=0){if((c=e[l])&&!(131072&c.__u)&&i==c.key&&o===c.type)return l;l--}if(u<e.length){if((c=e[u])&&!(131072&c.__u)&&i==c.key&&o===c.type)return u;u++}}return-1}function td(n,e,t){e[0]==="-"?n.setProperty(e,t??""):n[e]=t==null?"":typeof t!="number"||i1.test(e)?t:t+"px"}function ro(n,e,t,r,i){var o;e:if(e==="style")if(typeof t=="string")n.style.cssText=t;else{if(typeof r=="string"&&(n.style.cssText=r=""),r)for(e in r)t&&e in t||td(n.style,e,"");if(t)for(e in t)r&&t[e]===r[e]||td(n.style,e,t[e])}else if(e[0]==="o"&&e[1]==="n")o=e!==(e=e.replace(/(PointerCapture)$|Capture$/i,"$1")),e=e.toLowerCase()in n?e.toLowerCase().slice(2):e.slice(2),n.l||(n.l={}),n.l[e+o]=t,t?r?t.u=r.u:(t.u=Date.now(),n.addEventListener(e,o?nd:rd,o)):n.removeEventListener(e,o?nd:rd,o);else{if(i)e=e.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(e!=="width"&&e!=="height"&&e!=="href"&&e!=="list"&&e!=="form"&&e!=="tabIndex"&&e!=="download"&&e!=="rowSpan"&&e!=="colSpan"&&e!=="role"&&e in n)try{n[e]=t??"";break e}catch{}typeof t=="function"||(t==null||t===!1&&e[4]!=="-"?n.removeAttribute(e):n.setAttribute(e,t))}}function rd(n){if(this.l){var e=this.l[n.type+!1];if(n.t){if(n.t<=e.u)return}else n.t=Date.now();return e(fe.event?fe.event(n):n)}}function nd(n){if(this.l)return this.l[n.type+!0](fe.event?fe.event(n):n)}function Ms(n,e,t,r,i,o,l,u,c,f){var p,h,b,m,k,x,H,C,w,P,D,O,j,L,T,X=e.type;if(e.constructor!==void 0)return null;128&t.__u&&(c=!!(32&t.__u),o=[u=e.__e=t.__e]),(p=fe.__b)&&p(e);e:if(typeof X=="function")try{if(C=e.props,w=(p=X.contextType)&&r[p.__c],P=p?w?w.props.value:p.__:r,t.__c?H=(h=e.__c=t.__c).__=h.__E:("prototype"in X&&X.prototype.render?e.__c=h=new X(C,P):(e.__c=h=new hr(C,P),h.constructor=X,h.render=u1),w&&w.sub(h),h.props=C,h.state||(h.state={}),h.context=P,h.__n=r,b=h.__d=!0,h.__h=[],h._sb=[]),h.__s==null&&(h.__s=h.state),X.getDerivedStateFromProps!=null&&(h.__s==h.state&&(h.__s=Mr({},h.__s)),Mr(h.__s,X.getDerivedStateFromProps(C,h.__s))),m=h.props,k=h.state,h.__v=e,b)X.getDerivedStateFromProps==null&&h.componentWillMount!=null&&h.componentWillMount(),h.componentDidMount!=null&&h.__h.push(h.componentDidMount);else{if(X.getDerivedStateFromProps==null&&C!==m&&h.componentWillReceiveProps!=null&&h.componentWillReceiveProps(C,P),!h.__e&&(h.shouldComponentUpdate!=null&&h.shouldComponentUpdate(C,h.__s,P)===!1||e.__v===t.__v)){for(e.__v!==t.__v&&(h.props=C,h.state=h.__s,h.__d=!1),e.__e=t.__e,e.__k=t.__k,e.__k.forEach(function(M){M&&(M.__=e)}),D=0;D<h._sb.length;D++)h.__h.push(h._sb[D]);h._sb=[],h.__h.length&&l.push(h);break e}h.componentWillUpdate!=null&&h.componentWillUpdate(C,h.__s,P),h.componentDidUpdate!=null&&h.__h.push(function(){h.componentDidUpdate(m,k,x)})}if(h.context=P,h.props=C,h.__P=n,h.__e=!1,O=fe.__r,j=0,"prototype"in X&&X.prototype.render){for(h.state=h.__s,h.__d=!1,O&&O(e),p=h.render(h.props,h.state,h.context),L=0;L<h._sb.length;L++)h.__h.push(h._sb[L]);h._sb=[]}else do h.__d=!1,O&&O(e),p=h.render(h.props,h.state,h.context),h.state=h.__s;while(h.__d&&++j<25);h.state=h.__s,h.getChildContext!=null&&(r=Mr(Mr({},r),h.getChildContext())),b||h.getSnapshotBeforeUpdate==null||(x=h.getSnapshotBeforeUpdate(m,k)),$c(n,eo(T=p!=null&&p.type===ie&&p.key==null?p.props.children:p)?T:[T],e,t,r,i,o,l,u,c,f),h.base=e.__e,e.__u&=-161,h.__h.length&&l.push(h),H&&(h.__E=h.__=null)}catch(M){e.__v=null,c||o!=null?(e.__e=u,e.__u|=c?160:32,o[o.indexOf(u)]=null):(e.__e=t.__e,e.__k=t.__k),fe.__e(M,e,t)}else o==null&&e.__v===t.__v?(e.__k=t.__k,e.__e=t.__e):e.__e=l1(t.__e,e,t,r,i,o,l,c,f);(p=fe.diffed)&&p(e)}function id(n,e,t){e.__d=void 0;for(var r=0;r<t.length;r++)Ws(t[r],t[++r],t[++r]);fe.__c&&fe.__c(e,n),n.some(function(i){try{n=i.__h,i.__h=[],n.some(function(o){o.call(i)})}catch(o){fe.__e(o,i.__v)}})}function l1(n,e,t,r,i,o,l,u,c){var f,p,h,b,m,k,x,H=t.props,C=e.props,w=e.type;if(w==="svg"&&(i=!0),o!=null){for(f=0;f<o.length;f++)if((m=o[f])&&"setAttribute"in m==!!w&&(w?m.localName===w:m.nodeType===3)){n=m,o[f]=null;break}}if(n==null){if(w===null)return document.createTextNode(C);n=i?document.createElementNS("http://www.w3.org/2000/svg",w):document.createElement(w,C.is&&C),o=null,u=!1}if(w===null)H===C||u&&n.data===C||(n.data=C);else{if(o=o&&Sr.call(n.childNodes),H=t.props||_i,!u&&o!=null)for(H={},f=0;f<n.attributes.length;f++)H[(m=n.attributes[f]).name]=m.value;for(f in H)m=H[f],f=="children"||(f=="dangerouslySetInnerHTML"?h=m:f==="key"||f in C||ro(n,f,null,m,i));for(f in C)m=C[f],f=="children"?b=m:f=="dangerouslySetInnerHTML"?p=m:f=="value"?k=m:f=="checked"?x=m:f==="key"||u&&typeof m!="function"||H[f]===m||ro(n,f,m,H[f],i);if(p)u||h&&(p.__html===h.__html||p.__html===n.innerHTML)||(n.innerHTML=p.__html),e.__k=[];else if(h&&(n.innerHTML=""),$c(n,eo(b)?b:[b],e,t,r,i&&w!=="foreignObject",o,l,o?o[0]:t.__k&&oi(t,0),u,c),o!=null)for(f=o.length;f--;)o[f]!=null&&Kc(o[f]);u||(f="value",k!==void 0&&(k!==n[f]||w==="progress"&&!k||w==="option"&&k!==H[f])&&ro(n,f,k,H[f],!1),f="checked",x!==void 0&&x!==n[f]&&ro(n,f,x,H[f],!1))}return n}function Ws(n,e,t){try{typeof n=="function"?n(e):n.current=e}catch(r){fe.__e(r,t)}}function Zs(n,e,t){var r,i;if(fe.unmount&&fe.unmount(n),(r=n.ref)&&(r.current&&r.current!==n.__e||Ws(r,null,e)),(r=n.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(o){fe.__e(o,e)}r.base=r.__P=null,n.__c=void 0}if(r=n.__k)for(i=0;i<r.length;i++)r[i]&&Zs(r[i],e,t||typeof n.type!="function");t||n.__e==null||Kc(n.__e),n.__=n.__e=n.__d=void 0}function u1(n,e,t){return this.constructor(n,t)}function ln(n,e,t){var r,i,o,l;fe.__&&fe.__(n,e),i=(r=typeof t=="function")?null:t&&t.__k||e.__k,o=[],l=[],Ms(e,n=(!r&&t||e).__k=te(ie,null,[n]),i||_i,_i,e.ownerSVGElement!==void 0,!r&&t?[t]:i?null:e.firstChild?Sr.call(e.childNodes):null,o,!r&&t?t:i?i.__e:e.firstChild,r,l),id(o,n,l)}function Ys(n,e){ln(n,e,Ys)}function Fs(n,e,t){var r,i,o,l,u=Mr({},n.props);for(o in n.type&&n.type.defaultProps&&(l=n.type.defaultProps),e)o=="key"?r=e[o]:o=="ref"?i=e[o]:u[o]=e[o]===void 0&&l!==void 0?l[o]:e[o];return arguments.length>2&&(u.children=arguments.length>3?Sr.call(arguments,2):t),$i(n.type,u,r||n.key,i||n.ref,null)}function ea(n,e){var t={__c:e="__cC"+Jc++,__:n,Consumer:function(r,i){return r.children(i)},Provider:function(r){var i,o;return this.getChildContext||(i=[],(o={})[e]=this,this.getChildContext=function(){return o},this.shouldComponentUpdate=function(l){this.props.value!==l.value&&i.some(function(u){u.__e=!0,Ss(u)})},this.sub=function(l){i.push(l);var u=l.componentWillUnmount;l.componentWillUnmount=function(){i.splice(i.indexOf(l),1),u&&u.call(l)}}),r.children}};return t.Provider.__=t.Consumer.contextType=t}Sr=Uc.slice,fe={__e:function(n,e,t,r){for(var i,o,l;e=e.__;)if((i=e.__c)&&!i.__)try{if((o=i.constructor)&&o.getDerivedStateFromError!=null&&(i.setState(o.getDerivedStateFromError(n)),l=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(n,r||{}),l=i.__d),l)return i.__E=i}catch(u){n=u}throw n}},Gc=0,Qc=function(n){return n!=null&&n.constructor==null},hr.prototype.setState=function(n,e){var t;t=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=Mr({},this.state),typeof n=="function"&&(n=n(Mr({},t),this.props)),n&&Mr(t,n),n!=null&&this.__v&&(e&&this._sb.push(e),Ss(this))},hr.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),Ss(this))},hr.prototype.render=ie,jn=[],Vc=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Is=function(n,e){return n.__v.__b-e.__v.__b},to.__r=0,Jc=0;function Ns(){return(Ns=Object.assign?Object.assign.bind():function(n){for(var e=1;e<arguments.length;e++){var t=arguments[e];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=t[r])}return n}).apply(this,arguments)}var c1=["context","children"];function d1(n){this.getChildContext=function(){return n.context};var e=n.children,t=function(r,i){if(r==null)return{};var o,l,u={},c=Object.keys(r);for(l=0;l<c.length;l++)i.indexOf(o=c[l])>=0||(u[o]=r[o]);return u}(n,c1);return Fs(e,t)}function f1(){var n=new CustomEvent("_preact",{detail:{},bubbles:!0,cancelable:!0});this.dispatchEvent(n),this._vdom=te(d1,Ns({},this._props,{context:n.detail.context}),function e(t,r){if(t.nodeType===3)return t.data;if(t.nodeType!==1)return null;var i=[],o={},l=0,u=t.attributes,c=t.childNodes;for(l=u.length;l--;)u[l].name!=="slot"&&(o[u[l].name]=u[l].value,o[ad(u[l].name)]=u[l].value);for(l=c.length;l--;){var f=e(c[l],null),p=c[l].slot;p?o[p]=te(od,{name:p},f):i[l]=f}var h=r?te(od,null,i):i;return te(r||t.nodeName.toLowerCase(),o,h)}(this,this._vdomComponent)),(this.hasAttribute("hydrate")?Ys:ln)(this._vdom,this._root)}function ad(n){return n.replace(/-(\w)/g,function(e,t){return t?t.toUpperCase():""})}function p1(n,e,t){if(this._vdom){var r={};r[n]=t=t??void 0,r[ad(n)]=t,this._vdom=Fs(this._vdom,r),ln(this._vdom,this._root)}}function h1(){ln(this._vdom=null,this._root)}function od(n,e){var t=this;return te("slot",Ns({},n,{ref:function(r){r?(t.ref=r,t._listener||(t._listener=function(i){i.stopPropagation(),i.detail.context=e},r.addEventListener("_preact",t._listener))):t.ref.removeEventListener("_preact",t._listener)}}))}function v1(n,e,t,r){function i(){var o=Reflect.construct(HTMLElement,[],i);return o._vdomComponent=n,o._root=r&&r.shadow?o.attachShadow({mode:r.mode||"open"}):o,o}return(i.prototype=Object.create(HTMLElement.prototype)).constructor=i,i.prototype.connectedCallback=f1,i.prototype.attributeChangedCallback=p1,i.prototype.disconnectedCallback=h1,t=t||n.observedAttributes||Object.keys(n.propTypes||{}),i.observedAttributes=t,t.forEach(function(o){Object.defineProperty(i.prototype,o,{get:function(){return this._vdom.props[o]},set:function(l){this._vdom?this.attributeChangedCallback(o,null,l):(this._props||(this._props={}),this._props[o]=l,this.connectedCallback());var u=typeof l;l!=null&&u!=="string"&&u!=="boolean"&&u!=="number"||this.setAttribute(o,l)}})}),customElements.define(e||n.tagName||n.displayName||n.name,i)}var un,Ze,Rs,sd,si=0,ld=[],no=[],Qe=fe,ud=Qe.__b,cd=Qe.__r,dd=Qe.diffed,fd=Qe.__c,pd=Qe.unmount,hd=Qe.__;function li(n,e){Qe.__h&&Qe.__h(Ze,n,si||e),si=0;var t=Ze.__H||(Ze.__H={__:[],__h:[]});return n>=t.__.length&&t.__.push({__V:no}),t.__[n]}function $(n){return si=1,vd(md,n)}function vd(n,e,t){var r=li(un++,2);if(r.t=n,!r.__c&&(r.__=[t?t(e):md(void 0,e),function(u){var c=r.__N?r.__N[0]:r.__[0],f=r.t(c,u);c!==f&&(r.__N=[f,r.__[1]],r.__c.setState({}))}],r.__c=Ze,!Ze.u)){var i=function(u,c,f){if(!r.__c.__H)return!0;var p=r.__c.__H.__.filter(function(b){return!!b.__c});if(p.every(function(b){return!b.__N}))return!o||o.call(this,u,c,f);var h=!1;return p.forEach(function(b){if(b.__N){var m=b.__[0];b.__=b.__N,b.__N=void 0,m!==b.__[0]&&(h=!0)}}),!(!h&&r.__c.props===u)&&(!o||o.call(this,u,c,f))};Ze.u=!0;var o=Ze.shouldComponentUpdate,l=Ze.componentWillUpdate;Ze.componentWillUpdate=function(u,c,f){if(this.__e){var p=o;o=void 0,i(u,c,f),o=p}l&&l.call(this,u,c,f)},Ze.shouldComponentUpdate=i}return r.__N||r.__}function se(n,e){var t=li(un++,3);!Qe.__s&&qs(t.__H,e)&&(t.__=n,t.i=e,Ze.__H.__h.push(t))}function ui(n,e){var t=li(un++,4);!Qe.__s&&qs(t.__H,e)&&(t.__=n,t.i=e,Ze.__h.push(t))}function be(n){return si=5,kr(function(){return{current:n}},[])}function g1(n,e,t){si=6,ui(function(){return typeof n=="function"?(n(e()),function(){return n(null)}):n?(n.current=e(),function(){return n.current=null}):void 0},t==null?t:t.concat(n))}function kr(n,e){var t=li(un++,7);return qs(t.__H,e)?(t.__V=n(),t.i=e,t.__h=n,t.__V):t.__}function gd(n,e){return si=8,kr(function(){return n},e)}function Gs(n){var e=Ze.context[n.__c],t=li(un++,9);return t.c=n,e?(t.__==null&&(t.__=!0,e.sub(Ze)),e.props.value):n.__}function b1(n,e){Qe.useDebugValue&&Qe.useDebugValue(e?e(n):n)}function m1(){var n=li(un++,11);if(!n.__){for(var e=Ze.__v;e!==null&&!e.__m&&e.__!==null;)e=e.__;var t=e.__m||(e.__m=[0,0]);n.__="P"+t[0]+"-"+t[1]++}return n.__}function y1(){for(var n;n=ld.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(io),n.__H.__h.forEach(Qs),n.__H.__h=[]}catch(e){n.__H.__h=[],Qe.__e(e,n.__v)}}Qe.__b=function(n){Ze=null,ud&&ud(n)},Qe.__=function(n,e){n&&e.__k&&e.__k.__m&&(n.__m=e.__k.__m),hd&&hd(n,e)},Qe.__r=function(n){cd&&cd(n),un=0;var e=(Ze=n.__c).__H;e&&(Rs===Ze?(e.__h=[],Ze.__h=[],e.__.forEach(function(t){t.__N&&(t.__=t.__N),t.__V=no,t.__N=t.i=void 0})):(e.__h.forEach(io),e.__h.forEach(Qs),e.__h=[],un=0)),Rs=Ze},Qe.diffed=function(n){dd&&dd(n);var e=n.__c;e&&e.__H&&(e.__H.__h.length&&(ld.push(e)!==1&&sd===Qe.requestAnimationFrame||((sd=Qe.requestAnimationFrame)||w1)(y1)),e.__H.__.forEach(function(t){t.i&&(t.__H=t.i),t.__V!==no&&(t.__=t.__V),t.i=void 0,t.__V=no})),Rs=Ze=null},Qe.__c=function(n,e){e.some(function(t){try{t.__h.forEach(io),t.__h=t.__h.filter(function(r){return!r.__||Qs(r)})}catch(r){e.some(function(i){i.__h&&(i.__h=[])}),e=[],Qe.__e(r,t.__v)}}),fd&&fd(n,e)},Qe.unmount=function(n){pd&&pd(n);var e,t=n.__c;t&&t.__H&&(t.__H.__.forEach(function(r){try{io(r)}catch(i){e=i}}),t.__H=void 0,e&&Qe.__e(e,t.__v))};var bd=typeof requestAnimationFrame=="function";function w1(n){var e,t=function(){clearTimeout(r),bd&&cancelAnimationFrame(e),setTimeout(n)},r=setTimeout(t,100);bd&&(e=requestAnimationFrame(t))}function io(n){var e=Ze,t=n.__c;typeof t=="function"&&(n.__c=void 0,t()),Ze=e}function Qs(n){var e=Ze;n.__c=n.__(),Ze=e}function qs(n,e){return!n||n.length!==e.length||e.some(function(t,r){return t!==n[r]})}function md(n,e){return typeof e=="function"?e(n):e}function yd(n,e){for(var t in e)n[t]=e[t];return n}function Vs(n,e){for(var t in n)if(t!=="__source"&&!(t in e))return!0;for(var r in e)if(r!=="__source"&&n[r]!==e[r])return!0;return!1}function Js(n,e){this.props=n,this.context=e}function x1(n,e){function t(i){var o=this.props.ref,l=o==i.ref;return!l&&o&&(o.call?o(null):o.current=null),e?!e(this.props,i)||!l:Vs(this.props,i)}function r(i){return this.shouldComponentUpdate=t,te(n,i)}return r.displayName="Memo("+(n.displayName||n.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Js.prototype=new hr).isPureReactComponent=!0,Js.prototype.shouldComponentUpdate=function(n,e){return Vs(this.props,n)||Vs(this.state,e)};var wd=fe.__b;fe.__b=function(n){n.type&&n.type.__f&&n.ref&&(n.props.ref=n.ref,n.ref=null),wd&&wd(n)};var P1=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.forward_ref")||3911;function Us(n){function e(t){var r=yd({},t);return delete r.ref,n(r,t.ref||null)}return e.$$typeof=P1,e.render=e,e.prototype.isReactComponent=e.__f=!0,e.displayName="ForwardRef("+(n.displayName||n.name)+")",e}var xd=function(n,e){return n==null?null:Wr(Wr(n).map(e))},k1={map:xd,forEach:xd,count:function(n){return n?Wr(n).length:0},only:function(n){var e=Wr(n);if(e.length!==1)throw"Children.only";return e[0]},toArray:Wr},z1=fe.__e;fe.__e=function(n,e,t,r){if(n.then){for(var i,o=e;o=o.__;)if((i=o.__c)&&i.__c)return e.__e==null&&(e.__e=t.__e,e.__k=t.__k),i.__c(n,e)}z1(n,e,t,r)};var Pd=fe.unmount;function kd(n,e,t){return n&&(n.__c&&n.__c.__H&&(n.__c.__H.__.forEach(function(r){typeof r.__c=="function"&&r.__c()}),n.__c.__H=null),(n=yd({},n)).__c!=null&&(n.__c.__P===t&&(n.__c.__P=e),n.__c=null),n.__k=n.__k&&n.__k.map(function(r){return kd(r,e,t)})),n}function zd(n,e,t){return n&&t&&(n.__v=null,n.__k=n.__k&&n.__k.map(function(r){return zd(r,e,t)}),n.__c&&n.__c.__P===e&&(n.__e&&t.appendChild(n.__e),n.__c.__e=!0,n.__c.__P=t)),n}function ao(){this.__u=0,this.t=null,this.__b=null}function Cd(n){var e=n.__.__c;return e&&e.__a&&e.__a(n)}function C1(n){var e,t,r;function i(o){if(e||(e=n()).then(function(l){t=l.default||l},function(l){r=l}),r)throw r;if(!t)throw e;return te(t,o)}return i.displayName="Lazy",i.__f=!0,i}function ta(){this.u=null,this.o=null}fe.unmount=function(n){var e=n.__c;e&&e.__R&&e.__R(),e&&32&n.__u&&(n.type=null),Pd&&Pd(n)},(ao.prototype=new hr).__c=function(n,e){var t=e.__c,r=this;r.t==null&&(r.t=[]),r.t.push(t);var i=Cd(r.__v),o=!1,l=function(){o||(o=!0,t.__R=null,i?i(u):u())};t.__R=l;var u=function(){if(!--r.__u){if(r.state.__a){var c=r.state.__a;r.__v.__k[0]=zd(c,c.__c.__P,c.__c.__O)}var f;for(r.setState({__a:r.__b=null});f=r.t.pop();)f.forceUpdate()}};r.__u++||32&e.__u||r.setState({__a:r.__b=r.__v.__k[0]}),n.then(l,l)},ao.prototype.componentWillUnmount=function(){this.t=[]},ao.prototype.render=function(n,e){if(this.__b){if(this.__v.__k){var t=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=kd(this.__b,t,r.__O=r.__P)}this.__b=null}var i=e.__a&&te(ie,null,n.fallback);return i&&(i.__u&=-33),[te(ie,null,e.__a?null:n.children),i]};var Hd=function(n,e,t){if(++t[1]===t[0]&&n.o.delete(e),n.props.revealOrder&&(n.props.revealOrder[0]!=="t"||!n.o.size))for(t=n.u;t;){for(;t.length>3;)t.pop()();if(t[1]<t[0])break;n.u=t=t[2]}};function H1(n){return this.getChildContext=function(){return n.context},n.children}function A1(n){var e=this,t=n.i;e.componentWillUnmount=function(){ln(null,e.l),e.l=null,e.i=null},e.i&&e.i!==t&&e.componentWillUnmount(),e.l||(e.i=t,e.l={nodeType:1,parentNode:t,childNodes:[],appendChild:function(r){this.childNodes.push(r),e.i.appendChild(r)},insertBefore:function(r,i){this.childNodes.push(r),e.i.appendChild(r)},removeChild:function(r){this.childNodes.splice(this.childNodes.indexOf(r)>>>1,1),e.i.removeChild(r)}}),ln(te(H1,{context:e.context},n.__v),e.l)}function D1(n,e){var t=te(A1,{__v:n,i:e});return t.containerInfo=e,t}(ta.prototype=new hr).__a=function(n){var e=this,t=Cd(e.__v),r=e.o.get(n);return r[0]++,function(i){var o=function(){e.props.revealOrder?(r.push(i),Hd(e,n,r)):i()};t?t(o):o()}},ta.prototype.render=function(n){this.u=null,this.o=new Map;var e=Wr(n.children);n.revealOrder&&n.revealOrder[0]==="b"&&e.reverse();for(var t=e.length;t--;)this.o.set(e[t],this.u=[1,0,this.u]);return n.children},ta.prototype.componentDidUpdate=ta.prototype.componentDidMount=function(){var n=this;this.o.forEach(function(e,t){Hd(n,t,e)})};var Ad=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,O1=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,X1=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,E1=/[A-Z0-9]/g,L1=typeof document<"u",B1=function(n){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(n)};function j1(n,e,t){return e.__k==null&&(e.textContent=""),ln(n,e),typeof t=="function"&&t(),n?n.__c:null}function T1(n,e,t){return Ys(n,e),typeof t=="function"&&t(),n?n.__c:null}hr.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(n){Object.defineProperty(hr.prototype,n,{configurable:!0,get:function(){return this["UNSAFE_"+n]},set:function(e){Object.defineProperty(this,n,{configurable:!0,writable:!0,value:e})}})});var Dd=fe.event;function I1(){}function S1(){return this.cancelBubble}function M1(){return this.defaultPrevented}fe.event=function(n){return Dd&&(n=Dd(n)),n.persist=I1,n.isPropagationStopped=S1,n.isDefaultPrevented=M1,n.nativeEvent=n};var Ks,W1={enumerable:!1,configurable:!0,get:function(){return this.class}},Od=fe.vnode;fe.vnode=function(n){typeof n.type=="string"&&function(e){var t=e.props,r=e.type,i={};for(var o in t){var l=t[o];if(!(o==="value"&&"defaultValue"in t&&l==null||L1&&o==="children"&&r==="noscript"||o==="class"||o==="className")){var u=o.toLowerCase();o==="defaultValue"&&"value"in t&&t.value==null?o="value":o==="download"&&l===!0?l="":u==="translate"&&l==="no"?l=!1:u==="ondoubleclick"?o="ondblclick":u!=="onchange"||r!=="input"&&r!=="textarea"||B1(t.type)?u==="onfocus"?o="onfocusin":u==="onblur"?o="onfocusout":X1.test(o)?o=u:r.indexOf("-")===-1&&O1.test(o)?o=o.replace(E1,"-$&").toLowerCase():l===null&&(l=void 0):u=o="oninput",u==="oninput"&&i[o=u]&&(o="oninputCapture"),i[o]=l}}r=="select"&&i.multiple&&Array.isArray(i.value)&&(i.value=Wr(t.children).forEach(function(c){c.props.selected=i.value.indexOf(c.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=Wr(t.children).forEach(function(c){c.props.selected=i.multiple?i.defaultValue.indexOf(c.props.value)!=-1:i.defaultValue==c.props.value})),t.class&&!t.className?(i.class=t.class,Object.defineProperty(i,"className",W1)):(t.className&&!t.class||t.class&&t.className)&&(i.class=i.className=t.className),e.props=i}(n),n.$$typeof=Ad,Od&&Od(n)};var Xd=fe.__r;fe.__r=function(n){Xd&&Xd(n),Ks=n.__c};var Ed=fe.diffed;fe.diffed=function(n){Ed&&Ed(n);var e=n.props,t=n.__e;t!=null&&n.type==="textarea"&&"value"in e&&e.value!==t.value&&(t.value=e.value==null?"":e.value),Ks=null};var Z1={ReactCurrentDispatcher:{current:{readContext:function(n){return Ks.__n[n.__c].props.value}}}};function Y1(n){return te.bind(null,n)}function oo(n){return!!n&&n.$$typeof===Ad}function F1(n){return oo(n)&&n.type===ie}function N1(n){return oo(n)?Fs.apply(null,arguments):n}function R1(n){return!!n.__k&&(ln(null,n),!0)}function G1(n){return n&&(n.base||n.nodeType===1&&n)||null}var Q1=function(n,e){return n(e)},q1=function(n,e){return n(e)},V1=ie;function Ld(n){n()}function J1(n){return n}function U1(){return[!1,Ld]}var K1=ui,_1=oo;function $1(n,e){var t=e(),r=$({h:{__:t,v:e}}),i=r[0].h,o=r[1];return ui(function(){i.__=t,i.v=e,_s(i)&&o({h:i})},[n,t,e]),se(function(){return _s(i)&&o({h:i}),n(function(){_s(i)&&o({h:i})})},[n]),t}function _s(n){var e,t,r=n.v,i=n.__;try{var o=r();return!((e=i)===(t=o)&&(e!==0||1/e==1/t)||e!=e&&t!=t)}catch{return!0}}var it={useState:$,useId:m1,useReducer:vd,useEffect:se,useLayoutEffect:ui,useInsertionEffect:K1,useTransition:U1,useDeferredValue:J1,useSyncExternalStore:$1,startTransition:Ld,useRef:be,useImperativeHandle:g1,useMemo:kr,useCallback:gd,useContext:Gs,useDebugValue:b1,version:"17.0.2",Children:k1,render:j1,hydrate:T1,unmountComponentAtNode:R1,createPortal:D1,createElement:te,createContext:ea,createFactory:Y1,cloneElement:N1,createRef:a1,Fragment:ie,isValidElement:oo,isElement:_1,isFragment:F1,findDOMNode:G1,Component:hr,PureComponent:Js,memo:x1,forwardRef:Us,flushSync:q1,unstable_batchedUpdates:Q1,StrictMode:V1,Suspense:ao,SuspenseList:ta,lazy:C1,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:Z1},cn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function eg(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}const tg=(...n)=>{console!=null&&console.warn&&(Tn(n[0])&&(n[0]=`react-i18next:: ${n[0]}`),console.warn(...n))},Bd={},$s=(...n)=>{Tn(n[0])&&Bd[n[0]]||(Tn(n[0])&&(Bd[n[0]]=new Date),tg(...n))},jd=(n,e)=>()=>{if(n.isInitialized)e();else{const t=()=>{setTimeout(()=>{n.off("initialized",t)},0),e()};n.on("initialized",t)}},Td=(n,e,t)=>{n.loadNamespaces(e,jd(n,t))},Id=(n,e,t,r)=>{Tn(t)&&(t=[t]),t.forEach(i=>{n.options.ns.indexOf(i)<0&&n.options.ns.push(i)}),n.loadLanguages(e,jd(n,r))},rg=(n,e,t={})=>!e.languages||!e.languages.length?($s("i18n.languages were undefined or empty",e.languages),!0):e.hasLoadedNamespace(n,{lng:t.lng,precheck:(r,i)=>{var o;if(((o=t.bindI18n)==null?void 0:o.indexOf("languageChanging"))>-1&&r.services.backendConnector.backend&&r.isLanguageChangingTo&&!i(r.isLanguageChangingTo,n))return!1}}),Tn=n=>typeof n=="string",ng=n=>typeof n=="object"&&n!==null,ig=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,ag={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},og=n=>ag[n];let el={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:n=>n.replace(ig,og)};const sg=(n={})=>{el={...el,...n}},lg=()=>el;let Sd;const ug=n=>{Sd=n},ci=()=>Sd,cg={type:"3rdParty",init(n){sg(n.options.react),ug(n)}},dg=ea();class fg{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(t=>{this.usedNamespaces[t]||(this.usedNamespaces[t]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}}const pg=(n,e)=>{const t=be();return se(()=>{t.current=e?t.current:n},[n,e]),t.current},Md=(n,e,t,r)=>n.getFixedT(e,t,r),hg=(n,e,t,r)=>gd(Md(n,e,t,r),[n,e,t,r]),Le=(n,e={})=>{var D,O,j,L;const{i18n:t}=e,{i18n:r,defaultNS:i}=Gs(dg)||{},o=t||r||ci();if(o&&!o.reportNamespaces&&(o.reportNamespaces=new fg),!o){$s("You will need to pass in an i18next instance by using initReactI18next");const T=(M,W)=>Tn(W)?W:ng(W)&&Tn(W.defaultValue)?W.defaultValue:Array.isArray(M)?M[M.length-1]:M,X=[T,{},!1];return X.t=T,X.i18n={},X.ready=!1,X}(D=o.options.react)!=null&&D.wait&&$s("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");const l={...lg(),...o.options.react,...e},{useSuspense:u,keyPrefix:c}=l;let f=n||i||((O=o.options)==null?void 0:O.defaultNS);f=Tn(f)?[f]:f||["translation"],(L=(j=o.reportNamespaces).addUsedNamespaces)==null||L.call(j,f);const p=(o.isInitialized||o.initializedStoreOnce)&&f.every(T=>rg(T,o,l)),h=hg(o,e.lng||null,l.nsMode==="fallback"?f:f[0],c),b=()=>h,m=()=>Md(o,e.lng||null,l.nsMode==="fallback"?f:f[0],c),[k,x]=$(b);let H=f.join();e.lng&&(H=`${e.lng}${H}`);const C=pg(H),w=be(!0);se(()=>{const{bindI18n:T,bindI18nStore:X}=l;w.current=!0,!p&&!u&&(e.lng?Id(o,e.lng,f,()=>{w.current&&x(m)}):Td(o,f,()=>{w.current&&x(m)})),p&&C&&C!==H&&w.current&&x(m);const M=()=>{w.current&&x(m)};return T&&(o==null||o.on(T,M)),X&&(o==null||o.store.on(X,M)),()=>{w.current=!1,o&&(T==null||T.split(" ").forEach(W=>o.off(W,M))),X&&o&&X.split(" ").forEach(W=>o.store.off(W,M))}},[o,H]),se(()=>{w.current&&p&&x(b)},[o,c,p]);const P=[k,o,p];if(P.t=k,P.i18n=o,P.ready=p,p||!p&&!u)return P;throw new Promise(T=>{e.lng?Id(o,e.lng,f,()=>T()):Td(o,f,()=>T())})};var vg=Symbol.for("preact-signals");function so(){if(dn>1)dn--;else{for(var n,e=!1;ra!==void 0;){var t=ra;for(ra=void 0,tl++;t!==void 0;){var r=t.o;if(t.o=void 0,t.f&=-3,!(8&t.f)&&Zd(t))try{t.c()}catch(i){e||(n=i,e=!0)}t=r}}if(tl=0,dn--,e)throw n}}function gg(n){if(dn>0)return n();dn++;try{return n()}finally{so()}}var Be=void 0,ra=void 0,dn=0,tl=0,lo=0;function Wd(n){if(Be!==void 0){var e=n.n;if(e===void 0||e.t!==Be)return e={i:0,S:n,p:Be.s,n:void 0,t:Be,e:void 0,x:void 0,r:e},Be.s!==void 0&&(Be.s.n=e),Be.s=e,n.n=e,32&Be.f&&n.S(e),e;if(e.i===-1)return e.i=0,e.n!==void 0&&(e.n.p=e.p,e.p!==void 0&&(e.p.n=e.n),e.p=Be.s,e.n=void 0,Be.s.n=e,Be.s=e),e}}function ct(n){this.v=n,this.i=0,this.n=void 0,this.t=void 0}ct.prototype.brand=vg,ct.prototype.h=function(){return!0},ct.prototype.S=function(n){this.t!==n&&n.e===void 0&&(n.x=this.t,this.t!==void 0&&(this.t.e=n),this.t=n)},ct.prototype.U=function(n){if(this.t!==void 0){var e=n.e,t=n.x;e!==void 0&&(e.x=t,n.e=void 0),t!==void 0&&(t.e=e,n.x=void 0),n===this.t&&(this.t=t)}},ct.prototype.subscribe=function(n){var e=this;return nl(function(){var t=e.value,r=Be;Be=void 0;try{n(t)}finally{Be=r}})},ct.prototype.valueOf=function(){return this.value},ct.prototype.toString=function(){return this.value+""},ct.prototype.toJSON=function(){return this.value},ct.prototype.peek=function(){var n=Be;Be=void 0;try{return this.value}finally{Be=n}},Object.defineProperty(ct.prototype,"value",{get:function(){var n=Wd(this);return n!==void 0&&(n.i=this.i),this.v},set:function(n){if(n!==this.v){if(tl>100)throw new Error("Cycle detected");this.v=n,this.i++,lo++,dn++;try{for(var e=this.t;e!==void 0;e=e.x)e.t.N()}finally{so()}}}});function Ct(n){return new ct(n)}function Zd(n){for(var e=n.s;e!==void 0;e=e.n)if(e.S.i!==e.i||!e.S.h()||e.S.i!==e.i)return!0;return!1}function Yd(n){for(var e=n.s;e!==void 0;e=e.n){var t=e.S.n;if(t!==void 0&&(e.r=t),e.S.n=e,e.i=-1,e.n===void 0){n.s=e;break}}}function Fd(n){for(var e=n.s,t=void 0;e!==void 0;){var r=e.p;e.i===-1?(e.S.U(e),r!==void 0&&(r.n=e.n),e.n!==void 0&&(e.n.p=r)):t=e,e.S.n=e.r,e.r!==void 0&&(e.r=void 0),e=r}n.s=t}function di(n){ct.call(this,void 0),this.x=n,this.s=void 0,this.g=lo-1,this.f=4}(di.prototype=new ct).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===lo))return!0;if(this.g=lo,this.f|=1,this.i>0&&!Zd(this))return this.f&=-2,!0;var n=Be;try{Yd(this),Be=this;var e=this.x();(16&this.f||this.v!==e||this.i===0)&&(this.v=e,this.f&=-17,this.i++)}catch(t){this.v=t,this.f|=16,this.i++}return Be=n,Fd(this),this.f&=-2,!0},di.prototype.S=function(n){if(this.t===void 0){this.f|=36;for(var e=this.s;e!==void 0;e=e.n)e.S.S(e)}ct.prototype.S.call(this,n)},di.prototype.U=function(n){if(this.t!==void 0&&(ct.prototype.U.call(this,n),this.t===void 0)){this.f&=-33;for(var e=this.s;e!==void 0;e=e.n)e.S.U(e)}},di.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var n=this.t;n!==void 0;n=n.x)n.t.N()}},Object.defineProperty(di.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var n=Wd(this);if(this.h(),n!==void 0&&(n.i=this.i),16&this.f)throw this.v;return this.v}});function bg(n){return new di(n)}function Nd(n){var e=n.u;if(n.u=void 0,typeof e=="function"){dn++;var t=Be;Be=void 0;try{e()}catch(r){throw n.f&=-2,n.f|=8,rl(n),r}finally{Be=t,so()}}}function rl(n){for(var e=n.s;e!==void 0;e=e.n)e.S.U(e);n.x=void 0,n.s=void 0,Nd(n)}function mg(n){if(Be!==this)throw new Error("Out-of-order effect");Fd(this),Be=n,this.f&=-2,8&this.f&&rl(this),so()}function na(n){this.x=n,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}na.prototype.c=function(){var n=this.S();try{if(8&this.f||this.x===void 0)return;var e=this.x();typeof e=="function"&&(this.u=e)}finally{n()}},na.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,Nd(this),Yd(this),dn++;var n=Be;return Be=this,mg.bind(this,n)},na.prototype.N=function(){2&this.f||(this.f|=2,this.o=ra,ra=this)},na.prototype.d=function(){this.f|=8,1&this.f||rl(this)};function nl(n){var e=new na(n);try{e.c()}catch(t){throw e.d(),t}return e.d.bind(e)}var il;function fi(n,e){fe[n]=e.bind(null,fe[n]||function(){})}function uo(n){il&&il(),il=n&&n.S()}function Rd(n){var e=this,t=n.data,r=wg(t);r.value=t;var i=kr(function(){for(var o=e.__v;o=o.__;)if(o.__c){o.__c.__$f|=4;break}return e.__$u.c=function(){var l,u=e.__$u.S(),c=i.value;u(),Qc(c)||((l=e.base)==null?void 0:l.nodeType)!==3?(e.__$f|=1,e.setState({})):e.base.data=c},bg(function(){var l=r.value.value;return l===0?0:l===!0?"":l||""})},[]);return i.value}Rd.displayName="_st",Object.defineProperties(ct.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:Rd},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),fi("__b",function(n,e){if(typeof e.type=="string"){var t,r=e.props;for(var i in r)if(i!=="children"){var o=r[i];o instanceof ct&&(t||(e.__np=t={}),t[i]=o,r[i]=o.peek())}}n(e)}),fi("__r",function(n,e){uo();var t,r=e.__c;r&&(r.__$f&=-2,(t=r.__$u)===void 0&&(r.__$u=t=function(i){var o;return nl(function(){o=this}),o.c=function(){r.__$f|=1,r.setState({})},o}())),uo(t),n(e)}),fi("__e",function(n,e,t,r){uo(),n(e,t,r)}),fi("diffed",function(n,e){uo();var t;if(typeof e.type=="string"&&(t=e.__e)){var r=e.__np,i=e.props;if(r){var o=t.U;if(o)for(var l in o){var u=o[l];u!==void 0&&!(l in r)&&(u.d(),o[l]=void 0)}else t.U=o={};for(var c in r){var f=o[c],p=r[c];f===void 0?(f=yg(t,c,p,i),o[c]=f):f.o(p,i)}}}n(e)});function yg(n,e,t,r){var i=e in n&&n.ownerSVGElement===void 0,o=Ct(t);return{o:function(l,u){o.value=l,r=u},d:nl(function(){var l=o.value.value;r[e]!==l&&(r[e]=l,i?n[e]=l:l?n.setAttribute(e,l):n.removeAttribute(e))})}}fi("unmount",function(n,e){if(typeof e.type=="string"){var t=e.__e;if(t){var r=t.U;if(r){t.U=void 0;for(var i in r){var o=r[i];o&&o.d()}}}}else{var l=e.__c;if(l){var u=l.__$u;u&&(l.__$u=void 0,u.d())}}n(e)}),fi("__h",function(n,e,t,r){(r<3||r===9)&&(e.__$f|=2),n(e,t,r)}),hr.prototype.shouldComponentUpdate=function(n,e){var t=this.__$u;if(!(t&&t.s!==void 0||4&this.__$f)||3&this.__$f)return!0;for(var r in e)return!0;for(var i in n)if(i!=="__source"&&n[i]!==this.props[i])return!0;for(var o in this.props)if(!(o in n))return!0;return!1};function wg(n){return kr(function(){return Ct(n)},[])}const al=Ct(!1),Ae=Ct(null),pi=Ct([]),Zt=Ct(!1),hi=Ct([]),rr=Ct(!1),co=Ct(null),ht=Ct(null),fo=Ct(!1),po=Ct(!0),xg=()=>{gg(()=>{Ae.value=null,pi.value=[],Zt.value=!1,hi.value=[],rr.value=!1,co.value=null,ht.value=null,fo.value=!1,po.value=!0})},ol="bm_currentBike",Pg="v2",kg="https://cdn.bikematrix.io",Gd={isShopify:!1,skuField:"sku",apiUrl:"https://api.bikematrix.io/proxy/v3/",apiKey:"",apiToken:"",currentCollectionHandle:"",categories:[],collections:[],pageType:"index",showHomePageCollection:!1,showSearchPageCollection:!1,designMode:!1,bikeSelectorBrands:"",productsCollections:{},isHomePage:!1,isSearchPage:!1,products:{},collectionUrl:"",compatiblityListCurrentPage:0,showCompatibleList:!0,sku:"",productCollections:[],logLevel:"none",virtualWorkshop:!0},In=function(n){return new URL(n,kg).toString()};function Qd(n){var e,t,r="";if(typeof n=="string"||typeof n=="number")r+=n;else if(typeof n=="object")if(Array.isArray(n)){var i=n.length;for(e=0;e<i;e++)n[e]&&(t=Qd(n[e]))&&(r&&(r+=" "),r+=t)}else for(t in n)n[t]&&(r&&(r+=" "),r+=t);return r}function zg(){for(var n,e,t=0,r="",i=arguments.length;t<i;t++)(n=arguments[t])&&(e=Qd(n))&&(r&&(r+=" "),r+=e);return r}const sl="-";function Cg(n){const e=Ag(n),{conflictingClassGroups:t,conflictingClassGroupModifiers:r}=n;function i(l){const u=l.split(sl);return u[0]===""&&u.length!==1&&u.shift(),qd(u,e)||Hg(l)}function o(l,u){const c=t[l]||[];return u&&r[l]?[...c,...r[l]]:c}return{getClassGroupId:i,getConflictingClassGroupIds:o}}function qd(n,e){var l;if(n.length===0)return e.classGroupId;const t=n[0],r=e.nextPart.get(t),i=r?qd(n.slice(1),r):void 0;if(i)return i;if(e.validators.length===0)return;const o=n.join(sl);return(l=e.validators.find(({validator:u})=>u(o)))==null?void 0:l.classGroupId}const Vd=/^\[(.+)\]$/;function Hg(n){if(Vd.test(n)){const e=Vd.exec(n)[1],t=e==null?void 0:e.substring(0,e.indexOf(":"));if(t)return"arbitrary.."+t}}function Ag(n){const{theme:e,prefix:t}=n,r={nextPart:new Map,validators:[]};return Og(Object.entries(n.classGroups),t).forEach(([o,l])=>{ll(l,r,o,e)}),r}function ll(n,e,t,r){n.forEach(i=>{if(typeof i=="string"){const o=i===""?e:Jd(e,i);o.classGroupId=t;return}if(typeof i=="function"){if(Dg(i)){ll(i(r),e,t,r);return}e.validators.push({validator:i,classGroupId:t});return}Object.entries(i).forEach(([o,l])=>{ll(l,Jd(e,o),t,r)})})}function Jd(n,e){let t=n;return e.split(sl).forEach(r=>{t.nextPart.has(r)||t.nextPart.set(r,{nextPart:new Map,validators:[]}),t=t.nextPart.get(r)}),t}function Dg(n){return n.isThemeGetter}function Og(n,e){return e?n.map(([t,r])=>{const i=r.map(o=>typeof o=="string"?e+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([l,u])=>[e+l,u])):o);return[t,i]}):n}function Xg(n){if(n<1)return{get:()=>{},set:()=>{}};let e=0,t=new Map,r=new Map;function i(o,l){t.set(o,l),e++,e>n&&(e=0,r=t,t=new Map)}return{get(o){let l=t.get(o);if(l!==void 0)return l;if((l=r.get(o))!==void 0)return i(o,l),l},set(o,l){t.has(o)?t.set(o,l):i(o,l)}}}const Ud="!";function Eg(n){const e=n.separator,t=e.length===1,r=e[0],i=e.length;return function(l){const u=[];let c=0,f=0,p;for(let x=0;x<l.length;x++){let H=l[x];if(c===0){if(H===r&&(t||l.slice(x,x+i)===e)){u.push(l.slice(f,x)),f=x+i;continue}if(H==="/"){p=x;continue}}H==="["?c++:H==="]"&&c--}const h=u.length===0?l:l.substring(f),b=h.startsWith(Ud),m=b?h.substring(1):h,k=p&&p>f?p-f:void 0;return{modifiers:u,hasImportantModifier:b,baseClassName:m,maybePostfixModifierPosition:k}}}function Lg(n){if(n.length<=1)return n;const e=[];let t=[];return n.forEach(r=>{r[0]==="["?(e.push(...t.sort(),r),t=[]):t.push(r)}),e.push(...t.sort()),e}function Bg(n){return{cache:Xg(n.cacheSize),splitModifiers:Eg(n),...Cg(n)}}const jg=/\s+/;function Tg(n,e){const{splitModifiers:t,getClassGroupId:r,getConflictingClassGroupIds:i}=e,o=new Set;return n.trim().split(jg).map(l=>{const{modifiers:u,hasImportantModifier:c,baseClassName:f,maybePostfixModifierPosition:p}=t(l);let h=r(p?f.substring(0,p):f),b=!!p;if(!h){if(!p)return{isTailwindClass:!1,originalClassName:l};if(h=r(f),!h)return{isTailwindClass:!1,originalClassName:l};b=!1}const m=Lg(u).join(":");return{isTailwindClass:!0,modifierId:c?m+Ud:m,classGroupId:h,originalClassName:l,hasPostfixModifier:b}}).reverse().filter(l=>{if(!l.isTailwindClass)return!0;const{modifierId:u,classGroupId:c,hasPostfixModifier:f}=l,p=u+c;return o.has(p)?!1:(o.add(p),i(c,f).forEach(h=>o.add(u+h)),!0)}).reverse().map(l=>l.originalClassName).join(" ")}function Ig(){let n=0,e,t,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=Kd(e))&&(r&&(r+=" "),r+=t);return r}function Kd(n){if(typeof n=="string")return n;let e,t="";for(let r=0;r<n.length;r++)n[r]&&(e=Kd(n[r]))&&(t&&(t+=" "),t+=e);return t}function Sg(n,...e){let t,r,i,o=l;function l(c){const f=e.reduce((p,h)=>h(p),n());return t=Bg(f),r=t.cache.get,i=t.cache.set,o=u,u(c)}function u(c){const f=r(c);if(f)return f;const p=Tg(c,t);return i(c,p),p}return function(){return o(Ig.apply(null,arguments))}}function Ye(n){const e=t=>t[n]||[];return e.isThemeGetter=!0,e}const _d=/^\[(?:([a-z-]+):)?(.+)\]$/i,Mg=/^\d+\/\d+$/,Wg=new Set(["px","full","screen"]),Zg=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Yg=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Fg=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,Ng=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,Rg=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/;function Zr(n){return Sn(n)||Wg.has(n)||Mg.test(n)}function fn(n){return vi(n,"length",_g)}function Sn(n){return!!n&&!Number.isNaN(Number(n))}function ho(n){return vi(n,"number",Sn)}function ia(n){return!!n&&Number.isInteger(Number(n))}function Gg(n){return n.endsWith("%")&&Sn(n.slice(0,-1))}function me(n){return _d.test(n)}function pn(n){return Zg.test(n)}const Qg=new Set(["length","size","percentage"]);function qg(n){return vi(n,Qg,$d)}function Vg(n){return vi(n,"position",$d)}const Jg=new Set(["image","url"]);function Ug(n){return vi(n,Jg,e3)}function Kg(n){return vi(n,"",$g)}function aa(){return!0}function vi(n,e,t){const r=_d.exec(n);return r?r[1]?typeof e=="string"?r[1]===e:e.has(r[1]):t(r[2]):!1}function _g(n){return Yg.test(n)&&!Fg.test(n)}function $d(){return!1}function $g(n){return Ng.test(n)}function e3(n){return Rg.test(n)}function t3(){const n=Ye("colors"),e=Ye("spacing"),t=Ye("blur"),r=Ye("brightness"),i=Ye("borderColor"),o=Ye("borderRadius"),l=Ye("borderSpacing"),u=Ye("borderWidth"),c=Ye("contrast"),f=Ye("grayscale"),p=Ye("hueRotate"),h=Ye("invert"),b=Ye("gap"),m=Ye("gradientColorStops"),k=Ye("gradientColorStopPositions"),x=Ye("inset"),H=Ye("margin"),C=Ye("opacity"),w=Ye("padding"),P=Ye("saturate"),D=Ye("scale"),O=Ye("sepia"),j=Ye("skew"),L=Ye("space"),T=Ye("translate"),X=()=>["auto","contain","none"],M=()=>["auto","hidden","clip","visible","scroll"],W=()=>["auto",me,e],N=()=>[me,e],q=()=>["",Zr,fn],J=()=>["auto",Sn,me],ee=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],K=()=>["solid","dashed","dotted","double","none"],ne=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"],Q=()=>["start","end","center","between","around","evenly","stretch"],Y=()=>["","0",me],_=()=>["auto","avoid","all","avoid-page","page","left","right","column"],le=()=>[Sn,ho],ve=()=>[Sn,me];return{cacheSize:500,separator:":",theme:{colors:[aa],spacing:[Zr,fn],blur:["none","",pn,me],brightness:le(),borderColor:[n],borderRadius:["none","","full",pn,me],borderSpacing:N(),borderWidth:q(),contrast:le(),grayscale:Y(),hueRotate:ve(),invert:Y(),gap:N(),gradientColorStops:[n],gradientColorStopPositions:[Gg,fn],inset:W(),margin:W(),opacity:le(),padding:N(),saturate:le(),scale:le(),sepia:Y(),skew:ve(),space:N(),translate:N()},classGroups:{aspect:[{aspect:["auto","square","video",me]}],container:["container"],columns:[{columns:[pn]}],"break-after":[{"break-after":_()}],"break-before":[{"break-before":_()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...ee(),me]}],overflow:[{overflow:M()}],"overflow-x":[{"overflow-x":M()}],"overflow-y":[{"overflow-y":M()}],overscroll:[{overscroll:X()}],"overscroll-x":[{"overscroll-x":X()}],"overscroll-y":[{"overscroll-y":X()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[x]}],"inset-x":[{"inset-x":[x]}],"inset-y":[{"inset-y":[x]}],start:[{start:[x]}],end:[{end:[x]}],top:[{top:[x]}],right:[{right:[x]}],bottom:[{bottom:[x]}],left:[{left:[x]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",ia,me]}],basis:[{basis:W()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",me]}],grow:[{grow:Y()}],shrink:[{shrink:Y()}],order:[{order:["first","last","none",ia,me]}],"grid-cols":[{"grid-cols":[aa]}],"col-start-end":[{col:["auto",{span:["full",ia,me]},me]}],"col-start":[{"col-start":J()}],"col-end":[{"col-end":J()}],"grid-rows":[{"grid-rows":[aa]}],"row-start-end":[{row:["auto",{span:[ia,me]},me]}],"row-start":[{"row-start":J()}],"row-end":[{"row-end":J()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",me]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",me]}],gap:[{gap:[b]}],"gap-x":[{"gap-x":[b]}],"gap-y":[{"gap-y":[b]}],"justify-content":[{justify:["normal",...Q()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...Q(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...Q(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[w]}],px:[{px:[w]}],py:[{py:[w]}],ps:[{ps:[w]}],pe:[{pe:[w]}],pt:[{pt:[w]}],pr:[{pr:[w]}],pb:[{pb:[w]}],pl:[{pl:[w]}],m:[{m:[H]}],mx:[{mx:[H]}],my:[{my:[H]}],ms:[{ms:[H]}],me:[{me:[H]}],mt:[{mt:[H]}],mr:[{mr:[H]}],mb:[{mb:[H]}],ml:[{ml:[H]}],"space-x":[{"space-x":[L]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[L]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",me,e]}],"min-w":[{"min-w":[me,e,"min","max","fit"]}],"max-w":[{"max-w":[me,e,"none","full","min","max","fit","prose",{screen:[pn]},pn]}],h:[{h:[me,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[me,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[me,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[me,e,"auto","min","max","fit"]}],"font-size":[{text:["base",pn,fn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ho]}],"font-family":[{font:[aa]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",me]}],"line-clamp":[{"line-clamp":["none",Sn,ho]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Zr,me]}],"list-image":[{"list-image":["none",me]}],"list-style-type":[{list:["none","disc","decimal",me]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[n]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[n]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...K(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Zr,fn]}],"underline-offset":[{"underline-offset":["auto",Zr,me]}],"text-decoration-color":[{decoration:[n]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:N()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",me]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",me]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[C]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...ee(),Vg]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",qg]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Ug]}],"bg-color":[{bg:[n]}],"gradient-from-pos":[{from:[k]}],"gradient-via-pos":[{via:[k]}],"gradient-to-pos":[{to:[k]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[u]}],"border-w-x":[{"border-x":[u]}],"border-w-y":[{"border-y":[u]}],"border-w-s":[{"border-s":[u]}],"border-w-e":[{"border-e":[u]}],"border-w-t":[{"border-t":[u]}],"border-w-r":[{"border-r":[u]}],"border-w-b":[{"border-b":[u]}],"border-w-l":[{"border-l":[u]}],"border-opacity":[{"border-opacity":[C]}],"border-style":[{border:[...K(),"hidden"]}],"divide-x":[{"divide-x":[u]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[u]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[C]}],"divide-style":[{divide:K()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...K()]}],"outline-offset":[{"outline-offset":[Zr,me]}],"outline-w":[{outline:[Zr,fn]}],"outline-color":[{outline:[n]}],"ring-w":[{ring:q()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[n]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[Zr,fn]}],"ring-offset-color":[{"ring-offset":[n]}],shadow:[{shadow:["","inner","none",pn,Kg]}],"shadow-color":[{shadow:[aa]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":ne()}],"bg-blend":[{"bg-blend":ne()}],filter:[{filter:["","none"]}],blur:[{blur:[t]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",pn,me]}],grayscale:[{grayscale:[f]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[h]}],saturate:[{saturate:[P]}],sepia:[{sepia:[O]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[t]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[f]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[h]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[P]}],"backdrop-sepia":[{"backdrop-sepia":[O]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",me]}],duration:[{duration:ve()}],ease:[{ease:["linear","in","out","in-out",me]}],delay:[{delay:ve()}],animate:[{animate:["none","spin","ping","pulse","bounce",me]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[D]}],"scale-x":[{"scale-x":[D]}],"scale-y":[{"scale-y":[D]}],rotate:[{rotate:[ia,me]}],"translate-x":[{"translate-x":[T]}],"translate-y":[{"translate-y":[T]}],"skew-x":[{"skew-x":[j]}],"skew-y":[{"skew-y":[j]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",me]}],accent:[{accent:["auto",n]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",me]}],"caret-color":[{caret:[n]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":N()}],"scroll-mx":[{"scroll-mx":N()}],"scroll-my":[{"scroll-my":N()}],"scroll-ms":[{"scroll-ms":N()}],"scroll-me":[{"scroll-me":N()}],"scroll-mt":[{"scroll-mt":N()}],"scroll-mr":[{"scroll-mr":N()}],"scroll-mb":[{"scroll-mb":N()}],"scroll-ml":[{"scroll-ml":N()}],"scroll-p":[{"scroll-p":N()}],"scroll-px":[{"scroll-px":N()}],"scroll-py":[{"scroll-py":N()}],"scroll-ps":[{"scroll-ps":N()}],"scroll-pe":[{"scroll-pe":N()}],"scroll-pt":[{"scroll-pt":N()}],"scroll-pr":[{"scroll-pr":N()}],"scroll-pb":[{"scroll-pb":N()}],"scroll-pl":[{"scroll-pl":N()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",me]}],fill:[{fill:[n,"none"]}],"stroke-w":[{stroke:[Zr,fn,ho]}],stroke:[{stroke:[n,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}const r3=Sg(t3);function xe(...n){return r3(zg(n))}const n3={shopify:{bikeBrands:"bike/brands",bikeModels:"bike/models",framesSeries:"bike/frameSeries",bikeSpecs:"bike/bikeSpecBikes",bikeSpecYears:"bike/bikeSpecYears",bikeSpecSizes:"bike/bikeSpecSizes",bikeBrandProductCategories:"bike/bikeBrandProductCategories",checkSku:"compatibility/checkSku",checkSkus:"compatibility/checkSkus",checkSkusWithResults:"compatibility/checkSkusWithResults",bikeBom:"workshop/bikeBom",customBike:"workshop/addCustomBike",addComponent:"workshop/addComponent",findProducts:"workshop/findProducts",removeComponent:"workshop/removeComponent",revertComponent:"workshop/revertComponent",saveCustomBike:"workshop/saveCustomBike",updateCustomBike:"workshop/updateCustomBike",updateCustomBikeName:"workshop/updateCustomBikeName"},bikematrix:{bikeBrands:"GetBikeBrands",bikeModels:"GetBikeModels",framesSeries:"GetBikeFrameSeries",bikeSpecs:"GetBikeSpecBikes",bikeSpecYears:"GetBikeSpecYears",bikeSpecSizes:"GetBikeSpecSizes",bikeBrandProductCategories:"GetBikeBrandProductCategories",checkSku:"Compatibility_CheckSku",checkSkus:"Compatibility_CheckSkus",checkSkusWithResults:"Compatibility_CheckSkusWithResults",bikeBom:"GetBikeBillOfMaterials",customBike:"AddCustomBike",addComponent:"AddComponent",findProducts:"FindProducts",removeComponent:"RemoveComponent",revertComponent:"RevertComponent",saveCustomBike:"SaveCustomBike",updateCustomBike:"UpdateCustomBike",updateCustomBikeName:"UpdateCustomBikeName"}};class Ht{constructor(e,t,r,i){this._apiUrl=i?window.location.origin+"/apps/proxy/api/":e,this._apiKey=t??"",this._apiToken=r??"",this._apiType=i?"shopify":"bikematrix"}getEndpoint(e){return n3[this._apiType][e]}async getBikeBrands(){const e=this.getEndpoint("bikeBrands"),t=await this.makeRequest(e);return t.success?t.data:(console.error(t.error),[])}async getBikeModels(e){if(!e)return console.log("No bike brand selected."),[];const t=this.getEndpoint("bikeModels"),r=await this.makeRequest(t,{params:{bikeBrandId:e}});return r.success?r.data:(console.error(r.error),[])}async getBikeFrameSeries(e){if(!e)return console.log("No bike model selected."),[];const t=this.getEndpoint("framesSeries"),r=await this.makeRequest(t,{params:{bikeModelId:e}});return r.success?r.data:(console.error(r.error),[])}async getBikeSpecs(e){if(!e)return console.log("No bike frame series selected."),[];const t=this.getEndpoint("bikeSpecs"),r=await this.makeRequest(t,{params:{bikeModelSpecId:e}});return r.success?r.data:(console.error(r.error),[])}async getYears(e){if(!e)return console.log("No bike frame series selected."),[];const t=this.getEndpoint("bikeSpecYears"),r=await this.makeRequest(t,{params:{bikeModelSpecId:e}});return r.success?r.data:(console.error(r.error),[])}async getFrameSizes(e,t,r){if(!e||!t)return console.log("No bike frame series or bike spec selected."),[];const i=this.getEndpoint("bikeSpecSizes"),o=await this.makeRequest(i,{params:{bikeModelSpecId:e,bikeSpec:t,year:r}});return o.success?o.data:(console.error(o.error),[])}async getBikes(e,t,r){if(e&&(t||r)){const i=this.getEndpoint("bikeSpecs"),o=await this.makeRequest(i,{params:{bikeModelSpecId:e,bikeSpec:t,year:r}});return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike frame series and bike spec or year selected."),[]}async getBrandProductCategories(e){if(e){const t=this.getEndpoint("bikeBrandProductCategories"),r=await this.makeRequest(t,{params:{bikeBrandId:e}});return r.success?{data:r.data,success:!0}:(console.error(r.error),{data:[],success:!1,error:r.error})}else return{success:!1,error:"No brand selected"}}async checkSkuCompatibility(e,t,r){if(e&&t){const i=this.getEndpoint("checkSku")+`/${e}/${t}/${r}`,o=await this.makeRequest(i);return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike key and sku passed."),[]}async checkSkusCompatibility(e,t,r){if(e&&t){const i=this.getEndpoint("checkSkus")+`/${e}/${t}/${r}`,o=await this.makeRequest(i);return o.success?o.data:(console.error(o.error),[])}else return console.log("No bike key and list of skus passed."),[]}async checkSkusCompatibilityWithResults(e,t,r,i={}){if(e&&t){const o=this.getEndpoint("checkSkusWithResults")+`/${e}/${r}`,l=await this.makeRequest(o,{body:JSON.stringify(t),method:"POST",headers:{"Content-Type":"application/json"},...i});return l.success?{data:l.data,success:l.success}:{success:l.success,error:"error_compatiblelist"}}else return console.log("No bike key and list of skus passed."),[]}async getActiveSubscription(e){if(this._apiType==="shopify"){e({activeSubscription:!0});return}var t="activeSubscription";const r=await this.makeRequest(t);if(!r.success){console.log(`getActiveSubscription Error: ${r.error}`);return}e(r.data)}async getBikeBom(e){if(!e)return{success:!1,error:"error_generic getBikeBom"};const t=this.getEndpoint("bikeBom"),r=await this.makeRequest(t,{params:{bikeKey:e}});return r.success?{data:r.data,success:r.success}:{success:r.success,error:"error_get_bike_bom"}}async addCustomBike(e){if(!e)return{success:!1,error:"error_generic addCustomBike"};const t=this.getEndpoint("customBike"),r=await this.makeRequest(t,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e}});return r.success?{data:r.data,success:r.success}:(console.error(r.error),{success:r.success,error:"error_add_custom_bike"})}async findProducts(e,t){if(!e)return{success:!1,error:"error_generic findProducts"};const r=this.getEndpoint("findProducts"),i=await this.makeRequest(r,{params:{search:e,productCategoryId:t,recordCount:20}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_find_products"})}async addComponent(e,t,r,i){if(!e||!t||!r||!i)return{success:!1,error:"error_generic addComponent"};const o=this.getEndpoint("addComponent"),l=await this.makeRequest(o,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,productId:r,bikeFieldName:i}});return l.success?{data:l.data,success:l.success}:(console.error(l.error),{success:l.success,error:"error_add_component"})}async removeComponent(e,t,r){if(!e||!t||!r)return{success:!1,error:"error_generic removeComponent"};const i=this.getEndpoint("removeComponent"),o=await this.makeRequest(i,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,bikeFieldName:r}});return o.success?{data:o.data,success:o.success}:(console.error(o.error),{success:o.success,error:"error_remove_component"})}async revertComponent(e,t,r){if(!e||!t||!r)return{success:!1,error:"error_generic revertComponent"};const i=this.getEndpoint("revertComponent"),o=await this.makeRequest(i,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t,bikeFieldName:r}});return o.success?{data:o.data,success:o.success}:(console.error(o.error),{success:o.success,error:"error_revert_component"})}async saveCustomBike(e,t){if(!e||!t)return{success:!1,error:"error_generic saveCustomBike"};const r=this.getEndpoint("saveCustomBike"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,email:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_save_custom_bike"})}async updateCustomBike(e,t){if(!e||!t)return{success:!1,error:"error_generic saveCustomBike"};const r=this.getEndpoint("updateCustomBike"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,productCategoryId:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_update_custom_bike"})}async updateCustomBikeName(e,t){if(!e||!t)return{success:!1,error:"error_generic updateCustomBikeName"};const r=this.getEndpoint("updateCustomBikeName"),i=await this.makeRequest(r,{method:"POST",headers:{"Content-Type":"application/json"},params:{bikeKey:e,name:t}});return i.success?{data:i.data,success:i.success}:(console.error(i.error),{success:i.success,error:"error_update_custom_bike_name"})}async makeRequest(e,t={}){const r=new URL(e,this._apiUrl),i={"Cache-Control":"no-cache",...this._apiKey&&{"bm-subscription-key":this._apiKey},...this._apiToken&&{"bm-app-token":this._apiToken}};typeof t.params=="object"&&(Object.keys(t.params).forEach(l=>{t.params[l]&&r.searchParams.set(l,t.params[l])}),delete t.params);let o;try{const l={...i,...t.headers||{}},u={...t,headers:l};t.signal&&(u.signal=t.signal);const c=await fetch(r,u),f=await c.json().catch(()=>{throw new Error("Request failed: "+(c.statusText||"Status"+c.status))});f.status===400?o={success:!1,data:f}:o={success:!0,data:f}}catch(l){o={success:!1,error:l.message}}return o}}async function ef(n){var b;const{categories:e,collections:t,apiUrl:r,apiKey:i,apiToken:o,isShopify:l,logLevel:u}=window.BikeMatrix.getConfig(),c=JSON.parse(sessionStorage.getItem("bm_categories")||"null"),f=JSON.parse(localStorage.getItem(ol)||"null"),p=new Ht(r,i,o,l);let h=[];if(u==="verbose"&&console.log("useCompatibleCollections sessionCollections",c),!c||!(c!=null&&c.collections)||!(c!=null&&c.collections.length)||(c==null?void 0:c.key)!==(f==null?void 0:f.key)){u==="verbose"&&console.log("useCompatibleCollections fetching new collections");const m=await p.getBrandProductCategories(n);u==="verbose"&&console.log("useCompatibleCollections bikeBrandProductCategories",m),((b=m.data)==null?void 0:b.length)>0&&(h=e.filter(x=>{var H;return!!x.collection&&((H=m==null?void 0:m.data)==null?void 0:H.some(C=>C.product_Category.toLowerCase()===x.title.toLowerCase()))}).map(x=>t.filter(C=>x.collection.split(",").map(w=>w.trim().toLowerCase()).includes(C.title.toLowerCase())).map(C=>({title:C.title,text_id:x.text_id,handle:C.handle,url:C.url}))).flat(),h=h==null?void 0:h.filter((x,H,C)=>H===C.findIndex(w=>w.title===x.title&&w.text_id===x.text_id&&w.handle===x.handle&&w.url===x.url))),sessionStorage.setItem("bm_categories",JSON.stringify({key:f==null?void 0:f.key,collections:h})),u==="verbose"&&console.log("useCompatibleCollections fetched collections",h)}else u==="verbose"&&console.log("useCompatibleCollections using session collections"),h=c.collections;return h}const tf=class $a{constructor(){this.initialized=!1,this.currentBike=null,this.activeSubscription=null,this.components=[],this.config=Gd}async initialize(e){this.components=[],this.initialized&&this.cleanup(),e&&(this.config={...this.config,...e}),this.initializeConfig(),this.service=new Ht(this.config.apiUrl,this.config.apiKey,this.config.apiToken,this.config.isShopify),this.initializeActiveSubscription(),localStorage.bm_currentBike&&(this.currentBike=JSON.parse(localStorage.bm_currentBike)),this.setupEventListeners(),this.registerComponents(),this.initialized=!0,al.value=!0;const t=new Event("BM:Initialized");document.dispatchEvent(t),this.config.logLevel==="verbose"&&(console.log("BikeMatrix WebComponent Version: 1.1.41"),console.log("BikeMatrixCore initialized"))}static getInstance(){return $a.instance||($a.instance=new $a),$a.instance}registerComponents(){const e=["bikematrix-bikeselector","bikematrix-productresult","bikematrix-collectionresult","bikematrix-compatibilitylabel","bikematrix-compatiblelist","bikematrix-bikeselectorbanner","bikematrix-variantselector"];this.components=[],e.forEach(t=>{const r=document.getElementsByTagName(t);Array.from(r).forEach(i=>{this.components.push(i)})}),this.config.logLevel==="verbose"&&console.log(`Registered ${this.components.length} components`)}resetComponents(){this.components.forEach(e=>{var t;try{const r=e.cloneNode(!1);e.querySelectorAll("template").forEach(o=>{r.appendChild(o.cloneNode(!0))}),(t=e.parentNode)==null||t.replaceChild(r,e)}catch{console.error("Error resetting component",e)}})}isInitialized(){return this.initialized}updateConfig(e){this.config={...this.config,...e},this.reload(!1)}cleanup(){this.removeEventListeners(),xg()}async destroy(){this.cleanup(),this.service=null,this.currentBike=null,this.activeSubscription=null,this.config={...Gd},this.initialized=!1,al.value=!1,this.resetComponents()}refresh(){this.ChangeBike()}reset(){this.destroy(),this.initialize()}reload(e=!0){e&&this.initializeConfig(),this.refresh(),this.registerComponents(),this.resetComponents()}initializeConfig(){const e=document.querySelectorAll('script[type="application/json"][data-bikematrix-config]'),t=JSON.parse(sessionStorage.getItem("bm_diagnostics"));e.forEach(r=>{if(r!=null&&r.textContent)try{this.config={...this.config,...JSON.parse(r.textContent)}}catch{console.error("Invalid BikeMatrix configuration"),console.log("configScript ",r.textContent)}}),t!=null&&t.includes("verbose")&&(this.config.logLevel="verbose"),t!=null&&t.includes("virtualWorkshop")&&(this.config.virtualWorkshop=!0),t!=null&&t.includes("subscribtion")&&(this.activeSubscription=!0),t!=null&&t.includes("all")&&(this.config.logLevel="verbose",this.config.virtualWorkshop=!0,this.activeSubscription=!0),this.config.logLevel==="verbose"&&console.log("initializeConfig ",JSON.stringify(this.config,null,2))}initializeActiveSubscription(){const e=sessionStorage.getItem("bm_activeSubscription");if(!this.config.isShopify){this.activeSubscription=!0;return}this.activeSubscription=this.config.designMode||e==="true",e||this.service.getActiveSubscription(this.updateActiveSubscription.bind(this))}setupEventListeners(){document.addEventListener("BikeMatrix:RefreshCompatibleSkus",e=>{this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}),document.addEventListener("on:facet-filters:updated",this.handleRefreshCompatibleSkus.bind(this)),document.addEventListener("BikeChanged",this.handleBikeChanged.bind(this))}removeEventListeners(){document.removeEventListener("BikeMatrix:RefreshCompatibleSkus",this.handleRefreshCompatibleSkus),document.removeEventListener("on:facet-filters:updated",this.handleRefreshCompatibleSkus),document.removeEventListener("BikeChanged",this.handleBikeChanged)}async handleRefreshCompatibleSkus(e){this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}async handleBikeChanged(e){this.config.logLevel==="verbose"&&console.log("Listener BikeChanged..."),this.ChangeBike()}getConfig(){return this.config}getActiveSubscription(){return this.activeSubscription}getCurrentBike(){return this.currentBike}updateSku(e){const t=document.querySelector("bikematrix-productresult[data-sku]"),r=document.querySelector("bikematrix-variantselector[data-sku]");t&&t.setAttribute("data-sku",e),r&&r.setAttribute("data-sku",e),this.config.sku=e}ResetSelectedBikeIndicator(){var e,t;this.currentBike===null?(e=window.bm_selectBikeButton)==null||e.classList.remove("show-selected"):(t=window.bm_selectBikeButton)==null||t.classList.add("show-selected")}ChangeBike(){this.config.logLevel==="verbose"&&console.log("ChangeBike() Method Called"),!(Zt.value===!0||rr.value===!0)&&(Zt.value=!0,rr.value=!0,pi.value=[],hi.value=[],this.config.logLevel==="verbose"&&console.log("ChangeBike updateBikeSignal..."),this.updateBikeSignal().then(()=>{this.config.logLevel==="verbose"&&console.log("Bike Signal Updated: ",JSON.stringify(Ae.value,null,2)),this.ResetSelectedBikeIndicator(),this.RefreshCompatibleSkus().then(()=>{document.dispatchEvent(new Event("RefreshCompatibility",{bubbles:!0,composed:!0}))})}))}async RefreshCompatibleSkus(){var t,r;const e=`${(t=Ae.value)==null?void 0:t.key}:${this.config.currentCollectionHandle}:${Pg}`;switch(this.config.pageType){case"collection":const i=!!Ae.value&&((r=Ae.value.compatibleCollections)==null?void 0:r.find(o=>o.handle===this.config.currentCollectionHandle));this.config.logLevel==="verbose"&&console.log("Refresh Compatible SKUs. hasCompatibleCollection: ",i),i?(await this.RefreshCollectionPageSkus(e),await this.RefreshCollectionListSkus(e)):(Zt.value=!1,rr.value=!1);break;case"search":case"index":Zt.value=!1,this.config.pageType==="index"&&this.config.showHomePageCollection||this.config.pageType==="search"&&this.config.showSearchPageCollection?await this.RefreshCollectionPageSkus(e):rr.value=!1;break;default:Zt.value=!1,rr.value=!1;break}}async RefreshCollectionPageSkus(e){var l,u,c;let t=document.getElementsByTagName("bikematrix-collectionresult"),i=Array.from(t).map(f=>{const p=this.config.skuField==="barcode"?f.getAttribute("data-product-barcodes"):this.config.skuField==="metafield"?f.getAttribute("data-product-metafields"):f.getAttribute("data-product-skus")||"";return p==null?void 0:p.split(",").filter(h=>!!h)}).flat();this.config.logLevel==="verbose"&&console.log("Refresh Collection Page SKUs. SKUs: ",JSON.stringify(i),null,2);var o=((l=ci())==null?void 0:l.language)||"en-GB";if(i){const f=await this.service.checkSkusCompatibilityWithResults((u=Ae.value)==null?void 0:u.key,i,o);(c=f.data)!=null&&c.error?(fo.value=!0,this.config.logLevel==="verbose"&&console.log("Compatible List Error: ",f.data.errors)):hi.value=f.data}else hi.value=[];rr.value=!1}async RefreshCollectionListSkus(e){var i,o,l;var t=JSON.parse(sessionStorage.getItem(e));if(t)this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from Session: ",JSON.stringify(t),null,2),pi.value=t;else{const u=Object.values(this.config.products||{}).map(h=>h.skus).flat();this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from API. SKUs: ",JSON.stringify(u),null,2);var r=((i=ci())==null?void 0:i.language)||"en-GB";const c=new AbortController,f=c.signal,p=()=>c.abort();window.addEventListener("beforeunload",p);try{if(!((o=Ae.value)!=null&&o.key))throw new Error("BikeSignal key is undefined");const h=await this.service.checkSkusCompatibilityWithResults(Ae.value.key,u,r,{signal:f});if(this.config.logLevel==="verbose"&&console.log("Refresh Collection SKUs from API. SKUs: ",JSON.stringify(h)),f.aborted){this.config.logLevel==="verbose"&&console.log("function RefreshCompatibleSkus() operation aborted");return}(l=h.data)!=null&&l.errors?(fo.value=!0,this.config.logLevel==="verbose"&&console.log("Compatible List Error: ",h.data.errors)):(sessionStorage.setItem(e,JSON.stringify(h.data)),pi.value=h.data)}catch(h){h.name==="AbortError"?console.log("function RefreshCompatibleSkus() fetch aborted"):console.error("function RefreshCompatibleSkus() fetch error",h)}finally{window.removeEventListener("beforeunload",p)}}Zt.value=!1}updateActiveSubscription(e){const t=!!(e!=null&&e.activeSubscription);sessionStorage.setItem("bm_activeSubscription",JSON.stringify(t)),this.activeSubscription=t}async updateBikeSignal(){const e=localStorage.getItem(ol)||"null",t=JSON.parse(e);if(this.currentBike=t,t==null){Ae.value=null;return}const r=await ef(t==null?void 0:t.brandId);t.compatibleCollections=r,Ae.value=t,this.config.logLevel==="verbose"&&console.log("Bike Changed: ",JSON.stringify(Ae.value,null,2))}};tf.instance=null;let i3=tf;const oa=n=>te("svg",{width:10,height:10,viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M1.53553 8.60658L5.07107 5.07104M5.07107 5.07104L8.6066 1.53551M5.07107 5.07104L8.6066 8.60658M5.07107 5.07104L1.53553 1.53551",stroke:"currentColor",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"}));var a3=0;function g(n,e,t,r,i,o){var l,u,c={};for(u in e)u=="ref"?l=e[u]:c[u]=e[u];var f={type:n,props:c,key:t,ref:l,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:--a3,__i:-1,__u:0,__source:i,__self:o};if(typeof n=="function"&&(l=n.defaultProps))for(u in l)c[u]===void 0&&(c[u]=l[u]);return fe.vnode&&fe.vnode(f),f}function gi(){document.dispatchEvent(new Event("BmToggleModal"))}function o3({children:n}){return se(()=>{var o;const e=document.body,t=document.getElementById("bm_selectBikeButton"),r=(o=document.getElementsByTagName("bikematrix-bikeselector"))==null?void 0:o[0],i=l=>{l.preventDefault(),e.classList.toggle("bm-modal-active"),r.classList.toggle("active")};return document.addEventListener("BmToggleModal",i),t==null||t.addEventListener("click",i),()=>{document.removeEventListener("BmToggleModal",i),t==null||t.removeEventListener("click",i)}},[]),g(ie,{children:[g("div",{onClick:()=>{gi()},class:xe("overlay","fixed cursor-pointer inset-0 z-[2147483645] bg-black/40 transition-all duration-500 sm:duration-200")}),g("div",{className:xe("modal","fixed pointer-events-none inset-0 mx-auto justify-end z-[2147483646] flex flex-col items-center outline-none transition-all duration-500 sm:duration-200 ease-in-out","sm:justify-center"),children:g("div",{className:"flex sm:px-2 pointer-events-auto max-sm:max-h-[96%] sm:max-h-[90%] max-sm:h-[89vh] max-w-lg sm:max-w-[640px] flex-col items-center max-sm:flex-1 w-full bg-white rounded-t-3xl sm:rounded-xl shadow-[0px_-2px_10px_0px_rgba(0,0,0,0.04),0px_0px_0px_1px_rgba(0,0,0,0.06)]",children:[g("div",{className:"sm:hidden mx-auto mt-4 h-[6px] w-[100px] rounded-full bg-gray-400/50",onClick:gi}),g("div",{className:"sm:hidden h-[10px]"}),g("div",{className:"relative flex flex-col w-full sm:h-full max-sm:flex-none max-sm:grow",children:g("div",{class:"modal-content max-sm:absolute sm:h-full max-sm:inset-0 overflow-x-hidden overflow-y-auto px-8 sm:px-6",children:n})})]})})]})}const vr=n=>te("svg",{width:7,height:12,viewBox:"0 0 7 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M1 11L6 6L1 1",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})),s3=n=>te("svg",{width:31,height:31,viewBox:"0 0 31 31",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("circle",{cx:15.5,cy:15.5,r:15.5,fill:"#030712"}),te("path",{d:"M10.1974 17.1317L13.9955 20.4461L20.8639 10.8909",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})),l3=n=>te("svg",{width:31,height:31,viewBox:"0 0 31 31",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("g",{clipPath:"url(#clip0_64_2)"},te("path",{d:"M30.5 15.5C30.5 23.7843 23.7843 30.5 15.5 30.5C7.21573 30.5 0.5 23.7843 0.5 15.5C0.5 7.21573 7.21573 0.5 15.5 0.5C23.7843 0.5 30.5 7.21573 30.5 15.5Z",fill:"white",stroke:"#D1D5DB"})),te("path",{d:"M23.983 11.132C23.9699 10.9806 23.8699 10.8506 23.727 10.7988C23.5837 10.7466 23.4233 10.7822 23.3155 10.8894L21.1098 13.0866L18.6647 12.3153L17.8905 9.87937L20.0961 7.68201C20.2041 7.57458 20.2393 7.41475 20.1873 7.27224C20.1348 7.12945 20.0046 7.02999 19.8524 7.01688C18.5129 6.9019 17.2004 7.37836 16.2514 8.32387C14.9518 9.61873 14.6076 11.5096 15.217 13.1213C15.1504 13.1773 15.0847 13.2365 15.0199 13.3004L7.65736 20.2216C7.65476 20.2241 7.6522 20.2268 7.64939 20.2293C6.78354 21.092 6.78354 22.4955 7.64939 23.3583C8.51539 24.2209 9.91396 24.2104 10.7797 23.3477C10.7834 23.3443 10.7868 23.3408 10.7902 23.3369L17.677 15.945C17.7398 15.8822 17.798 15.8165 17.853 15.749C19.4713 16.3573 21.3705 16.0152 22.6713 14.7195C23.62 13.7739 24.0986 12.4663 23.983 11.132ZM9.67019 22.4264C9.35113 22.7442 8.83439 22.744 8.51536 22.4264C8.19644 22.1089 8.19644 21.5937 8.51536 21.2761C8.83439 20.9585 9.35113 20.9585 9.67019 21.2761C9.98911 21.5937 9.98911 22.1089 9.67019 22.4264Z",fill:"black"}),te("defs",null,te("clipPath",{id:"clip0_64_2"},te("rect",{width:31,height:31,fill:"white"})))),u3=n=>te("svg",{width:31,height:31,viewBox:"0 0 46 46",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M2 24.0437V22.6518C4.30404 21.9559 5.82929 20.347 6.17596 18.244C6.45967 16.523 5.87584 14.7802 4.66788 13.505L5.50401 12.1672C6.3441 12.2632 7.12499 12.2938 7.83019 12.2273C8.91308 12.1253 10.0603 11.7686 10.8965 10.814C11.7162 9.87828 11.9364 8.70751 11.9455 7.65019C11.9509 7.01984 11.882 6.33439 11.7615 5.60532L13.1089 4.93163C14.6862 6.27858 16.5967 7.00972 18.5085 6.50659C20.496 5.98355 21.7104 4.35171 22.2287 2.32023L23.4959 2.17943C23.7105 2.84427 23.9686 3.45839 24.2803 4.0055C24.8609 5.02453 25.7009 5.93317 26.8959 6.37534C28.1054 6.8229 29.35 6.6716 30.4872 6.21488C31.2478 5.9094 32.0092 5.4502 32.771 4.87155L33.84 5.40607C33.3102 7.17682 33.6407 8.97473 34.9205 10.3525C36.2854 11.8219 38.3837 12.4206 40.6053 12.1884L41.4091 13.3137C40.1484 14.904 39.5422 16.7943 40.0082 18.6621C40.4975 20.623 42.0098 21.9631 44 22.6091V23.6937C42.0295 24.646 40.407 25.9295 39.9934 27.9032C39.7449 29.089 40.0083 30.2272 40.4663 31.2395C40.7549 31.8775 41.1444 32.5183 41.6038 33.1622L41.0881 34.0648C39.1096 33.5569 37.1545 33.7409 35.7252 35.1442C34.3293 36.5148 34.0136 38.5186 34.2755 40.5318L32.7931 41.4583C31.191 40.0523 29.3504 39.2822 27.3831 40.0414C26.2841 40.4655 25.451 41.2846 24.816 42.1501C24.4114 42.7016 24.0463 43.3278 23.7127 44H22.6585C22.1786 42.2318 21.2165 40.6691 19.4091 40.0247C17.4936 39.3418 15.3888 40.0023 13.3765 41.2022L11.9877 40.5078C12.4255 38.6858 12.158 36.865 10.7918 35.5311C9.4171 34.1889 7.44044 33.8741 5.42929 34.2133L4.6584 32.9799C6.03869 31.6871 6.93069 30.0087 6.40539 28.071C6.07607 26.8563 5.24467 25.9088 4.25062 25.2068C3.60737 24.7526 2.85005 24.3664 2 24.0437Z",stroke:"black",strokeWidth:4}),te("circle",{cx:23,cy:23,r:12,stroke:"black",strokeWidth:4}),te("path",{d:"M23 39.75C32.2508 39.75 39.75 32.2508 39.75 23C39.75 13.7492 32.2508 6.25 23 6.25C13.7492 6.25 6.25 13.7492 6.25 23C6.25 32.2508 13.7492 39.75 23 39.75Z",stroke:"black",strokeWidth:3.5})),c3=`.shared-icon{background-color:#fba157;padding:5px 10px;border-radius:8px;font-size:12px;display:flex;justify-content:center;align-items:center;color:#fff}
|
|
2
2
|
`,rf=({text:n})=>g(ie,{children:[g("style",{type:"text/css",children:c3}),g("div",{className:"shared-icon",children:g("p",{className:"text",children:n||"Shared with you"})})]});function gr({spanner:n,selected:e,settings:t,simple:r,bike:i,compact:o,readOnly:l,onClick:u,shared:c,custom:f,noSymbol:p,...h}){var j;const b=(j=i.images)!=null&&j.length?i.images:[In("bike.png")],m=be(null),[k,x]=$(0),H=be(null);se(()=>{const L=m==null?void 0:m.current;if(L){var T=new IntersectionObserver(function(X){var M=X.reduce(function(W,N){return N.intersectionRatio>W.intersectionRatio?N:W});M.intersectionRatio>0&&x(Number(M.target.getAttribute("data-slide")))},{root:L,threshold:.8});return L.querySelectorAll("&>div").forEach(X=>{T.observe(X)}),()=>{T.disconnect()}}},[m]);function C(L){if(!m.current)return;const T=m.current.querySelectorAll("&>div")[L];m.current.scrollLeft=T.clientWidth*L}function w(){k!=0&&C(k-1)}function P(){k!=b.length-1&&C(k+1)}const D=(b==null?void 0:b.length)&&k!==b.length-1,O=(b==null?void 0:b.length)&&k!==0;return g("div",{class:xe("rounded-xl select-none border py-4 relative",e?"border-gray-950":"border-gray-300"),...h,onClick:L=>{if(H.current&&!H.current.contains(L.target))u(L);else{L.preventDefault();return}},children:[!r&&g("p",{class:"text-gray-950 px-4 text-base font-normal font-nunito leading-tight ",children:o?g(ie,{children:l?`${i.bike_Brand} ${i.year} ${i.spec}`:i?`${i.brand} ${i.year} ${i.bikeSpec} ${i.variant?i.variant:""}`:""}):g(ie,{children:l?i.bike_Name:i.name})}),g("div",{class:"relative mt-2",children:[g("div",{ref:m,class:xe("flex scroll-smooth snap-mandatory no-scrollbar h-32 snap-x space-x-2 relative overflow-x-auto","px-4"),"data-active-slide":k,children:[!l&&b.length&&b.map((L,T)=>g("div",{"data-slide":T,class:"w-full h-full snap-center flex items-center flex-none",children:g("img",{class:"max-w-full pointer-events-none mx-auto max-h-full h-auto w-auto",src:L,alt:L})},T)),l&&g("div",{class:"w-full h-full snap-center flex items-center flex-none",children:g("img",{class:"max-w-full pointer-events-none mx-auto max-h-full h-auto w-auto",src:`https://imagestore.bikematrix.io/${i.bike_Reference}/400-${i.bike_Thumbnail}`,alt:i.bike_Reference})})]}),g(ie,{children:[g("div",{onClick:w,class:xe("border !ml-0 bg-white absolute w-9 h-9 flex items-center justify-center left-4 top-1/2 -translate-y-1/2 rounded-xl border-gray-300",O?"":"hidden"),children:g(vr,{class:"h-3 text-gray-500 -rotate-180"})}),g("div",{onClick:P,class:xe("border !ml-0 bg-white absolute w-9 h-9 flex items-center justify-center right-4 top-1/2 -translate-y-1/2 rounded-xl border-gray-300",D?"":"hidden"),children:g(vr,{class:"h-3 text-gray-500 translate-x-px"})})]})]}),(b==null?void 0:b.length)>1&&g("div",{class:"space-x-2 flex items-center justify-center",children:b.map((L,T)=>g("div",{class:xe("rounded-xl w-2 h-2 transition-all duration-300",T==k?" bg-gray-950 scale-125":" bg-gray-200")},T))}),(c||i.isShared)&&g("div",{className:"absolute left-4 bottom-4",children:g(rf,{})}),(f||i.isCustom)&&g("div",{className:"absolute left-4 bottom-4",children:g(rf,{text:"Custom"})}),g("div",{className:"spanner_wrapper absolute right-4 bottom-14 h-fit w-fit",ref:H,children:n&&e&&g(l3,{class:"cursor-pointer",onClick:L=>{L.preventDefault(),!(i!=null&&i.isCustom)&&!(i!=null&&i.isShared)?De("/workshop"):i!=null&&i.isShared?De("/read-only"):De("/bom")}})}),e&&!t?g(s3,{class:"absolute right-4 bottom-4 cursor-pointer"}):t?g(u3,{class:"absolute right-4 bottom-4 cursor-pointer",onClick:()=>De("/settings")}):l?g("span",{}):p?g("span",{}):g(ie,{children:g("span",{class:"border absolute right-4 bottom-4 rounded-full h-8 w-8 border-gray-300 bg-white/75"})})]})}function nf(n,e){const t=()=>{try{const o=window.localStorage.getItem(n);return o?JSON.parse(o):e}catch(o){return console.error(o),e}},[r,i]=$(t);return se(()=>{try{if(!r)window.localStorage.removeItem(n);else{const o=JSON.stringify(r);window.localStorage.setItem(n,o)}}catch(o){console.error(o)}},[n,r]),[r,i,t]}function d3(n,e){const t=()=>{try{const o=window.sessionStorage.getItem(n);return o?JSON.parse(o):e}catch(o){return console.error(o),e}},[r,i]=$(t);return se(()=>{try{if(!r)window.sessionStorage.removeItem(n);else{const o=JSON.stringify(r);window.sessionStorage.setItem(n,o)}}catch(o){console.error(o)}},[n,r]),[r,i,t]}const ul={brand:{options:[],value:null},model:{options:[],value:null},frameSeries:{options:[],value:null},year:{options:[],value:[]},bikeSpec:{options:[],value:null},frameSize:{options:[],value:null},options:[],value:{}},af=ea(void 0),f3=({children:n})=>{var ne;const e=window.BikeMatrix.getConfig(),[t,r]=nf(ol,null),[i,o]=nf("bm_lounge",[]),l=new Ht(e.apiUrl,e.apiKey,e.apiToken,e.isShopify),[u,c]=$(ul),f=be({}),[p,h]=$([]),[b,m]=$(!1),[k,x]=$(null);se(()=>{(async()=>{const Y=await ef(t==null?void 0:t.brandId);x(Y)})()},[t==null?void 0:t.brandId]);function H(Q){c(Y=>{var _;return{...Y,[Q]:{options:[],value:(_=ul[Q])==null?void 0:_.value}}})}function C(Q,Y){c(_=>(_[Q].value=Y,{..._}))}const w=()=>{c(Q=>{var Y;return{...ul,brand:{options:((Y=Q.brand)==null?void 0:Y.options)||[]}}})},P=Q=>{r({...Q}),o([...(i||[]).filter(Y=>!!Y.key&&Y.key!==Q.key),Q])},D=Q=>{(t==null?void 0:t.key)===Q&&r(null),o([...(i||[]).filter(Y=>!!Y.key&&Y.key!==Q)])},O=()=>{e.logLevel==="verbose"&&console.log("Dispatch BikeChanged..."),document.dispatchEvent(new Event("BikeChanged",{bubbles:!0,composed:!0}))},j=()=>{setTimeout(()=>{w(),De("/")},500)},L=async()=>{const Q=await l.getBikeBrands();sessionStorage.setItem("bm_brands",JSON.stringify(Q)),c(Y=>(Y.brand.options=Q.map(_=>({label:_.bike_Brand,value:_.bike_Brand_ID})),{...Y}))},T=async()=>l.getBikeModels(u.brand.value).then(Q=>{c(Y=>(Y.model.options=Q.map(_=>({label:_.model_Family,value:_.model_Family_ID})),{...Y}))}),X=async()=>l.getBikeFrameSeries(u.model.value).then(Q=>{c(Y=>{var le,ve;const _=[];return Y.frameSeries.options=Q.reduce((pe,Re)=>{const Ie={label:Re.model_Spec,value:Re.model_Spec_ID};return _.includes(Ie.value)||(_.push(Ie.value),pe.push(Ie)),pe},[]),((le=Y.frameSeries.options)==null?void 0:le.length)===1&&(Y.frameSeries.value=(ve=Y.frameSeries.options[0])==null?void 0:ve.value),{...Y}})}),M=async()=>l.getBikeSpecs(u.frameSeries.value).then(Q=>{const Y=[],_=[],le=[],ve=[];Q.forEach(pe=>{var Bt,$e;const Re=pe.year+"-"+pe.spec.replace(/[^0-9a-zA-Z]/g,"")+(pe.bike_Variant?"-"+pe.bike_Variant.replace(/[^0-9a-zA-Z]/g,""):""),Ie={label:pe.spec,value:pe.spec};if(Y.includes(Ie.value)||(Y.push(Ie.value),le.push(Ie)),!_.includes(Re)){_.push(Re);const Vt={_key:Re,key:pe.bike_Key,name:pe.bike_Name,variant:pe.bike_Variant,brand:pe.bike_Brand,brandId:pe.bike_Brand_ID,model:pe.model_Family,modelId:pe.model_Family_ID,frameSeries:pe.model_Spec,frameSeriesId:pe.model_Spec_ID,bikeSpec:pe.spec,year:pe.year,images:[pe.bike_Thumbnail,...((Bt=pe==null?void 0:pe.bike_Images)==null?void 0:Bt.split(","))||[]].filter(Jt=>!!Jt).map(Jt=>`https://imagestore.bikematrix.io/${pe.bike_Reference}/400-${Jt}`)},jt=Q.reduce((Jt,at)=>(at.year==pe.year&&at.spec===pe.spec&&at.model_Spec===pe.model_Spec&&at.bike_Variant===pe.bike_Variant&&Jt.push({key:at.bike_Key,name:at.bike_Name,variant:at.bike_Variant,sizeId:at.bike_Size_ID,size:at.bike_Size}),Jt),[]);($e=jt==null?void 0:jt.filter(Jt=>!!Jt.sizeId))!=null&&$e.length&&(Vt.sizes=jt),ve.push(Vt)}f.current[u.frameSeries.value]=Array.from(new Set([...f.current[u.frameSeries.value]||[],pe.year]))}),c(pe=>(pe.bikeSpec.options=le,{...pe})),h(ve)}),W=async()=>{c(Q=>{const Y=f.current[Q.frameSeries.value]||[];return Q.year.options=Y.map(_=>({label:_,value:_})),{...Q}})},N=async()=>{c(Q=>{var Y,_,le;if(Q.frameSize.options=(Y=u==null?void 0:u.value)!=null&&Y.sizes?u.value.sizes.filter(ve=>!!ve.size).map(ve=>({label:ve.size,value:ve.size})):[],((_=Q.frameSize.options)==null?void 0:_.length)===1){const ve=(le=Q.frameSize.options[0])==null?void 0:le.value;Q.frameSize.value=ve,Q.value.frameSize=ve}return{...Q}})};se(()=>(document.addEventListener("BmToggleModal",j),()=>{document.removeEventListener("BmToggleModal",j)}),[]);const[q,J]=d3("bm_diagnostics",[]),ee=()=>{const Y=new URLSearchParams(window.location.search).get("diagnostics");JSON.parse(sessionStorage.getItem("bm_diagnostics")).includes(Y)||J([...q,Y]),Y===null&&J([])};se(()=>{O(),ee()},[t]),se(()=>{sessionStorage.getItem("bm_brands")?c(Q=>(Q.brand.options=JSON.parse(sessionStorage.getItem("bm_brands")).map(Y=>({label:Y.bike_Brand,value:Y.bike_Brand_ID})),{...Q})):L()},[]),se(()=>{u.brand.value&&(H("model"),H("frameSeries"),T())},[u.brand.value]),se(()=>{u.model.value&&(H("frameSeries"),X())},[u.model.value]),se(()=>{u.frameSeries.value&&(H("bikeSpec"),H("year"),h([]),M().then(()=>{W()}))},[u.frameSeries.value]),se(()=>{u.value._key&&(H("frameSize"),N())},[(ne=u.value)==null?void 0:ne._key]),se(()=>{u.frameSize.value&&c(Q=>{var Y,_;return Q.value={...Q.value,...((_=(Y=Q==null?void 0:Q.value)==null?void 0:Y.sizes)==null?void 0:_.find(le=>u.frameSize.value==le.size))||{}},delete Q.value.sizes,Q})},[u.frameSize.value]);const K={bike:u,setBike:c,setBikeAttr:C,resetBike:w,results:p,loading:b,setLoading:m,compatibleCollections:k,currentBike:t,setCurrentBike:r,removeBike:D,saveBike:P,lounge:i};return g(af.Provider,{value:K,children:n})},At=()=>{const n=Gs(af);if(!n)throw new Error("useBikeState must be used within a BikeProvider");return n};function Yr(){const{t:n}=Le();return g(ie,{children:[g("p",{class:"text-gray-600 max-w-sm mx-auto mt-4 text-center font-normal text-xs",children:n("bikeselector_home_footer_message")}),g("a",{href:"https://bikematrix.io/landed-it",target:"_blank",class:"text-gray-950 block underline mb-4 font-bold mt-4 text-center text-xs",children:n("bikematrix_poweredby")})]})}const p3=n=>te("svg",{width:17,height:17,viewBox:"0 0 17 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("path",{d:"M16.983 4.13197C16.9699 3.98064 16.8699 3.85064 16.727 3.7988C16.5837 3.74665 16.4233 3.78215 16.3155 3.88937L14.1098 6.08655L11.6647 5.31527L10.8905 2.87937L13.0961 0.682011C13.2041 0.574581 13.2393 0.414746 13.1873 0.272238C13.1348 0.129446 13.0046 0.0299881 12.8524 0.0168782C11.5129 -0.0980992 10.2004 0.378357 9.25142 1.32387C7.95176 2.61873 7.60759 4.50961 8.21705 6.12135C8.15043 6.17726 8.08471 6.2365 8.01987 6.30039L0.65736 13.2216C0.654763 13.2241 0.652203 13.2268 0.649393 13.2293C-0.216464 14.092 -0.216464 15.4955 0.649393 16.3583C1.51539 17.2209 2.91396 17.2104 3.77967 16.3477C3.78341 16.3443 3.78682 16.3408 3.79024 16.3369L10.677 8.94505C10.7398 8.88222 10.798 8.8165 10.853 8.74903C12.4713 9.3573 14.3705 9.01524 15.6713 7.71952C16.62 6.77394 17.0986 5.46628 16.983 4.13197ZM2.67019 15.4264C2.35113 15.7442 1.83439 15.744 1.51536 15.4264C1.19644 15.1089 1.19644 14.5937 1.51536 14.2761C1.83439 13.9585 2.35113 13.9585 2.67019 14.2761C2.98911 14.5937 2.98911 15.1089 2.67019 15.4264Z",fill:"black"}));function h3(){const{currentBike:n,setCurrentBike:e,lounge:t,removeBike:r,resetBike:i}=At(),{t:o}=Le(),{virtualWorkshop:l}=window.BikeMatrix.getConfig();return se(()=>{ht.value=null},[]),se(()=>{t.map(u=>{u!=null&&u.isCustom&&(po.value=!1)})},[t]),g(ie,{children:[t!=null&&t.length?t==null?void 0:t.filter(u=>!!u._key).map(u=>g("div",{class:"mb-4 relative",children:[g("div",{onClick:()=>r(u.key),class:"w-7 h-7 z-10 -right-2 -top-2 flex items-center justify-center absolute bg-gray-200 text-gray-800 rounded-full",children:g(oa,{class:"h-3 w-3"})}),g(gr,{compact:!0,onClick:c=>{c.preventDefault(),e((n==null?void 0:n.key)===(u==null?void 0:u.key)?null:{...u})},bike:u,selected:(n==null?void 0:n.key)===(u==null?void 0:u.key),spanner:l,custom:u==null?void 0:u.isCustom})]},u.key)):g("div",{class:xe("relative mb-4 z-10 "),children:[g("div",{class:"w-full p-4 relative rounded-xl bg-white border border-gray-300 mb-4",children:[g("span",{class:"block rounded-lg h-6 w-1/2 bg-gray-200"}),g("img",{class:"w-auto mx-auto h-auto max-h-36 opacity-30",src:In("bike.png")}),g("span",{class:" absolute right-4 bottom-4 rounded-full h-8 w-8 bg-gray-100"})]}),g("div",{class:xe("w-full relative bg-white border -z-10 border-b-0 border-gray-300 rounded-t-xl h-20 mb-4","after:bottom-0 after:-inset-x-px after:-top-6 after:bg-gradient-to-t after:absolute after:from-white after:to-transparent"),children:[g("span",{class:" absolute left-4 top-4 rounded-lg h-6 w-1/2 bg-gray-200"}),g("span",{class:" absolute right-4 bottom-4 rounded-full h-8 w-8 bg-gray-100"})]}),g("div",{class:" text-gray-800 text-center flex -mt-5 z-20 justify-center",children:[o("bikeselector_home_empty"),g("br",{}),o("bikeselector_home_add_a_bike")]})]}),g("button",{onClick:u=>{u.preventDefault(),i(),De("/add")},class:xe("duration-300 transition-colors sticky bottom-[128px] mt-auto rounded-xl p-3 pr-5 w-full flex justify-center items-center",t.length&&!(n!=null&&n.key)?"bg-gray-950 text-white":t.length?"bg-gray-200 text-gray-800":"bg-gray-950 text-white",!n&&"bottom-0",n&&l&&"bottom-[128px]",n&&!l&&"bottom-[72px]"),children:[o("bikeselector_home_add_btn"),g(oa,{class:"h-3 absolute [&>path]:stroke-[2px] right-5 justify-self-end rotate-45"})]}),!!(t!=null&&t.length)&&!!(n!=null&&n.key)&&l&&g("button",{onClick:u=>{u.preventDefault(),!(n!=null&&n.isCustom)&&!(n!=null&&n.isShared)?De("/workshop"):n!=null&&n.isCustom&&!(n!=null&&n.isShared)?De("/bom"):!(n!=null&&n.isCustom)&&(n!=null&&n.isShared)&&De("/read-only")},class:xe("duration-300 sticky bottom-[72px] transition-colors mt-4 rounded-xl p-3 w-full flex justify-center items-center","bg-gray-200 text-gray-800"),children:[o("virtualworkshop_title"),g(p3,{class:"h-5 absolute right-5 justify-self-end"})]}),!!(t!=null&&t.length)&&!!(n!=null&&n.key)&&g("button",{onClick:u=>{u.preventDefault(),De("/browse")},class:xe("duration-300 sticky bottom-4 transition-colors mt-4 rounded-xl p-3 w-full flex justify-center items-center",t.length?"bg-gray-950 text-white":"bg-gray-200 text-gray-800"),children:o("bikeselector_home_browse_btn")}),g(Yr,{})]})}const v3=n=>te("svg",{width:20,height:20,viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("circle",{cx:10,cy:10,r:10,fill:"#030712"}),te("path",{d:"M6.57886 11.0526L9.02922 13.191L13.4604 7.02636",stroke:"white",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}));function sa({type:n,title:e,placeholder:t,options:r=[],disabled:i=void 0,loading:o=!1,infoVisible:l=!1,children:u=void 0,...c}){const{t:f}=Le(),p=b=>{switch(b){case"brand":return f("bikeselector_addbike_brand_desc");case"model":return f("bikeselector_addbike_model_desc");case"framespec":return f("bikeselector_addbike_framespec_desc");case"framesize":return f("bikeselector_size_framesize_desc");default:return""}},h=(b,m)=>b==="framesize"&&m==="One Size"?f("bikeselector_size_framesize_one_size"):m;return g(ie,{children:g("div",{class:"w-full flex flex-col space-y-2",children:[g("label",{class:"text-gray-800 font-bold text",children:e}),u&&g("div",{class:xe("!my-0 overflow-hidden box-border transition-all duration-300",l?"max-h-screen":"h-0"),children:[g("p",{class:"text-gray-600 my-1 italic text-sm",children:p(n)}),g("div",{class:xe("rounded-xl overflow-hidden my-0 relative py-1 h-32 bg-gray-100 w-full"),children:u})]}),g("div",{class:"w-full flex items-center relative",children:[g("select",{class:xe("rounded-xl peer !pr-8 flex w-full border-gray-300 border p-4 py-3 text-lg bg-white placeholder:text-gray-700 text-gray-700","disabled:bg-gray-100 disabled:border-gray-200 disabled:text-gray-400",c.class),disabled:i,...c,children:[g("option",{value:"",selected:!c.value,disabled:!0,children:t}),r.map(b=>g("option",{value:b.value,disabled:b.disabled,children:h(n,b.label)}))]}),o?g("span",{class:"absolute block loader animate-spin right-4 w-5 h-5"}):c.value&&typeof i=="boolean"?g(v3,{class:"right-3 absolute w-5 pointer-events-none"}):g(vr,{class:"absolute h-3 text-gray-700 pointer-events-none rotate-90 right-5 peer-disabled:text-gray-400"})]})]})})}const U={id:null,name:null,product_category_id:null,swap:!1,version_id:null,unsaved_changes:null,translation:null},la={bike_Key:"",bike_Type:null,bike_Name:null,bike_Variant:null,bike_Reference:null,bike_Thumbnail:null,bike_Images:null,bike_Brand_ID:0,bike_Brand:null,model_Family_ID:0,model_Family:null,model_Spec_ID:0,model_Spec:null,spec:null,bike_Size_ID:null,bike_Size:null,year:0,original_Bike_Key:null,share_Bike_Key:null,owner_Email_Address:null,brake_Configuration:null,cockpit:{stem:U,handlebar:U,seat_Post:U,seat_Post_Clamp:U,dropper_Lever:U,lockout_Lever:U,grips:U,pedals:U,saddle:U},"frame_&_fork":{fork:U,rear_Shock:U,headseat:U},drivetrain:{chainguide:U,bottom_Bracket:U,crankset:U,largest_Chainring:U,second_Largest_Chainring:U,third_Largest_Chainring:U,chainring_Spider:U,chain:U,cassette:U,rear_Derailleur:U,front_Derailleur:U,shifter_RH:U,shifter_LH:U,shift_Brake_Combo_RH:U,shift_Brake_Combo_LH:U,brake_Lever_RH:U,brake_Lever_LH:U,shifter_Adapter_RH:U,shifter_Adapter_LH:U},brakes:{brake_Caliper_Front:U,brake_Caliper_Rear:U,brake_Pads_Front:U,brake_Pads_Rear:U,brake_Rotor_Front:U,brake_Rotor_Rear:U,brake_Adapter_Front:U,brake_Adapter_Rear:U},"wheels_&_tyres":{front_Wheel:U,front_Axle:U,rear_Wheel:U,rear_Axle:U,tyre_Front:U,tyre_Rear:U},is_E_Bike:null,eMotor_System_ID:null,eBattery_ID:null,eControl_Unit_ID:null,eCharger_ID:null,eInterconnects_ID:null},ua={cockpit:{stem:U,handlebar:U,seat_Post:U,seat_Post_Clamp:U,dropper_Lever:U,lockout_Lever:U,grips:U,pedals:U,saddle:U},"frame_&_fork":{headset:U,fork:U,rear_Shock:U},drivetrain:{chainguide:U,bottom_Bracket:U,crankset:U,largest_Chainring:U,second_Largest_Chainring:U,third_Largest_Chainring:U,chainring_Spider:U,chain:U,cassette:U,rear_Derailleur:U,front_Derailleur:U,shifter_RH:U,shifter_LH:U,shift_Brake_Combo_RH:U,shift_Brake_Combo_LH:U,brake_Lever_RH:U,brake_Lever_LH:U,shifter_Adapter_RH:U,shifter_Adapter_LH:U},brakes:{brake_Caliper_Front:U,brake_Caliper_Rear:U,brake_Pads_Front:U,brake_Pads_Rear:U,brake_Rotor_Front:U,brake_Rotor_Rear:U,brake_Adapter_Front:U,brake_Adapter_Rear:U},"wheels_&_tyres":{front_Wheel:U,front_Axle:U,rear_Wheel:U,rear_Axle:U,tyre_Front:U,tyre_Rear:U}},Fr={headset:{},stem:{},handlebar:{},seat_Post:{},seat_Post_Clamp:{},dropper_Lever:{},lockout_Lever:{},grips:{},pedals:{},saddle:{},fork:{},rear_Shock:{},chainguide:{},bottom_Bracket:{},crankset:{},largest_Chainring:{},second_Largest_Chainring:{},third_Largest_Chainring:{},chainring_Spider:{},chain:{},cassette:{},rear_Derailleur:{},front_Derailleur:{},shifter_RH:{},shifter_LH:{},shift_Brake_Combo_RH:{},shift_Brake_Combo_LH:{},brake_Lever_RH:{},brake_Lever_LH:{},shifter_Adapter_RH:{},shifter_Adapter_LH:{},brake_Caliper_Front:{},brake_Caliper_Rear:{},brake_Pads_Front:{},brake_Pads_Rear:{},brake_Rotor_Front:{},brake_Rotor_Rear:{},brake_Adapter_Front:{},brake_Adapter_Rear:{},front_Wheel:{},front_Axle:{},rear_Wheel:{},rear_Axle:{},tyre_Front:{},tyre_Rear:{}},cl=(n,e)=>Object.keys(n).includes(e),ca=n=>(Object.keys(Fr).forEach(e=>{Object.keys(n).forEach(t=>{`${e}_ID`===t&&(Fr[e].id=n[t]),`${e}_Name`===t&&(Fr[e].name=n[t]),`${e}_Product_Category_ID`===t&&(Fr[e].product_category_id=n[t]),`${e}_Swap`===t&&(Fr[e].swap=n[t]),`${e}_Version_ID`===t&&(Fr[e].version_id=n[t]),`${e}_Unsaved_Changes`===t&&(Fr[e].unsaved_changes=n[t])})}),Object.keys(ua).forEach(e=>{Object.keys(Fr).forEach(t=>{cl(ua[e],t)&&(ua[e][t]=Fr[t])})}),Object.keys(ua).forEach(e=>{cl(la,e)&&(la[e]=ua[e])}),Object.keys(n).forEach(e=>{cl(la,e)&&(la[e]=n[e])}),la),of=n=>te("svg",{width:25,height:25,viewBox:"0 0 25 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},te("circle",{cx:12.5,cy:12.5,r:12,fill:"white",stroke:"black"}),te("path",{d:"M9 16.0711L12.5355 12.5355M12.5355 12.5355L16.0711 9M12.5355 12.5355L16.0711 16.0711M12.5355 12.5355L9 9",stroke:"black",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round"})),g3=`.input_container{display:flex;flex-direction:column}.input_wrapper{width:100%;border-radius:12px;padding:12px;border:1px solid #d1d5db;display:flex;align-items:center;justify-content:space-between}.input_wrapper input{width:100%}
|
|
3
|
-
`,sf=({value:n,setValue:e,placeholder:t,type:r,error:i,submitInput:o,label:l,instructions:u})=>g(ie,{children:[g("style",{type:"text/css",children:g3}),g("div",{className:"input_container",children:[l&&g("label",{class:"text-gray-800 font-bold text",children:l}),u&&g("label",{class:"text-gray-600 my-1 italic text-sm",children:u}),g("div",{className:"input_wrapper",children:[g("input",{placeholder:t,value:n,onChange:c=>e(c.currentTarget.value),type:r,onKeyDown:c=>{c.key==="Enter"&&o()}}),g(of,{height:20,width:20,onClick:()=>e(""),className:"cursor-pointer"})]}),i&&g("p",{className:"text-red-500 text-xs pt-1",children:i})]})]}),lf=({messages:n})=>g("div",{className:"flex h-4 w-auto justify-center",children:n&&g("p",{className:"message text-xs text-red-500",children:n})}),b3=`.lds-ring{display:inline-block;position:relative;width:24px;height:24px}.lds-ring div{box-sizing:border-box;display:block;position:absolute;width:19px;height:19px;margin:2px;border:2px solid #c4cdd5;border-radius:50%;animation:lds-ring 1.2s cubic-bezier(.5,0,.5,1) infinite;border-color:#c4cdd5 transparent transparent transparent}.lds-ring div:nth-child(1){animation-delay:-.45s}.lds-ring div:nth-child(2){animation-delay:-.3s}.lds-ring div:nth-child(3){animation-delay:-.15s}@keyframes lds-ring{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
|
|
3
|
+
`,sf=({value:n,setValue:e,placeholder:t,type:r,error:i,submitInput:o,label:l,instructions:u})=>g(ie,{children:[g("style",{type:"text/css",children:g3}),g("div",{className:"input_container",children:[l&&g("label",{class:"text-gray-800 font-bold text",children:l}),u&&g("label",{class:"text-gray-600 my-1 italic text-sm",children:u}),g("div",{className:"input_wrapper",children:[g("input",{placeholder:t,value:n,onChange:c=>e(c.currentTarget.value),type:r,onKeyDown:c=>{c.key==="Enter"&&o()}}),g(of,{height:20,width:20,onClick:()=>e(""),className:"cursor-pointer"})]}),i&&g("p",{className:"text-red-500 text-xs pt-1",children:i})]})]}),lf=({messages:n})=>{const{t:e}=Le();return g("div",{className:"flex h-4 w-auto justify-center",children:n&&g("p",{className:"message text-xs text-red-500",children:e(n)})})},b3=`.lds-ring{display:inline-block;position:relative;width:24px;height:24px}.lds-ring div{box-sizing:border-box;display:block;position:absolute;width:19px;height:19px;margin:2px;border:2px solid #c4cdd5;border-radius:50%;animation:lds-ring 1.2s cubic-bezier(.5,0,.5,1) infinite;border-color:#c4cdd5 transparent transparent transparent}.lds-ring div:nth-child(1){animation-delay:-.45s}.lds-ring div:nth-child(2){animation-delay:-.3s}.lds-ring div:nth-child(3){animation-delay:-.15s}@keyframes lds-ring{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
|
|
4
4
|
`;function hn({isLoading:n,colour:e}){return g(ie,{children:[g("style",{type:"text/css",children:b3}),g("div",{class:"lds-ring",id:"bm-loading-spinner",style:{display:n?"inline-block":"none"},children:[g("div",{style:{border:`2px solid ${e}`,borderColor:`${e} transparent transparent transparent`}}),g("div",{style:{border:`2px solid ${e}`,borderColor:`${e} transparent transparent transparent`}}),g("div",{style:{border:`2px solid ${e}`,borderColor:`${e} transparent transparent transparent`}}),g("div",{style:{border:`2px solid ${e}`,borderColor:`${e} transparent transparent transparent`}})]})]})}const zr=({onClick:n,primary:e,text:t,loading:r,disabled:i,sticky:o,children:l,active:u=!0})=>g("button",{onClick:c=>{!i&&!r&&(c.preventDefault(),n())},class:xe("duration-300 bottom-4 transition-colors mt-4 rounded-xl p-3 w-full flex justify-center items-center",`${e&&u?"bg-gray-950 text-white":e&&!u?"bg-gray-200 text-gray-400 ":"bg-gray-200 text-gray-800"} ${o&&"sticky"} `),style:{cursor:i?"not-allowed":"pointer",opacity:i?.5:1},children:r?g(hn,{isLoading:r,colour:e?"#fff":"#000"}):g(ie,{children:[g("span",{className:l?"ml-auto":"",children:t}),l]})});function m3(){const n=window.BikeMatrix.getConfig(),{bike:e,setBikeAttr:t}=At(),{brand:r,model:i,frameSeries:o}=e,{t:l}=Le(),[u,c]=$([]),[f,p]=$(!1),h=new Ht(n.apiUrl,n.apiKey,n.apiToken,n.isShopify),[b,m]=$(null),[k,x]=$(""),H=r.value,C=r.value&&i.value;se(()=>{const P=n.bikeSelectorBrands?n.bikeSelectorBrands.split(",").filter(D=>D!==""):[];if(P.length>0&&r.options.length>0){let D=[];r.options.forEach(O=>{P.includes(O.value.toString().trim())&&D.push(O)}),c(D)}else c(r.options)},[n.bikeSelectorBrands,r.options]);const w=async()=>{var O;p(!0);const P=await h.getBikeBom(k);if(!(P!=null&&P.success)){p(!1),m(P.error);return}const D=ca(P.data);ht.value=D,e.value={bikeSpec:D.spec,brand:D.bike_Brand,brandId:D.bike_Brand_ID,frameSeries:D.spec,frameSeriesId:D.model_Spec_ID,frameSize:D.bike_Size,images:[`https://imagestore.bikematrix.io/${D.bike_Reference}/400-${D.bike_Thumbnail}`],isCustom:D.bike_Type==="Custom_Bike",isShared:D.bike_Type==="Shared_Bike",key:D.bike_Type==="Shared_Bike"?D.share_Bike_Key:D.bike_Key,model:D.model_Family,modelId:D.model_Family_ID,name:D.bike_Name,size:D.bike_Size,sizeId:D.bike_Size_ID,variant:D.bike_Variant,year:D.year,_key:`${D.year}-${(O=D.spec)==null?void 0:O.replace(" ","")}`},p(!1),De("/confirm")};return g(ie,{children:[g("div",{class:"space-y-5 mb-6 relative w-full flex flex-col",children:[n.virtualWorkshop&&g(ie,{children:[g(sf,{value:k,setValue:P=>x(P),label:"Bike Matrix ID",placeholder:"Enter your Bike Matrix ID",type:"text",instructions:l("virtualworkshop_bm_id_text")}),g("div",{className:"flex justify-center items-center gap-2",children:[g("div",{className:"bg-gray-300 h-[1px] w-full"}),g("p",{className:" font-semibold text-sm",children:"OR"}),g("div",{className:"bg-gray-300 h-[1px] w-full"})]})]}),g(sa,{type:"brand",title:l("bikeselector_addbike_brand_label"),placeholder:l("bikeselector_addbike_brand_select"),value:r.value,options:u,onChange:P=>{t("brand",P.target.value)},loading:!r.options.length,disabled:!r.options.length,info:!0,infoVisible:!r.value,children:g("img",{src:In("info-brand.svg"),class:"w-full h-full"})}),g(sa,{type:"model",title:l("bikeselector_addbike_model_label"),placeholder:l("bikeselector_addbike_model_select"),value:i.value,options:i.options,onChange:P=>{t("model",P.target.value)},loading:H&&!i.options.length,disabled:!H||!i.options.length,info:!0,infoVisible:H&&!i.value,children:g("img",{src:In("info-model.svg"),class:"w-full h-full"})}),g(sa,{type:"framespec",title:l("bikeselector_addbike_framespec_label"),placeholder:l("bikeselector_addbike_framespec_select"),value:o.value,loading:C&&!o.options.length,options:o.options,onChange:P=>{t("frameSeries",P.target.value)},disabled:!C||!o.options.length,info:!0,infoVisible:C&&!o.value,children:g("img",{src:In("info-frameseries.svg"),class:"w-full h-full"})})]}),g(lf,{messages:b}),g(zr,{primary:!0,text:l("bikeselector_addbike_find_btn"),onClick:()=>{r.value&&i.value&&o.value?De("/search"):k&&w()},active:r.value&&i.value&&o.value||k,loading:f,children:g(vr,{class:"h-3 ml-auto justify-self-end"})})]})}function y3(){var k,x,H,C;const{bike:n,setBike:e,setBikeAttr:t,results:r,loading:i}=At(),{year:o,bikeSpec:l}=n,{t:u}=Le(),[c,f]=[n.value,w=>e(P=>({...P,value:w}))],p=kr(()=>{const w=r==null?void 0:r.filter(P=>{var O;let D=!0;return l.value&&(D=P.bikeSpec===l.value),D&&o.value.length&&(D=(O=o.value)==null?void 0:O.includes(P.year)),D});return w.some(P=>P._key==c._key)||f({}),w},[r,l.value,o.value]),h=kr(()=>l.value?r.filter(P=>l.value==P.bikeSpec).map(P=>P.year):o.options.map(P=>P.value),[l.value]),b=kr(()=>{var P;if(!((P=o.value)!=null&&P.length))return l.options;const w=r.filter(D=>{var O;return(O=o.value)==null?void 0:O.includes(D.year)}).map(D=>D.bikeSpec);return l.options.map(D=>({...D,disabled:!w.includes(D.value)}))},[l.options,o.value]),m=w=>w===0?u("bikeselector_search_no_bikes_found"):w===1?u("bikeselector_search_one_bike_found"):u("bikeselector_search_number_bikes_found",{number_found:w});return g(ie,{children:[g("div",{class:"space-y-3 mb-6 relative w-full flex flex-col",children:[g(sa,{type:"bikespec",title:u("bikeselector_search_bikespec_label"),placeholder:u("bikeselector_search_bikespec_select"),value:l.value,options:[{label:u("bikeselector_search_bikespec_select_all"),value:""},...b],onChange:w=>{t("bikeSpec",w.target.value)},disabled:!((k=l.options)!=null&&k.length),loading:!((x=l.options)!=null&&x.length)}),g("div",{class:"w-full flex flex-col space-y-2",children:[g("label",{class:"text-gray-800 font-bold text",children:u("bikeselector_search_year_label")}),g("div",{class:xe("flex space-x-2 overflow-x-auto","-mx-8 w-[calc(100%_+_64px)] px-8 no-scrollbar"),children:(H=o.options)!=null&&H.length?(C=o.options)==null?void 0:C.map(w=>{var O;const P=l.value&&!h.includes(w.value),D=(O=o.value)==null?void 0:O.includes(w.value);return g("div",{onClick:()=>{P||t("year",D?o.value.filter(j=>j!==w.value):[...o.value,w.value])},class:xe("rounded-full cursor-pointer items-center flex border py-2 px-4",D?"pr-3 bg-gray-950 border-gray-950 text-white":"border-gray-300 text-gray-700 ",P&&"hidden"),children:[w.label,D&&g(oa,{class:"w-3 h-3 ml-2"})]})}):Array(2).fill(0).map((w,P)=>g("div",{class:"rounded-full items-center flex border py-2 bg-gray-100 px-4 bg-100 border-gray-300 animate-pulse",children:g("span",{class:"rounded-lg bg-gray-100 w-9 h-5"})},P))})]}),g("div",{class:xe("text-nowrap font-medium w-full flex","[&>span]:text-gray-500 [&>span]:font-normal"),children:[i?g(ie,{children:u("bikeselector_search_searching")}):g(ie,{children:m(p.length)})," ",(r==null?void 0:r.length)>0&&g(ie,{children:[g("span",{children:"("}),g("span",{class:"whitespace-nowrap overflow-hidden text-ellipsis truncate",children:[r[0].brand," ",r[0].frameSeries]}),g("span",{children:")"})]})]}),g("div",{class:"grid grid-cols-1 sm:grid-cols-2 gap-4",children:p!=null&&p.length&&!i?p.map((w,P)=>g(gr,{"data-key":w._key,bike:w,selected:w._key===c._key,onClick:D=>{D.preventDefault(),f(w)},compact:!0},w._key)):Array(i?2:1).fill(0).map((w,P)=>g("div",{class:xe("w-full relative rounded-xl h-40 bg-white border border-gray-200 ",i&&"animate-pulse"),children:[g("span",{class:" absolute left-4 top-4 rounded-lg h-6 w-1/2 bg-gray-200"}),g("span",{class:" absolute right-4 bottom-4 rounded-full h-8 w-8 bg-gray-200"})]},P))})]}),g("button",{onClick:w=>{var P,D;if(w.preventDefault(),c._key){const O=(P=this.base.querySelector(`[data-key="${c._key}"] [data-active-slide]`))==null?void 0:P.getAttribute("data-active-slide"),L=[(D=this.base.querySelector(`[data-key="${c._key}"] [data-slide="${O}"] img`))==null?void 0:D.src].filter(T=>!!T);L!=null&&L.length&&e(T=>(T.value={...T.value||{},images:L},{...T})),De("/size")}},class:xe("duration-300 transition-colors sticky bottom-6 mt-auto rounded-xl p-3 pr-5 w-full flex justify-center items-center",c._key?"bg-gray-950 text-white":"bg-gray-200 text-gray-400 "),children:[g("span",{class:"ml-auto",children:u("bikeselector_search_confirm_btn")})," ",g(vr,{class:"h-3 ml-auto justify-self-end"})]})]})}function w3(){var o,l;const{bike:n,setBikeAttr:e,setBike:t}=At(),{frameSize:r}=n,{t:i}=Le();return se(()=>{var u;(u=r.options)!=null&&u.length||De("/confirm")},[]),g(ie,{children:[g(gr,{bike:n.value,selected:!0,compact:!0}),g("div",{class:" mt-4 mb-6 relative w-full flex flex-col",children:g(sa,{type:"framesize",instruction:!0,title:i("bikeselector_size_framesize_label"),placeholder:i("bikeselector_size_framesize_select"),value:r.value,options:r.options,onChange:u=>{e("frameSize",u.target.value),t(c=>{var f;return c.value.frameSize=((f=r.options.find(p=>p.value==u.target.value))==null?void 0:f.label)||"",c})},selected:!0,info:!0,infoVisible:!0,disabled:!((o=r.options)!=null&&o.length),loading:!((l=r.options)!=null&&l.length),children:g("img",{src:In("info-size.svg"),class:"w-full h-full"})})}),g("button",{onClick:u=>{u.preventDefault(),r.value&&De("/confirm")},class:xe("duration-300 transition-colors sticky bottom-10 mt-auto rounded-xl p-3 pr-5 w-full flex justify-center items-center",r.value?"bg-gray-950 text-white":"bg-gray-200 text-gray-400 "),children:[g("span",{class:"ml-auto",children:i("bikeselector_size_confirm_btn")})," ",g(vr,{class:"h-3 ml-auto justify-self-end"})]})]})}const Cr=Ct({title:"",step:0,back:""});function x3({children:n}){const{t:e}=Le();return g(ie,{children:[g("div",{class:"relative flex items-center justify-center w-full h-10 my-5 sm:mt-8",children:[!!Cr.value.back&&g("div",{onClick:()=>De(Cr.value.back),class:" w-10 h-10 absolute left-0 rounded-xl self-start border-gray-200 border items-center justify-center flex",children:g(vr,{class:"h-3 text-gray-500 -translate-x-px -rotate-180"})}),g("h2",{class:"text-xl font-bold",style:{maxWidth:"70%",textAlign:"center"},children:e(Cr.value.title)})]}),n,typeof Cr.value.step<"u"&&g("div",{class:"space-x-2 my-6 flex items-center justify-center",children:[0,1,2,3].map(t=>g("div",{class:xe("rounded-xl h-2 transition-all duration-300",t==Cr.value.step?"w-6 bg-gray-950":"w-2 bg-gray-200")},t))})]})}function P3(){const{bike:n,saveBike:e}=At(),{brand:t,model:r,frameSeries:i,frameSize:o,year:l,bikeSpec:u}=n.value,{t:c}=Le(),f=ht.value;return se(()=>{!o&&!f?Cr.value.back="/search":f&&(Cr.value.back="/add")},[]),g(ie,{children:[g(gr,{bike:n.value,selected:!0,compact:!0}),g("div",{class:" space-y-4 mt-4 mb-6 relative w-full flex flex-col",children:[{title:c("bikeselector_confirm_brandmodelframespec_label"),value:[t,r,i].join(", "),path:"/add"},{title:c("bikeselector_confirm_yearbikespec_label"),value:[l,u].join(", "),path:"/search"},{title:c("bikeselector_confirm_framesize_label"),value:o,path:"/size"}].filter(p=>!!p.value).map(p=>g("div",{class:"w-full flex flex-col space-y-2",children:[g("label",{class:"text-gray-800 font-bold",children:p.title}),g("div",{onClick:()=>De(p.path),class:"w-full flex items-center relative cursor-pointer",children:[g("div",{class:xe("rounded-xl peer whitespace-nowrap truncate !pr-8 flex w-full border-gray-300 border p-4 py-3 text-lg placeholder:text-gray-700 text-gray-700"),children:p.value}),g(vr,{class:"absolute h-3 text-gray-700 pointer-events-none right-4 peer-disabled:text-gray-400"})]})]},p.path))}),g("button",{onClick:p=>{p.preventDefault(),e(n.value),De("/browse")},class:xe("duration-300 transition-colors sticky bottom-10 mt-auto rounded-xl p-3 w-full flex justify-center items-center","bg-gray-950 text-white"),children:c("bikeselector_confirm_confirm_btn")}),g("p",{class:"text-gray-600 -mb-3 mt-2 text-center font-normal text-xs",children:c("bikeselector_confirm_notyourride_msg")})]})}function k3(){const{currentBike:n,compatibleCollections:e}=At(),{t}=Le();return g(ie,{children:[g(gr,{bike:n,selected:!0}),!!(e!=null&&e.length)&&g(ie,{children:[g("p",{class:"text-gray-800 mt-4 font-bold",children:t("bikeselector_browse_products_label")}),g("div",{class:"gap-3 mt-2 mb-6 relative w-full flex flex-wrap",children:e.map(r=>g("a",{href:r.url,class:"group flex items-center relative cursor-pointer",children:[g("div",{class:xe("rounded-xl peer whitespace-nowrap truncate !pr-8 flex w-full border-gray-300 border p-4 py-3 text-lg placeholder:text-gray-700 text-gray-950","group-disabled:bg-gray-100 group-disabled:border-gray-200 group-disabled:text-gray-400"),children:t(r.text_id)}),g(vr,{class:"absolute h-3 pointer-events-none right-4 group-disabled:text-gray-400 text-gray-950"})]},r.text_id))})]}),g("button",{onClick:r=>{r.preventDefault(),gi()},class:xe("duration-300 transition-colors mt-4 rounded-xl p-3 w-full flex justify-center items-center","bg-gray-950 text-white"),children:t("bikeselector_browse_shop_btn")}),g("button",{onClick:r=>{r.preventDefault(),De("/")},class:xe("duration-300 transition-colors mt-4 rounded-xl p-3 w-full flex justify-center items-center","bg-gray-200 text-gray-800"),children:t("bikeselector_browse_back_btn")}),g(Yr,{})]})}const bi=()=>g("div",{class:"w-full p-4 relative rounded-xl bg-white border border-gray-300 mb-4",children:[g("span",{class:"block rounded-lg h-6 w-1/2 bg-gray-200"}),g("img",{class:"w-auto mx-auto h-auto max-h-36 opacity-30",src:In("bike.png")}),g("span",{class:" absolute right-4 bottom-4 rounded-full h-8 w-8 bg-gray-100"})]});function z3(){const{t:n}=Le(),t=window.BikeMatrix.getConfig(),{currentBike:r,setCurrentBike:i,compatibleCollections:o}=At(),l=new Ht(t.apiUrl,t.apiKey,t.apiToken,t.isShopify),[u,c]=$(!1),[f,p]=$(null),{saveBike:h}=At(),b=async()=>{c(!0);const m=await l.addCustomBike(r.key);if(m.success){const k=await l.getBikeBom(m==null?void 0:m.data);if(!k.success){p(k.error),c(!1);return}const x=ca(k.data);ht.value=x;const H={...r,key:x.bike_Key,isCustom:!0,shareId:x.share_Bike_Key};h(H),i(H),c(!1),De("/bom")}else{p(m.error),c(!1);return}};return g(ie,{children:[g("div",{style:{marginBottom:"1rem"},children:[r?g(gr,{bike:r,noSymbol:!0,compact:!0}):g(bi,{}),g("div",{class:" text-gray-800 text-center flex z-20 justify-center font-bold mt-6",children:o.length>1?n("virtualworkshop_intro_text"):n("virtualworkshop_do_not_pass")})]}),g(lf,{messages:f}),g(zr,{text:o.length>1?n("virtualworkshop_enter_button"):n("bikeselector_browse_back_btn"),onClick:o.length>1?()=>b():()=>De("/"),loading:u,primary:!0}),g(Yr,{})]})}const C3=`.overflowing{width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:flex;justify-content:flex-start}.flexend{justify-content:flex-end}
|
|
5
5
|
`,Nr=({paragraph:n,subheader:e,header:t,text:r,small:i,left:o,bold:l,capitalize:u,nowrap:c,flexend:f})=>g(ie,{children:[g("style",{type:"text/css",children:C3}),t?g("h2",{class:"text-xl font-bold",children:r}):e?g("h4",{className:`text-gray-800 text-center flex z-20 justify-center font-bold ${u?"capitalize":""}`,children:r}):g("p",{class:`text-gray-800 flex z-20 ${i?"text-sm":""} ${o?"text-start justify-start":"text-center justify-center"} ${l?"font-bold":""} ${u?"capitalize":""} ${c?"overflowing":""} ${f?"flexend":""}`,children:r})]}),H3=`.background-alert-wrapper{opacity:0;position:absolute;height:100%;width:100%;display:none;top:0;left:0;pointer-events:none}.alert-wrapper{position:absolute;z-index:200;width:calc(100% + 16px);height:100%;background-color:#0003;top:0;left:-8px;border-radius:12px;display:flex;align-items:center;justify-content:center;opacity:0;pointer-events:none}.alert{width:80%;padding:2rem;border-radius:12px;background-color:#fff;position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);z-index:300}.text-wrapper{display:flex;flex-direction:column;align-items:center;gap:1rem}.button-wrapper{display:flex;gap:1rem;width:100%;margin-top:1rem}
|
|
6
6
|
`;function Rr(n){if(n===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n}function uf(n,e){n.prototype=Object.create(e.prototype),n.prototype.constructor=n,n.__proto__=e}/*!
|