tour-2.0.x-dev/dist/third-party.js
dist/third-party.js
/*! shepherd.js 13.0.3 */function tn(e){return e instanceof Element}function ke(e){return e instanceof HTMLElement}function Z(e){return typeof e=="function"}function Ce(e){return typeof e=="string"}function E(e){return e===void 0}class Qe{on(t,n,i,o=!1){var r;return E(this.bindings)&&(this.bindings={}),E(this.bindings[t])&&(this.bindings[t]=[]),(r=this.bindings[t])==null||r.push({handler:n,ctx:i,once:o}),this}once(t,n,i){return this.on(t,n,i,!0)}off(t,n){if(E(this.bindings)||E(this.bindings[t]))return this;if(E(n))delete this.bindings[t];else{var i;(i=this.bindings[t])==null||i.forEach((o,r)=>{if(o.handler===n){var s;(s=this.bindings[t])==null||s.splice(r,1)}})}return this}trigger(t,...n){if(!E(this.bindings)&&this.bindings[t]){var i;(i=this.bindings[t])==null||i.forEach((o,r)=>{const{ctx:s,handler:l,once:c}=o,f=s||this;if(l.apply(f,n),c){var u;(u=this.bindings[t])==null||u.splice(r,1)}})}return this}}function C(){return C=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)({}).hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},C.apply(null,arguments)}function kt(e,t){if(e==null)return{};var n={};for(var i in e)if({}.hasOwnProperty.call(e,i)){if(t.includes(i))continue;n[i]=e[i]}return n}const Q={defaultMerge:Symbol("deepmerge-ts: default merge"),skip:Symbol("deepmerge-ts: skip")};Q.defaultMerge;function nn(e,t){return t}function at(e){return typeof e!="object"||e===null?0:Array.isArray(e)?2:rn(e)?1:e instanceof Set?3:e instanceof Map?4:5}function on(e){const t=new Set;for(const n of e)for(const i of[...Object.keys(n),...Object.getOwnPropertySymbols(n)])t.add(i);return t}function sn(e,t){return typeof e=="object"&&Object.prototype.propertyIsEnumerable.call(e,t)}function Rt(e){return{*[Symbol.iterator](){for(const t of e)for(const n of t)yield n}}}const ut=new Set(["[object Object]","[object Module]"]);function rn(e){if(!ut.has(Object.prototype.toString.call(e)))return!1;const{constructor:t}=e;if(t===void 0)return!0;const n=t.prototype;return!(n===null||typeof n!="object"||!ut.has(Object.prototype.toString.call(n))||!n.hasOwnProperty("isPrototypeOf"))}function ln(e,t,n){const i={};for(const o of on(e)){const r=[];for(const c of e)sn(c,o)&&r.push(c[o]);if(r.length===0)continue;const s=t.metaDataUpdater(n,{key:o,parents:e}),l=Pt(r,t,s);l!==Q.skip&&(o==="__proto__"?Object.defineProperty(i,o,{value:l,configurable:!0,enumerable:!0,writable:!0}):i[o]=l)}return i}function cn(e){return e.flat()}function fn(e){return new Set(Rt(e))}function an(e){return new Map(Rt(e))}function Lt(e){return e.at(-1)}var Ue=Object.freeze({__proto__:null,mergeArrays:cn,mergeMaps:an,mergeOthers:Lt,mergeRecords:ln,mergeSets:fn});function et(...e){return un({})(...e)}function un(e,t){const n=dn(e,i);function i(...o){return Pt(o,n,t)}return i}function dn(e,t){var n,i;return{defaultMergeFunctions:Ue,mergeFunctions:C({},Ue,Object.fromEntries(Object.entries(e).filter(([o,r])=>Object.hasOwn(Ue,o)).map(([o,r])=>r===!1?[o,Lt]:[o,r]))),metaDataUpdater:(n=e.metaDataUpdater)!=null?n:nn,deepmerge:t,useImplicitDefaultMerging:(i=e.enableImplicitDefaultMerging)!=null?i:!1,actions:Q}}function Pt(e,t,n){if(e.length===0)return;if(e.length===1)return ze(e,t,n);const i=at(e[0]);if(i!==0&&i!==5){for(let o=1;o<e.length;o++)if(at(e[o])!==i)return ze(e,t,n)}switch(i){case 1:return hn(e,t,n);case 2:return pn(e,t,n);case 3:return mn(e,t,n);case 4:return gn(e,t,n);default:return ze(e,t,n)}}function hn(e,t,n){const i=t.mergeFunctions.mergeRecords(e,t,n);return i===Q.defaultMerge||t.useImplicitDefaultMerging&&i===void 0&&t.mergeFunctions.mergeRecords!==t.defaultMergeFunctions.mergeRecords?t.defaultMergeFunctions.mergeRecords(e,t,n):i}function pn(e,t,n){const i=t.mergeFunctions.mergeArrays(e,t,n);return i===Q.defaultMerge||t.useImplicitDefaultMerging&&i===void 0&&t.mergeFunctions.mergeArrays!==t.defaultMergeFunctions.mergeArrays?t.defaultMergeFunctions.mergeArrays(e):i}function mn(e,t,n){const i=t.mergeFunctions.mergeSets(e,t,n);return i===Q.defaultMerge||t.useImplicitDefaultMerging&&i===void 0&&t.mergeFunctions.mergeSets!==t.defaultMergeFunctions.mergeSets?t.defaultMergeFunctions.mergeSets(e):i}function gn(e,t,n){const i=t.mergeFunctions.mergeMaps(e,t,n);return i===Q.defaultMerge||t.useImplicitDefaultMerging&&i===void 0&&t.mergeFunctions.mergeMaps!==t.defaultMergeFunctions.mergeMaps?t.defaultMergeFunctions.mergeMaps(e):i}function ze(e,t,n){const i=t.mergeFunctions.mergeOthers(e,t,n);return i===Q.defaultMerge||t.useImplicitDefaultMerging&&i===void 0&&t.mergeFunctions.mergeOthers!==t.defaultMergeFunctions.mergeOthers?t.defaultMergeFunctions.mergeOthers(e):i}function tt(e){const t=Object.getOwnPropertyNames(e.constructor.prototype);for(let n=0;n<t.length;n++){const i=t[n],o=e[i];i!=="constructor"&&typeof o=="function"&&(e[i]=o.bind(e))}return e}function bn(e,t){return n=>{if(e.isOpen()){const i=e.el&&n.currentTarget===e.el;(!E(t)&&n.currentTarget.matches(t)||i)&&e.tour.next()}}}function wn(e){const{event:t,selector:n}=e.options.advanceOn||{};if(t){const i=bn(e,n);let o=null;if(!E(n)&&(o=document.querySelector(n),!o))return console.error(`No element was found for the selector supplied to advanceOn: ${n}`);o?(o.addEventListener(t,i),e.on("destroy",()=>o.removeEventListener(t,i))):(document.body.addEventListener(t,i,!0),e.on("destroy",()=>document.body.removeEventListener(t,i,!0)))}else return console.error("advanceOn was defined, but no event name was passed.")}class yn{constructor(t){}}class _n{constructor(t,n){}}function Ft(e){return!Ce(e)||e===""?"":e.charAt(e.length-1)!=="-"?`${e}-`:e}function xn(e){const t=e.options.attachTo||{},n=Object.assign({},t);if(Z(n.element)&&(n.element=n.element.call(e)),Ce(n.element)){try{n.element=document.querySelector(n.element)}catch{}n.element||console.error(`The element for this Shepherd step was not found ${t.element}`)}return n}function Dt(e){return e==null?!0:!e.element||!e.on}function Bt(){let e=Date.now();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const n=(e+Math.random()*16)%16|0;return e=Math.floor(e/16),(t=="x"?n:n&3|8).toString(16)})}const ye=Math.min,se=Math.max,De=Math.round,Pe=Math.floor,G=e=>({x:e,y:e}),vn={left:"right",right:"left",bottom:"top",top:"bottom"},Sn={start:"end",end:"start"};function Xe(e,t,n){return se(e,ye(t,n))}function _e(e,t){return typeof e=="function"?e(t):e}function ce(e){return e.split("-")[0]}function Ne(e){return e.split("-")[1]}function nt(e){return e==="x"?"y":"x"}function it(e){return e==="y"?"height":"width"}function xe(e){return["top","bottom"].includes(ce(e))?"y":"x"}function ot(e){return nt(xe(e))}function On(e,t,n){n===void 0&&(n=!1);const i=Ne(e),o=ot(e),r=it(o);let s=o==="x"?i===(n?"end":"start")?"right":"left":i==="start"?"bottom":"top";return t.reference[r]>t.floating[r]&&(s=Be(s)),[s,Be(s)]}function An(e){const t=Be(e);return[Ke(e),t,Ke(t)]}function Ke(e){return e.replace(/start|end/g,t=>Sn[t])}function En(e,t,n){const i=["left","right"],o=["right","left"],r=["top","bottom"],s=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:i:t?i:o;case"left":case"right":return t?r:s;default:return[]}}function Tn(e,t,n,i){const o=Ne(e);let r=En(ce(e),n==="start",i);return o&&(r=r.map(s=>s+"-"+o),t&&(r=r.concat(r.map(Ke)))),r}function Be(e){return e.replace(/left|right|bottom|top/g,t=>vn[t])}function Cn(e){return C({top:0,right:0,bottom:0,left:0},e)}function Ht(e){return typeof e!="number"?Cn(e):{top:e,right:e,bottom:e,left:e}}function He(e){const{x:t,y:n,width:i,height:o}=e;return{width:i,height:o,top:n,left:t,right:t+i,bottom:n+o,x:t,y:n}}const In=["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"],Mn=["mainAxis","crossAxis","limiter"];function dt(e,t,n){let{reference:i,floating:o}=e;const r=xe(t),s=ot(t),l=it(s),c=ce(t),f=r==="y",u=i.x+i.width/2-o.width/2,d=i.y+i.height/2-o.height/2,a=i[l]/2-o[l]/2;let h;switch(c){case"top":h={x:u,y:i.y-o.height};break;case"bottom":h={x:u,y:i.y+i.height};break;case"right":h={x:i.x+i.width,y:d};break;case"left":h={x:i.x-o.width,y:d};break;default:h={x:i.x,y:i.y}}switch(Ne(t)){case"start":h[s]-=a*(n&&f?-1:1);break;case"end":h[s]+=a*(n&&f?-1:1);break}return h}const kn=async(e,t,n)=>{const{placement:i="bottom",strategy:o="absolute",middleware:r=[],platform:s}=n,l=r.filter(Boolean),c=await(s.isRTL==null?void 0:s.isRTL(t));let f=await s.getElementRects({reference:e,floating:t,strategy:o}),{x:u,y:d}=dt(f,i,c),a=i,h={},m=0;for(let b=0;b<l.length;b++){const{name:y,fn:w}=l[b],{x:_,y:x,data:g,reset:p}=await w({x:u,y:d,initialPlacement:i,placement:a,strategy:o,middlewareData:h,rects:f,platform:s,elements:{reference:e,floating:t}});u=_??u,d=x??d,h=C({},h,{[y]:C({},h[y],g)}),p&&m<=50&&(m++,typeof p=="object"&&(p.placement&&(a=p.placement),p.rects&&(f=p.rects===!0?await s.getElementRects({reference:e,floating:t,strategy:o}):p.rects),{x:u,y:d}=dt(f,a,c)),b=-1)}return{x:u,y:d,placement:a,strategy:o,middlewareData:h}};async function jt(e,t){var n;t===void 0&&(t={});const{x:i,y:o,platform:r,rects:s,elements:l,strategy:c}=e,{boundary:f="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:a=!1,padding:h=0}=_e(t,e),m=Ht(h),y=l[a?d==="floating"?"reference":"floating":d],w=He(await r.getClippingRect({element:(n=await(r.isElement==null?void 0:r.isElement(y)))==null||n?y:y.contextElement||await(r.getDocumentElement==null?void 0:r.getDocumentElement(l.floating)),boundary:f,rootBoundary:u,strategy:c})),_=d==="floating"?{x:i,y:o,width:s.floating.width,height:s.floating.height}:s.reference,x=await(r.getOffsetParent==null?void 0:r.getOffsetParent(l.floating)),g=await(r.isElement==null?void 0:r.isElement(x))?await(r.getScale==null?void 0:r.getScale(x))||{x:1,y:1}:{x:1,y:1},p=He(r.convertOffsetParentRelativeRectToViewportRelativeRect?await r.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:_,offsetParent:x,strategy:c}):_);return{top:(w.top-p.top+m.top)/g.y,bottom:(p.bottom-w.bottom+m.bottom)/g.y,left:(w.left-p.left+m.left)/g.x,right:(p.right-w.right+m.right)/g.x}}const Rn=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:i,placement:o,rects:r,platform:s,elements:l,middlewareData:c}=t,{element:f,padding:u=0}=_e(e,t)||{};if(f==null)return{};const d=Ht(u),a={x:n,y:i},h=ot(o),m=it(h),b=await s.getDimensions(f),y=h==="y",w=y?"top":"left",_=y?"bottom":"right",x=y?"clientHeight":"clientWidth",g=r.reference[m]+r.reference[h]-a[h]-r.floating[m],p=a[h]-r.reference[h],v=await(s.getOffsetParent==null?void 0:s.getOffsetParent(f));let T=v?v[x]:0;(!T||!await(s.isElement==null?void 0:s.isElement(v)))&&(T=l.floating[x]||r.floating[m]);const q=g/2-p/2,F=T/2-b[m]/2-1,N=ye(d[w],F),k=ye(d[_],F),R=N,ne=T-b[m]-k,L=T/2-b[m]/2+q,ue=Xe(R,L,ne),D=!c.arrow&&Ne(o)!=null&&L!==ue&&r.reference[m]/2-(L<R?N:k)-b[m]/2<0,de=D?L<R?L-R:L-ne:0;return{[h]:a[h]+de,data:C({[h]:ue,centerOffset:L-ue-de},D&&{alignmentOffset:de}),reset:D}}}),Ln=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(n){var i,o;const{placement:r,middlewareData:s,rects:l,initialPlacement:c,platform:f,elements:u}=n,d=_e(t,n),{mainAxis:a=!0,crossAxis:h=!0,fallbackPlacements:m,fallbackStrategy:b="bestFit",fallbackAxisSideDirection:y="none",flipAlignment:w=!0}=d,_=kt(d,In);if((i=s.arrow)!=null&&i.alignmentOffset)return{};const x=ce(r),g=xe(c),p=ce(c)===c,v=await(f.isRTL==null?void 0:f.isRTL(u.floating)),T=m||(p||!w?[Be(c)]:An(c)),q=y!=="none";!m&&q&&T.push(...Tn(c,w,y,v));const F=[c,...T],N=await jt(n,_),k=[];let R=((o=s.flip)==null?void 0:o.overflows)||[];if(a&&k.push(N[x]),h){const D=On(r,l,v);k.push(N[D[0]],N[D[1]])}if(R=[...R,{placement:r,overflows:k}],!k.every(D=>D<=0)){var ne,L;const D=(((ne=s.flip)==null?void 0:ne.index)||0)+1,de=F[D];if(de)return{data:{index:D,overflows:R},reset:{placement:de}};let Ee=(L=R.filter(he=>he.overflows[0]<=0).sort((he,X)=>he.overflows[1]-X.overflows[1])[0])==null?void 0:L.placement;if(!Ee)switch(b){case"bestFit":{var ue;const he=(ue=R.filter(X=>{if(q){const K=xe(X.placement);return K===g||K==="y"}return!0}).map(X=>[X.placement,X.overflows.filter(K=>K>0).reduce((K,en)=>K+en,0)]).sort((X,K)=>X[1]-K[1])[0])==null?void 0:ue[0];he&&(Ee=he);break}case"initialPlacement":Ee=c;break}if(r!==Ee)return{reset:{placement:Ee}}}return{}}}},Pn=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(n){const{x:i,y:o,placement:r}=n,s=_e(t,n),{mainAxis:l=!0,crossAxis:c=!1,limiter:f={fn:_=>{let{x,y:g}=_;return{x,y:g}}}}=s,u=kt(s,Mn),d={x:i,y:o},a=await jt(n,u),h=xe(ce(r)),m=nt(h);let b=d[m],y=d[h];if(l){const _=m==="y"?"top":"left",x=m==="y"?"bottom":"right",g=b+a[_],p=b-a[x];b=Xe(g,b,p)}if(c){const _=h==="y"?"top":"left",x=h==="y"?"bottom":"right",g=y+a[_],p=y-a[x];y=Xe(g,y,p)}const w=f.fn(C({},n,{[m]:b,[h]:y}));return C({},w,{data:{x:w.x-i,y:w.y-o}})}}},Fn=function(t){return t===void 0&&(t={}),{options:t,fn(n){const{x:i,y:o,placement:r,rects:s,middlewareData:l}=n,{offset:c=0,mainAxis:f=!0,crossAxis:u=!0}=_e(t,n),d={x:i,y:o},a=xe(r),h=nt(a);let m=d[h],b=d[a];const y=_e(c,n),w=typeof y=="number"?{mainAxis:y,crossAxis:0}:C({mainAxis:0,crossAxis:0},y);if(f){const g=h==="y"?"height":"width",p=s.reference[h]-s.floating[g]+w.mainAxis,v=s.reference[h]+s.reference[g]-w.mainAxis;m<p?m=p:m>v&&(m=v)}if(u){var _,x;const g=h==="y"?"width":"height",p=["top","left"].includes(ce(r)),v=s.reference[a]-s.floating[g]+(p&&((_=l.offset)==null?void 0:_[a])||0)+(p?0:w.crossAxis),T=s.reference[a]+s.reference[g]+(p?0:((x=l.offset)==null?void 0:x[a])||0)-(p?w.crossAxis:0);b<v?b=v:b>T&&(b=T)}return{[h]:m,[a]:b}}}};function Ae(e){return Nt(e)?(e.nodeName||"").toLowerCase():"#document"}function I(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function W(e){var t;return(t=(Nt(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Nt(e){return e instanceof Node||e instanceof I(e).Node}function B(e){return e instanceof Element||e instanceof I(e).Element}function V(e){return e instanceof HTMLElement||e instanceof I(e).HTMLElement}function ht(e){return typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof I(e).ShadowRoot}function Re(e){const{overflow:t,overflowX:n,overflowY:i,display:o}=H(e);return/auto|scroll|overlay|hidden|clip/.test(t+i+n)&&!["inline","contents"].includes(o)}function Dn(e){return["table","td","th"].includes(Ae(e))}function Ve(e){return[":popover-open",":modal"].some(t=>{try{return e.matches(t)}catch{return!1}})}function st(e){const t=rt(),n=B(e)?H(e):e;return n.transform!=="none"||n.perspective!=="none"||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||["transform","perspective","filter"].some(i=>(n.willChange||"").includes(i))||["paint","layout","strict","content"].some(i=>(n.contain||"").includes(i))}function Bn(e){let t=J(e);for(;V(t)&&!ve(t);){if(st(t))return t;if(Ve(t))return null;t=J(t)}return null}function rt(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}function ve(e){return["html","body","#document"].includes(Ae(e))}function H(e){return I(e).getComputedStyle(e)}function $e(e){return B(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function J(e){if(Ae(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ht(e)&&e.host||W(e);return ht(t)?t.host:t}function Vt(e){const t=J(e);return ve(t)?e.ownerDocument?e.ownerDocument.body:e.body:V(t)&&Re(t)?t:Vt(t)}function Ie(e,t,n){var i;t===void 0&&(t=[]),n===void 0&&(n=!0);const o=Vt(e),r=o===((i=e.ownerDocument)==null?void 0:i.body),s=I(o);return r?t.concat(s,s.visualViewport||[],Re(o)?o:[],s.frameElement&&n?Ie(s.frameElement):[]):t.concat(o,Ie(o,[],n))}function $t(e){const t=H(e);let n=parseFloat(t.width)||0,i=parseFloat(t.height)||0;const o=V(e),r=o?e.offsetWidth:n,s=o?e.offsetHeight:i,l=De(n)!==r||De(i)!==s;return l&&(n=r,i=s),{width:n,height:i,$:l}}function lt(e){return B(e)?e:e.contextElement}function be(e){const t=lt(e);if(!V(t))return G(1);const n=t.getBoundingClientRect(),{width:i,height:o,$:r}=$t(t);let s=(r?De(n.width):n.width)/i,l=(r?De(n.height):n.height)/o;return(!s||!Number.isFinite(s))&&(s=1),(!l||!Number.isFinite(l))&&(l=1),{x:s,y:l}}const Hn=G(0);function Wt(e){const t=I(e);return!rt()||!t.visualViewport?Hn:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function jn(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==I(e)?!1:t}function fe(e,t,n,i){t===void 0&&(t=!1),n===void 0&&(n=!1);const o=e.getBoundingClientRect(),r=lt(e);let s=G(1);t&&(i?B(i)&&(s=be(i)):s=be(e));const l=jn(r,n,i)?Wt(r):G(0);let c=(o.left+l.x)/s.x,f=(o.top+l.y)/s.y,u=o.width/s.x,d=o.height/s.y;if(r){const a=I(r),h=i&&B(i)?I(i):i;let m=a,b=m.frameElement;for(;b&&i&&h!==m;){const y=be(b),w=b.getBoundingClientRect(),_=H(b),x=w.left+(b.clientLeft+parseFloat(_.paddingLeft))*y.x,g=w.top+(b.clientTop+parseFloat(_.paddingTop))*y.y;c*=y.x,f*=y.y,u*=y.x,d*=y.y,c+=x,f+=g,m=I(b),b=m.frameElement}}return He({width:u,height:d,x:c,y:f})}function Nn(e){let{elements:t,rect:n,offsetParent:i,strategy:o}=e;const r=o==="fixed",s=W(i),l=t?Ve(t.floating):!1;if(i===s||l&&r)return n;let c={scrollLeft:0,scrollTop:0},f=G(1);const u=G(0),d=V(i);if((d||!d&&!r)&&((Ae(i)!=="body"||Re(s))&&(c=$e(i)),V(i))){const a=fe(i);f=be(i),u.x=a.x+i.clientLeft,u.y=a.y+i.clientTop}return{width:n.width*f.x,height:n.height*f.y,x:n.x*f.x-c.scrollLeft*f.x+u.x,y:n.y*f.y-c.scrollTop*f.y+u.y}}function Vn(e){return Array.from(e.getClientRects())}function Ut(e){return fe(W(e)).left+$e(e).scrollLeft}function $n(e){const t=W(e),n=$e(e),i=e.ownerDocument.body,o=se(t.scrollWidth,t.clientWidth,i.scrollWidth,i.clientWidth),r=se(t.scrollHeight,t.clientHeight,i.scrollHeight,i.clientHeight);let s=-n.scrollLeft+Ut(e);const l=-n.scrollTop;return H(i).direction==="rtl"&&(s+=se(t.clientWidth,i.clientWidth)-o),{width:o,height:r,x:s,y:l}}function Wn(e,t){const n=I(e),i=W(e),o=n.visualViewport;let r=i.clientWidth,s=i.clientHeight,l=0,c=0;if(o){r=o.width,s=o.height;const f=rt();(!f||f&&t==="fixed")&&(l=o.offsetLeft,c=o.offsetTop)}return{width:r,height:s,x:l,y:c}}function Un(e,t){const n=fe(e,!0,t==="fixed"),i=n.top+e.clientTop,o=n.left+e.clientLeft,r=V(e)?be(e):G(1),s=e.clientWidth*r.x,l=e.clientHeight*r.y,c=o*r.x,f=i*r.y;return{width:s,height:l,x:c,y:f}}function pt(e,t,n){let i;if(t==="viewport")i=Wn(e,n);else if(t==="document")i=$n(W(e));else if(B(t))i=Un(t,n);else{const o=Wt(e);i=C({},t,{x:t.x-o.x,y:t.y-o.y})}return He(i)}function zt(e,t){const n=J(e);return n===t||!B(n)||ve(n)?!1:H(n).position==="fixed"||zt(n,t)}function zn(e,t){const n=t.get(e);if(n)return n;let i=Ie(e,[],!1).filter(l=>B(l)&&Ae(l)!=="body"),o=null;const r=H(e).position==="fixed";let s=r?J(e):e;for(;B(s)&&!ve(s);){const l=H(s),c=st(s);!c&&l.position==="fixed"&&(o=null),(r?!c&&!o:!c&&l.position==="static"&&!!o&&["absolute","fixed"].includes(o.position)||Re(s)&&!c&&zt(e,s))?i=i.filter(u=>u!==s):o=l,s=J(s)}return t.set(e,i),i}function Yn(e){let{element:t,boundary:n,rootBoundary:i,strategy:o}=e;const s=[...n==="clippingAncestors"?Ve(t)?[]:zn(t,this._c):[].concat(n),i],l=s[0],c=s.reduce((f,u)=>{const d=pt(t,u,o);return f.top=se(d.top,f.top),f.right=ye(d.right,f.right),f.bottom=ye(d.bottom,f.bottom),f.left=se(d.left,f.left),f},pt(t,l,o));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function qn(e){const{width:t,height:n}=$t(e);return{width:t,height:n}}function Xn(e,t,n){const i=V(t),o=W(t),r=n==="fixed",s=fe(e,!0,r,t);let l={scrollLeft:0,scrollTop:0};const c=G(0);if(i||!i&&!r)if((Ae(t)!=="body"||Re(o))&&(l=$e(t)),i){const d=fe(t,!0,r,t);c.x=d.x+t.clientLeft,c.y=d.y+t.clientTop}else o&&(c.x=Ut(o));const f=s.left+l.scrollLeft-c.x,u=s.top+l.scrollTop-c.y;return{x:f,y:u,width:s.width,height:s.height}}function Ye(e){return H(e).position==="static"}function mt(e,t){return!V(e)||H(e).position==="fixed"?null:t?t(e):e.offsetParent}function Yt(e,t){const n=I(e);if(Ve(e))return n;if(!V(e)){let o=J(e);for(;o&&!ve(o);){if(B(o)&&!Ye(o))return o;o=J(o)}return n}let i=mt(e,t);for(;i&&Dn(i)&&Ye(i);)i=mt(i,t);return i&&ve(i)&&Ye(i)&&!st(i)?n:i||Bn(e)||n}const Kn=async function(t){const n=this.getOffsetParent||Yt,i=this.getDimensions,o=await i(t.floating);return{reference:Xn(t.reference,await n(t.floating),t.strategy),floating:{x:0,y:0,width:o.width,height:o.height}}};function Zn(e){return H(e).direction==="rtl"}const Gn={convertOffsetParentRelativeRectToViewportRelativeRect:Nn,getDocumentElement:W,getClippingRect:Yn,getOffsetParent:Yt,getElementRects:Kn,getClientRects:Vn,getDimensions:qn,getScale:be,isElement:B,isRTL:Zn};function Jn(e,t){let n=null,i;const o=W(e);function r(){var l;clearTimeout(i),(l=n)==null||l.disconnect(),n=null}function s(l,c){l===void 0&&(l=!1),c===void 0&&(c=1),r();const{left:f,top:u,width:d,height:a}=e.getBoundingClientRect();if(l||t(),!d||!a)return;const h=Pe(u),m=Pe(o.clientWidth-(f+d)),b=Pe(o.clientHeight-(u+a)),y=Pe(f),_={rootMargin:-h+"px "+-m+"px "+-b+"px "+-y+"px",threshold:se(0,ye(1,c))||1};let x=!0;function g(p){const v=p[0].intersectionRatio;if(v!==c){if(!x)return s();v?s(!1,v):i=setTimeout(()=>{s(!1,1e-7)},1e3)}x=!1}try{n=new IntersectionObserver(g,C({},_,{root:o.ownerDocument}))}catch{n=new IntersectionObserver(g,_)}n.observe(e)}return s(!0),r}function Qn(e,t,n,i){i===void 0&&(i={});const{ancestorScroll:o=!0,ancestorResize:r=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:c=!1}=i,f=lt(e),u=o||r?[...f?Ie(f):[],...Ie(t)]:[];u.forEach(w=>{o&&w.addEventListener("scroll",n,{passive:!0}),r&&w.addEventListener("resize",n)});const d=f&&l?Jn(f,n):null;let a=-1,h=null;s&&(h=new ResizeObserver(w=>{let[_]=w;_&&_.target===f&&h&&(h.unobserve(t),cancelAnimationFrame(a),a=requestAnimationFrame(()=>{var x;(x=h)==null||x.observe(t)})),n()}),f&&!c&&h.observe(f),h.observe(t));let m,b=c?fe(e):null;c&&y();function y(){const w=fe(e);b&&(w.x!==b.x||w.y!==b.y||w.width!==b.width||w.height!==b.height)&&n(),b=w,m=requestAnimationFrame(y)}return n(),()=>{var w;u.forEach(_=>{o&&_.removeEventListener("scroll",n),r&&_.removeEventListener("resize",n)}),d==null||d(),(w=h)==null||w.disconnect(),h=null,c&&cancelAnimationFrame(m)}}const ei=Pn,ti=Ln,ni=Rn,ii=Fn,oi=(e,t,n)=>{const i=new Map,o=C({platform:Gn},n),r=C({},o.platform,{_c:i});return kn(e,t,C({},o,{platform:r}))};function si(e){e.cleanup&&e.cleanup();const t=e._getResolvedAttachToOptions();let n=t.element;const i=ui(t,e),o=Dt(t);return o&&(n=document.body,e.shepherdElementComponent.getElement().classList.add("shepherd-centered")),e.cleanup=Qn(n,e.el,()=>{if(!e.el){e.cleanup==null||e.cleanup();return}ci(n,e,i,o)}),e.target=t.element,i}function ri(e,t){return{floatingUIOptions:et(e.floatingUIOptions||{},t.floatingUIOptions||{})}}function li(e){e.cleanup&&e.cleanup(),e.cleanup=null}function ci(e,t,n,i){return oi(e,t.el,n).then(fi(t,i)).then(o=>new Promise(r=>{setTimeout(()=>r(o),300)})).then(o=>{o!=null&&o.el&&o.el.focus({preventScroll:!0})})}function fi(e,t){return({x:n,y:i,placement:o,middlewareData:r})=>(e.el&&(t?Object.assign(e.el.style,{position:"fixed",left:"50%",top:"50%",transform:"translate(-50%, -50%)"}):Object.assign(e.el.style,{position:"absolute",left:`${n}px`,top:`${i}px`}),e.el.dataset.popperPlacement=o,ai(e.el,r)),e)}function ai(e,t){const n=e.querySelector(".shepherd-arrow");if(ke(n)&&t.arrow){const{x:i,y:o}=t.arrow;Object.assign(n.style,{left:i!=null?`${i}px`:"",top:o!=null?`${o}px`:""})}}function ui(e,t){const n={strategy:"absolute"};n.middleware=[];const i=di(t);if(!Dt(e)){if(n.middleware.push(ti(),ei({limiter:ii(),crossAxis:!0})),i){var r,s;const l=(e==null||(r=e.on)==null?void 0:r.includes("-start"))||(e==null||(s=e.on)==null?void 0:s.includes("-end"));n.middleware.push(ni({element:i,padding:l?4:0}))}n.placement=e.on}return et(t.options.floatingUIOptions||{},n)}function di(e){return e.options.arrow&&e.el?e.el.querySelector(".shepherd-arrow"):!1}function M(){}function hi(e,t){for(const n in t)e[n]=t[n];return e}function qt(e){return e()}function gt(){return Object.create(null)}function Le(e){e.forEach(qt)}function ct(e){return typeof e=="function"}function U(e,t){return e!=e?t==t:e!==t||e&&typeof e=="object"||typeof e=="function"}function pi(e){return Object.keys(e).length===0}function Se(e,t){e.appendChild(t)}function j(e,t,n){e.insertBefore(t,n||null)}function P(e){e.parentNode&&e.parentNode.removeChild(e)}function mi(e,t){for(let n=0;n<e.length;n+=1)e[n]&&e[n].d(t)}function $(e){return document.createElement(e)}function bt(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function Xt(e){return document.createTextNode(e)}function je(){return Xt(" ")}function gi(){return Xt("")}function We(e,t,n,i){return e.addEventListener(t,n,i),()=>e.removeEventListener(t,n,i)}function O(e,t,n){n==null?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}const bi=["width","height"];function wt(e,t){const n=Object.getOwnPropertyDescriptors(e.__proto__);for(const i in t)t[i]==null?e.removeAttribute(i):i==="style"?e.style.cssText=t[i]:i==="__value"?e.value=e[i]=t[i]:n[i]&&n[i].set&&bi.indexOf(i)===-1?e[i]=t[i]:O(e,i,t[i])}function wi(e){return Array.from(e.childNodes)}function pe(e,t,n){e.classList.toggle(t,!!n)}let Me;function Te(e){Me=e}function Kt(){if(!Me)throw new Error("Function called outside component initialization");return Me}function yi(e){Kt().$$.on_mount.push(e)}function ft(e){Kt().$$.after_update.push(e)}const ge=[],Oe=[];let we=[];const yt=[],_i=Promise.resolve();let Ze=!1;function xi(){Ze||(Ze=!0,_i.then(Zt))}function Ge(e){we.push(e)}const qe=new Set;let me=0;function Zt(){if(me!==0)return;const e=Me;do{try{for(;me<ge.length;){const t=ge[me];me++,Te(t),vi(t.$$)}}catch(t){throw ge.length=0,me=0,t}for(Te(null),ge.length=0,me=0;Oe.length;)Oe.pop()();for(let t=0;t<we.length;t+=1){const n=we[t];qe.has(n)||(qe.add(n),n())}we.length=0}while(ge.length);for(;yt.length;)yt.pop()();Ze=!1,qe.clear(),Te(e)}function vi(e){if(e.fragment!==null){e.update(),Le(e.before_update);const t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(Ge)}}function Si(e){const t=[],n=[];we.forEach(i=>e.indexOf(i)===-1?t.push(i):n.push(i)),n.forEach(i=>i()),we=t}const Fe=new Set;let ie;function re(){ie={r:0,c:[],p:ie}}function le(){ie.r||Le(ie.c),ie=ie.p}function S(e,t){e&&e.i&&(Fe.delete(e),e.i(t))}function A(e,t,n,i){if(e&&e.o){if(Fe.has(e))return;Fe.add(e),ie.c.push(()=>{Fe.delete(e),i&&(n&&e.d(1),i())}),e.o(t)}else i&&i()}function _t(e){return(e==null?void 0:e.length)!==void 0?e:Array.from(e)}function Oi(e,t){const n={},i={},o={$$scope:1};let r=e.length;for(;r--;){const s=e[r],l=t[r];if(l){for(const c in s)c in l||(i[c]=1);for(const c in l)o[c]||(n[c]=l[c],o[c]=1);e[r]=l}else for(const c in s)o[c]=1}for(const s in i)s in n||(n[s]=void 0);return n}function ae(e){e&&e.c()}function ee(e,t,n){const{fragment:i,after_update:o}=e.$$;i&&i.m(t,n),Ge(()=>{const r=e.$$.on_mount.map(qt).filter(ct);e.$$.on_destroy?e.$$.on_destroy.push(...r):Le(r),e.$$.on_mount=[]}),o.forEach(Ge)}function te(e,t){const n=e.$$;n.fragment!==null&&(Si(n.after_update),Le(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function Ai(e,t){e.$$.dirty[0]===-1&&(ge.push(e),xi(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}function z(e,t,n,i,o,r,s=null,l=[-1]){const c=Me;Te(e);const f=e.$$={fragment:null,ctx:[],props:r,update:M,not_equal:o,bound:gt(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(t.context||(c?c.$$.context:[])),callbacks:gt(),dirty:l,skip_bound:!1,root:t.target||c.$$.root};s&&s(f.root);let u=!1;if(f.ctx=n?n(e,t.props||{},(d,a,...h)=>{const m=h.length?h[0]:a;return f.ctx&&o(f.ctx[d],f.ctx[d]=m)&&(!f.skip_bound&&f.bound[d]&&f.bound[d](m),u&&Ai(e,d)),a}):[],f.update(),u=!0,Le(f.before_update),f.fragment=i?i(f.ctx):!1,t.target){if(t.hydrate){const d=wi(t.target);f.fragment&&f.fragment.l(d),d.forEach(P)}else f.fragment&&f.fragment.c();t.intro&&S(e.$$.fragment),ee(e,t.target,t.anchor),Zt()}Te(c)}class Y{constructor(){this.$$=void 0,this.$$set=void 0}$destroy(){te(this,1),this.$destroy=M}$on(t,n){if(!ct(n))return M;const i=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return i.push(n),()=>{const o=i.indexOf(n);o!==-1&&i.splice(o,1)}}$set(t){this.$$set&&!pi(t)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}const Ei="4";typeof window<"u"&&(window.__svelte||(window.__svelte={v:new Set})).v.add(Ei);function Ti(e){let t,n,i,o,r;return{c(){t=$("button"),O(t,"aria-label",n=e[3]?e[3]:null),O(t,"class",i=`${e[1]||""} shepherd-button ${e[4]?"shepherd-button-secondary":""}`),t.disabled=e[2],O(t,"tabindex","0"),O(t,"type","button")},m(s,l){j(s,t,l),t.innerHTML=e[5],o||(r=We(t,"click",function(){ct(e[0])&&e[0].apply(this,arguments)}),o=!0)},p(s,[l]){e=s,l&32&&(t.innerHTML=e[5]),l&8&&n!==(n=e[3]?e[3]:null)&&O(t,"aria-label",n),l&18&&i!==(i=`${e[1]||""} shepherd-button ${e[4]?"shepherd-button-secondary":""}`)&&O(t,"class",i),l&4&&(t.disabled=e[2])},i:M,o:M,d(s){s&&P(t),o=!1,r()}}}function Ci(e,t,n){let{config:i,step:o}=t,r,s,l,c,f,u;function d(a){return Z(a)?a=a.call(o):a}return e.$$set=a=>{"config"in a&&n(6,i=a.config),"step"in a&&n(7,o=a.step)},e.$$.update=()=>{e.$$.dirty&192&&(n(0,r=i.action?i.action.bind(o.tour):null),n(1,s=i.classes),n(2,l=i.disabled?d(i.disabled):!1),n(3,c=i.label?d(i.label):null),n(4,f=i.secondary),n(5,u=i.text?d(i.text):null))},[r,s,l,c,f,u,i,o]}class Ii extends Y{constructor(t){super(),z(this,t,Ci,Ti,U,{config:6,step:7})}}function xt(e,t,n){const i=e.slice();return i[2]=t[n],i}function vt(e){let t,n,i=_t(e[1]),o=[];for(let s=0;s<i.length;s+=1)o[s]=St(xt(e,i,s));const r=s=>A(o[s],1,1,()=>{o[s]=null});return{c(){for(let s=0;s<o.length;s+=1)o[s].c();t=gi()},m(s,l){for(let c=0;c<o.length;c+=1)o[c]&&o[c].m(s,l);j(s,t,l),n=!0},p(s,l){if(l&3){i=_t(s[1]);let c;for(c=0;c<i.length;c+=1){const f=xt(s,i,c);o[c]?(o[c].p(f,l),S(o[c],1)):(o[c]=St(f),o[c].c(),S(o[c],1),o[c].m(t.parentNode,t))}for(re(),c=i.length;c<o.length;c+=1)r(c);le()}},i(s){if(!n){for(let l=0;l<i.length;l+=1)S(o[l]);n=!0}},o(s){o=o.filter(Boolean);for(let l=0;l<o.length;l+=1)A(o[l]);n=!1},d(s){s&&P(t),mi(o,s)}}}function St(e){let t,n;return t=new Ii({props:{config:e[2],step:e[0]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&2&&(r.config=i[2]),o&1&&(r.step=i[0]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function Mi(e){let t,n,i=e[1]&&vt(e);return{c(){t=$("footer"),i&&i.c(),O(t,"class","shepherd-footer")},m(o,r){j(o,t,r),i&&i.m(t,null),n=!0},p(o,[r]){o[1]?i?(i.p(o,r),r&2&&S(i,1)):(i=vt(o),i.c(),S(i,1),i.m(t,null)):i&&(re(),A(i,1,1,()=>{i=null}),le())},i(o){n||(S(i),n=!0)},o(o){A(i),n=!1},d(o){o&&P(t),i&&i.d()}}}function ki(e,t,n){let i,{step:o}=t;return e.$$set=r=>{"step"in r&&n(0,o=r.step)},e.$$.update=()=>{e.$$.dirty&1&&n(1,i=o.options.buttons)},[o,i]}class Ri extends Y{constructor(t){super(),z(this,t,ki,Mi,U,{step:0})}}function Li(e){let t,n,i,o,r;return{c(){t=$("button"),n=$("span"),n.textContent="×",O(n,"aria-hidden","true"),O(t,"aria-label",i=e[0].label?e[0].label:"Close Tour"),O(t,"class","shepherd-cancel-icon"),O(t,"type","button")},m(s,l){j(s,t,l),Se(t,n),o||(r=We(t,"click",e[1]),o=!0)},p(s,[l]){l&1&&i!==(i=s[0].label?s[0].label:"Close Tour")&&O(t,"aria-label",i)},i:M,o:M,d(s){s&&P(t),o=!1,r()}}}function Pi(e,t,n){let{cancelIcon:i,step:o}=t;const r=s=>{s.preventDefault(),o.cancel()};return e.$$set=s=>{"cancelIcon"in s&&n(0,i=s.cancelIcon),"step"in s&&n(2,o=s.step)},[i,r,o]}class Fi extends Y{constructor(t){super(),z(this,t,Pi,Li,U,{cancelIcon:0,step:2})}}function Di(e){let t;return{c(){t=$("h3"),O(t,"id",e[1]),O(t,"class","shepherd-title")},m(n,i){j(n,t,i),e[3](t)},p(n,[i]){i&2&&O(t,"id",n[1])},i:M,o:M,d(n){n&&P(t),e[3](null)}}}function Bi(e,t,n){let{labelId:i,element:o,title:r}=t;ft(()=>{Z(r)&&n(2,r=r()),n(0,o.innerHTML=r,o)});function s(l){Oe[l?"unshift":"push"](()=>{o=l,n(0,o)})}return e.$$set=l=>{"labelId"in l&&n(1,i=l.labelId),"element"in l&&n(0,o=l.element),"title"in l&&n(2,r=l.title)},[o,i,r,s]}class Hi extends Y{constructor(t){super(),z(this,t,Bi,Di,U,{labelId:1,element:0,title:2})}}function Ot(e){let t,n;return t=new Hi({props:{labelId:e[0],title:e[2]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&1&&(r.labelId=i[0]),o&4&&(r.title=i[2]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function At(e){let t,n;return t=new Fi({props:{cancelIcon:e[3],step:e[1]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&8&&(r.cancelIcon=i[3]),o&2&&(r.step=i[1]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function ji(e){let t,n,i,o=e[2]&&Ot(e),r=e[3]&&e[3].enabled&&At(e);return{c(){t=$("header"),o&&o.c(),n=je(),r&&r.c(),O(t,"class","shepherd-header")},m(s,l){j(s,t,l),o&&o.m(t,null),Se(t,n),r&&r.m(t,null),i=!0},p(s,[l]){s[2]?o?(o.p(s,l),l&4&&S(o,1)):(o=Ot(s),o.c(),S(o,1),o.m(t,n)):o&&(re(),A(o,1,1,()=>{o=null}),le()),s[3]&&s[3].enabled?r?(r.p(s,l),l&8&&S(r,1)):(r=At(s),r.c(),S(r,1),r.m(t,null)):r&&(re(),A(r,1,1,()=>{r=null}),le())},i(s){i||(S(o),S(r),i=!0)},o(s){A(o),A(r),i=!1},d(s){s&&P(t),o&&o.d(),r&&r.d()}}}function Ni(e,t,n){let{labelId:i,step:o}=t,r,s;return e.$$set=l=>{"labelId"in l&&n(0,i=l.labelId),"step"in l&&n(1,o=l.step)},e.$$.update=()=>{e.$$.dirty&2&&(n(2,r=o.options.title),n(3,s=o.options.cancelIcon))},[i,o,r,s]}class Vi extends Y{constructor(t){super(),z(this,t,Ni,ji,U,{labelId:0,step:1})}}function $i(e){let t;return{c(){t=$("div"),O(t,"class","shepherd-text"),O(t,"id",e[1])},m(n,i){j(n,t,i),e[3](t)},p(n,[i]){i&2&&O(t,"id",n[1])},i:M,o:M,d(n){n&&P(t),e[3](null)}}}function Wi(e,t,n){let{descriptionId:i,element:o,step:r}=t;ft(()=>{let{text:l}=r.options;Z(l)&&(l=l.call(r)),ke(l)?o.appendChild(l):n(0,o.innerHTML=l,o)});function s(l){Oe[l?"unshift":"push"](()=>{o=l,n(0,o)})}return e.$$set=l=>{"descriptionId"in l&&n(1,i=l.descriptionId),"element"in l&&n(0,o=l.element),"step"in l&&n(2,r=l.step)},[o,i,r,s]}class Ui extends Y{constructor(t){super(),z(this,t,Wi,$i,U,{descriptionId:1,element:0,step:2})}}function Et(e){let t,n;return t=new Vi({props:{labelId:e[1],step:e[2]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&2&&(r.labelId=i[1]),o&4&&(r.step=i[2]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function Tt(e){let t,n;return t=new Ui({props:{descriptionId:e[0],step:e[2]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&1&&(r.descriptionId=i[0]),o&4&&(r.step=i[2]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function Ct(e){let t,n;return t=new Ri({props:{step:e[2]}}),{c(){ae(t.$$.fragment)},m(i,o){ee(t,i,o),n=!0},p(i,o){const r={};o&4&&(r.step=i[2]),t.$set(r)},i(i){n||(S(t.$$.fragment,i),n=!0)},o(i){A(t.$$.fragment,i),n=!1},d(i){te(t,i)}}}function zi(e){let t,n=!E(e[2].options.title)||e[2].options.cancelIcon&&e[2].options.cancelIcon.enabled,i,o=!E(e[2].options.text),r,s=Array.isArray(e[2].options.buttons)&&e[2].options.buttons.length,l,c=n&&Et(e),f=o&&Tt(e),u=s&&Ct(e);return{c(){t=$("div"),c&&c.c(),i=je(),f&&f.c(),r=je(),u&&u.c(),O(t,"class","shepherd-content")},m(d,a){j(d,t,a),c&&c.m(t,null),Se(t,i),f&&f.m(t,null),Se(t,r),u&&u.m(t,null),l=!0},p(d,[a]){a&4&&(n=!E(d[2].options.title)||d[2].options.cancelIcon&&d[2].options.cancelIcon.enabled),n?c?(c.p(d,a),a&4&&S(c,1)):(c=Et(d),c.c(),S(c,1),c.m(t,i)):c&&(re(),A(c,1,1,()=>{c=null}),le()),a&4&&(o=!E(d[2].options.text)),o?f?(f.p(d,a),a&4&&S(f,1)):(f=Tt(d),f.c(),S(f,1),f.m(t,r)):f&&(re(),A(f,1,1,()=>{f=null}),le()),a&4&&(s=Array.isArray(d[2].options.buttons)&&d[2].options.buttons.length),s?u?(u.p(d,a),a&4&&S(u,1)):(u=Ct(d),u.c(),S(u,1),u.m(t,null)):u&&(re(),A(u,1,1,()=>{u=null}),le())},i(d){l||(S(c),S(f),S(u),l=!0)},o(d){A(c),A(f),A(u),l=!1},d(d){d&&P(t),c&&c.d(),f&&f.d(),u&&u.d()}}}function Yi(e,t,n){let{descriptionId:i,labelId:o,step:r}=t;return e.$$set=s=>{"descriptionId"in s&&n(0,i=s.descriptionId),"labelId"in s&&n(1,o=s.labelId),"step"in s&&n(2,r=s.step)},[i,o,r]}class qi extends Y{constructor(t){super(),z(this,t,Yi,zi,U,{descriptionId:0,labelId:1,step:2})}}function It(e){let t;return{c(){t=$("div"),O(t,"class","shepherd-arrow"),O(t,"data-popper-arrow","")},m(n,i){j(n,t,i)},d(n){n&&P(t)}}}function Xi(e){let t,n,i,o,r,s,l,c,f=e[4].options.arrow&&e[4].options.attachTo&&e[4].options.attachTo.element&&e[4].options.attachTo.on&&It();i=new qi({props:{descriptionId:e[2],labelId:e[3],step:e[4]}});let u=[{"aria-describedby":o=E(e[4].options.text)?null:e[2]},{"aria-labelledby":r=e[4].options.title?e[3]:null},e[1],{role:"dialog"},{tabindex:"0"}],d={};for(let a=0;a<u.length;a+=1)d=hi(d,u[a]);return{c(){t=$("div"),f&&f.c(),n=je(),ae(i.$$.fragment),wt(t,d),pe(t,"shepherd-has-cancel-icon",e[5]),pe(t,"shepherd-has-title",e[6]),pe(t,"shepherd-element",!0)},m(a,h){j(a,t,h),f&&f.m(t,null),Se(t,n),ee(i,t,null),e[13](t),s=!0,l||(c=We(t,"keydown",e[7]),l=!0)},p(a,[h]){a[4].options.arrow&&a[4].options.attachTo&&a[4].options.attachTo.element&&a[4].options.attachTo.on?f||(f=It(),f.c(),f.m(t,n)):f&&(f.d(1),f=null);const m={};h&4&&(m.descriptionId=a[2]),h&8&&(m.labelId=a[3]),h&16&&(m.step=a[4]),i.$set(m),wt(t,d=Oi(u,[(!s||h&20&&o!==(o=E(a[4].options.text)?null:a[2]))&&{"aria-describedby":o},(!s||h&24&&r!==(r=a[4].options.title?a[3]:null))&&{"aria-labelledby":r},h&2&&a[1],{role:"dialog"},{tabindex:"0"}])),pe(t,"shepherd-has-cancel-icon",a[5]),pe(t,"shepherd-has-title",a[6]),pe(t,"shepherd-element",!0)},i(a){s||(S(i.$$.fragment,a),s=!0)},o(a){A(i.$$.fragment,a),s=!1},d(a){a&&P(t),f&&f.d(),te(i),e[13](null),l=!1,c()}}}const Ki=9,Zi=27,Gi=37,Ji=39;function Mt(e){return e.split(" ").filter(t=>!!t.length)}function Qi(e,t,n){let{classPrefix:i,element:o,descriptionId:r,firstFocusableElement:s,focusableElements:l,labelId:c,lastFocusableElement:f,step:u,dataStepId:d}=t,a,h,m;const b=()=>o;yi(()=>{n(1,d={[`data-${i}shepherd-step-id`]:u.id}),n(9,l=o.querySelectorAll('a[href], area[href], input:not([disabled]), select:not([disabled]), textarea:not([disabled]), button:not([disabled]), [tabindex="0"]')),n(8,s=l[0]),n(10,f=l[l.length-1])}),ft(()=>{m!==u.options.classes&&y()});function y(){w(m),m=u.options.classes,_(m)}function w(p){if(Ce(p)){const v=Mt(p);v.length&&o.classList.remove(...v)}}function _(p){if(Ce(p)){const v=Mt(p);v.length&&o.classList.add(...v)}}const x=p=>{const{tour:v}=u;switch(p.keyCode){case Ki:if(l.length===0){p.preventDefault();break}p.shiftKey?(document.activeElement===s||document.activeElement.classList.contains("shepherd-element"))&&(p.preventDefault(),f.focus()):document.activeElement===f&&(p.preventDefault(),s.focus());break;case Zi:v.options.exitOnEsc&&(p.preventDefault(),p.stopPropagation(),u.cancel());break;case Gi:v.options.keyboardNavigation&&(p.preventDefault(),p.stopPropagation(),v.back());break;case Ji:v.options.keyboardNavigation&&(p.preventDefault(),p.stopPropagation(),v.next());break}};function g(p){Oe[p?"unshift":"push"](()=>{o=p,n(0,o)})}return e.$$set=p=>{"classPrefix"in p&&n(11,i=p.classPrefix),"element"in p&&n(0,o=p.element),"descriptionId"in p&&n(2,r=p.descriptionId),"firstFocusableElement"in p&&n(8,s=p.firstFocusableElement),"focusableElements"in p&&n(9,l=p.focusableElements),"labelId"in p&&n(3,c=p.labelId),"lastFocusableElement"in p&&n(10,f=p.lastFocusableElement),"step"in p&&n(4,u=p.step),"dataStepId"in p&&n(1,d=p.dataStepId)},e.$$.update=()=>{e.$$.dirty&16&&(n(5,a=u.options&&u.options.cancelIcon&&u.options.cancelIcon.enabled),n(6,h=u.options&&u.options.title))},[o,d,r,c,u,a,h,x,s,l,f,i,b,g]}class eo extends Y{constructor(t){super(),z(this,t,Qi,Xi,U,{classPrefix:11,element:0,descriptionId:2,firstFocusableElement:8,focusableElements:9,labelId:3,lastFocusableElement:10,step:4,dataStepId:1,getElement:12})}get getElement(){return this.$$.ctx[12]}}class Je extends Qe{constructor(t,n={}){return super(),this._resolvedAttachTo=void 0,this.classPrefix=void 0,this.el=void 0,this.target=void 0,this.tour=void 0,this.tour=t,this.classPrefix=this.tour.options?Ft(this.tour.options.classPrefix):"",this.styles=t.styles,this._resolvedAttachTo=null,tt(this),this._setOptions(n),this}cancel(){this.tour.cancel(),this.trigger("cancel")}complete(){this.tour.complete(),this.trigger("complete")}destroy(){li(this),ke(this.el)&&(this.el.remove(),this.el=null),this._updateStepTargetOnHide(),this.trigger("destroy")}getTour(){return this.tour}hide(){var t;(t=this.tour.modal)==null||t.hide(),this.trigger("before-hide"),this.el&&(this.el.hidden=!0),this._updateStepTargetOnHide(),this.trigger("hide")}_resolveAttachToOptions(){return this._resolvedAttachTo=xn(this),this._resolvedAttachTo}_getResolvedAttachToOptions(){return this._resolvedAttachTo===null?this._resolveAttachToOptions():this._resolvedAttachTo}isOpen(){return!!(this.el&&!this.el.hidden)}show(){return Z(this.options.beforeShowPromise)?Promise.resolve(this.options.beforeShowPromise()).then(()=>this._show()):Promise.resolve(this._show())}updateStepOptions(t){Object.assign(this.options,t),this.shepherdElementComponent&&this.shepherdElementComponent.$set({step:this})}getElement(){return this.el}getTarget(){return this.target}_createTooltipContent(){const t=`${this.id}-description`,n=`${this.id}-label`;return this.shepherdElementComponent=new eo({target:this.tour.options.stepsContainer||document.body,props:{classPrefix:this.classPrefix,descriptionId:t,labelId:n,step:this,styles:this.styles}}),this.shepherdElementComponent.getElement()}_scrollTo(t){const{element:n}=this._getResolvedAttachToOptions();Z(this.options.scrollToHandler)?this.options.scrollToHandler(n):tn(n)&&typeof n.scrollIntoView=="function"&&n.scrollIntoView(t)}_getClassOptions(t){const n=this.tour&&this.tour.options&&this.tour.options.defaultStepOptions,i=t.classes?t.classes:"",o=n&&n.classes?n.classes:"",r=[...i.split(" "),...o.split(" ")],s=new Set(r);return Array.from(s).join(" ").trim()}_setOptions(t={}){let n=this.tour&&this.tour.options&&this.tour.options.defaultStepOptions;n=et({},n||{}),this.options=Object.assign({arrow:!0},n,t,ri(n,t));const{when:i}=this.options;this.options.classes=this._getClassOptions(t),this.destroy(),this.id=this.options.id||`step-${Bt()}`,i&&Object.keys(i).forEach(o=>{this.on(o,i[o],this)})}_setupElements(){E(this.el)||this.destroy(),this.el=this._createTooltipContent(),this.options.advanceOn&&wn(this),si(this)}_show(){var t;this.trigger("before-show"),this._resolveAttachToOptions(),this._setupElements(),this.tour.modal||this.tour.setupModal(),(t=this.tour.modal)==null||t.setupForStep(this),this._styleTargetElementForStep(this),this.el&&(this.el.hidden=!1),this.options.scrollTo&&setTimeout(()=>{this._scrollTo(this.options.scrollTo)}),this.el&&(this.el.hidden=!1);const n=this.shepherdElementComponent.getElement(),i=this.target||document.body;i.classList.add(`${this.classPrefix}shepherd-enabled`),i.classList.add(`${this.classPrefix}shepherd-target`),n.classList.add("shepherd-enabled"),this.trigger("show")}_styleTargetElementForStep(t){const n=t.target;n&&(t.options.highlightClass&&n.classList.add(t.options.highlightClass),n.classList.remove("shepherd-target-click-disabled"),t.options.canClickTarget===!1&&n.classList.add("shepherd-target-click-disabled"))}_updateStepTargetOnHide(){const t=this.target||document.body;this.options.highlightClass&&t.classList.remove(this.options.highlightClass),t.classList.remove("shepherd-target-click-disabled",`${this.classPrefix}shepherd-enabled`,`${this.classPrefix}shepherd-target`)}}function to(e){if(e){const{steps:t}=e;t.forEach(n=>{n.options&&n.options.canClickTarget===!1&&n.options.attachTo&&ke(n.target)&&n.target.classList.remove("shepherd-target-click-disabled")})}}function no({width:e,height:t,x:n=0,y:i=0,r:o=0}){const{innerWidth:r,innerHeight:s}=window,{topLeft:l=0,topRight:c=0,bottomRight:f=0,bottomLeft:u=0}=typeof o=="number"?{topLeft:o,topRight:o,bottomRight:o,bottomLeft:o}:o;return`M${r},${s}H0V0H${r}V${s}ZM${n+l},${i}a${l},${l},0,0,0-${l},${l}V${t+i-u}a${u},${u},0,0,0,${u},${u}H${e+n-f}a${f},${f},0,0,0,${f}-${f}V${i+c}a${c},${c},0,0,0-${c}-${c}Z`}function io(e){let t,n,i,o,r;return{c(){t=bt("svg"),n=bt("path"),O(n,"d",e[2]),O(t,"class",i=`${e[1]?"shepherd-modal-is-visible":""} shepherd-modal-overlay-container`)},m(s,l){j(s,t,l),Se(t,n),e[11](t),o||(r=We(t,"touchmove",e[3]),o=!0)},p(s,[l]){l&4&&O(n,"d",s[2]),l&2&&i!==(i=`${s[1]?"shepherd-modal-is-visible":""} shepherd-modal-overlay-container`)&&O(t,"class",i)},i:M,o:M,d(s){s&&P(t),e[11](null),o=!1,r()}}}function Gt(e){if(!e)return null;const n=e instanceof HTMLElement&&window.getComputedStyle(e).overflowY;return n!=="hidden"&&n!=="visible"&&e.scrollHeight>=e.clientHeight?e:Gt(e.parentElement)}function oo(e){let t={top:0,left:0};if(!e)return t;let n=e.ownerDocument.defaultView;for(;n!==window.top;){var i;const s=(i=n)==null?void 0:i.frameElement;if(s){var o,r;const l=s.getBoundingClientRect();t.top+=l.top+((o=l.scrollTop)!=null?o:0),t.left+=l.left+((r=l.scrollLeft)!=null?r:0)}n=n.parent}return t}function so(e,t){const n=e.getBoundingClientRect();let i=n.y||n.top,o=n.bottom||i+n.height;if(t){const s=t.getBoundingClientRect(),l=s.y||s.top,c=s.bottom||l+s.height;i=Math.max(i,l),o=Math.min(o,c)}const r=Math.max(o-i,0);return{y:i,height:r}}function ro(e,t,n){let{element:i,openingProperties:o}=t,r=!1,s,l;f();const c=()=>i;function f(){n(4,o={width:0,height:0,x:0,y:0,r:0})}function u(){n(1,r=!1),w()}function d(g=0,p=0,v=0,T=0,q,F){if(F){const{y:N,height:k}=so(F,q),{x:R,width:ne,left:L}=F.getBoundingClientRect();n(4,o={width:ne+g*2,height:k+g*2,x:(R||L)+v-g,y:N+T-g,r:p})}else f()}function a(g){w(),g.tour.options.useModalOverlay?(_(g),h()):u()}function h(){n(1,r=!0)}const m=g=>{g.preventDefault()},b=g=>{g.stopPropagation()};function y(){window.addEventListener("touchmove",m,{passive:!1})}function w(){s&&(cancelAnimationFrame(s),s=void 0),window.removeEventListener("touchmove",m,{passive:!1})}function _(g){const{modalOverlayOpeningPadding:p,modalOverlayOpeningRadius:v,modalOverlayOpeningXOffset:T=0,modalOverlayOpeningYOffset:q=0}=g.options,F=oo(g.target),N=Gt(g.target),k=()=>{s=void 0,d(p,v,T+F.left,q+F.top,N,g.target),s=requestAnimationFrame(k)};k(),y()}function x(g){Oe[g?"unshift":"push"](()=>{i=g,n(0,i)})}return e.$$set=g=>{"element"in g&&n(0,i=g.element),"openingProperties"in g&&n(4,o=g.openingProperties)},e.$$.update=()=>{e.$$.dirty&16&&n(2,l=no(o))},[i,r,l,b,o,c,f,u,d,a,h,x]}class lo extends Y{constructor(t){super(),z(this,t,ro,io,U,{element:0,openingProperties:4,getElement:5,closeModalOpening:6,hide:7,positionModal:8,setupForStep:9,show:10})}get getElement(){return this.$$.ctx[5]}get closeModalOpening(){return this.$$.ctx[6]}get hide(){return this.$$.ctx[7]}get positionModal(){return this.$$.ctx[8]}get setupForStep(){return this.$$.ctx[9]}get show(){return this.$$.ctx[10]}}class co extends Qe{constructor(){super(),this.activeTour=void 0,tt(this)}}class fo extends Qe{constructor(t={}){super(),this.trackedEvents=["active","cancel","complete","show"],this.classPrefix=void 0,this.currentStep=void 0,this.focusedElBeforeOpen=void 0,this.id=void 0,this.modal=void 0,this.options=void 0,this.steps=void 0,tt(this);const n={exitOnEsc:!0,keyboardNavigation:!0};return this.options=Object.assign({},n,t),this.classPrefix=Ft(this.options.classPrefix),this.steps=[],this.addSteps(this.options.steps),["active","cancel","complete","inactive","show","start"].map(o=>{(r=>{this.on(r,s=>{s=s||{},s.tour=this,oe.trigger(r,s)})})(o)}),this._setTourID(t.id),this}addStep(t,n){let i=t;return i instanceof Je?i.tour=this:i=new Je(this,i),E(n)?this.steps.push(i):this.steps.splice(n,0,i),i}addSteps(t){return Array.isArray(t)&&t.forEach(n=>{this.addStep(n)}),this}back(){const t=this.steps.indexOf(this.currentStep);this.show(t-1,!1)}async cancel(){if(this.options.confirmCancel){const t=this.options.confirmCancelMessage||"Are you sure you want to stop the tour?";let n;Z(this.options.confirmCancel)?n=await this.options.confirmCancel():n=window.confirm(t),n&&this._done("cancel")}else this._done("cancel")}complete(){this._done("complete")}getById(t){return this.steps.find(n=>n.id===t)}getCurrentStep(){return this.currentStep}hide(){const t=this.getCurrentStep();if(t)return t.hide()}isActive(){return oe.activeTour===this}next(){const t=this.steps.indexOf(this.currentStep);t===this.steps.length-1?this.complete():this.show(t+1,!0)}removeStep(t){const n=this.getCurrentStep();this.steps.some((i,o)=>{if(i.id===t)return i.isOpen()&&i.hide(),i.destroy(),this.steps.splice(o,1),!0}),n&&n.id===t&&(this.currentStep=void 0,this.steps.length?this.show(0):this.cancel())}show(t=0,n=!0){const i=Ce(t)?this.getById(t):this.steps[t];i&&(this._updateStateBeforeShow(),Z(i.options.showOn)&&!i.options.showOn()?this._skipStep(i,n):(this.trigger("show",{step:i,previous:this.currentStep}),this.currentStep=i,i.show()))}async start(){this.trigger("start"),this.focusedElBeforeOpen=document.activeElement,this.currentStep=null,this.setupModal(),this._setupActiveTour(),this.next()}_done(t){const n=this.steps.indexOf(this.currentStep);if(Array.isArray(this.steps)&&this.steps.forEach(i=>i.destroy()),to(this),this.trigger(t,{index:n}),oe.activeTour=null,this.trigger("inactive",{tour:this}),this.modal&&this.modal.hide(),(t==="cancel"||t==="complete")&&this.modal){const i=document.querySelector(".shepherd-modal-overlay-container");i&&(i.remove(),this.modal=null)}ke(this.focusedElBeforeOpen)&&this.focusedElBeforeOpen.focus()}_setupActiveTour(){this.trigger("active",{tour:this}),oe.activeTour=this}setupModal(){this.modal=new lo({target:this.options.modalContainer||document.body,props:{styles:this.styles}})}_skipStep(t,n){const i=this.steps.indexOf(t);if(i===this.steps.length-1)this.complete();else{const o=n?i+1:i-1;this.show(o,n)}}_updateStateBeforeShow(){this.currentStep&&this.currentStep.hide(),this.isActive()||this._setupActiveTour()}_setTourID(t){const n=this.options.tourName||"tour",i=t||Bt();this.id=`${n}--${i}`}}const oe=new co,Jt=typeof window>"u";oe.Step=Jt?yn:Je;oe.Tour=Jt?_n:fo;function ao(e,t){return typeof e=="function"?e(t):e}function Qt(e){return e.split("-")[0]}function uo(e){return e.split("-")[1]}const ho=new Set(["top","bottom"]);function po(e){return ho.has(Qt(e))?"y":"x"}const mo=new Set(["left","top"]);async function go(e,t){const{placement:n,platform:i,elements:o}=e,r=await(i.isRTL==null?void 0:i.isRTL(o.floating)),s=Qt(n),l=uo(n),c=po(n)==="y",f=mo.has(s)?-1:1,u=r&&c?-1:1,d=ao(t,e);let{mainAxis:a,crossAxis:h,alignmentAxis:m}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return l&&typeof m=="number"&&(h=l==="end"?m*-1:m),c?{x:h*u,y:a*f}:{x:a*f,y:h*u}}const bo=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,i;const{x:o,y:r,placement:s,middlewareData:l}=t,c=await go(t,e);return s===((n=l.offset)==null?void 0:n.placement)&&(i=l.arrow)!=null&&i.alignmentOffset?{}:{x:o+c.x,y:r+c.y,data:{...c,placement:s}}}}},wo=bo;window.Shepherd=oe;window.offsetFloating=wo;
