@embedreach/components 0.1.92 → 0.1.93
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/chunks/index.js +5 -305
- package/dist/index.umd.js +1 -1
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
*
|
|
31
31
|
* This source code is licensed under the ISC license.
|
|
32
32
|
* See the LICENSE file in the root directory of this source tree.
|
|
33
|
-
*/function ud(){let e,t,n=0,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=dd(e))&&(r&&(r+=" "),r+=t);return r}const dd=e=>{if("string"==typeof e)return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=dd(e[r]))&&(n&&(n+=" "),n+=t);return n};function pd(e,...t){let n,r,o,i=function(s){const l=t.reduce(((e,t)=>t(e)),e());return n=(e=>({cache:ad(e.cacheSize),parseClassName:sd(e),...Qu(e)}))(l),r=n.cache.get,o=n.cache.set,i=a,a(s)};function a(e){const t=r(e);if(t)return t;const i=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,i=[],a=e.trim().split(cd);let s="";for(let l=a.length-1;l>=0;l-=1){const e=a[l],{modifiers:t,hasImportantModifier:c,baseClassName:u,maybePostfixModifierPosition:d}=n(e);let p=Boolean(d),f=r(p?u.substring(0,d):u);if(!f){if(!p){s=e+(s.length>0?" "+s:s);continue}if(f=r(u),!f){s=e+(s.length>0?" "+s:s);continue}p=!1}const h=ld(t).join(":"),m=c?h+"!":h,g=m+f;if(i.includes(g))continue;i.push(g);const y=o(f,p);for(let n=0;n<y.length;++n)i.push(m+y[n]);s=e+(s.length>0?" "+s:s)}return s})(e,n);return o(e,i),i}return function(){return i(ud.apply(null,arguments))}}const fd=e=>{const t=t=>t[e]||[];return t.isThemeGetter=!0,t},hd=/^\[(?:([a-z-]+):)?(.+)\]$/i,md=/^\d+\/\d+$/,gd=new Set(["px","full","screen"]),yd=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,vd=/\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$/,bd=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,wd=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xd=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ed=e=>Sd(e)||gd.has(e)||md.test(e),_d=e=>Id(e,"length",Fd),Sd=e=>Boolean(e)&&!Number.isNaN(Number(e)),Td=e=>Id(e,"number",Sd),Cd=e=>Boolean(e)&&Number.isInteger(Number(e)),Ad=e=>e.endsWith("%")&&Sd(e.slice(0,-1)),Od=e=>hd.test(e),Nd=e=>yd.test(e),Rd=new Set(["length","size","percentage"]),Pd=e=>Id(e,Rd,Ud),kd=e=>Id(e,"position",Ud),Ld=new Set(["image","url"]),Md=e=>Id(e,Ld,Bd),Dd=e=>Id(e,"",$d),jd=()=>!0,Id=(e,t,n)=>{const r=hd.exec(e);return!!r&&(r[1]?"string"==typeof t?r[1]===t:t.has(r[1]):n(r[2]))},Fd=e=>vd.test(e)&&!bd.test(e),Ud=()=>!1,$d=e=>wd.test(e),Bd=e=>xd.test(e),Vd=pd((()=>{const e=fd("colors"),t=fd("spacing"),n=fd("blur"),r=fd("brightness"),o=fd("borderColor"),i=fd("borderRadius"),a=fd("borderSpacing"),s=fd("borderWidth"),l=fd("contrast"),c=fd("grayscale"),u=fd("hueRotate"),d=fd("invert"),p=fd("gap"),f=fd("gradientColorStops"),h=fd("gradientColorStopPositions"),m=fd("inset"),g=fd("margin"),y=fd("opacity"),v=fd("padding"),b=fd("saturate"),w=fd("scale"),x=fd("sepia"),E=fd("skew"),_=fd("space"),S=fd("translate"),T=()=>["auto",Od,t],C=()=>[Od,t],A=()=>["",Ed,_d],O=()=>["auto",Sd,Od],N=()=>["","0",Od],R=()=>[Sd,Od];return{cacheSize:500,separator:":",theme:{colors:[jd],spacing:[Ed,_d],blur:["none","",Nd,Od],brightness:R(),borderColor:[e],borderRadius:["none","","full",Nd,Od],borderSpacing:C(),borderWidth:A(),contrast:R(),grayscale:N(),hueRotate:R(),invert:N(),gap:C(),gradientColorStops:[e],gradientColorStopPositions:[Ad,_d],inset:T(),margin:T(),opacity:R(),padding:C(),saturate:R(),scale:R(),sepia:N(),skew:R(),space:C(),translate:C()},classGroups:{aspect:[{aspect:["auto","square","video",Od]}],container:["container"],columns:[{columns:[Nd]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"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:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Od]}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Cd,Od]}],basis:[{basis:T()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Od]}],grow:[{grow:N()}],shrink:[{shrink:N()}],order:[{order:["first","last","none",Cd,Od]}],"grid-cols":[{"grid-cols":[jd]}],"col-start-end":[{col:["auto",{span:["full",Cd,Od]},Od]}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":[jd]}],"row-start-end":[{row:["auto",{span:[Cd,Od]},Od]}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Od]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Od]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal","start","end","center","between","around","evenly","stretch"]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[_]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[_]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Od,t]}],"min-w":[{"min-w":[Od,t,"min","max","fit"]}],"max-w":[{"max-w":[Od,t,"none","full","min","max","fit","prose",{screen:[Nd]},Nd]}],h:[{h:[Od,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Od,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Od,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Od,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Nd,_d]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Td]}],"font-family":[{font:[jd]}],"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-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Od]}],"line-clamp":[{"line-clamp":["none",Sd,Td]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Ed,Od]}],"list-image":[{"list-image":["none",Od]}],"list-style-type":[{list:["none","disc","decimal",Od]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","none","wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Ed,_d]}],"underline-offset":[{"underline-offset":["auto",Ed,Od]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:C()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Od]}],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",Od]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",kd]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Pd]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Md]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[h]}],"gradient-via-pos":[{via:[h]}],"gradient-to-pos":[{to:[h]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:["solid","dashed","dotted","double","none","hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:["solid","dashed","dotted","double","none"]}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["","solid","dashed","dotted","double","none"]}],"outline-offset":[{"outline-offset":[Ed,Od]}],"outline-w":[{outline:[Ed,_d]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:A()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Ed,_d]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Nd,Dd]}],"shadow-color":[{shadow:[jd]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Nd,Od]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[b]}],sepia:[{sepia:[x]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[b]}],"backdrop-sepia":[{"backdrop-sepia":[x]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Od]}],duration:[{duration:R()}],ease:[{ease:["linear","in","out","in-out",Od]}],delay:[{delay:R()}],animate:[{animate:["none","spin","ping","pulse","bounce",Od]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[w]}],"scale-x":[{"scale-x":[w]}],"scale-y":[{"scale-y":[w]}],rotate:[{rotate:[Cd,Od]}],"translate-x":[{"translate-x":[S]}],"translate-y":[{"translate-y":[S]}],"skew-x":[{"skew-x":[E]}],"skew-y":[{"skew-y":[E]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Od]}],accent:[{accent:["auto",e]}],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",Od]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":C()}],"scroll-mx":[{"scroll-mx":C()}],"scroll-my":[{"scroll-my":C()}],"scroll-ms":[{"scroll-ms":C()}],"scroll-me":[{"scroll-me":C()}],"scroll-mt":[{"scroll-mt":C()}],"scroll-mr":[{"scroll-mr":C()}],"scroll-mb":[{"scroll-mb":C()}],"scroll-ml":[{"scroll-ml":C()}],"scroll-p":[{"scroll-p":C()}],"scroll-px":[{"scroll-px":C()}],"scroll-py":[{"scroll-py":C()}],"scroll-ps":[{"scroll-ps":C()}],"scroll-pe":[{"scroll-pe":C()}],"scroll-pt":[{"scroll-pt":C()}],"scroll-pr":[{"scroll-pr":C()}],"scroll-pb":[{"scroll-pb":C()}],"scroll-pl":[{"scroll-pl":C()}],"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",Od]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Ed,_d,Td]}],stroke:[{stroke:[e,"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-s","border-color-e","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"]}}}));function qd(...e){return Vd(Xc(e))}const zd=Vc,Hd=i.forwardRef((({className:e,...n},r)=>t.jsx(qc,{ref:r,className:qd("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:top-0 sm:right-0 sm:bottom-auto sm:flex-col md:max-w-[420px]",e),...n})));Hd.displayName=qc.displayName;const Gd=Jc("group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Kd=i.forwardRef((({className:e,variant:n,...r},o)=>t.jsx(zc,{ref:o,className:qd(Gd({variant:n}),e),...r})));Kd.displayName=zc.displayName;i.forwardRef((({className:e,...n},r)=>t.jsx(Kc,{ref:r,className:qd("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium transition-colors hover:bg-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...n}))).displayName=Kc.displayName;const Wd=i.forwardRef((({className:e,...n},r)=>t.jsx(Wc,{ref:r,className:qd("absolute right-1 top-1 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...n,children:t.jsx(Yu,{className:"h-4 w-4"})})));Wd.displayName=Wc.displayName;const Yd=i.forwardRef((({className:e,...n},r)=>t.jsx(Hc,{ref:r,className:qd("text-sm font-semibold [&+div]:text-xs",e),...n})));Yd.displayName=Hc.displayName;const Xd=i.forwardRef((({className:e,...n},r)=>t.jsx(Gc,{ref:r,className:qd("text-sm opacity-90",e),...n})));function Qd(){const{toasts:e}=Rl();return t.jsxs(zd,{children:[e.map((function({id:e,title:n,description:r,action:o,...i}){return t.jsxs(Kd,{...i,children:[t.jsxs("div",{className:"grid gap-1",children:[n&&t.jsx(Yd,{children:n}),r&&t.jsx(Xd,{children:r})]}),o,t.jsx(Wd,{})]},e)})),t.jsx(Hd,{})]})}Xd.displayName=Gc.displayName;const Zd=(e,r,o,i)=>{const a=n.createContext({state:o});return{Context:a,Provider:({children:s})=>{const[l,c]=n.useReducer(e,o),u=n.useMemo((()=>Object.keys(r).reduce(((e,t)=>({...e,[t]:r[t](c)})),{})),[c]);n.useEffect((()=>{const e=[];return i?.length&&i.forEach((({eventName:t,handler:n})=>{const r=n(c),o=ve.subscribe(t,r);e.push(o)})),()=>e.forEach((e=>e()))}),[c]);const d=n.useMemo((()=>({state:l,...u})),[l,u]);return t.jsx(a.Provider,{value:d,children:s})}}},Jd=[{eventName:be,handler:e=>()=>{e({type:"SET_AUTHENTICATED",payload:!1}),e({type:"SET_REAUTHING",payload:!0})}},{eventName:we,handler:e=>()=>{e({type:"SET_AUTHENTICATED",payload:!0})}}],{Provider:ep}=Zd(((e,t)=>{switch(t.type){case"SET_AUTHENTICATED":return{...e,isAuthenticated:t.payload,error:null,reauthing:!1};case"SET_LOADING":return{...e,loading:t.payload};case"SET_ERROR":return{...e,error:t.payload,isAuthenticated:!1,reauthing:!1};case"SET_REAUTHING":return e.reauthing&&t.payload?e:{...e,reauthing:t.payload};default:return e}}),{handleReauth:e=>async t=>{if(t){e({type:"SET_REAUTHING",payload:!0});try{t()}catch(n){e({type:"SET_ERROR",payload:n instanceof Error?n.message:"Reauthorization failed"})}}else e({type:"SET_ERROR",payload:"No reauth callback provided"})}},{isAuthenticated:!1,loading:!1,error:null,reauthing:!1},Jd),tp={background:"0 0% 100%",foreground:"225 15% 16%",card:"0 0% 100%","card-foreground":"225 15% 16%",popover:"0 0% 100%","popover-foreground":"225 15% 16%",primary:"210 30% 25%","primary-foreground":"0 0% 100%",secondary:"210 15% 94%","secondary-foreground":"210 30% 25%",muted:"210 10% 96%","muted-foreground":"220 10% 45%",accent:"210 15% 94%","accent-foreground":"210 30% 25%",destructive:"0 84.2% 60.2%","destructive-foreground":"0 0% 100%",border:"220 13% 90%",input:"220 13% 90%",ring:"210 30% 25%","chart-1":"210 50% 50%","chart-2":"260 50% 55%","chart-3":"150 50% 45%","chart-4":"325 50% 55%","chart-5":"45 80% 55%",radius:"0.625rem","font-body":'Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',"font-heading":'"Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},np=e=>{if(/^\d+\s+\d+(?:\.\d+)?%\s+\d+(?:\.\d+)?%$/.test(e.trim()))return e.trim();try{const t=(e=>{const t=document.createElement("div");t.style.color=e,document.body.appendChild(t);const n=window.getComputedStyle(t).color;return document.body.removeChild(t),n})(e),[n,r,o]=(e=>{const t=e.match(/\d+/g);if(!t||t.length<3)throw new Error(`Invalid RGB color format: ${e}`);return[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)]})(t);return((e,t,n)=>{e/=255,t/=255,n/=255;const r=Math.max(e,t,n),o=Math.min(e,t,n);let i=0,a=0;const s=(r+o)/2;if(r!==o){const l=r-o;switch(a=s>.5?l/(2-r-o):l/(r+o),r){case e:i=(t-n)/l+(t<n?6:0);break;case t:i=(n-e)/l+2;break;case n:i=(e-t)/l+4}i*=60}return`${Math.round(i)} ${Math.round(100*a)}% ${Math.round(100*s)}%`})(n,r,o)}catch(t){return e}},rp=e=>{const t=document.getElementById("reach-theme-styles");t&&t.remove();const n=document.createElement("style");n.id="reach-theme-styles";const r=`\n [data-reach-root] {\n ${Object.entries(tp).map((([t,n])=>{const r=e[t];let o=n;if(void 0!==r)if("radius"===t||"font-body"===t||"font-heading"===t)o=r;else if((e=>{if(/^\d+\s+\d+(?:\.\d+)?%\s+\d+(?:\.\d+)?%$/.test(e.trim()))return!0;if(["bg-","text-","border-","ring-","accent-","fill-","stroke-"].some((t=>e.trim().startsWith(t))))return!0;const t=document.createElement("div"),n=t.style.color;return t.style.color=e,t.style.color!==n})(r)){if(/^bg-/.test(r.trim()))o=(e=>{if("bg-inherit"===e)return"inherit";if("bg-current"===e)return"currentColor";if("bg-transparent"===e)return"transparent";if("bg-black"===e)return"0 0% 0%";if("bg-white"===e)return"0 0% 100%";const t=e.match(/^bg-([a-z]+)-(\d{2,3})$/);if(!t)throw new Error(`Invalid tailwind color class: ${e}`);const[,n,r]=t,o={red:{50:"0 100% 97.1%",100:"0 100% 93.6%",200:"0 100% 88.5%",300:"0 100% 80.8%",400:"0 100% 70.4%",500:"0 100% 63.7%",600:"0 100% 57.7%",700:"0 100% 50.5%",800:"0 100% 44.4%",900:"0 100% 39.6%",950:"0 100% 25.8%"},orange:{50:"98% 0.016 73.684",100:"95.4% 0.038 75.164",200:"90.1% 0.076 70.697",300:"83.7% 0.128 66.29",400:"75% 0.183 55.934",500:"70.5% 0.213 47.604",600:"64.6% 0.222 41.116",700:"55.3% 0.195 38.402",800:"47% 0.157 37.304",900:"40.8% 0.123 38.172",950:"26.6% 0.079 36.259"},amber:{50:"98.7% 0.022 95.277",100:"96.2% 0.059 95.617",200:"92.4% 0.12 95.746",300:"87.9% 0.169 91.605",400:"82.8% 0.189 84.429",500:"76.9% 0.188 70.08",600:"66.6% 0.179 58.318",700:"55.5% 0.163 48.998",800:"47.3% 0.137 46.201",900:"41.4% 0.112 45.904",950:"27.9% 0.077 45.635"},yellow:{50:"98.7% 0.026 102.212",100:"97.3% 0.071 103.193",200:"94.5% 0.129 101.54",300:"90.5% 0.182 98.111",400:"85.2% 0.199 91.936",500:"79.5% 0.184 86.047",600:"68.1% 0.162 75.834",700:"55.4% 0.135 66.442",800:"47.6% 0.114 61.907",900:"42.1% 0.095 57.708",950:"28.6% 0.066 53.813"},lime:{50:"98.6% 0.031 120.757",100:"96.7% 0.067 122.328",200:"93.8% 0.127 124.321",300:"89.7% 0.196 126.665",400:"84.1% 0.238 128.85",500:"76.8% 0.233 130.85",600:"64.8% 0.2 131.684",700:"53.2% 0.157 131.589",800:"45.3% 0.124 130.933",900:"40.5% 0.101 131.063",950:"27.4% 0.072 132.109"},green:{50:"98.2% 0.018 155.826",100:"96.2% 0.044 156.743",200:"92.5% 0.084 155.995",300:"87.1% 0.15 154.449",400:"79.2% 0.209 151.711",500:"72.3% 0.219 149.579",600:"62.7% 0.194 149.214",700:"52.7% 0.154 150.069",800:"44.8% 0.119 151.328",900:"39.3% 0.095 152.535",950:"26.6% 0.065 152.934"},emerald:{50:"97.9% 0.021 166.113",100:"95% 0.052 163.051",200:"90.5% 0.093 164.15",300:"84.5% 0.143 164.978",400:"76.5% 0.177 163.223",500:"69.6% 0.17 162.48",600:"59.6% 0.145 163.225",700:"50.8% 0.118 165.612",800:"43.2% 0.095 166.913",900:"37.8% 0.077 168.94",950:"26.2% 0.051 172.552"},teal:{50:"98.4% 0.014 180.72",100:"95.3% 0.051 180.801",200:"91% 0.096 180.426",300:"85.5% 0.138 181.071",400:"77.7% 0.152 181.912",500:"70.4% 0.14 182.503",600:"60% 0.118 184.704",700:"51.1% 0.096 186.391",800:"43.7% 0.078 188.216",900:"38.6% 0.063 188.416",950:"27.7% 0.046 192.524"},cyan:{50:"98.4% 0.019 200.873",100:"95.6% 0.045 203.388",200:"91.7% 0.08 205.041",300:"86.5% 0.127 207.078",400:"78.9% 0.154 211.53",500:"71.5% 0.143 215.221",600:"60.9% 0.126 221.723",700:"52% 0.105 223.128",800:"45% 0.085 224.283",900:"39.8% 0.07 227.392",950:"30.2% 0.056 229.695"},sky:{50:"97.7% 0.013 236.62",100:"95.1% 0.026 236.824",200:"90.1% 0.058 230.902",300:"82.8% 0.111 230.318",400:"74.6% 0.16 232.661",500:"68.5% 0.169 237.323",600:"58.8% 0.158 241.966",700:"50% 0.134 242.749",800:"44.3% 0.11 240.79",900:"39.1% 0.09 240.876",950:"29.3% 0.066 243.157"},blue:{50:"97% 0.014 254.604",100:"93.2% 0.032 255.585",200:"88.2% 0.059 254.128",300:"80.9% 0.105 251.813",400:"70.7% 0.165 254.624",500:"62.3% 0.214 259.815",600:"54.6% 0.245 262.881",700:"48.8% 0.243 264.376",800:"42.4% 0.199 265.638",900:"37.9% 0.146 265.522",950:"28.2% 0.091 267.935"},indigo:{50:"96.2% 0.018 272.314",100:"93% 0.034 272.788",200:"87% 0.065 274.039",300:"78.5% 0.115 274.713",400:"67.3% 0.182 276.935",500:"58.5% 0.233 277.117",600:"51.1% 0.262 276.966",700:"45.7% 0.24 277.023",800:"39.8% 0.195 277.366",900:"35.9% 0.144 278.697",950:"25.7% 0.09 281.288"},violet:{50:"96.9% 0.016 293.756",100:"94.3% 0.029 294.588",200:"89.4% 0.057 293.283",300:"81.1% 0.111 293.571",400:"70.2% 0.183 293.541",500:"60.6% 0.25 292.717",600:"54.1% 0.281 293.009",700:"49.1% 0.27 292.581",800:"43.2% 0.232 292.759",900:"38% 0.189 293.745",950:"28.3% 0.141 291.089"},purple:{50:"97.7% 0.014 308.299",100:"94.6% 0.033 307.174",200:"90.2% 0.063 306.703",300:"82.7% 0.119 306.383",400:"71.4% 0.203 305.504",500:"62.7% 0.265 303.9",600:"55.8% 0.288 302.321",700:"49.6% 0.265 301.924",800:"43.8% 0.218 303.724",900:"38.1% 0.176 304.987",950:"29.1% 0.149 302.717"},fuchsia:{50:"97.7% 0.017 320.058",100:"95.2% 0.037 318.852",200:"90.3% 0.076 319.62",300:"83.3% 0.145 321.434",400:"74% 0.238 322.16",500:"66.7% 0.295 322.15",600:"59.1% 0.293 322.896",700:"51.8% 0.253 323.949",800:"45.2% 0.211 324.591",900:"40.1% 0.17 325.612",950:"29.3% 0.136 325.661"},pink:{50:"97.1% 0.014 343.198",100:"94.8% 0.028 342.258",200:"89.9% 0.061 343.231",300:"82.3% 0.12 346.018",400:"71.8% 0.202 349.761",500:"65.6% 0.241 354.308",600:"59.2% 0.249 0.584",700:"52.5% 0.223 3.958",800:"45.9% 0.187 3.815",900:"40.8% 0.153 2.432",950:"28.4% 0.109 3.907"},rose:{50:"96.9% 0.015 12.422",100:"94.1% 0.03 12.58",200:"89.2% 0.058 10.001",300:"81% 0.117 11.638",400:"71.2% 0.194 13.428",500:"64.5% 0.246 16.439",600:"58.6% 0.253 17.585",700:"51.4% 0.222 16.935",800:"45.5% 0.188 13.697",900:"41% 0.159 10.272",950:"27.1% 0.105 12.094"},slate:{50:"98.4% 0.003 247.858",100:"96.8% 0.007 247.896",200:"92.9% 0.013 255.508",300:"86.9% 0.022 252.894",400:"70.4% 0.04 256.788",500:"55.4% 0.046 257.417",600:"44.6% 0.043 257.281",700:"37.2% 0.044 257.287",800:"27.9% 0.041 260.031",900:"20.8% 0.042 265.755",950:"12.9% 0.042 264.695"},gray:{50:"98.5% 0.002 247.839",100:"96.7% 0.003 264.542",200:"92.8% 0.006 264.531",300:"87.2% 0.01 258.338",400:"70.7% 0.022 261.325",500:"55.1% 0.027 264.364",600:"44.6% 0.03 256.802",700:"37.3% 0.034 259.733",800:"27.8% 0.033 256.848",900:"21% 0.034 264.665",950:"13% 0.028 261.692"},zinc:{50:"98.5% 0 0",100:"96.7% 0.001 286.375",200:"92% 0.004 286.32",300:"87.1% 0.006 286.286",400:"70.5% 0.015 286.067",500:"55.2% 0.016 285.938",600:"44.2% 0.017 285.786",700:"37% 0.013 285.805",800:"27.4% 0.006 286.033",900:"21% 0.006 285.885",950:"14.1% 0.005 285.823"},neutral:{50:"98.5% 0 0",100:"97% 0 0",200:"92.2% 0 0",300:"87% 0 0",400:"70.8% 0 0",500:"55.6% 0 0",600:"43.9% 0 0",700:"37.1% 0 0",800:"26.9% 0 0",900:"20.5% 0 0",950:"14.5% 0 0"},stone:{50:"98.5% 0.001 106.423",100:"97% 0.001 106.424",200:"92.3% 0.003 48.717",300:"86.9% 0.005 56.366",400:"70.9% 0.01 56.259",500:"55.3% 0.013 58.071",600:"44.4% 0.011 73.639",700:"37.4% 0.01 67.558",800:"26.8% 0.007 34.298",900:"21.6% 0.006 56.043",950:"14.7% 0.004 49.25"}};if(!o[n]||!o[n][r])throw new Error(`Unsupported color or shade: ${e}`);return o[n][r]})(r);else try{o=np(r)}catch(i){}}return`--reach-${t}: ${o};`})).join("\n")}\n }\n\n /* Apply font families directly */\n [data-reach-root] {\n font-family: var(--reach-font-body);\n }\n \n [data-reach-root] h1,\n [data-reach-root] h2,\n [data-reach-root] h3,\n [data-reach-root] h4,\n [data-reach-root] h5,\n [data-reach-root] h6 {\n font-family: var(--reach-font-heading);\n }\n `;n.textContent=r,document.head.appendChild(n)},{Context:op,Provider:ip}=Zd(((e,t)=>{switch(t.type){case"set_theme":return{...e,loading:!1,error:null,theme:t.payload};case"set_loading":return{...e,loading:t.payload};case"set_error":return{...e,loading:!1,error:t.payload};default:return e}}),{setTheme:e=>t=>e({type:"set_theme",payload:t}),setLoading:e=>t=>e({type:"set_loading",payload:t}),setError:e=>t=>e({type:"set_error",payload:t})},{theme:null,loading:!0,error:null}),ap=({initialTheme:e,children:r})=>{const{setTheme:o,setLoading:i}=n.useContext(op),a=n.useRef(!1);return n.useEffect((()=>{e&&!a.current?(rp(e.styles),o(e),a.current=!0):i(!1)}),[e,o,i]),t.jsx(t.Fragment,{children:r})},sp=({initialTheme:e,children:n})=>t.jsx(ip,{children:t.jsx(ap,{initialTheme:e,children:n})}),lp=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,cp={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},up=e=>cp[e];let dp={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:e=>e.replace(lp,up)};const pp={type:"3rdParty",init(e){((e={})=>{dp={...dp,...e}})(e.options.react)}},fp=n.createContext();function hp({i18n:e,defaultNS:t,children:r}){const o=n.useMemo((()=>({i18n:e,defaultNS:t})),[e,t]);return n.createElement(fp.Provider,{value:o},r)}const mp=e=>"string"==typeof e,gp=()=>{let e,t;const n=new Promise(((n,r)=>{e=n,t=r}));return n.resolve=e,n.reject=t,n},yp=e=>null==e?"":""+e,vp=/###/g,bp=e=>e&&e.indexOf("###")>-1?e.replace(vp,"."):e,wp=e=>!e||mp(e),xp=(e,t,n)=>{const r=mp(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(wp(e))return{};const t=bp(r[o]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return wp(e)?{}:{obj:e,k:bp(r[o])}},Ep=(e,t,n)=>{const{obj:r,k:o}=xp(e,t,Object);if(void 0!==r||1===t.length)return void(r[o]=n);let i=t[t.length-1],a=t.slice(0,t.length-1),s=xp(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=xp(e,a,Object),s?.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=n},_p=(e,t)=>{const{obj:n,k:r}=xp(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},Sp=(e,t,n)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?mp(e[r])||e[r]instanceof String||mp(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):Sp(e[r],t[r],n):e[r]=t[r]);return e},Tp=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var Cp={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const Ap=e=>mp(e)?e.replace(/[&<>"'\/]/g,(e=>Cp[e])):e;const Op=[" ",",","?","!",";"],Np=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}(20),Rp=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(!e)return;if(e[t]){if(!Object.prototype.hasOwnProperty.call(e,t))return;return e[t]}const r=t.split(n);let o=e;for(let i=0;i<r.length;){if(!o||"object"!=typeof o)return;let e,t="";for(let a=i;a<r.length;++a)if(a!==i&&(t+=n),t+=r[a],e=o[t],void 0!==e){if(["string","number","boolean"].indexOf(typeof e)>-1&&a<r.length-1)continue;i+=a-i+1;break}o=e}return o},Pp=e=>e?.replace("_","-"),kp={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){}};class Lp{constructor(e){this.init(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{})}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||kp,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}warn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}error(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}deprecate(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,r){return r&&!this.debug?null:(mp(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new Lp(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new Lp(this.logger,e)}}var Mp=new Lp;class Dp{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach((e=>{this.observers[e]||(this.observers[e]=new Map);const n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)})),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(this.observers[e]){Array.from(this.observers[e].entries()).forEach((e=>{let[t,r]=e;for(let o=0;o<r;o++)t(...n)}))}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach((t=>{let[r,o]=t;for(let i=0;i<o;i++)r.apply(r,[e,...n])}))}}}class jp extends Dp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):mp(n)&&o?a.push(...n.split(o)):a.push(n)));const s=_p(this.data,a);return!s&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),!s&&i&&mp(n)?Rp(this.data?.[e]?.[t],n,o):s}addResource(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1};const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),Ep(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}addResources(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(const o in n)(mp(n[o])||Array.isArray(n[o]))&&this.addResource(e,t,o,n[o],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1,skipCopy:!1},a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let s=_p(this.data,a)||{};i.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?Sp(s,n,o):s={...s,...n},Ep(this.data,a,s),i.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find((e=>t[e]&&Object.keys(t[e]).length>0))}toJSON(){return this.data}}var Ip={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,o){return e.forEach((e=>{t=this.processors[e]?.process(t,n,r,o)??t})),t}};const Fp={};class Up extends Dp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};var n,r;super(),n=e,r=this,["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"].forEach((e=>{n[e]&&(r[e]=n[e])})),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=Mp.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){if(null==e)return!1;const t=this.resolve(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}});return void 0!==t?.res}extractFromKey(e,t){let n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");const r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,n)=>{t=t||"",n=n||"";const r=Op.filter((e=>t.indexOf(e)<0&&n.indexOf(e)<0));if(0===r.length)return!0;const o=Np.getRegExp(`(${r.map((e=>"?"===e?"\\?":e)).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(n);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,n,r));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:mp(o)?[o]:o};const i=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(r)}return{key:e,namespaces:mp(o)?[o]:o}}translate(e,t,n){if("object"!=typeof t&&this.options.overloadTranslationOptionHandler&&(t=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof t&&(t={...t}),t||(t={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);const r=void 0!==t.returnDetails?t.returnDetails:this.options.returnDetails,o=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,{key:i,namespaces:a}=this.extractFromKey(e[e.length-1],t),s=a[a.length-1],l=t.lng||this.language,c=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===l?.toLowerCase()){if(c){const e=t.nsSeparator||this.options.nsSeparator;return r?{res:`${s}${e}${i}`,usedKey:i,exactUsedKey:i,usedLng:l,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:`${s}${e}${i}`}return r?{res:i,usedKey:i,exactUsedKey:i,usedLng:l,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:i}const u=this.resolve(e,t);let d=u?.res;const p=u?.usedKey||i,f=u?.exactUsedKey||i,h=Object.prototype.toString.apply(d),m=void 0!==t.joinArrays?t.joinArrays:this.options.joinArrays,g=!this.i18nFormat||this.i18nFormat.handleAsObject,y=!mp(d)&&"boolean"!=typeof d&&"number"!=typeof d;if(!(g&&d&&y&&["[object Number]","[object Function]","[object RegExp]"].indexOf(h)<0)||mp(m)&&Array.isArray(d))if(g&&mp(m)&&Array.isArray(d))d=d.join(m),d&&(d=this.extendTranslation(d,e,t,n));else{let r=!1,a=!1;const c=void 0!==t.count&&!mp(t.count),p=Up.hasDefaultValue(t),f=c?this.pluralResolver.getSuffix(l,t.count,t):"",h=t.ordinal&&c?this.pluralResolver.getSuffix(l,t.count,{ordinal:!1}):"",m=c&&!t.ordinal&&0===t.count,g=m&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${f}`]||t[`defaultValue${h}`]||t.defaultValue;!this.isValidLookup(d)&&p&&(r=!0,d=g),this.isValidLookup(d)||(a=!0,d=i);const y=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&a?void 0:d,v=p&&g!==d&&this.options.updateMissing;if(a||r||v){if(this.logger.log(v?"updateKey":"missingKey",l,s,i,v?g:d),o){const e=this.resolve(i,{...t,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const n=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if("fallback"===this.options.saveMissingTo&&n&&n[0])for(let t=0;t<n.length;t++)e.push(n[t]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(t.lng||this.language):e.push(t.lng||this.language);const r=(e,n,r)=>{const o=p&&r!==d?r:y;this.options.missingKeyHandler?this.options.missingKeyHandler(e,s,n,o,v,t):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,s,n,o,v,t),this.emit("missingKey",e,s,n,d)};this.options.saveMissing&&(this.options.saveMissingPlurals&&c?e.forEach((e=>{const n=this.pluralResolver.getSuffixes(e,t);m&&t[`defaultValue${this.options.pluralSeparator}zero`]&&n.indexOf(`${this.options.pluralSeparator}zero`)<0&&n.push(`${this.options.pluralSeparator}zero`),n.forEach((n=>{r([e],i+n,t[`defaultValue${n}`]||g)}))})):r(e,i,g))}d=this.extendTranslation(d,e,t,u,n),a&&d===i&&this.options.appendNamespaceToMissingKey&&(d=`${s}:${i}`),(a||r)&&this.options.parseMissingKeyHandler&&(d=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${s}:${i}`:i,r?d:void 0))}else{if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(p,d,{...t,ns:a}):`key '${i} (${this.language})' returned an object instead of string.`;return r?(u.res=e,u.usedParams=this.getUsedParamsDetails(t),u):e}if(o){const e=Array.isArray(d),n=e?[]:{},r=e?f:p;for(const i in d)if(Object.prototype.hasOwnProperty.call(d,i)){const e=`${r}${o}${i}`;n[i]=this.translate(e,{...t,joinArrays:!1,ns:a}),n[i]===e&&(n[i]=d[i])}d=n}}return r?(u.res=d,u.usedParams=this.getUsedParamsDetails(t),u):d}extendTranslation(e,t,n,r,o){var i=this;if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const a=mp(e)&&(void 0!==n?.interpolation?.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let s;if(a){const t=e.match(this.interpolator.nestingRegexp);s=t&&t.length}let l=n.replace&&!mp(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(l={...this.options.interpolation.defaultVariables,...l}),e=this.interpolator.interpolate(e,l,n.lng||this.language||r.usedLng,n),a){const t=e.match(this.interpolator.nestingRegexp);s<(t&&t.length)&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,(function(){for(var e=arguments.length,r=new Array(e),a=0;a<e;a++)r[a]=arguments[a];return o?.[0]!==r[0]||n.context?i.translate(...r,t):(i.logger.warn(`It seems you are nesting recursively key: ${r[0]} in key: ${t[0]}`),null)}),n)),n.interpolation&&this.interpolator.reset()}const a=n.postProcess||this.options.postProcess,s=mp(a)?[a]:a;return null!=e&&s?.length&&!1!==n.applyPostProcessor&&(e=Ip.handle(s,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e){let t,n,r,o,i,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return mp(e)&&(e=[e]),e.forEach((e=>{if(this.isValidLookup(t))return;const s=this.extractFromKey(e,a),l=s.key;n=l;let c=s.namespaces;this.options.fallbackNS&&(c=c.concat(this.options.fallbackNS));const u=void 0!==a.count&&!mp(a.count),d=u&&!a.ordinal&&0===a.count,p=void 0!==a.context&&(mp(a.context)||"number"==typeof a.context)&&""!==a.context,f=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);c.forEach((e=>{this.isValidLookup(t)||(i=e,Fp[`${f[0]}-${e}`]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(i)||(Fp[`${f[0]}-${e}`]=!0,this.logger.warn(`key "${n}" for languages "${f.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach((n=>{if(this.isValidLookup(t))return;o=n;const i=[l];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(i,l,n,e,a);else{let e;u&&(e=this.pluralResolver.getSuffix(n,a.count,a));const t=`${this.options.pluralSeparator}zero`,r=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(u&&(i.push(l+e),a.ordinal&&0===e.indexOf(r)&&i.push(l+e.replace(r,this.options.pluralSeparator)),d&&i.push(l+t)),p){const n=`${l}${this.options.contextSeparator}${a.context}`;i.push(n),u&&(i.push(n+e),a.ordinal&&0===e.indexOf(r)&&i.push(n+e.replace(r,this.options.pluralSeparator)),d&&i.push(n+t))}}let s;for(;s=i.pop();)this.isValidLookup(t)||(r=s,t=this.getResource(n,e,s,a))})))}))})),{res:t,usedKey:n,exactUsedKey:r,usedLng:o,usedNS:i}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!mp(e.replace);let r=n?e.replace:e;if(n&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(const e of t)delete r[e]}return r}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}class $p{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Mp.create("languageUtils")}getScriptPartFromCode(e){if(!(e=Pp(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=Pp(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(mp(e)&&e.indexOf("-")>-1){let n;try{n=Intl.getCanonicalLocales(e)[0]}catch(t){}return n&&this.options.lowerCaseLng&&(n=n.toLowerCase()),n||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach((e=>{if(t)return;const n=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(n)||(t=n)})),!t&&this.options.supportedLngs&&e.forEach((e=>{if(t)return;const n=this.getLanguagePartFromCode(e);if(this.isSupportedCode(n))return t=n;t=this.options.supportedLngs.find((e=>e===n?e:e.indexOf("-")<0&&n.indexOf("-")<0?void 0:e.indexOf("-")>0&&n.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===n||0===e.indexOf(n)&&n.length>1?e:void 0))})),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),mp(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){const n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],o=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return mp(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):mp(e)&&o(this.formatLanguageCode(e)),n.forEach((e=>{r.indexOf(e)<0&&o(this.formatLanguageCode(e))})),r}}const Bp={zero:0,one:1,two:2,few:3,many:4,other:5},Vp={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class qp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=Mp.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=Pp("dev"===e?"en":e),r=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:n,type:r});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(n,{type:r})}catch(a){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),Vp;if(!e.match(/-|_/))return Vp;const n=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(n,t)}return this.pluralRulesCache[o]=i,i}needsPlural(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t){return this.getSuffixes(e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}).map((e=>`${t}${e}`))}getSuffixes(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?n.resolvedOptions().pluralCategories.sort(((e,t)=>Bp[e]-Bp[t])).map((e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`)):[]}getSuffix(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix("dev",t,n))}}const zp=function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],i=((e,t,n)=>{const r=_p(e,n);return void 0!==r?r:_p(t,n)})(e,t,n);return!i&&o&&mp(n)&&(i=Rp(e,n,r),void 0===i&&(i=Rp(t,n,r))),i},Hp=e=>e.replace(/\$/g,"$$$$");class Gp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=Mp.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:l,unescapeSuffix:c,unescapePrefix:u,nestingPrefix:d,nestingPrefixEscaped:p,nestingSuffix:f,nestingSuffixEscaped:h,nestingOptionsSeparator:m,maxReplaces:g,alwaysFormat:y}=e.interpolation;this.escape=void 0!==t?t:Ap,this.escapeValue=void 0===n||n,this.useRawValueToEscape=void 0!==r&&r,this.prefix=o?Tp(o):i||"{{",this.suffix=a?Tp(a):s||"}}",this.formatSeparator=l||",",this.unescapePrefix=c?"":u||"-",this.unescapeSuffix=this.unescapePrefix?"":c||"",this.nestingPrefix=d?Tp(d):p||Tp("$t("),this.nestingSuffix=f?Tp(f):h||Tp(")"),this.nestingOptionsSeparator=m||",",this.maxReplaces=g||1e3,this.alwaysFormat=void 0!==y&&y,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},l=e=>{if(e.indexOf(this.formatSeparator)<0){const o=zp(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,n,{...r,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(zp(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,n,{...r,...t,interpolationkey:i})};this.resetRegExp();const c=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=void 0!==r?.interpolation?.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>Hp(e)},{regex:this.regexp,safeValue:e=>Hp(this.escapeValue?this.escape(e):e)}].forEach((t=>{for(a=0;o=t.regex.exec(e);){const n=o[1].trim();if(i=l(n),void 0===i)if("function"==typeof c){const t=c(e,o,r);i=mp(t)?t:""}else if(r&&Object.prototype.hasOwnProperty.call(r,n))i="";else{if(u){i=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),i=""}else mp(i)||this.useRawValueToEscape||(i=yp(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),u?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}})),e}nest(e,t){let n,r,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const a=(e,t)=>{const n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;const r=e.split(new RegExp(`${n}[ ]*{`));let i=`{${r[1]}`;e=r[0],i=this.interpolate(i,o);const a=i.match(/'/g),s=i.match(/"/g);((a?.length??0)%2==0&&!s||s.length%2!=0)&&(i=i.replace(/'/g,'"'));try{o=JSON.parse(i),t&&(o={...t,...o})}catch(l){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,l),`${e}${n}${i}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,e};for(;n=this.nestingRegexp.exec(e);){let s=[];o={...i},o=o.replace&&!mp(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let l=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){const e=n[1].split(this.formatSeparator).map((e=>e.trim()));n[1]=e.shift(),s=e,l=!0}if(r=t(a.call(this,n[1].trim(),o),o),r&&n[0]===e&&!mp(r))return r;mp(r)||(r=yp(r)),r||(this.logger.warn(`missed to resolve ${n[1]} for nesting ${e}`),r=""),l&&(r=s.reduce(((e,t)=>this.format(e,t,i.lng,{...i,interpolationkey:n[1].trim()})),r.trim())),e=e.replace(n[0],r),this.regexp.lastIndex=0}return e}}const Kp=e=>{const t={};return(n,r,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=r+JSON.stringify(i);let s=t[a];return s||(s=e(Pp(r),o),t[a]=s),s(n)}};class Wp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=Mp.create("formatter"),this.options=e,this.formats={number:Kp(((e,t)=>{const n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)})),currency:Kp(((e,t)=>{const n=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>n.format(e)})),datetime:Kp(((e,t)=>{const n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)})),relativetime:Kp(((e,t)=>{const n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||"day")})),list:Kp(((e,t)=>{const n=new Intl.ListFormat(e,{...t});return e=>n.format(e)}))},this.init(e)}init(e){this.formatSeparator=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}}).interpolation.formatSeparator||","}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Kp(t)}format(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find((e=>e.indexOf(")")>-1))){const e=o.findIndex((e=>e.indexOf(")")>-1));o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}return o.reduce(((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach((e=>{if(e){const[t,...r]=e.split(":"),o=r.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();n[i]||(n[i]=o),"false"===o&&(n[i]=!1),"true"===o&&(n[i]=!0),isNaN(o)||(n[i]=parseInt(o,10))}}))}return{formatName:t,formatOptions:n}})(t);if(this.formats[o]){let t=e;try{const a=r?.formatParams?.[r.interpolationkey]||{};t=this.formats[o](e,a.locale||a.lng||r.locale||r.lng||n,{...i,...r,...a})}catch(a){this.logger.warn(a)}return t}return this.logger.warn(`there was no format function for ${o}`),e}),e)}}class Yp extends Dp{constructor(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=Mp.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){const o={},i={},a={},s={};return e.forEach((e=>{let r=!0;t.forEach((t=>{const a=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,r=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))})),r||(a[e]=!0)})),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){const r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),!t&&n&&this.store.addResourceBundle(o,i,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);const a={};this.queue.forEach((n=>{((e,t,n)=>{const{obj:r,k:o}=xp(e,t,Object);r[o]=r[o]||[],r[o].push(n)})(n.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach((e=>{a[e]||(a[e]={});const t=n.loaded[e];t.length&&t.forEach((t=>{void 0===a[e][t]&&(a[e][t]=!0)}))})),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())})),this.emit("loaded",a),this.queue=this.queue.filter((e=>!e.done))}read(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,i=arguments.length>5?arguments[5]:void 0;if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&r<this.maxRetries?setTimeout((()=>{this.read.call(this,e,t,n,r+1,2*o,i)}),o):i(a,s)},s=this.backend[n].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const n=s(e,t);n&&"function"==typeof n.then?n.then((e=>a(null,e))).catch(a):a(null,n)}catch(l){a(l)}}prepareLoading(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();mp(e)&&(e=this.languageUtils.toResolveHierarchy(e)),mp(t)&&(t=[t]);const o=this.queueLoad(e,t,n,r);if(!o.toLoad.length)return o.pending.length||r(),null;o.toLoad.forEach((e=>{this.loadOne(e)}))}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=e.split("|"),r=n[0],o=n[1];this.read(r,o,"read",void 0,void 0,((n,i)=>{n&&this.logger.warn(`${t}loading namespace ${o} for language ${r} failed`,n),!n&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${r}`,i),this.loaded(e,n,i)}))}saveMissing(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:()=>{};if(!this.services?.utils?.hasLoadedNamespace||this.services?.utils?.hasLoadedNamespace(t)){if(null!=n&&""!==n){if(this.backend?.create){const l={...i,isUpdate:o},c=this.backend.create.bind(this.backend);if(c.length<6)try{let o;o=5===c.length?c(e,t,n,r,l):c(e,t,n,r),o&&"function"==typeof o.then?o.then((e=>a(null,e))).catch(a):a(null,o)}catch(s){a(s)}else c(e,t,n,r,a,l)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}else this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}const Xp=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),mp(e[1])&&(t.defaultValue=e[1]),mp(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const n=e[3]||e[2];Object.keys(n).forEach((e=>{t[e]=n[e]}))}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),Qp=e=>(mp(e.ns)&&(e.ns=[e.ns]),mp(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),mp(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),Zp=()=>{};class Jp extends Dp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;var n;if(super(),this.options=Qp(e),this.services={},this.logger=Mp,this.modules={external:[]},n=this,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach((e=>{"function"==typeof n[e]&&(n[e]=n[e].bind(n))})),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout((()=>{this.init(e,t)}),0)}}init(){var e=this;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,"function"==typeof t&&(n=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&(mp(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=Xp();this.options={...r,...this.options,...Qp(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator);const o=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let t;Mp.init(this.modules.logger?o(this.modules.logger):null,this.options),t=this.modules.formatter?this.modules.formatter:Wp;const n=new $p(this.options);this.store=new jp(this.options.resources,this.options);const i=this.services;i.logger=Mp,i.resourceStore=this.store,i.languageUtils=n,i.pluralResolver=new qp(n,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!t||this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format||(i.formatter=o(t),i.formatter.init(i,this.options),this.options.interpolation.format=i.formatter.format.bind(i.formatter)),i.interpolator=new Gp(this.options),i.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},i.backendConnector=new Yp(o(this.modules.backend),i.resourceStore,i,this.options),i.backendConnector.on("*",(function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)})),this.modules.languageDetector&&(i.languageDetector=o(this.modules.languageDetector),i.languageDetector.init&&i.languageDetector.init(i,this.options.detection,this.options)),this.modules.i18nFormat&&(i.i18nFormat=o(this.modules.i18nFormat),i.i18nFormat.init&&i.i18nFormat.init(this)),this.translator=new Up(this.services,this.options),this.translator.on("*",(function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)})),this.modules.external.forEach((e=>{e.init&&e.init(this)}))}if(this.format=this.options.interpolation.format,n||(n=Zp),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach((t=>{this[t]=function(){return e.store[t](...arguments)}}));["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach((t=>{this[t]=function(){return e.store[t](...arguments),e}}));const i=gp(),a=()=>{const e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),n(e,t)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Zp;const n=mp(e)?e:this.language;if("function"==typeof e&&(t=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===n?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return t();const e=[],r=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach((t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)}))};if(n)r(n);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach((e=>r(e)))}this.options.preload?.forEach?.((e=>r(e))),this.services.backendConnector.load(e,this.options.ns,(e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),t(e)}))}else t(null)}reloadResources(e,t,n){const r=gp();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=Zp),this.services.backendConnector.reload(e,t,(e=>{r.resolve(),n(e)})),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&Ip.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(let t=0;t<this.languages.length;t++){const e=this.languages[t];if(!(["cimode","dev"].indexOf(e)>-1)&&this.store.hasLanguageSomeTranslations(e)){this.resolvedLanguage=e;break}}}changeLanguage(e,t){var n=this;this.isLanguageChangingTo=e;const r=gp();this.emit("languageChanging",e);const o=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(e,i)=>{i?(o(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,r.resolve((function(){return n.t(...arguments)})),t&&t(e,(function(){return n.t(...arguments)}))},a=t=>{e||t||!this.services.languageDetector||(t=[]);const n=mp(t)?t:this.services.languageUtils.getBestMatchFromCodes(t);n&&(this.language||o(n),this.translator.language||this.translator.changeLanguage(n),this.services.languageDetector?.cacheUserLanguage?.(n)),this.loadResources(n,(e=>{i(e,n)}))};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),r}getFixedT(e,t,n){var r=this;const o=function(e,t){let i;if("object"!=typeof t){for(var a=arguments.length,s=new Array(a>2?a-2:0),l=2;l<a;l++)s[l-2]=arguments[l];i=r.options.overloadTranslationOptionHandler([e,t].concat(s))}else i={...t};i.lng=i.lng||o.lng,i.lngs=i.lngs||o.lngs,i.ns=i.ns||o.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||n||o.keyPrefix);const c=r.options.keySeparator||".";let u;return u=i.keyPrefix&&Array.isArray(e)?e.map((e=>`${i.keyPrefix}${c}${e}`)):i.keyPrefix?`${i.keyPrefix}${c}${e}`:e,r.t(u,i)};return mp(e)?o.lng=e:o.lngs=e,o.ns=t,o.keyPrefix=n,o}t(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.translator?.translate(...t)}exists(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.translator?.exists(...t)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;const i=(e,t)=>{const n=this.services.backendConnector.state[`${e}|${t}`];return-1===n||0===n||2===n};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(n,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(n,e)||r&&!i(o,e)))}loadNamespaces(e,t){const n=gp();return this.options.ns?(mp(e)&&(e=[e]),e.forEach((e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)})),this.loadResources((e=>{n.resolve(),t&&t(e)})),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=gp();mp(e)&&(e=[e]);const r=this.options.preload||[],o=e.filter((e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e)));return o.length?(this.options.preload=r.concat(o),this.loadResources((e=>{n.resolve(),t&&t(e)})),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language)),!e)return"rtl";const t=this.services?.languageUtils||new $p(Xp());return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){return new Jp(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)}cloneInstance(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Zp;const n=e.forkResourceStore;n&&delete e.forkResourceStore;const r={...this.options,...e,isClone:!0},o=new Jp(r);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));if(["store","services","language"].forEach((e=>{o[e]=this[e]})),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},n){const e=Object.keys(this.store.data).reduce(((e,t)=>(e[t]={...this.store.data[t]},Object.keys(e[t]).reduce(((n,r)=>(n[r]={...e[t][r]},n)),{}))),{});o.store=new jp(e,r),o.services.resourceStore=o.store}return o.translator=new Up(o.services,r),o.translator.on("*",(function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];o.emit(e,...n)})),o.init(r,t),o.translator.options=r,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const ef=Jp.createInstance();ef.createInstance=Jp.createInstance;const tf=ef.t,{slice:nf,forEach:rf}=[];const of=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,af={create(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{path:"/",sameSite:"strict"};n&&(o.expires=new Date,o.expires.setTime(o.expires.getTime()+60*n*1e3)),r&&(o.domain=r),document.cookie=function(e,t){const n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{path:"/"};let r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){const e=n.maxAge-0;if(Number.isNaN(e))throw new Error("maxAge should be a Number");r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!of.test(n.domain))throw new TypeError("option domain is invalid");r+=`; Domain=${n.domain}`}if(n.path){if(!of.test(n.path))throw new TypeError("option path is invalid");r+=`; Path=${n.path}`}if(n.expires){if("function"!=typeof n.expires.toUTCString)throw new TypeError("option expires is invalid");r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+="; HttpOnly"),n.secure&&(r+="; Secure"),n.sameSite)switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:r+="; SameSite=Strict";break;case"lax":r+="; SameSite=Lax";break;case"strict":r+="; SameSite=Strict";break;case"none":r+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return r}(e,encodeURIComponent(t),o)},read(e){const t=`${e}=`,n=document.cookie.split(";");for(let r=0;r<n.length;r++){let e=n[r];for(;" "===e.charAt(0);)e=e.substring(1,e.length);if(0===e.indexOf(t))return e.substring(t.length,e.length)}return null},remove(e){this.create(e,"",-1)}};var sf={name:"cookie",lookup(e){let{lookupCookie:t}=e;if(t&&"undefined"!=typeof document)return af.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:o,cookieOptions:i}=t;n&&"undefined"!=typeof document&&af.create(n,e,r,o,i)}},lf={name:"querystring",lookup(e){let t,{lookupQuerystring:n}=e;if("undefined"!=typeof window){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf("?")>-1&&(e=window.location.hash.substring(window.location.hash.indexOf("?")));const r=e.substring(1).split("&");for(let o=0;o<r.length;o++){const e=r[o].indexOf("=");if(e>0){r[o].substring(0,e)===n&&(t=r[o].substring(e+1))}}}return t}};let cf=null;const uf=()=>{if(null!==cf)return cf;try{cf="undefined"!==window&&null!==window.localStorage;const e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch(e){cf=!1}return cf};var df={name:"localStorage",lookup(e){let{lookupLocalStorage:t}=e;if(t&&uf())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&uf()&&window.localStorage.setItem(n,e)}};let pf=null;const ff=()=>{if(null!==pf)return pf;try{pf="undefined"!==window&&null!==window.sessionStorage;const e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch(e){pf=!1}return pf};var hf={name:"sessionStorage",lookup(e){let{lookupSessionStorage:t}=e;if(t&&ff())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&ff()&&window.sessionStorage.setItem(n,e)}},mf={name:"navigator",lookup(e){const t=[];if("undefined"!=typeof navigator){const{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let o=0;o<e.length;o++)t.push(e[o]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},gf={name:"htmlTag",lookup(e){let t,{htmlTag:n}=e;const r=n||("undefined"!=typeof document?document.documentElement:null);return r&&"function"==typeof r.getAttribute&&(t=r.getAttribute("lang")),t}},yf={name:"path",lookup(e){let{lookupFromPathIndex:t}=e;if("undefined"==typeof window)return;const n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(n))return;const r="number"==typeof t?t:0;return n[r]?.replace("/","")}},vf={name:"subdomain",lookup(e){let{lookupFromSubdomainIndex:t}=e;const n="number"==typeof t?t+1:1,r="undefined"!=typeof window&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}};let bf=!1;try{document,bf=!0}catch(tme){}const wf=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];bf||wf.splice(1,1);class xf{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(e,t)}init(){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.services=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{languageUtils:{}},this.options=function(e){return rf.call(nf.call(arguments,1),(t=>{if(t)for(const n in t)void 0===e[n]&&(e[n]=t[n])})),e}(e,this.options||{},{order:wf,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e}),"string"==typeof this.options.convertDetectedLanguage&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=e=>e.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=t,this.addDetector(sf),this.addDetector(lf),this.addDetector(df),this.addDetector(hf),this.addDetector(mf),this.addDetector(gf),this.addDetector(yf),this.addDetector(vf)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=[];return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.order).forEach((t=>{if(this.detectors[t]){let n=this.detectors[t].lookup(this.options);n&&"string"==typeof n&&(n=[n]),n&&(e=e.concat(n))}})),e=e.map((e=>this.options.convertDetectedLanguage(e))),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?e:e.length>0?e[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach((t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)})))}}xf.type="languageDetector";const Ef={en:{common:{ad_spend:"Ad Spend",date:"Date",close:"Close",continue:"Continue",connected:"Connected",connecting:"Connecting...",reauthenticate:"Reauthenticate",account_settings:"Account Settings",manage_account_settings:"Manage your account settings",copy:"Copy",copied:"Copied",error:"An error occurred",filter:"Filter",finishingUp:"Finishing up...",loading:"Loading...",need_help:"Need help? let us know",next:"Next",next_steps:"Next steps:",number:"{{number}}",previous:"Previous",revenue:"Revenue",revenue_from_ads:"Revenue From Ads",roas:"ROAS",return_on_ad_spend:"Return on Ad Spend",select_dates:"Select dates",total_ads_spend:"Total Ads Spend",measure:{dashboard:{title:"Marketing ROI Dashboard",subtitle:"Track and analyze how your marketing efforts are driving sales",application_status_banner_title:"We are experiencing some issues",application_status_banner_description:"We are aware of an issue affecting the dashboard. We are working on it and will have it resolved soon.",no_metrics_banner_title:"We are unable to display any metrics for this date range",no_metrics_banner_description:"If you have just connected your ad accounts, your metrics should begin populating within the next 24 hours. Please check back soon.",reach_managed_campaign_banner:"Your ads are being managed by Reach. We’ll automatically optimize them to drive the best results."}},authentication:{required:"Authentication required",failed:"Authentication failed",connect_account_title:"Connect Your {{provider}} Account",connect_account_description:"To create and manage ad campaigns, please connect your {{provider}} account",connect_account_button:"Continue with {{provider}}",connect_account_TOS:"By connecting, you agree to our Terms of Service and Privacy Policy"},theme:{loading:"Loading theme...",error:"Error loading theme: {{message}}"},dates:{last_week:"Last week",last_month:"Last month",last_quarter:"Last quarter",last_year:"Last year"},campaigns:{setup:{card_header:"Run paid digital ads to get new leads & customers",title:"Create your first AI-driven Ad campaign in 4 simple clicks",description:"Welcome to the future of advertising! Our AI-powered campaign builder helps you effortlessly design and manage ads that reach your target audience with precision. Get started now to unlock the potential of automated, data-driven advertising.",button:"Set up paid ads",next_steps_description:"Already running ads? Track Your Marketing Results with a few clicks.",link_to_analytics:"Connect your existing accounts to get instant insights into your marketing performance."},how_it_works:{dialog_title:"How It Works",title:"Setup your ad campaign",step1:{title:"Set up budget & review your ads",description:"Define how much you want to spend, review the ad designs, and configure who you want to reach."},step2:{title:"We’ll publish & optimize your ads on Google",description:"We’ll do the hard work of publishing & continuously optimizing your ads on Google making sure you’re getting the best possible return on investment."},step3:{title:"See Customers & Results",description:"When a customer buys from you, we’ll notify you and show you the total revenue driven to your business from each dollar invested in ads. "}},ads_builder:{dialog_trigger:"New campaign",title:"Ads Builder",description:"Create your new ad campaign",review_ad_themes:"Review Ad Themes",example_ad_preview:"Example Ad Preview",example_ad_preview_description:"Here's an example of how prospective customers might see your ads. We will automagically tweak the copy based on your products offered, and improve targeting based on what results in the most dollars to your business."}},analytics:{setup_analytics:"Setup analytics",setup_analytics_description:"Let's get you started with analytics. Connect your data sources to start tracking your customers.",connect_data:{title:"Connect Your Data",description:"We bring all of your ads data together to give you a clear view of which customers are coming in from where."},install_pixel:{copied_to_clipboard:"Copied to clipboard",copied_to_clipboard_description:"The tracking pixel code has been copied to your clipboard.",title:"Install our Tracking Pixel",description:"In order to get a complete picture of how users are interacting with your website, it’s important for the Reach analytics code to be on every page of your website and within as many third-party tools that you use as possible.",card_title:"Install the Snippet inside the <HEAD> of every page",third_party_pages_your_tracking_pixel:"Your Tracking Pixel:",card_description:"Copy this following text and insert it inside of the <HEAD> tags on all pages.",error_generating_pixel_code:"Error generating pixel code - please contact your administrator",third_party_pages_question:"Do you use any websites or landing pages for marketing your business?",third_party_pages_yes:"Yes, I have marketing websites",third_party_pages_no:"No, I don't use any websites",third_party_pages_why_asking:"Why We're Asking For This",third_party_pages_why_asking_description:"Adding our tracking pixel to your website allows us to:",third_party_pages_why_asking_list_1:"Understand how visitors interact with your pages",third_party_pages_why_asking_list_2:"Measure which ads are driving visitors to your site",third_party_pages_why_asking_list_3:"Track conversions from your campaigns",third_party_pages_enter_marketing_website:"Enter your marketing website:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"We'll use this to help you install the tracking pixel",third_party_pages_select_your_website_platform:"Select your website platform:"},third_party_installation_guides:{title:"Installation Guides",description:"These guides will help you add the Reach analytics snippet to your website. The process works with any website builder or platform and most third-party tools.",installation_guide:"{{name}} Installation Guide",official_guide:"Official Guide",shopify:{step_1:"From your Shopify admin, go to Online Store > Themes",step_2:"Find the theme you want to edit, click the … button to open the actions menu, and then click Edit code",step_3:'Open "theme.liquid"',step_4:"Find the </head> tag",step_5:"Paste the code snippet from the section above just before it"},google_tag_manager:{step_1:"Go to https://tagmanager.google.com",step_2:"Sign in to your Google Account",step_3:"Click the Accounts tab, then select Create Account",step_4:"Enter an account name and select your country location",step_5:"In Container Setup, enter a container name (e.g., your website URL)",step_6:'Select "Web" as the container type',step_7:"Click Create and agree to the Terms of Service",step_8:"Once created, you'll receive two code snippets to install:",step_9:"• Place the first snippet in the <head> of your page",step_10:"• Place the second snippet immediately after the opening <body> tag",step_11:"In the Tags tab, click the + button to create a new tag",step_12:'Select "Google Analytics: Universal Analytics" as the tag type',special_note:"Make sure you have the Google Tag Manager container code already installed on your site before adding this tag."},hubspot:{step_1:"Go to Settings → Content → Pages",step_2:'In the upper left, select a domain to edit its settings. Or select "Default settings for all domains"',step_3:'Paste the code from the section above to the "Site Header HTML" field',step_4:'Click "Save"'},wordpress:{step_1:"We recommend using the popular WPCode Plugin",step_2:'In the plugin, select "+ Add Snippet"',step_3:'When presented with a menu of options, navigate to "Add Your Custom Code (New Snippet)" and select "Use snippet"',step_4:"Paste the code snippet from the section above",step_5:'For Insert Method, choose "Auto Insert"',step_6:'For Location, select "Site Wide Header"',step_7:"Be sure to save your snippet"},squarespace:{step_1:"Go to Settings → Advanced → Code Injection",step_2:'Paste the code from the section above into the "Header" field',step_3:'Click "Save"'},wix:{step_1:"Go to Settings → Custom Code",step_2:'Click "+ Add Custom Code"',step_3:"Paste the code from the section above",step_4:'Click "Apply"',step_5:'Set "Add Code to Pages" to "All Pages"'},webflow:{step_1:"Open your project settings",step_2:'Navigate to "Custom Code"',step_3:'Paste the code from the section above into the "Head Code" section',step_4:'Click "Save Changes"'},third_party_systems:{step_1:"Check if your third-party tools (lead forms, scheduling tools, etc.) allow custom code injection",step_2:'Look for options labeled "Custom Code", "Embed Code", or "Advanced Settings"',step_3:"Paste the same tracking code into these sections where available",step_4:"Common locations include:",step_5:"• Head section of your website (for tracking scripts and styles)",step_6:"• Footer section of your website (for tracking scripts and styles)",special_note:"This helps ensure consistent tracking across all your customer touchpoints, even when using external tools."},custom:{step_1:"Locate your website's HTML template or main layout file",step_2:"Find the </head> tag in your HTML",step_3:"Paste the code snippet just before the </head> tag",step_4:"Save the file and deploy your changes"}},success:{title:"Success!",description:"You have successfully connected your data sources and installed our tracking pixel.",what_next:"What happens next?",step_1:"Your ad data will start syncing automatically",step_2:"The pixel will begin tracking conversions on your site",step_3:"You'll see your first analytics reports within 24 hours"}},dashboard:{banners:{metrics_crunching:{title:"Crunching your data",description:"You have successfully connected your ad accounts. We're now crunching your data. Check back soon for relevant metrics."},revoked_accounts:{title:"Your ad accounts have been revoked",description:"Please reconnect your ad accounts to continue using the dashboard."}},roas_chart:{title:"Ad Spend vs Revenue Over Time",campaign_not_available:"Chart is not available for individual campaigns yet"},customer_acquisition:{title:"Client Acquisition",description:"See how many new clients you acquired from each channel",client:"Client",source:"Source",total_spent:"Total Spent",total_revenue:"Total Revenue",status:"Status",no_data:"No data available",source_breakdown:"Source",payment_status:"Payment Status",paid:"Paid",unpaid:"Unpaid",invoice_details:"Invoice Details",amount:"Amount",service:"Service",invoice_date:"Invoice Date"},channel_performance:{title:"Channel Performance",description:"See how each channel performs",channel:"Channel",spend:"Spend",revenue:"Revenue",roas:"ROAS",new_customers:"New Customers"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Overview",channel_performance:"Channel Performance",campaign_performance:"Campaign Performance",customer_acquisition:"Customer Acquisition",traffic_conversion:"Traffic Conversion"},metrics:{ads_spend:"Ads Spend",ads_spend_description:"The amount spent on ads in a given period. Sum of all sub-ads accounts (e.g. insta, google). Excluding agency fees",direct_measured_revenue:"Direct Measured Revenue",direct_measured_revenue_description:"The amount of revenue directly measured from ads",measured_revenue:"Measured Revenue",measured_revenue_description:"The amount of revenue measured from ads",direct_measured_conversions:"Direct Measured Conversions",direct_measured_conversions_description:"The amount of conversions directly measured from ads",measured_conversions:"Measured Conversions",measured_conversions_description:"The amount of conversions measured from ads",roas:"ROAS",roas_description:"This is the ratio of the revenue to the ads spend",impressions:"Impressions",impressions_description:"Number of times your ads were shown to potential customers",clicks:"Clicks/Actions",clicks_description:"Total interactions with your ads, including clicks and other actions",website_visitors:"Website Visitors",website_visitors_description:"Unique visitors to your website from advertising campaigns",new_leads:"New Leads",new_leads_description:"New potential customers who provided contact information",customer_ltv:"Customer LTV",customer_ltv_description:"Average lifetime value of customers acquired through ads",new_customers:"New Customers",new_customers_description:"New customers who made a purchase or took an action",new_leads_conversion_rate:"New Leads Conversion Rate",new_leads_conversion_rate_description:"The ratio of new leads to the total number of leads",new_customers_conversion_rate:"New Customers Conversion Rate",new_customers_conversion_rate_description:"The ratio of new customers to the total number of customers",cost_per_click:"Cost Per Click",cost_per_click_description:"The amount spent per click on your ads",click_conversion_rate:"Click Conversion Rate",click_conversion_rate_description:"The ratio of clicks to the total number of clicks",click_through_rate:"Click Through Rate",click_through_rate_description:"The ratio of clicks to the total number of impressions",conversion_rate:"Conversion Rate",conversion_rate_description:"The ratio of conversions to the total number of clicks",total_conversion:"Total Conversion",total_conversion_description:"The total number of conversions from your ads",cac:"CAC",cac_description:"The amount spent per customer acquisition",revenue_per_click:"Revenue Per Click",revenue_per_click_description:"The amount of revenue generated per click on your ads",revenue_per_new_customer:"Revenue Per New Customer",revenue_per_new_customer_description:"The amount of revenue generated per new customer",reengaged_customers:"Reengaged Customers",reengaged_customers_description:"The number of customers who have been reengaged with your ads",expected_revenue:"Expected Revenue",expected_revenue_description:"The amount of revenue you expect to generate from your ads",estimated_revenue:"Estimated Revenue",estimated_revenue_description:"The amount of revenue you expect to generate from your ads"},title:"Marketing Revenue Dashboard",settings_sheet:{setup:"Setup",connected_accounts:"Connected Accounts",setup_analytics:"Setup analytics",setup_analytics_description:"Configure your analytics tracking",setup_campaigns:"Setup campaigns",setup_campaigns_description:"Set up your first campaign",legal:"Legal",terms_of_service:"Terms of Service",privacy_policy:"Privacy Policy"}},setup:{how_it_works:{title:"How It Works",dialog_title:"Setup Marketing Insights",connect_ads_title:"Connect your Ads Accounts",connect_ads_description:"Link your advertising accounts from platforms like Google and Meta to consolidate all your campaign data in one place. This enables comprehensive tracking and analysis of your marketing spend.",install_pixel_title:"Install Our Tracking Pixel",install_pixel_description:"Add our lightweight tracking code to your website to accurately measure customer interactions and conversions. This simple integration helps identify which ads are driving real results for your business.",see_customers_results_title:"See Customers & Results",see_customers_results_description:"Get clear insights into your marketing performance with detailed analytics on customer acquisition, conversion rates, and return on ad spend. Make data-driven decisions to optimize your campaigns and grow your business.",still_have_more_questions:"Still have more questions?",get_started:"Get Started"},initial_setup:{wizard_title:"Connect your ad accounts and see exactly how your campaigns drive revenue",title:"Unlock Clear Insights into Your Marketing Performance",description:"Stop guessing and start knowing. Our performance dashboard gives you a complete view of your marketing efforts, including ad spend, conversions, and return on ad spend (ROAS).",description_2:"With a simple setup process, you’ll have actionable insights at your fingertips to help you make smarter decisions and grow your business.",setup_performance_analytics:"Setup Performance Analytics",next_steps_description:"If you're not running ads yet, you can launch your first AI-powered ad campaign in minutes.",next_steps_link:"We will prompt you to connect your ad accounts and set up your first campaign."}},oauth:{selectAccount:{title:"Select {{platform}} Account",description:"Choose the {{platform}} account you want to connect.",loading:"Loading accounts...",loadingPlatform:"Loading {{platform}} accounts...",loadingDescription:"Please wait while we fetch your available accounts...",noAccounts:"No {{platform}} accounts were found for your account.",noAccountsDescription:"Please make sure you have access to a {{platform}} account and try again.",selectAccountPlaceholder:"Select an account",searchPlaceholder:"Search accounts...",fetchAccounts:"Fetching accounts...",noAccountSelected:"No account selected",enableTrackingParams:"Enable Tracking Parameters",enableTrackingParamsDescription:"Append the reach campaign id parameter to your ad platform tracking settings. We will not overwrite any existing tracking parameters. Required for accurate tracking.",google:{selectAccountDescription:"Select the Google Ads account you want to connect to view your data. These will be linked to our MCC for optimal tracking.",mccAccounts:"MCC Accounts",directAccounts:"Direct Accounts"},meta:{selectAccountDescription:"Choose the Meta Ads account you want to connect to view your data."}},success:{connection:{title:"Connected successfully",description:"Your {{provider}} account has been connected."},revoke:{title:"Account revoked",description:"Your {{provider}} account has been revoked."}},error:{title:"Connection failed",description:"Failed to connect account"},revoke:{title:"Revoke access",description:"Are you sure? Revoking access will remove the connection you have and you will be unable to view your ad metrics.",cancel:"Cancel",revoke:"Revoke",error:{title:"Error",description:"Failed to revoke access"}}},magic_link:{get_started:"Get Started",description:"Reach will be embedded within your platform dashboard but until then, you can get started with a magic link. Log in to your account and start creating AI-powered campaigns or measuring your ad spend and performance.",create_campaigns:"Create AI-generated ad campaigns in minutes",unlock_insights:"Unlock insights into your ad spend and performance",save_time:"Save time with automated campaign optimization",request_new_magic_link:"Request New Magic Link",go_to_dashboard:"Go to Dashboard",continuation_disclaimer:"By continuing, you agree to our <terms_of_service>Terms of Service</terms_of_service> and <privacy_policy>Privacy Policy</privacy_policy>."},empty_state:{analytics:{title:"You haven't connected any ad accounts yet",description:"You can connect your ad accounts in minutes and start driving more customers to your business.",button_text:"Setup analytics"}}},engage:{user:"User",user_other:"Users",automation:"Automation",automation_other:"Automations",segment:"Segment",segment_other:"Segments",one_time:"One Time",trigger_based:"Trigger Based"}},es:{common:{ad_spend:"Gasto en anuncios",date:"Fecha",close:"Cerrar",continue:"Continuar",connected:"Conectado",connecting:"Conectando...",reauthenticate:"Reautenticar",account_settings:"Configuración de cuenta",manage_account_settings:"Configuración de tu cuenta",copy:"Copiar",copied:"Copiado",error:"Se produjo un error",filter:"Filtrar",finishingUp:"Finalizando...",loading:"Cargando...",need_help:"¿Necesitas ayuda? Háznoslo saber",next:"Siguiente",next_steps:"Siguientes pasos:",number:"{{number}}",previous:"Anterior",revenue:"Ingresos",revenue_from_ads:"Ingresos de anuncios",roas:"ROAS",return_on_ad_spend:"Retorno de inversión en anuncios",select_dates:"Selecciona fechas",total_ads_spend:"Gasto total en anuncios",measure:{dashboard:{title:"Panel de ingresos de marketing",subtitle:"Rastrea y analiza cómo tus esfuerzos de marketing están generando ventas",application_status_banner_title:"Estamos experimentando algunos problemas",application_status_banner_description:"Estamos al tanto de un problema que está afectando al panel. Estamos trabajando en ello y lo resolveremos pronto.",no_metrics_banner_title:"No podemos mostrar ninguna métrica para este rango de fechas",no_metrics_banner_description:"Si has conectado tus cuentas de anuncios recientemente, tus métricas deberían comenzar a poblarse en las próximas 24 horas. Por favor, vuelve pronto.",reach_managed_campaign_banner:"Tus anuncios están siendo gestionados por Reach. Automáticamente los optimizaremos para obtener los mejores resultados."}},authentication:{required:"Se requiere autenticación",failed:"Error de autenticación",connect_account_title:"Conecta tu cuenta de {{provider}}",connect_account_description:"Para crear y gestionar campañas de anuncios, por favor conecta tu cuenta de {{provider}}",connect_account_button:"Continuar con {{provider}}",connect_account_TOS:"Al conectarte, aceptas nuestros Términos de Servicio y Política de Privacidad"},theme:{loading:"Cargando tema...",error:"Error al cargar el tema: {{message}}"},dates:{last_week:"Semana pasada",last_month:"Mes pasado",last_quarter:"Trimestre pasado",last_year:"Año pasado"},campaigns:{setup:{card_header:"Lanza anuncios pagados para obtener nuevos leads y clientes",title:"Crea tu primera campaña de anuncios AI en 4 clicks",description:"Bienvenido al futuro del marketing! Nuestro creador de campañas AI te ayuda a diseñar y gestionar anuncios que alcanzan a tu audiencia con precisión. ¡Comienza ahora para desbloquear el potencial de anuncios automatizados y basados en datos.",button:"Configura tus anuncios pagados",next_steps_description:"¿Ya tienes anuncios? Rastrea tus resultados de marketing con solo unos clicks.",link_to_analytics:"Conecta tus cuentas existentes para obtener insights instantáneos sobre tu rendimiento de marketing."},how_it_works:{dialog_title:"Cómo funciona",title:"Configura tu campaña de anuncios",step1:{title:"Configura tu presupuesto y revisa tus anuncios",description:"Define cuánto quieres gastar, revisa los diseños de anuncios y configura quién quieres llegar."},step2:{title:"Publicaremos y optimizaremos tus anuncios en Google",description:"Haremos el trabajo duro de publicar y optimizar tus anuncios en Google para asegurarnos de que obtengas el mejor retorno de inversión posible."},step3:{title:"Ver clientes y resultados",description:"Cuando un cliente compra de ti, te notificaremos y te mostraremos el total de ingresos generados para tu negocio por cada dólar invertido en anuncios."}},ads_builder:{dialog_trigger:"Nueva campaña",title:"Ads Builder",description:"Crea tu nueva campaña de anuncios",review_ad_themes:"Revisa temas de anuncios",example_ad_preview:"Ejemplo de anuncio",example_ad_preview_description:"Aquí tienes un ejemplo de cómo los clientes potenciales podrían ver tus anuncios. Automáticamente ajustaremos el texto basándonos en tus productos ofrecidos y mejoraremos el targeting basándonos en lo que resulta en más dinero para tu negocio."}},analytics:{setup_analytics:"Configura analytics",setup_analytics_description:"Vamos a empezar con analytics. Conecta tus fuentes de datos para empezar a rastrear tus clientes.",connect_data:{title:"Conecta tus datos",description:"Juntamos todos tus datos de anuncios para darte una visión clara de qué clientes están llegando de dónde."},install_pixel:{copied_to_clipboard:"Copiado al portapapeles",copied_to_clipboard_description:"El código del pixel de seguimiento ha sido copiado a tu portapapeles.",title:"Instala nuestro pixel de seguimiento",description:"Para obtener una visión completa de cómo los usuarios interactúan con tu sitio web, es importante que el código de analytics de Reach esté en cada página de tu sitio web y dentro de tantos terceros como puedas usar.",card_title:"Instala el fragmento dentro del <HEAD> de cada página",third_party_pages_your_tracking_pixel:"Tu pixel de seguimiento:",card_description:"Copia este texto y insertalo dentro de las etiquetas <HEAD> en todas las páginas.",error_generating_pixel_code:"Error generando código del pixel - por favor contacta a tu administrador",third_party_pages_question:"¿Utilizas alguna página web o landing page para promocionar tu negocio?",third_party_pages_yes:"Sí, tengo páginas web de marketing",third_party_pages_no:"No, no utilizo ninguna página web",third_party_pages_why_asking:"¿Por qué te pedimos esto?",third_party_pages_why_asking_description:"Añadir nuestro pixel de seguimiento a tu sitio web nos permite:",third_party_pages_why_asking_list_1:"Entender cómo los visitantes interactúan con tus páginas",third_party_pages_why_asking_list_2:"Medir qué anuncios están llevando visitantes a tu sitio",third_party_pages_why_asking_list_3:"Rastrear conversiones desde tus campañas",third_party_pages_enter_marketing_website:"Ingresa tu página web de marketing:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"Usaremos esto para ayudarte a instalar el pixel de seguimiento",third_party_pages_select_your_website_platform:"Selecciona tu plataforma de sitio web:"},third_party_installation_guides:{title:"Guías de instalación",description:"Estas guías te ayudarán a agregar el fragmento de analytics de Reach a tu sitio web. El proceso funciona con cualquier constructor de sitios web o plataforma y la mayoría de las herramientas de terceros.",installation_guide:"Guía de instalación de {{name}}",official_guide:"Guía oficial",shopify:{step_1:"Desde tu Shopify admin, ve a Online Store > Themes",step_2:"Encuentra el tema que quieres editar, haz click en el botón … para abrir el menú de acciones y luego haz click en Editar código",step_3:'Abre "theme.liquid"',step_4:"Encuentra la etiqueta </head>",step_5:"Pega el fragmento de código de la sección anterior justo antes de ella"},google_tag_manager:{step_1:"Ve a https://tagmanager.google.com",step_2:"Inicia sesión en tu cuenta de Google",step_3:"Haz click en la pestaña de Cuentas y selecciona Crear cuenta",step_4:"Ingresa un nombre para tu cuenta y selecciona tu ubicación",step_5:"En Container Setup, ingresa un nombre para tu contenedor (e.g., tu URL de sitio web)",step_6:'Selecciona "Web" como tipo de contenedor',step_7:"Haz click en Crear y acepta los Términos de Servicio",step_8:"Una vez creado, recibirás dos fragmentos de código para instalar:",step_9:"• Coloca el primer fragmento en la etiqueta <head> de tu página",step_10:"• Coloca el segundo fragmento justo después de la etiqueta <body>",step_11:"En la pestaña de Etiquetas, haz click en el botón + para crear una nueva etiqueta",step_12:'Selecciona "Google Analytics: Universal Analytics" como tipo de etiqueta',special_note:"Asegúrate de tener el código del contenedor de Google Tag Manager instalado en tu sitio web antes de agregar esta etiqueta."},hubspot:{step_1:"Ve a Configuración → Contenido → Páginas",step_2:'En la esquina superior izquierda, selecciona un dominio para editar sus ajustes. O selecciona "Ajustes predeterminados para todos los dominios"',step_3:'Pega el código de la sección anterior en el campo "HTML del encabezado del sitio"',step_4:'Haz click en "Guardar"'},wordpress:{step_1:"Recomendamos usar el plugin WPCode",step_2:'En el plugin, selecciona "+ Añadir fragmento"',step_3:'Cuando se te presente un menú de opciones, navega a "Añadir tu código personalizado (nuevo fragmento)" y selecciona "Usar fragmento"',step_4:"Pega el fragmento de código de la sección anterior",step_5:'Para el método de inserción, elige "Auto insertar"',step_6:'Para la ubicación, selecciona "Encabezado del sitio"',step_7:"Asegúrate de guardar tu fragmento"},squarespace:{step_1:"Ve a Configuración → Avanzado → Inyección de código",step_2:'Pega el código de la sección anterior en el campo "Encabezado"',step_3:'Haz click en "Guardar"'},wix:{step_1:"Ve a Configuración → Código personalizado",step_2:'Haz click en "+ Añadir código personalizado"',step_3:"Pega el código de la sección anterior",step_4:'Haz click en "Aplicar"',step_5:'Establece "Añadir código a páginas" a "Todas las páginas"'},webflow:{step_1:"Abre tus ajustes de proyecto",step_2:'Navega a "Código personalizado"',step_3:'Pega el código de la sección anterior en la sección "Código de encabezado"',step_4:'Haz click en "Guardar cambios"'},third_party_systems:{step_1:"Revisa si tus herramientas de terceros (formularios de leads, herramientas de programación, etc.) permiten la inyección de código personalizado",step_2:'Busca opciones etiquetadas como "Código personalizado", "Código incrustado" o "Ajustes avanzados"',step_3:"Pega el mismo código de seguimiento en estas secciones donde esté disponible",step_4:"Los lugares comunes incluyen:",step_5:"• Sección de encabezado de tu sitio web (para scripts y estilos de seguimiento)",step_6:"• Sección de pie de página de tu sitio web (para scripts y estilos de seguimiento)",special_note:"Esto asegura un seguimiento consistente en todos tus puntos de contacto con clientes, incluso cuando usas herramientas externas."},custom:{step_1:"Localiza tu plantilla HTML o archivo de diseño principal",step_2:"Encuentra la etiqueta </head> en tu HTML",step_3:"Pega el fragmento de código justo antes de la etiqueta </head>",step_4:"Guarda el archivo y desplíalo"}},success:{title:"¡Éxito!",description:"Has conectado tus fuentes de datos y instalado nuestro pixel de seguimiento.",what_next:"¿Qué pasa a continuación?",step_1:"Tus datos de anuncios comenzarán a sincronizarse automáticamente",step_2:"El pixel comenzará a rastrear conversiones en tu sitio",step_3:"Verás tus primeros informes de analytics en 24 horas"}},dashboard:{banners:{metrics_crunching:{title:"Trabajando en tus datos",description:"Has conectado tus cuentas de anuncios. Estamos ahora trabajando en tus datos. Vuelve pronto para ver tus métricas relevantes."},revoked_accounts:{title:"Tus cuentas de anuncios han sido revocadas",description:"Por favor, reconecta tus cuentas de anuncios para continuar usando el panel."}},roas_chart:{title:"Gasto en anuncios vs ingresos en el tiempo",campaign_not_available:"El gráfico no está disponible para campañas individuales todavía"},customer_acquisition:{title:"Adquisición de clientes",description:"Ver cómo adquieres nuevos clientes desde cada canal",client:"Cliente",source:"Fuente",total_spent:"Total gastado",total_revenue:"Ingresos totales",status:"Estado",no_data:"No hay datos disponibles",source_breakdown:"Desglose de fuentes",payment_status:"Estado de pago",paid:"Pagado",unpaid:"No pagado",invoice_details:"Detalles de la factura",amount:"Cantidad",service:"Servicio",invoice_date:"Fecha de la factura"},channel_performance:{title:"Rendimiento de canales",description:"Ver cómo cada canal se desempeña",channel:"Canal",spend:"Gasto",revenue:"Ingresos",roas:"ROAS",new_customers:"Nuevos clientes"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Resumen",channel_performance:"Rendimiento de canales",campaign_performance:"Rendimiento de campañas",customer_acquisition:"Adquisición de clientes",traffic_conversion:"Conversión de tráfico"},metrics:{ads_spend:"Gasto en anuncios",ads_spend_description:"El gasto en anuncios en un período determinado. Suma de todos los sub-cuentas de anuncios (e.g. insta, google). Excluyendo comisiones de agencias",direct_measured_revenue:"Ingresos medidos directamente",direct_measured_revenue_description:"La cantidad de ingresos medidos directamente desde anuncios",measured_revenue:"Ingresos medidos",measured_revenue_description:"La cantidad de ingresos medidos desde anuncios",direct_measured_conversions:"Conversiones medidas directamente",direct_measured_conversions_description:"La cantidad de conversiones medidas directamente desde anuncios",measured_conversions:"Conversiones medidas",measured_conversions_description:"La cantidad de conversiones medidas desde anuncios",roas:"ROAS",roas_description:"Este es el ratio de los ingresos a los gastos en anuncios",impressions:"Impresiones",impressions_description:"Número de veces que tus anuncios fueron mostrados a potenciales clientes",clicks:"Clicks/Acciones",clicks_description:"Total de interacciones con tus anuncios, incluyendo clicks y otras acciones",website_visitors:"Visitantes web",website_visitors_description:"Visitantes únicos a tu sitio web desde campañas de anuncios",new_leads:"Nuevos leads",new_leads_description:"Nuevos potenciales clientes que proporcionaron información de contacto",customer_ltv:"LTV de cliente",customer_ltv_description:"Valor promedio de vida de clientes adquiridos a través de anuncios",new_customers:"Nuevos clientes",new_customers_description:"Nuevos clientes que hicieron una compra o tomaron una acción",new_leads_conversion_rate:"Tasa de conversión de leads nuevos",new_leads_conversion_rate_description:"El ratio de leads nuevos al total de leads",new_customers_conversion_rate:"Tasa de conversión de nuevos clientes",new_customers_conversion_rate_description:"El ratio de nuevos clientes al total de clientes",cost_per_click:"Costo por click",cost_per_click_description:"El gasto por click en tus anuncios",click_conversion_rate:"Tasa de conversión de clicks",click_conversion_rate_description:"El ratio de clicks al total de clicks",click_through_rate:"Tasa de clics",click_through_rate_description:"El ratio de clicks al total de impresiones",conversion_rate:"Tasa de conversión",conversion_rate_description:"El ratio de conversiones al total de clicks",total_conversion:"Total de conversiones",total_conversion_description:"El número total de conversiones desde tus anuncios",cac:"CAC",cac_description:"El gasto por cliente adquirido",revenue_per_click:"Ingresos por click",revenue_per_click_description:"El ingreso generado por cada click en tus anuncios",revenue_per_new_customer:"Ingresos por nuevo cliente",revenue_per_new_customer_description:"El ingreso generado por cada nuevo cliente",reengaged_customers:"Clientes reactivados",reengaged_customers_description:"El número de clientes que han sido reactivados con tus anuncios",expected_revenue:"Ingresos esperados",expected_revenue_description:"El ingreso que esperas generar desde tus anuncios",estimated_revenue:"Ingresos estimados",estimated_revenue_description:"El ingreso que estimas generar desde tus anuncios"},title:"Panel de ingresos de marketing",settings_sheet:{setup:"Configuración",connected_accounts:"Cuentas conectadas",setup_analytics:"Configurar analytics",setup_analytics_description:"Configura tu tracking de analytics",setup_campaigns:"Configurar campañas",setup_campaigns_description:"Configura tu primera campaña",legal:"Legal",terms_of_service:"Términos de servicio",privacy_policy:"Política de privacidad"}},setup:{how_it_works:{title:"Cómo funciona",dialog_title:"Configura Marketing Insights",connect_ads_title:"Conecta tus cuentas de anuncios",connect_ads_description:"Conecta tus cuentas de anuncios de plataformas como Google y Meta para consolidar todos tus datos de campañas en un solo lugar. Esto te permite rastrear y analizar tu gasto en marketing de manera completa.",install_pixel_title:"Instala nuestro pixel de seguimiento",install_pixel_description:"Añade nuestro código de seguimiento ligero a tu sitio web para medir las interacciones y conversiones de los clientes. Esta integración simple ayuda a identificar qué anuncios están generando resultados reales para tu negocio.",see_customers_results_title:"Ver clientes y resultados",see_customers_results_description:"Obtén una visión clara de tu rendimiento en marketing con análisis detallados sobre adquisición de clientes, tasas de conversión y retorno de inversión en anuncios. Haz decisiones basadas en datos para optimizar tus campañas y crecer tu negocio.",still_have_more_questions:"¿Tienes más preguntas?",get_started:"Comenzar"},initial_setup:{wizard_title:"Conecta tus cuentas de anuncios y ver cómo tus campañas generan ingresos",title:"Desbloquea insights claros en tu rendimiento de marketing",description:"Para empezar, conecta tus cuentas de anuncios de Google y Meta. Esto te permitirá rastrear y analizar tu gasto en marketing de manera completa.",description_2:"Con un proceso de configuración simple, tendrás insights accionables a tu disposición para ayudarte a tomar mejores decisiones y crecer tu negocio.",setup_performance_analytics:"Configura analytics de rendimiento",next_steps_description:"Si no tienes anuncios aún, puedes lanzar tu primera campaña de anuncios AI en minutos.",next_steps_link:"Te pediremos que conectes tus cuentas de anuncios y configures tu primera campaña."}},oauth:{selectAccount:{title:"Cuenta de {{platform}}",description:"Elige la cuenta de {{platform}} que quieres conectar.",loading:"Cargando cuentas...",loadingPlatform:"Cargando cuentas de {{platform}}...",loadingDescription:"Por favor, espera mientras obtenemos tus cuentas disponibles...",noAccounts:"No se encontraron cuentas de {{platform}} para tu cuenta.",noAccountsDescription:"Por favor, asegúrate de tener acceso a una cuenta de {{platform}} y vuelve a intentarlo.",selectAccountPlaceholder:"Selecciona una cuenta",searchPlaceholder:"Buscar cuentas...",fetchAccounts:"Buscando cuentas...",noAccountSelected:"No hay cuenta seleccionada",enableTrackingParams:"Habilitar parámetros de seguimiento",enableTrackingParamsDescription:"Añada el parámetro de ID de campaña de alcance a la configuración de seguimiento de su plataforma publicitaria. No sobrescribiremos ningún parámetro de seguimiento existente. Necesario para un seguimiento preciso.",google:{selectAccountDescription:"Elige la cuenta de Google Ads que quieres conectar para ver tus datos. Estas serán vinculadas a nuestra MCC para un seguimiento óptimo.",mccAccounts:"Cuentas MCC",directAccounts:"Cuentas Directas"},meta:{selectAccountDescription:"Elige la cuenta de Meta Ads que quieres conectar para ver tus datos."}},success:{connection:{title:"Conectado correctamente",description:"Tu cuenta de {{provider}} ha sido conectada."},revoke:{title:"Cuenta revocada",description:"Tu cuenta de {{provider}} ha sido revocada."}},error:{title:"Error al conectar",description:"Error al conectar cuenta"},revoke:{title:"Revocar acceso",description:"¿Estás seguro? Revocar acceso eliminará la conexión que tienes y no podrás ver tus métricas de anuncios.",cancel:"Cancelar",revoke:"Revocar",error:{title:"Error",description:"Error al revocar acceso"}}},magic_link:{get_started:"Comenzar",description:"Reach estará incrustado en tu panel de control pero hasta entonces, puedes comenzar con un enlace mágico. Inicia sesión en tu cuenta y comienza a crear campañas AI o mide tu gasto en anuncios y rendimiento.",create_campaigns:"Crea campañas de anuncios AI en minutos",unlock_insights:"Desbloquea insights en tu gasto en anuncios y rendimiento",save_time:"Ahorra tiempo con optimización de campañas automatizadas",request_new_magic_link:"Solicitar nuevo enlace mágico",go_to_dashboard:"Ir al panel de control",continuation_disclaimer:"Al continuar, aceptas nuestros <terms_of_service>Términos de servicio</terms_of_service> y <privacy_policy>Política de privacidad</privacy_policy>."},empty_state:{analytics:{title:"No tienes ninguna cuenta de anuncios conectada",description:"Puedes conectar tus cuentas de anuncios en minutos y empezar a atraer más clientes a tu negocio.",button_text:"Configurar analytics"}}},engage:{user:"Usuario",user_other:"Usuarios",automation:"Automatización",automation_other:"Automatizaciones",segment:"Segmento",segment_other:"Segmentos",one_time:"Una vez",trigger_based:"Basado en un disparador"}}};ef.use(xf).use(pp).init({resources:Ef,fallbackLng:"en",debug:!1,interpolation:{escapeValue:!1},react:{useSuspense:!1},defaultNS:"common",ns:["common"],load:"languageOnly",detection:{order:["querystring","localStorage","navigator"],lookupQuerystring:"lang",lookupLocalStorage:"i18nextLng",caches:["localStorage"],convertDetectedLanguage:e=>e.split("-")[0]}});const _f={ad_spend:"Ad Spend",date:"Date",close:"Close",continue:"Continue",connected:"Connected",connecting:"Connecting...",reauthenticate:"Reauthenticate",account_settings:"Account Settings",manage_account_settings:"Manage your account settings",copy:"Copy",copied:"Copied",error:"An error occurred",filter:"Filter",finishingUp:"Finishing up...",loading:"Loading...",need_help:"Need help? let us know",next:"Next",next_steps:"Next steps:",number:"{{number}}",previous:"Previous",revenue:"Revenue",revenue_from_ads:"Revenue From Ads",roas:"ROAS",return_on_ad_spend:"Return on Ad Spend",select_dates:"Select dates",total_ads_spend:"Total Ads Spend",measure:{dashboard:{title:"Marketing ROI Dashboard",subtitle:"Track and analyze how your marketing efforts are driving sales",application_status_banner_title:"We are experiencing some issues",application_status_banner_description:"We are aware of an issue affecting the dashboard. We are working on it and will have it resolved soon.",no_metrics_banner_title:"We are unable to display any metrics for this date range",no_metrics_banner_description:"If you have just connected your ad accounts, your metrics should begin populating within the next 24 hours. Please check back soon.",reach_managed_campaign_banner:"Your ads are being managed by Reach. We’ll automatically optimize them to drive the best results."}},authentication:{required:"Authentication required",failed:"Authentication failed",connect_account_title:"Connect Your {{provider}} Account",connect_account_description:"To create and manage ad campaigns, please connect your {{provider}} account",connect_account_button:"Continue with {{provider}}",connect_account_TOS:"By connecting, you agree to our Terms of Service and Privacy Policy"},theme:{loading:"Loading theme...",error:"Error loading theme: {{message}}"},dates:{last_week:"Last week",last_month:"Last month",last_quarter:"Last quarter",last_year:"Last year"},campaigns:{setup:{card_header:"Run paid digital ads to get new leads & customers",title:"Create your first AI-driven Ad campaign in 4 simple clicks",description:"Welcome to the future of advertising! Our AI-powered campaign builder helps you effortlessly design and manage ads that reach your target audience with precision. Get started now to unlock the potential of automated, data-driven advertising.",button:"Set up paid ads",next_steps_description:"Already running ads? Track Your Marketing Results with a few clicks.",link_to_analytics:"Connect your existing accounts to get instant insights into your marketing performance."},how_it_works:{dialog_title:"How It Works",title:"Setup your ad campaign",step1:{title:"Set up budget & review your ads",description:"Define how much you want to spend, review the ad designs, and configure who you want to reach."},step2:{title:"We’ll publish & optimize your ads on Google",description:"We’ll do the hard work of publishing & continuously optimizing your ads on Google making sure you’re getting the best possible return on investment."},step3:{title:"See Customers & Results",description:"When a customer buys from you, we’ll notify you and show you the total revenue driven to your business from each dollar invested in ads. "}},ads_builder:{dialog_trigger:"New campaign",title:"Ads Wizard",description:"Create your new ad campaign",review_ad_themes:"Review Ad Themes",example_ad_preview:"Example Ad Preview",example_ad_preview_description:"Here's an example of how prospective customers might see your ads. We will automagically tweak the copy based on your products offered, and improve targeting based on what results in the most dollars to your business."}},analytics:{setup_analytics:"Setup analytics",setup_analytics_description:"Let's get you started with analytics. Connect your data sources to start tracking your customers.",connect_data:{title:"Connect Your Data",description:"We bring all of your ads data together to give you a clear view of which customers are coming in from where."},install_pixel:{copied_to_clipboard:"Copied to clipboard",copied_to_clipboard_description:"The tracking pixel code has been copied to your clipboard.",title:"Install our Tracking Pixel",description:"In order to get a complete picture of how users are interacting with your website, it’s important for the Reach analytics code to be on every page of your website and within as many third-party tools that you use as possible.",card_title:"Install the Snippet inside the <HEAD> of every page",third_party_pages_your_tracking_pixel:"Your Tracking Pixel:",card_description:"Copy this following text and insert it inside of the <HEAD> tags on all pages.",error_generating_pixel_code:"Error generating pixel code - please contact your administrator",third_party_pages_question:"Do you use any websites or landing pages for marketing your business?",third_party_pages_yes:"Yes, I have marketing websites",third_party_pages_no:"No, I don't use any websites",third_party_pages_why_asking:"Why We're Asking For This",third_party_pages_why_asking_description:"Adding our tracking pixel to your website allows us to:",third_party_pages_why_asking_list_1:"Understand how visitors interact with your pages",third_party_pages_why_asking_list_2:"Measure which ads are driving visitors to your site",third_party_pages_why_asking_list_3:"Track conversions from your campaigns",third_party_pages_enter_marketing_website:"Enter your marketing website:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"We'll use this to help you install the tracking pixel",third_party_pages_select_your_website_platform:"Select your website platform:"},third_party_installation_guides:{title:"Installation Guides",description:"These guides will help you add the Reach analytics snippet to your website. The process works with any website builder or platform and most third-party tools.",installation_guide:"{{name}} Installation Guide",official_guide:"Official Guide",shopify:{step_1:"From your Shopify admin, go to Online Store > Themes",step_2:"Find the theme you want to edit, click the … button to open the actions menu, and then click Edit code",step_3:'Open "theme.liquid"',step_4:"Find the </head> tag",step_5:"Paste the code snippet from the section above just before it"},google_tag_manager:{step_1:"Go to https://tagmanager.google.com",step_2:"Sign in to your Google Account",step_3:"Click the Accounts tab, then select Create Account",step_4:"Enter an account name and select your country location",step_5:"In Container Setup, enter a container name (e.g., your website URL)",step_6:'Select "Web" as the container type',step_7:"Click Create and agree to the Terms of Service",step_8:"Once created, you'll receive two code snippets to install:",step_9:"• Place the first snippet in the <head> of your page",step_10:"• Place the second snippet immediately after the opening <body> tag",step_11:"In the Tags tab, click the + button to create a new tag",step_12:'Select "Google Analytics: Universal Analytics" as the tag type',special_note:"Make sure you have the Google Tag Manager container code already installed on your site before adding this tag."},hubspot:{step_1:"Go to Settings → Content → Pages",step_2:'In the upper left, select a domain to edit its settings. Or select "Default settings for all domains"',step_3:'Paste the code from the section above to the "Site Header HTML" field',step_4:'Click "Save"'},wordpress:{step_1:"We recommend using the popular WPCode Plugin",step_2:'In the plugin, select "+ Add Snippet"',step_3:'When presented with a menu of options, navigate to "Add Your Custom Code (New Snippet)" and select "Use snippet"',step_4:"Paste the code snippet from the section above",step_5:'For Insert Method, choose "Auto Insert"',step_6:'For Location, select "Site Wide Header"',step_7:"Be sure to save your snippet"},squarespace:{step_1:"Go to Settings → Advanced → Code Injection",step_2:'Paste the code from the section above into the "Header" field',step_3:'Click "Save"'},wix:{step_1:"Go to Settings → Custom Code",step_2:'Click "+ Add Custom Code"',step_3:"Paste the code from the section above",step_4:'Click "Apply"',step_5:'Set "Add Code to Pages" to "All Pages"'},webflow:{step_1:"Open your project settings",step_2:'Navigate to "Custom Code"',step_3:'Paste the code from the section above into the "Head Code" section',step_4:'Click "Save Changes"'},third_party_systems:{step_1:"Check if your third-party tools (lead forms, scheduling tools, etc.) allow custom code injection",step_2:'Look for options labeled "Custom Code", "Embed Code", or "Advanced Settings"',step_3:"Paste the same tracking code into these sections where available",step_4:"Common locations include:",step_5:"• Head section of your website (for tracking scripts and styles)",step_6:"• Footer section of your website (for tracking scripts and styles)",special_note:"This helps ensure consistent tracking across all your customer touchpoints, even when using external tools."},custom:{step_1:"Locate your website's HTML template or main layout file",step_2:"Find the </head> tag in your HTML",step_3:"Paste the code snippet just before the </head> tag",step_4:"Save the file and deploy your changes"}},success:{title:"Success!",description:"You have successfully connected your data sources and installed our tracking pixel.",what_next:"What happens next?",step_1:"Your ad data will start syncing automatically",step_2:"The pixel will begin tracking conversions on your site",step_3:"You'll see your first analytics reports within 24 hours"}},dashboard:{banners:{metrics_crunching:{title:"Crunching your data",description:"You have successfully connected your ad accounts. We're now crunching your data. Check back soon for relevant metrics."},revoked_accounts:{title:"Your ad accounts have been revoked",description:"Please reconnect your ad accounts to continue using the dashboard."}},roas_chart:{title:"Ad Spend vs Revenue Over Time",campaign_not_available:"Chart is not available for individual campaigns yet"},customer_acquisition:{title:"Client Acquisition",description:"See how many new clients you acquired from each channel",client:"Client",source:"Source",total_spent:"Total Spent",total_revenue:"Total Revenue",status:"Status",no_data:"No data available",source_breakdown:"Source",payment_status:"Payment Status",paid:"Paid",unpaid:"Unpaid",invoice_details:"Invoice Details",amount:"Amount",service:"Service",invoice_date:"Invoice Date"},channel_performance:{title:"Channel Performance",description:"See how each channel performs",channel:"Channel",spend:"Spend",revenue:"Revenue",roas:"ROAS",new_customers:"New Customers"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Overview",channel_performance:"Channel Performance",campaign_performance:"Campaign Performance",customer_acquisition:"Customer Acquisition",traffic_conversion:"Traffic Conversion"},metrics:{ads_spend:"Ads Spend",ads_spend_description:"The amount spent on ads in a given period. Sum of all sub-ads accounts (e.g. insta, google). Excluding agency fees",direct_measured_revenue:"Direct Measured Revenue",direct_measured_revenue_description:"The amount of revenue directly measured from ads",measured_revenue:"Measured Revenue",measured_revenue_description:"The amount of revenue measured from ads",direct_measured_conversions:"Direct Measured Conversions",direct_measured_conversions_description:"The amount of conversions directly measured from ads",measured_conversions:"Measured Conversions",measured_conversions_description:"The amount of conversions measured from ads",roas:"ROAS",roas_description:"This is the ratio of the revenue to the ads spend",impressions:"Impressions",impressions_description:"Number of times your ads were shown to potential customers",clicks:"Clicks/Actions",clicks_description:"Total interactions with your ads, including clicks and other actions",website_visitors:"Website Visitors",website_visitors_description:"Unique visitors to your website from advertising campaigns",new_leads:"New Leads",new_leads_description:"New potential customers who provided contact information",customer_ltv:"Customer LTV",customer_ltv_description:"Average lifetime value of customers acquired through ads",new_customers:"New Customers",new_customers_description:"New customers who made a purchase or took an action",new_leads_conversion_rate:"New Leads Conversion Rate",new_leads_conversion_rate_description:"The ratio of new leads to the total number of leads",new_customers_conversion_rate:"New Customers Conversion Rate",new_customers_conversion_rate_description:"The ratio of new customers to the total number of customers",cost_per_click:"Cost Per Click",cost_per_click_description:"The amount spent per click on your ads",click_conversion_rate:"Click Conversion Rate",click_conversion_rate_description:"The ratio of clicks to the total number of clicks",click_through_rate:"Click Through Rate",click_through_rate_description:"The ratio of clicks to the total number of impressions",conversion_rate:"Conversion Rate",conversion_rate_description:"The ratio of conversions to the total number of clicks",total_conversion:"Total Conversion",total_conversion_description:"The total number of conversions from your ads",cac:"CAC",cac_description:"The amount spent per customer acquisition",revenue_per_click:"Revenue Per Click",revenue_per_click_description:"The amount of revenue generated per click on your ads",revenue_per_new_customer:"Revenue Per New Customer",revenue_per_new_customer_description:"The amount of revenue generated per new customer",reengaged_customers:"Reengaged Customers",reengaged_customers_description:"The number of customers who have been reengaged with your ads",expected_revenue:"Expected Revenue",expected_revenue_description:"The amount of revenue you expect to generate from your ads",estimated_revenue:"Estimated Revenue",estimated_revenue_description:"The amount of revenue you expect to generate from your ads"},title:"Marketing Revenue Dashboard",settings_sheet:{setup:"Setup",connected_accounts:"Connected Accounts",setup_analytics:"Setup analytics",setup_analytics_description:"Configure your analytics tracking",setup_campaigns:"Setup campaigns",setup_campaigns_description:"Set up your first campaign",legal:"Legal",terms_of_service:"Terms of Service",privacy_policy:"Privacy Policy"}},setup:{how_it_works:{title:"How It Works",dialog_title:"Setup Marketing Insights",connect_ads_title:"Connect your Ads Accounts",connect_ads_description:"Link your advertising accounts from platforms like Google and Meta to consolidate all your campaign data in one place. This enables comprehensive tracking and analysis of your marketing spend.",install_pixel_title:"Install Our Tracking Pixel",install_pixel_description:"Add our lightweight tracking code to your website to accurately measure customer interactions and conversions. This simple integration helps identify which ads are driving real results for your business.",see_customers_results_title:"See Customers & Results",see_customers_results_description:"Get clear insights into your marketing performance with detailed analytics on customer acquisition, conversion rates, and return on ad spend. Make data-driven decisions to optimize your campaigns and grow your business.",still_have_more_questions:"Still have more questions?",get_started:"Get Started"},initial_setup:{wizard_title:"Connect your ad accounts and see exactly how your campaigns drive revenue",title:"Unlock Clear Insights into Your Marketing Performance",description:"Stop guessing and start knowing. Our performance dashboard gives you a complete view of your marketing efforts, including ad spend, conversions, and return on ad spend (ROAS).",description_2:"With a simple setup process, you’ll have actionable insights at your fingertips to help you make smarter decisions and grow your business.",setup_performance_analytics:"Setup Performance Analytics",next_steps_description:"If you're not running ads yet, you can launch your first AI-powered ad campaign in minutes.",next_steps_link:"We will prompt you to connect your ad accounts and set up your first campaign."}},oauth:{selectAccount:{title:"Select {{platform}} Account",description:"Choose the {{platform}} account you want to connect.",loading:"Loading accounts...",loadingPlatform:"Loading {{platform}} accounts...",loadingDescription:"Please wait while we fetch your available accounts...",noAccounts:"No {{platform}} accounts were found for your account.",noAccountsDescription:"Please make sure you have access to a {{platform}} account and try again.",selectAccountPlaceholder:"Select an account",searchPlaceholder:"Search accounts...",fetchAccounts:"Fetching accounts...",noAccountSelected:"No account selected",enableTrackingParams:"Enable Tracking Parameters",enableTrackingParamsDescription:"Append the reach campaign id parameter to your ad platform tracking settings. We will not overwrite any existing tracking parameters. Required for accurate tracking.",google:{selectAccountDescription:"Select the Google Ads account you want to connect to view your data. These will be linked to our MCC for optimal tracking.",mccAccounts:"MCC Accounts",directAccounts:"Direct Accounts"},meta:{selectAccountDescription:"Choose the Meta Ads account you want to connect to view your data."}},success:{connection:{title:"Connected successfully",description:"Your {{provider}} account has been connected."},revoke:{title:"Account revoked",description:"Your {{provider}} account has been revoked."}},error:{title:"Connection failed",description:"Failed to connect account"},revoke:{title:"Revoke access",description:"Are you sure? Revoking access will remove the connection you have and you will be unable to view your ad metrics.",cancel:"Cancel",revoke:"Revoke",error:{title:"Error",description:"Failed to revoke access"}}},magic_link:{get_started:"Get Started",description:"Reach will be embedded within your platform dashboard but until then, you can get started with a magic link. Log in to your account and start creating AI-powered campaigns or measuring your ad spend and performance.",create_campaigns:"Create AI-generated ad campaigns in minutes",unlock_insights:"Unlock insights into your ad spend and performance",save_time:"Save time with automated campaign optimization",request_new_magic_link:"Request New Magic Link",go_to_dashboard:"Go to Dashboard",continuation_disclaimer:"By continuing, you agree to our <terms_of_service>Terms of Service</terms_of_service> and <privacy_policy>Privacy Policy</privacy_policy>."},empty_state:{analytics:{title:"You haven't connected any ad accounts yet",description:"You can connect your ad accounts in minutes and start driving more customers to your business.",button_text:"Setup analytics"}}},Sf=({children:e,language:r,initialLanguage:o})=>(n.useEffect((()=>{o&&ef.changeLanguage(o)}),[o]),n.useEffect((()=>{if(r?.overrides){const e=(e,t)=>{const n=r?.overrides?.[e]?.[t];return n?{..._f,...Object.entries(n).reduce(((e,[t,n])=>({...e,[t]:n})),{})}:_f};Object.keys(r.overrides).forEach((t=>{const n=e(t,"en"),r=e(t,"es");ef.addResourceBundle("en",t,n,!0,!0),ef.addResourceBundle("es",t,r,!0,!0)}))}}),[r?.overrides]),t.jsx(hp,{i18n:ef,children:e}));var Tf={},Cf={},Af="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},Of="1.8.0",Nf=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;var Rf=function(e){var t=new Set([e]),n=new Set,r=e.match(Nf);if(!r)return function(){return!1};var o=+r[1],i=+r[2],a=+r[3];if(null!=r[4])return function(t){return t===e};function s(e){return n.add(e),!1}function l(e){return t.add(e),!0}return function(e){if(t.has(e))return!0;if(n.has(e))return!1;var r=e.match(Nf);if(!r)return s(e);var c=+r[2],u=+r[3];return null!=r[4]||o!==+r[1]?s(e):0===o?i===c&&a<=u?l(e):s(e):i<=c?l(e):s(e)}}(Of),Pf=Of.split(".")[0],kf=Symbol.for("opentelemetry.js.api."+Pf),Lf=Af;function Mf(e,t,n,r){var o;void 0===r&&(r=!1);var i=Lf[kf]=null!==(o=Lf[kf])&&void 0!==o?o:{version:Of};if(!r&&i[e]){var a=new Error("@opentelemetry/api: Attempted duplicate registration of API: "+e);return n.error(a.stack||a.message),!1}if(i.version!==Of){a=new Error("@opentelemetry/api: Registration of version v"+i.version+" for "+e+" does not match previously registered API v"+Of);return n.error(a.stack||a.message),!1}return i[e]=t,n.debug("@opentelemetry/api: Registered a global for "+e+" v"+Of+"."),!0}function Df(e){var t,n,r=null===(t=Lf[kf])||void 0===t?void 0:t.version;if(r&&Rf(r))return null===(n=Lf[kf])||void 0===n?void 0:n[e]}function jf(e,t){t.debug("@opentelemetry/api: Unregistering a global for "+e+" v"+Of+".");var n=Lf[kf];n&&delete n[e]}var If,Ff,Uf=function(){function e(e){this._namespace=e.namespace||"DiagComponentLogger"}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("debug",this._namespace,e)},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("error",this._namespace,e)},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("info",this._namespace,e)},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("warn",this._namespace,e)},e.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("verbose",this._namespace,e)},e}();function $f(e,t,n){var r=Df("diag");if(r)return n.unshift(t),r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))}(Ff=If||(If={}))[Ff.NONE=0]="NONE",Ff[Ff.ERROR=30]="ERROR",Ff[Ff.WARN=50]="WARN",Ff[Ff.INFO=60]="INFO",Ff[Ff.DEBUG=70]="DEBUG",Ff[Ff.VERBOSE=80]="VERBOSE",Ff[Ff.ALL=9999]="ALL";var Bf=function(){function e(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=Df("diag");if(r)return r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(t),!1))}}var t=this;t.setLogger=function(e,n){var r,o,i;if(void 0===n&&(n={logLevel:If.INFO}),e===t){var a=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return t.error(null!==(r=a.stack)&&void 0!==r?r:a.message),!1}"number"==typeof n&&(n={logLevel:n});var s=Df("diag"),l=function(e,t){function n(n,r){var o=t[n];return"function"==typeof o&&e>=r?o.bind(t):function(){}}return e<If.NONE?e=If.NONE:e>If.ALL&&(e=If.ALL),t=t||{},{error:n("error",If.ERROR),warn:n("warn",If.WARN),info:n("info",If.INFO),debug:n("debug",If.DEBUG),verbose:n("verbose",If.VERBOSE)}}(null!==(o=n.logLevel)&&void 0!==o?o:If.INFO,e);if(s&&!n.suppressOverrideMessage){var c=null!==(i=(new Error).stack)&&void 0!==i?i:"<failed to generate stacktrace>";s.warn("Current logger will be overwritten from "+c),l.warn("Current logger will overwrite one already registered from "+c)}return Mf("diag",l,t,!0)},t.disable=function(){jf("diag",t)},t.createComponentLogger=function(e){return new Uf(e)},t.verbose=e("verbose"),t.debug=e("debug"),t.info=e("info"),t.warn=e("warn"),t.error=e("error")}return e.instance=function(){return this._instance||(this._instance=new e),this._instance},e}(),Vf=function(){function e(e){this._entries=e?new Map(e):new Map}return e.prototype.getEntry=function(e){var t=this._entries.get(e);if(t)return Object.assign({},t)},e.prototype.getAllEntries=function(){return Array.from(this._entries.entries()).map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);return[t[0],t[1]]}))},e.prototype.setEntry=function(t,n){var r=new e(this._entries);return r._entries.set(t,n),r},e.prototype.removeEntry=function(t){var n=new e(this._entries);return n._entries.delete(t),n},e.prototype.removeEntries=function(){for(var t,n,r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=new e(this._entries);try{for(var a=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(r),s=a.next();!s.done;s=a.next()){i._entries.delete(s.value)}}catch(l){t={error:l}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return i},e.prototype.clear=function(){return new e},e}(),qf=Symbol("BaggageEntryMetadata"),zf=Bf.instance();function Hf(e){return void 0===e&&(e={}),new Vf(new Map(Object.entries(e)))}function Gf(e){return"string"!=typeof e&&(zf.error("Cannot create baggage metadata from unknown type: "+typeof e),e=""),{__TYPE__:qf,toString:function(){return e}}}function Kf(e){return Symbol.for(e)}var Wf,Yf,Xf=new(function(){return function e(t){var n=this;n._currentContext=t?new Map(t):new Map,n.getValue=function(e){return n._currentContext.get(e)},n.setValue=function(t,r){var o=new e(n._currentContext);return o._currentContext.set(t,r),o},n.deleteValue=function(t){var r=new e(n._currentContext);return r._currentContext.delete(t),r}}}()),Qf=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}],Zf=function(){return function(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];if(console){var r=console[e];if("function"!=typeof r&&(r=console.log),"function"==typeof r)return r.apply(console,t)}}}for(var t=0;t<Qf.length;t++)this[Qf[t].n]=e(Qf[t].c)}}(),Jf=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eh=function(){function e(){}return e.prototype.createHistogram=function(e,t){return dh},e.prototype.createCounter=function(e,t){return uh},e.prototype.createUpDownCounter=function(e,t){return ph},e.prototype.createObservableGauge=function(e,t){return hh},e.prototype.createObservableCounter=function(e,t){return fh},e.prototype.createObservableUpDownCounter=function(e,t){return mh},e.prototype.addBatchObservableCallback=function(e,t){},e.prototype.removeBatchObservableCallback=function(e){},e}(),th=function(){return function(){}}(),nh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.add=function(e,t){},t}(th),rh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.add=function(e,t){},t}(th),oh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.record=function(e,t){},t}(th),ih=function(){function e(){}return e.prototype.addCallback=function(e){},e.prototype.removeCallback=function(e){},e}(),ah=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),sh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),lh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),ch=new eh,uh=new nh,dh=new oh,ph=new rh,fh=new ah,hh=new sh,mh=new lh;(Yf=Wf||(Wf={}))[Yf.INT=0]="INT",Yf[Yf.DOUBLE=1]="DOUBLE";var gh,yh,vh={get:function(e,t){if(null!=e)return e[t]},keys:function(e){return null==e?[]:Object.keys(e)}},bh={set:function(e,t,n){null!=e&&(e[t]=n)}},wh=function(){function e(){}return e.prototype.active=function(){return Xf},e.prototype.with=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];return t.call.apply(t,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(r),!1))},e.prototype.bind=function(e,t){return t},e.prototype.enable=function(){return this},e.prototype.disable=function(){return this},e}(),xh="context",Eh=new wh,_h=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalContextManager=function(e){return Mf(xh,e,Bf.instance())},e.prototype.active=function(){return this._getContextManager().active()},e.prototype.with=function(e,t,n){for(var r,o=[],i=3;i<arguments.length;i++)o[i-3]=arguments[i];return(r=this._getContextManager()).with.apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([e,t,n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(o),!1))},e.prototype.bind=function(e,t){return this._getContextManager().bind(e,t)},e.prototype._getContextManager=function(){return Df(xh)||Eh},e.prototype.disable=function(){this._getContextManager().disable(),jf(xh,Bf.instance())},e}();(yh=gh||(gh={}))[yh.NONE=0]="NONE",yh[yh.SAMPLED=1]="SAMPLED";var Sh="0000000000000000",Th="00000000000000000000000000000000",Ch={traceId:Th,spanId:Sh,traceFlags:gh.NONE},Ah=function(){function e(e){void 0===e&&(e=Ch),this._spanContext=e}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return this},e.prototype.setAttributes=function(e){return this},e.prototype.addEvent=function(e,t){return this},e.prototype.setStatus=function(e){return this},e.prototype.updateName=function(e){return this},e.prototype.end=function(e){},e.prototype.isRecording=function(){return!1},e.prototype.recordException=function(e,t){},e}(),Oh=Kf("OpenTelemetry Context Key SPAN");function Nh(e){return e.getValue(Oh)||void 0}function Rh(){return Nh(_h.getInstance().active())}function Ph(e,t){return e.setValue(Oh,t)}function kh(e){return e.deleteValue(Oh)}function Lh(e,t){return Ph(e,new Ah(t))}function Mh(e){var t;return null===(t=Nh(e))||void 0===t?void 0:t.spanContext()}var Dh=/^([0-9a-f]{32})$/i,jh=/^[0-9a-f]{16}$/i;function Ih(e){return Dh.test(e)&&e!==Th}function Fh(e){return jh.test(e)&&e!==Sh}function Uh(e){return Ih(e.traceId)&&Fh(e.spanId)}function $h(e){return new Ah(e)}var Bh=_h.getInstance(),Vh=function(){function e(){}return e.prototype.startSpan=function(e,t,n){if(void 0===n&&(n=Bh.active()),Boolean(null==t?void 0:t.root))return new Ah;var r,o=n&&Mh(n);return"object"==typeof(r=o)&&"string"==typeof r.spanId&&"string"==typeof r.traceId&&"number"==typeof r.traceFlags&&Uh(o)?new Ah(o):new Ah},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:Bh.active(),l=this.startSpan(e,o,s),c=Ph(s,l);return Bh.with(c,a,void 0,l)}},e}();var qh,zh,Hh,Gh,Kh,Wh,Yh=new Vh,Xh=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.startSpan=function(e,t,n){return this._getTracer().startSpan(e,t,n)},e.prototype.startActiveSpan=function(e,t,n,r){var o=this._getTracer();return Reflect.apply(o.startActiveSpan,o,arguments)},e.prototype._getTracer=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateTracer(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):Yh},e}(),Qh=new(function(){function e(){}return e.prototype.getTracer=function(e,t,n){return new Vh},e}()),Zh=function(){function e(){}return e.prototype.getTracer=function(e,t,n){var r;return null!==(r=this.getDelegateTracer(e,t,n))&&void 0!==r?r:new Xh(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:Qh},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateTracer=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getTracer(e,t,n)},e}();(zh=qh||(qh={}))[zh.NOT_RECORD=0]="NOT_RECORD",zh[zh.RECORD=1]="RECORD",zh[zh.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED",(Gh=Hh||(Hh={}))[Gh.INTERNAL=0]="INTERNAL",Gh[Gh.SERVER=1]="SERVER",Gh[Gh.CLIENT=2]="CLIENT",Gh[Gh.PRODUCER=3]="PRODUCER",Gh[Gh.CONSUMER=4]="CONSUMER",(Wh=Kh||(Kh={}))[Wh.UNSET=0]="UNSET",Wh[Wh.OK=1]="OK",Wh[Wh.ERROR=2]="ERROR";var Jh="[_0-9a-z-*/]",em=new RegExp("^(?:"+("[a-z]"+Jh+"{0,255}")+"|"+("[a-z0-9]"+Jh+"{0,240}@[a-z]"+Jh+"{0,13}")+")$"),tm=/^[ -~]{0,255}[!-~]$/,nm=/,|=/;var rm=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return em.test(e)})(o)&&function(e){return tm.test(e)&&!nm.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}();var om=_h.getInstance(),im=Bf.instance(),am=new(function(){function e(){}return e.prototype.getMeter=function(e,t,n){return ch},e}()),sm="metrics",lm=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalMeterProvider=function(e){return Mf(sm,e,Bf.instance())},e.prototype.getMeterProvider=function(){return Df(sm)||am},e.prototype.getMeter=function(e,t,n){return this.getMeterProvider().getMeter(e,t,n)},e.prototype.disable=function(){jf(sm,Bf.instance())},e}().getInstance(),cm=function(){function e(){}return e.prototype.inject=function(e,t){},e.prototype.extract=function(e,t){return e},e.prototype.fields=function(){return[]},e}(),um=Kf("OpenTelemetry Baggage Key");function dm(e){return e.getValue(um)||void 0}function pm(){return dm(_h.getInstance().active())}function fm(e,t){return e.setValue(um,t)}function hm(e){return e.deleteValue(um)}var mm="propagation",gm=new cm,ym=function(){function e(){this.createBaggage=Hf,this.getBaggage=dm,this.getActiveBaggage=pm,this.setBaggage=fm,this.deleteBaggage=hm}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalPropagator=function(e){return Mf(mm,e,Bf.instance())},e.prototype.inject=function(e,t,n){return void 0===n&&(n=bh),this._getGlobalPropagator().inject(e,t,n)},e.prototype.extract=function(e,t,n){return void 0===n&&(n=vh),this._getGlobalPropagator().extract(e,t,n)},e.prototype.fields=function(){return this._getGlobalPropagator().fields()},e.prototype.disable=function(){jf(mm,Bf.instance())},e.prototype._getGlobalPropagator=function(){return Df(mm)||gm},e}().getInstance(),vm="trace",bm=function(){function e(){this._proxyTracerProvider=new Zh,this.wrapSpanContext=$h,this.isSpanContextValid=Uh,this.deleteSpan=kh,this.getSpan=Nh,this.getActiveSpan=Rh,this.getSpanContext=Mh,this.setSpan=Ph,this.setSpanContext=Lh}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalTracerProvider=function(e){var t=Mf(vm,this._proxyTracerProvider,Bf.instance());return t&&this._proxyTracerProvider.setDelegate(e),t},e.prototype.getTracerProvider=function(){return Df(vm)||this._proxyTracerProvider},e.prototype.getTracer=function(e,t){return this.getTracerProvider().getTracer(e,t)},e.prototype.disable=function(){jf(vm,Bf.instance()),this._proxyTracerProvider=new Zh},e}().getInstance();const wm={context:om,diag:im,metrics:lm,propagation:ym,trace:bm},xm=Object.freeze(Object.defineProperty({__proto__:null,DiagConsoleLogger:Zf,get DiagLogLevel(){return If},INVALID_SPANID:Sh,INVALID_SPAN_CONTEXT:Ch,INVALID_TRACEID:Th,ProxyTracer:Xh,ProxyTracerProvider:Zh,ROOT_CONTEXT:Xf,get SamplingDecision(){return qh},get SpanKind(){return Hh},get SpanStatusCode(){return Kh},get TraceFlags(){return gh},get ValueType(){return Wf},baggageEntryMetadataFromString:Gf,context:om,createContextKey:Kf,createNoopMeter:function(){return ch},createTraceState:function(e){return new rm(e)},default:wm,defaultTextMapGetter:vh,defaultTextMapSetter:bh,diag:im,isSpanContextValid:Uh,isValidSpanId:Fh,isValidTraceId:Ih,metrics:lm,propagation:ym,trace:bm},Symbol.toStringTag,{value:"Module"}));var Em=function(){function e(){}return e.prototype.emit=function(e){},e}(),_m=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new Em},e}()),Sm="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},Tm=Symbol.for("io.opentelemetry.js.api.logs"),Cm=Sm;var Am=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return Cm[Tm]?this.getLoggerProvider():(Cm[Tm]=(t=1,n=e,r=_m,function(e){return e===t?n:r}),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=Cm[Tm])||void 0===e?void 0:e.call(Cm,1))&&void 0!==t?t:_m},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete Cm[Tm]},e}().getInstance();function Om(e){void 0===e&&(e=[]);for(var t=[],n=0,r=e.length;n<r;n++){var o=e[n];if(Array.isArray(o)){var i=Om(o);t=t.concat(i.instrumentations)}else"function"==typeof o?t.push(new o):o.instrumentationName&&t.push(o)}return{instrumentations:t}}function Nm(e){return"function"==typeof e}var Rm=function(){}.bind();function Pm(e,t,n){var r=!!e[t]&&e.propertyIsEnumerable(t);Object.defineProperty(e,t,{configurable:!0,enumerable:r,writable:!0,value:n})}function km(e){e&&e.logger&&(Nm(e.logger)?Rm=e.logger:Rm("new logger isn't a function, not replacing"))}function Lm(e,t,n){if(e&&e[t]){if(!n)return Rm("no wrapper function"),void Rm((new Error).stack);if(Nm(e[t])&&Nm(n)){var r=e[t],o=n(r,t);return Pm(o,"__original",r),Pm(o,"__unwrap",(function(){e[t]===o&&Pm(e,t,r)})),Pm(o,"__wrapped",!0),Pm(e,t,o),o}Rm("original object and wrapper must be functions")}else Rm("no original function "+t+" to wrap")}function Mm(e,t){return e&&e[t]?e[t].__unwrap?e[t].__unwrap():void Rm("no original to unwrap to -- has "+t+" already been unwrapped?"):(Rm("no function to unwrap."),void Rm((new Error).stack))}km.wrap=Lm,km.massWrap=function(e,t,n){if(!e)return Rm("must provide one or more modules to patch"),void Rm((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){Lm(e,t,n)}))})):Rm("must provide one or more functions to wrap on modules")},km.unwrap=Mm,km.massUnwrap=function(e,t){if(!e)return Rm("must provide one or more modules to patch"),void Rm((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){Mm(e,t)}))})):Rm("must provide one or more functions to unwrap on modules")};var Dm=km,jm=function(){return jm=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},jm.apply(this,arguments)},Im=function(){function e(e,t,n){void 0===n&&(n={}),this.instrumentationName=e,this.instrumentationVersion=t,this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this._config=jm({enabled:!0},n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=Am.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){void 0===e&&(e={}),this._config=Object.assign({},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e}(),Fm=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Um=function(e){function t(t,n,r){void 0===r&&(r={});var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return Fm(t,e),t}(Im);var $m=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},Bm=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};const Vm=Object.freeze(Object.defineProperty({__proto__:null,InstrumentationBase:Um,InstrumentationNodeModuleDefinition:function(){return function(e,t,n,r,o){this.name=e,this.supportedVersions=t,this.patch=n,this.unpatch=r,this.files=o||[]}}(),InstrumentationNodeModuleFile:function(){return function(e,t,n,r){var o;this.supportedVersions=t,this.patch=n,this.unpatch=r,this.name=(o=e,im.warn("Path normalization is not implemented for this platform. To silence this warning, ensure no node-specific instrumentations are loaded, and node-specific types (e.g. InstrumentationNodeModuleFile), are not used in a browser context)"),o)}}(),isWrapped:function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped},registerInstrumentations:function(e){var t=Om(e.instrumentations).instrumentations,n=e.tracerProvider||bm.getTracerProvider(),r=e.meterProvider||lm.getMeterProvider(),o=e.loggerProvider||Am.getLoggerProvider();return function(e,t,n,r){for(var o=0,i=e.length;o<i;o++){var a=e[o];t&&a.setTracerProvider(t),n&&a.setMeterProvider(n),r&&a.setLoggerProvider&&a.setLoggerProvider(r),a.getConfig().enabled||a.enable()}}(t,n,r,o),function(){!function(e){e.forEach((function(e){return e.disable()}))}(t)}},safeExecuteInTheMiddle:function(e,t,n){var r,o;try{o=e()}catch(tme){r=tme}finally{if(t(r,o),r&&!n)throw r;return o}},safeExecuteInTheMiddleAsync:function(e,t,n){return $m(this,void 0,void 0,(function(){var r,o,i;return Bm(this,(function(a){switch(a.label){case 0:return a.trys.push([0,2,3,4]),[4,e()];case 1:return o=a.sent(),[3,4];case 2:return i=a.sent(),r=i,[3,4];case 3:if(t(r,o),r&&!n)throw r;return[2,o];case 4:return[2]}}))}))}},Symbol.toStringTag,{value:"Module"})),qm=za(Vm);function zm(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}var Hm="aws.lambda.invoked_arn",Gm="db.system",Km="db.connection_string",Wm="db.user",Ym="db.jdbc.driver_classname",Xm="db.name",Qm="db.statement",Zm="db.operation",Jm="db.mssql.instance_name",eg="db.cassandra.keyspace",tg="db.cassandra.page_size",ng="db.cassandra.consistency_level",rg="db.cassandra.table",og="db.cassandra.idempotence",ig="db.cassandra.speculative_execution_count",ag="db.cassandra.coordinator.id",sg="db.cassandra.coordinator.dc",lg="db.hbase.namespace",cg="db.redis.database_index",ug="db.mongodb.collection",dg="db.sql.table",pg="exception.type",fg="exception.message",hg="exception.stacktrace",mg="exception.escaped",gg="faas.trigger",yg="faas.execution",vg="faas.document.collection",bg="faas.document.operation",wg="faas.document.time",xg="faas.document.name",Eg="faas.time",_g="faas.cron",Sg="faas.coldstart",Tg="faas.invoked_name",Cg="faas.invoked_provider",Ag="faas.invoked_region",Og="net.transport",Ng="net.peer.ip",Rg="net.peer.port",Pg="net.peer.name",kg="net.host.ip",Lg="net.host.port",Mg="net.host.name",Dg="net.host.connection.type",jg="net.host.connection.subtype",Ig="net.host.carrier.name",Fg="net.host.carrier.mcc",Ug="net.host.carrier.mnc",$g="net.host.carrier.icc",Bg="peer.service",Vg="enduser.id",qg="enduser.role",zg="enduser.scope",Hg="thread.id",Gg="thread.name",Kg="code.function",Wg="code.namespace",Yg="code.filepath",Xg="code.lineno",Qg="http.method",Zg="http.url",Jg="http.target",ey="http.host",ty="http.scheme",ny="http.status_code",ry="http.flavor",oy="http.user_agent",iy="http.request_content_length",ay="http.request_content_length_uncompressed",sy="http.response_content_length",ly="http.response_content_length_uncompressed",cy="http.server_name",uy="http.route",dy="http.client_ip",py="aws.dynamodb.table_names",fy="aws.dynamodb.consumed_capacity",hy="aws.dynamodb.item_collection_metrics",my="aws.dynamodb.provisioned_read_capacity",gy="aws.dynamodb.provisioned_write_capacity",yy="aws.dynamodb.consistent_read",vy="aws.dynamodb.projection",by="aws.dynamodb.limit",wy="aws.dynamodb.attributes_to_get",xy="aws.dynamodb.index_name",Ey="aws.dynamodb.select",_y="aws.dynamodb.global_secondary_indexes",Sy="aws.dynamodb.local_secondary_indexes",Ty="aws.dynamodb.exclusive_start_table",Cy="aws.dynamodb.table_count",Ay="aws.dynamodb.scan_forward",Oy="aws.dynamodb.segment",Ny="aws.dynamodb.total_segments",Ry="aws.dynamodb.count",Py="aws.dynamodb.scanned_count",ky="aws.dynamodb.attribute_definitions",Ly="aws.dynamodb.global_secondary_index_updates",My="messaging.system",Dy="messaging.destination",jy="messaging.destination_kind",Iy="messaging.temp_destination",Fy="messaging.protocol",Uy="messaging.protocol_version",$y="messaging.url",By="messaging.message_id",Vy="messaging.conversation_id",qy="messaging.message_payload_size_bytes",zy="messaging.message_payload_compressed_size_bytes",Hy="messaging.operation",Gy="messaging.consumer_id",Ky="messaging.rabbitmq.routing_key",Wy="messaging.kafka.message_key",Yy="messaging.kafka.consumer_group",Xy="messaging.kafka.client_id",Qy="messaging.kafka.partition",Zy="messaging.kafka.tombstone",Jy="rpc.system",ev="rpc.service",tv="rpc.method",nv="rpc.grpc.status_code",rv="rpc.jsonrpc.version",ov="rpc.jsonrpc.request_id",iv="rpc.jsonrpc.error_code",av="rpc.jsonrpc.error_message",sv="message.type",lv="message.id",cv="message.compressed_size",uv="message.uncompressed_size",dv=Hm,pv=Gm,fv=Km,hv=Wm,mv=Ym,gv=Xm,yv=Qm,vv=Zm,bv=Jm,wv=eg,xv=tg,Ev=ng,_v=rg,Sv=og,Tv=ig,Cv=ag,Av=sg,Ov=lg,Nv=cg,Rv=ug,Pv=dg,kv=pg,Lv=fg,Mv=hg,Dv=mg,jv=gg,Iv=yg,Fv=vg,Uv=bg,$v=wg,Bv=xg,Vv=Eg,qv=_g,zv=Sg,Hv=Tg,Gv=Cg,Kv=Ag,Wv=Og,Yv=Ng,Xv=Rg,Qv=Pg,Zv=kg,Jv=Lg,eb=Mg,tb=Dg,nb=jg,rb=Ig,ob=Fg,ib=Ug,ab=$g,sb=Bg,lb=Vg,cb=qg,ub=zg,db=Hg,pb=Gg,fb=Kg,hb=Wg,mb=Yg,gb=Xg,yb=Qg,vb=Zg,bb=Jg,wb=ey,xb=ty,Eb=ny,_b=ry,Sb=oy,Tb=iy,Cb=ay,Ab=sy,Ob=ly,Nb=cy,Rb=uy,Pb=dy,kb=py,Lb=fy,Mb=hy,Db=my,jb=gy,Ib=yy,Fb=vy,Ub=by,$b=wy,Bb=xy,Vb=Ey,qb=_y,zb=Sy,Hb=Ty,Gb=Cy,Kb=Ay,Wb=Oy,Yb=Ny,Xb=Ry,Qb=Py,Zb=ky,Jb=Ly,ew=My,tw=Dy,nw=jy,rw=Iy,ow=Fy,iw=Uy,aw=$y,sw=By,lw=Vy,cw=qy,uw=zy,dw=Hy,pw=Gy,fw=Ky,hw=Wy,mw=Yy,gw=Xy,yw=Qy,vw=Zy,bw=Jy,ww=ev,xw=tv,Ew=nv,_w=rv,Sw=ov,Tw=iv,Cw=av,Aw=sv,Ow=lv,Nw=cv,Rw=uv,Pw=zm([Hm,Gm,Km,Wm,Ym,Xm,Qm,Zm,Jm,eg,tg,ng,rg,og,ig,ag,sg,lg,cg,ug,dg,pg,fg,hg,mg,gg,yg,vg,bg,wg,xg,Eg,_g,Sg,Tg,Cg,Ag,Og,Ng,Rg,Pg,kg,Lg,Mg,Dg,jg,Ig,Fg,Ug,$g,Bg,Vg,qg,zg,Hg,Gg,Kg,Wg,Yg,Xg,Qg,Zg,Jg,ey,ty,ny,ry,oy,iy,ay,sy,ly,cy,uy,dy,py,fy,hy,my,gy,yy,vy,by,wy,xy,Ey,_y,Sy,Ty,Cy,Ay,Oy,Ny,Ry,Py,ky,Ly,My,Dy,jy,Iy,Fy,Uy,$y,By,Vy,qy,zy,Hy,Gy,Ky,Wy,Yy,Xy,Qy,Zy,Jy,ev,tv,nv,rv,ov,iv,av,sv,lv,cv,uv]),kw="other_sql",Lw="mssql",Mw="mysql",Dw="oracle",jw="postgresql",Iw="redshift",Fw="hive",Uw="cloudscape",$w="hsqldb",Bw="progress",Vw="maxdb",qw="hanadb",zw="ingres",Hw="firstsql",Gw="cache",Kw="adabas",Ww="firebird",Yw="derby",Xw="filemaker",Qw="informix",Zw="instantdb",Jw="interbase",ex="mariadb",tx="netezza",nx="pervasive",rx="pointbase",ox="sqlite",ix="sybase",ax="teradata",sx="vertica",lx="coldfusion",cx="cassandra",ux="hbase",dx="mongodb",px="redis",fx="couchbase",hx="couchdb",mx="cosmosdb",gx="dynamodb",yx="neo4j",vx="geode",bx="elasticsearch",wx="memcached",xx="cockroachdb",Ex=kw,_x=Lw,Sx=Mw,Tx=Dw,Cx=jw,Ax=Iw,Ox=Fw,Nx=Uw,Rx=$w,Px=Bw,kx=Vw,Lx=qw,Mx=zw,Dx=Hw,jx=Gw,Ix=Kw,Fx=Ww,Ux=Yw,$x=Xw,Bx=Qw,Vx=Zw,qx=Jw,zx=ex,Hx=tx,Gx=nx,Kx=rx,Wx=ox,Yx=ix,Xx=ax,Qx=sx,Zx=lx,Jx=cx,eE=ux,tE=dx,nE=px,rE=fx,oE=hx,iE=mx,aE=gx,sE=yx,lE=vx,cE=bx,uE=wx,dE=xx,pE=zm([kw,Lw,Mw,Dw,"db2",jw,Iw,Fw,Uw,$w,Bw,Vw,qw,zw,Hw,"edb",Gw,Kw,Ww,Yw,Xw,Qw,Zw,Jw,ex,tx,nx,rx,ox,ix,ax,sx,"h2",lx,cx,ux,dx,px,fx,hx,mx,gx,yx,vx,bx,wx,xx]),fE="each_quorum",hE="quorum",mE="local_quorum",gE="three",yE="local_one",vE="serial",bE="local_serial",wE=fE,xE=hE,EE=mE,_E=gE,SE=yE,TE=vE,CE=bE,AE=zm(["all",fE,hE,mE,"one","two",gE,yE,"any",vE,bE]),OE="datasource",NE="http",RE="pubsub",PE="timer",kE="other",LE=OE,ME=NE,DE=RE,jE=PE,IE=kE,FE=zm([OE,NE,RE,PE,kE]),UE="insert",$E="edit",BE="delete",VE=UE,qE=$E,zE=BE,HE=zm([UE,$E,BE]),GE="alibaba_cloud",KE="azure",WE=GE,YE=KE,XE=zm([GE,"aws",KE,"gcp"]),QE="ip_tcp",ZE="ip_udp",JE="unix",e_="pipe",t_="inproc",n_="other",r_=QE,o_=ZE,i_=JE,a_=e_,s_=t_,l_=n_,c_=zm([QE,ZE,"ip",JE,e_,t_,n_]),u_="wifi",d_="wired",p_="cell",f_="unavailable",h_="unknown",m_=u_,g_=d_,y_=p_,v_=f_,b_=h_,w_=zm([u_,d_,p_,f_,h_]),x_="gprs",E_="edge",__="umts",S_="cdma",T_="evdo_0",C_="evdo_a",A_="cdma2000_1xrtt",O_="hsdpa",N_="hsupa",R_="hspa",P_="iden",k_="evdo_b",L_="ehrpd",M_="hspap",D_="td_scdma",j_="iwlan",I_="nrnsa",F_="lte_ca",U_=x_,$_=E_,B_=__,V_=S_,q_=T_,z_=C_,H_=A_,G_=O_,K_=N_,W_=R_,Y_=P_,X_=k_,Q_=L_,Z_=M_,J_=D_,eS=j_,tS=I_,nS=F_,rS=zm([x_,E_,__,S_,T_,C_,A_,O_,N_,R_,P_,k_,"lte",L_,M_,"gsm",D_,j_,"nr",I_,F_]),oS="SPDY",iS="QUIC",aS=oS,sS=iS,lS={HTTP_1_0:"1.0",HTTP_1_1:"1.1",HTTP_2_0:"2.0",SPDY:oS,QUIC:iS},cS="queue",uS="topic",dS=cS,pS=uS,fS=zm([cS,uS]),hS="receive",mS="process",gS=hS,yS=mS,vS=zm([hS,mS]),bS={OK:0,CANCELLED:1,UNKNOWN:2,INVALID_ARGUMENT:3,DEADLINE_EXCEEDED:4,NOT_FOUND:5,ALREADY_EXISTS:6,PERMISSION_DENIED:7,RESOURCE_EXHAUSTED:8,FAILED_PRECONDITION:9,ABORTED:10,OUT_OF_RANGE:11,UNIMPLEMENTED:12,INTERNAL:13,UNAVAILABLE:14,DATA_LOSS:15,UNAUTHENTICATED:16},wS="SENT",xS="RECEIVED",ES=wS,_S=xS,SS=zm([wS,xS]),TS="cloud.provider",CS="cloud.account.id",AS="cloud.region",OS="cloud.availability_zone",NS="cloud.platform",RS="aws.ecs.container.arn",PS="aws.ecs.cluster.arn",kS="aws.ecs.launchtype",LS="aws.ecs.task.arn",MS="aws.ecs.task.family",DS="aws.ecs.task.revision",jS="aws.eks.cluster.arn",IS="aws.log.group.names",FS="aws.log.group.arns",US="aws.log.stream.names",$S="aws.log.stream.arns",BS="container.name",VS="container.id",qS="container.runtime",zS="container.image.name",HS="container.image.tag",GS="deployment.environment",KS="device.id",WS="device.model.identifier",YS="device.model.name",XS="faas.name",QS="faas.id",ZS="faas.version",JS="faas.instance",eT="faas.max_memory",tT="host.id",nT="host.name",rT="host.type",oT="host.arch",iT="host.image.name",aT="host.image.id",sT="host.image.version",lT="k8s.cluster.name",cT="k8s.node.name",uT="k8s.node.uid",dT="k8s.namespace.name",pT="k8s.pod.uid",fT="k8s.pod.name",hT="k8s.container.name",mT="k8s.replicaset.uid",gT="k8s.replicaset.name",yT="k8s.deployment.uid",vT="k8s.deployment.name",bT="k8s.statefulset.uid",wT="k8s.statefulset.name",xT="k8s.daemonset.uid",ET="k8s.daemonset.name",_T="k8s.job.uid",ST="k8s.job.name",TT="k8s.cronjob.uid",CT="k8s.cronjob.name",AT="os.type",OT="os.description",NT="os.name",RT="os.version",PT="process.pid",kT="process.executable.name",LT="process.executable.path",MT="process.command",DT="process.command_line",jT="process.command_args",IT="process.owner",FT="process.runtime.name",UT="process.runtime.version",$T="process.runtime.description",BT="service.name",VT="service.namespace",qT="service.instance.id",zT="service.version",HT="telemetry.sdk.name",GT="telemetry.sdk.language",KT="telemetry.sdk.version",WT="telemetry.auto.version",YT="webengine.name",XT="webengine.version",QT="webengine.description",ZT=TS,JT=CS,eC=AS,tC=OS,nC=NS,rC=RS,oC=PS,iC=kS,aC=LS,sC=MS,lC=DS,cC=jS,uC=IS,dC=FS,pC=US,fC=$S,hC=BS,mC=VS,gC=qS,yC=zS,vC=HS,bC=GS,wC=KS,xC=WS,EC=YS,_C=XS,SC=QS,TC=ZS,CC=JS,AC=eT,OC=tT,NC=nT,RC=rT,PC=oT,kC=iT,LC=aT,MC=sT,DC=lT,jC=cT,IC=uT,FC=dT,UC=pT,$C=fT,BC=hT,VC=mT,qC=gT,zC=yT,HC=vT,GC=bT,KC=wT,WC=xT,YC=ET,XC=_T,QC=ST,ZC=TT,JC=CT,eA=AT,tA=OT,nA=NT,rA=RT,oA=PT,iA=kT,aA=LT,sA=MT,lA=DT,cA=jT,uA=IT,dA=FT,pA=UT,fA=$T,hA=BT,mA=VT,gA=qT,yA=zT,vA=HT,bA=GT,wA=KT,xA=WT,EA=YT,_A=XT,SA=QT,TA=zm([TS,CS,AS,OS,NS,RS,PS,kS,LS,MS,DS,jS,IS,FS,US,$S,BS,VS,qS,zS,HS,GS,KS,WS,YS,XS,QS,ZS,JS,eT,tT,nT,rT,oT,iT,aT,sT,lT,cT,uT,dT,pT,fT,hT,mT,gT,yT,vT,bT,wT,xT,ET,_T,ST,TT,CT,AT,OT,NT,RT,PT,kT,LT,MT,DT,jT,IT,FT,UT,$T,BT,VT,qT,zT,HT,GT,KT,WT,YT,XT,QT]),CA="alibaba_cloud",AA="azure",OA=CA,NA=AA,RA=zm([CA,"aws",AA,"gcp"]),PA="alibaba_cloud_ecs",kA="alibaba_cloud_fc",LA="aws_ec2",MA="aws_ecs",DA="aws_eks",jA="aws_lambda",IA="aws_elastic_beanstalk",FA="azure_vm",UA="azure_container_instances",$A="azure_aks",BA="azure_functions",VA="azure_app_service",qA="gcp_compute_engine",zA="gcp_cloud_run",HA="gcp_kubernetes_engine",GA="gcp_cloud_functions",KA="gcp_app_engine",WA=PA,YA=kA,XA=LA,QA=MA,ZA=DA,JA=jA,eO=IA,tO=FA,nO=UA,rO=$A,oO=BA,iO=VA,aO=qA,sO=zA,lO=HA,cO=GA,uO=KA,dO=zm([PA,kA,LA,MA,DA,jA,IA,FA,UA,$A,BA,VA,qA,zA,HA,GA,KA]),pO="fargate",fO=pO,hO=zm(["ec2",pO]),mO="amd64",gO="arm32",yO="arm64",vO="ia64",bO="ppc32",wO="ppc64",xO=mO,EO=gO,_O=yO,SO=vO,TO=bO,CO=wO,AO=zm([mO,gO,yO,vO,bO,wO,"x86"]),OO="windows",NO="linux",RO="darwin",PO="freebsd",kO="netbsd",LO="openbsd",MO="dragonflybsd",DO="hpux",jO="solaris",IO="z_os",FO=OO,UO=NO,$O=RO,BO=PO,VO=kO,qO=LO,zO=MO,HO=DO,GO=jO,KO=IO,WO=zm([OO,NO,RO,PO,kO,LO,MO,DO,"aix",jO,IO]),YO="dotnet",XO="erlang",QO="java",ZO="nodejs",JO="python",eN="ruby",tN="webjs",nN=YO,rN=XO,oN=QO,iN=ZO,aN=JO,sN=eN,lN=tN,cN=zm(["cpp",YO,XO,"go",QO,ZO,"php",JO,eN,tN]);const uN=Object.freeze(Object.defineProperty({__proto__:null,AWSECSLAUNCHTYPEVALUES_EC2:"ec2",AWSECSLAUNCHTYPEVALUES_FARGATE:fO,AwsEcsLaunchtypeValues:hO,CLOUDPLATFORMVALUES_ALIBABA_CLOUD_ECS:WA,CLOUDPLATFORMVALUES_ALIBABA_CLOUD_FC:YA,CLOUDPLATFORMVALUES_AWS_EC2:XA,CLOUDPLATFORMVALUES_AWS_ECS:QA,CLOUDPLATFORMVALUES_AWS_EKS:ZA,CLOUDPLATFORMVALUES_AWS_ELASTIC_BEANSTALK:eO,CLOUDPLATFORMVALUES_AWS_LAMBDA:JA,CLOUDPLATFORMVALUES_AZURE_AKS:rO,CLOUDPLATFORMVALUES_AZURE_APP_SERVICE:iO,CLOUDPLATFORMVALUES_AZURE_CONTAINER_INSTANCES:nO,CLOUDPLATFORMVALUES_AZURE_FUNCTIONS:oO,CLOUDPLATFORMVALUES_AZURE_VM:tO,CLOUDPLATFORMVALUES_GCP_APP_ENGINE:uO,CLOUDPLATFORMVALUES_GCP_CLOUD_FUNCTIONS:cO,CLOUDPLATFORMVALUES_GCP_CLOUD_RUN:sO,CLOUDPLATFORMVALUES_GCP_COMPUTE_ENGINE:aO,CLOUDPLATFORMVALUES_GCP_KUBERNETES_ENGINE:lO,CLOUDPROVIDERVALUES_ALIBABA_CLOUD:OA,CLOUDPROVIDERVALUES_AWS:"aws",CLOUDPROVIDERVALUES_AZURE:NA,CLOUDPROVIDERVALUES_GCP:"gcp",CloudPlatformValues:dO,CloudProviderValues:RA,DBCASSANDRACONSISTENCYLEVELVALUES_ALL:"all",DBCASSANDRACONSISTENCYLEVELVALUES_ANY:"any",DBCASSANDRACONSISTENCYLEVELVALUES_EACH_QUORUM:wE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_ONE:SE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_QUORUM:EE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_SERIAL:CE,DBCASSANDRACONSISTENCYLEVELVALUES_ONE:"one",DBCASSANDRACONSISTENCYLEVELVALUES_QUORUM:xE,DBCASSANDRACONSISTENCYLEVELVALUES_SERIAL:TE,DBCASSANDRACONSISTENCYLEVELVALUES_THREE:_E,DBCASSANDRACONSISTENCYLEVELVALUES_TWO:"two",DBSYSTEMVALUES_ADABAS:Ix,DBSYSTEMVALUES_CACHE:jx,DBSYSTEMVALUES_CASSANDRA:Jx,DBSYSTEMVALUES_CLOUDSCAPE:Nx,DBSYSTEMVALUES_COCKROACHDB:dE,DBSYSTEMVALUES_COLDFUSION:Zx,DBSYSTEMVALUES_COSMOSDB:iE,DBSYSTEMVALUES_COUCHBASE:rE,DBSYSTEMVALUES_COUCHDB:oE,DBSYSTEMVALUES_DB2:"db2",DBSYSTEMVALUES_DERBY:Ux,DBSYSTEMVALUES_DYNAMODB:aE,DBSYSTEMVALUES_EDB:"edb",DBSYSTEMVALUES_ELASTICSEARCH:cE,DBSYSTEMVALUES_FILEMAKER:$x,DBSYSTEMVALUES_FIREBIRD:Fx,DBSYSTEMVALUES_FIRSTSQL:Dx,DBSYSTEMVALUES_GEODE:lE,DBSYSTEMVALUES_H2:"h2",DBSYSTEMVALUES_HANADB:Lx,DBSYSTEMVALUES_HBASE:eE,DBSYSTEMVALUES_HIVE:Ox,DBSYSTEMVALUES_HSQLDB:Rx,DBSYSTEMVALUES_INFORMIX:Bx,DBSYSTEMVALUES_INGRES:Mx,DBSYSTEMVALUES_INSTANTDB:Vx,DBSYSTEMVALUES_INTERBASE:qx,DBSYSTEMVALUES_MARIADB:zx,DBSYSTEMVALUES_MAXDB:kx,DBSYSTEMVALUES_MEMCACHED:uE,DBSYSTEMVALUES_MONGODB:tE,DBSYSTEMVALUES_MSSQL:_x,DBSYSTEMVALUES_MYSQL:Sx,DBSYSTEMVALUES_NEO4J:sE,DBSYSTEMVALUES_NETEZZA:Hx,DBSYSTEMVALUES_ORACLE:Tx,DBSYSTEMVALUES_OTHER_SQL:Ex,DBSYSTEMVALUES_PERVASIVE:Gx,DBSYSTEMVALUES_POINTBASE:Kx,DBSYSTEMVALUES_POSTGRESQL:Cx,DBSYSTEMVALUES_PROGRESS:Px,DBSYSTEMVALUES_REDIS:nE,DBSYSTEMVALUES_REDSHIFT:Ax,DBSYSTEMVALUES_SQLITE:Wx,DBSYSTEMVALUES_SYBASE:Yx,DBSYSTEMVALUES_TERADATA:Xx,DBSYSTEMVALUES_VERTICA:Qx,DbCassandraConsistencyLevelValues:AE,DbSystemValues:pE,FAASDOCUMENTOPERATIONVALUES_DELETE:zE,FAASDOCUMENTOPERATIONVALUES_EDIT:qE,FAASDOCUMENTOPERATIONVALUES_INSERT:VE,FAASINVOKEDPROVIDERVALUES_ALIBABA_CLOUD:WE,FAASINVOKEDPROVIDERVALUES_AWS:"aws",FAASINVOKEDPROVIDERVALUES_AZURE:YE,FAASINVOKEDPROVIDERVALUES_GCP:"gcp",FAASTRIGGERVALUES_DATASOURCE:LE,FAASTRIGGERVALUES_HTTP:ME,FAASTRIGGERVALUES_OTHER:IE,FAASTRIGGERVALUES_PUBSUB:DE,FAASTRIGGERVALUES_TIMER:jE,FaasDocumentOperationValues:HE,FaasInvokedProviderValues:XE,FaasTriggerValues:FE,HOSTARCHVALUES_AMD64:xO,HOSTARCHVALUES_ARM32:EO,HOSTARCHVALUES_ARM64:_O,HOSTARCHVALUES_IA64:SO,HOSTARCHVALUES_PPC32:TO,HOSTARCHVALUES_PPC64:CO,HOSTARCHVALUES_X86:"x86",HTTPFLAVORVALUES_HTTP_1_0:"1.0",HTTPFLAVORVALUES_HTTP_1_1:"1.1",HTTPFLAVORVALUES_HTTP_2_0:"2.0",HTTPFLAVORVALUES_QUIC:sS,HTTPFLAVORVALUES_SPDY:aS,HostArchValues:AO,HttpFlavorValues:lS,MESSAGETYPEVALUES_RECEIVED:_S,MESSAGETYPEVALUES_SENT:ES,MESSAGINGDESTINATIONKINDVALUES_QUEUE:dS,MESSAGINGDESTINATIONKINDVALUES_TOPIC:pS,MESSAGINGOPERATIONVALUES_PROCESS:yS,MESSAGINGOPERATIONVALUES_RECEIVE:gS,MessageTypeValues:SS,MessagingDestinationKindValues:fS,MessagingOperationValues:vS,NETHOSTCONNECTIONSUBTYPEVALUES_CDMA:V_,NETHOSTCONNECTIONSUBTYPEVALUES_CDMA2000_1XRTT:H_,NETHOSTCONNECTIONSUBTYPEVALUES_EDGE:$_,NETHOSTCONNECTIONSUBTYPEVALUES_EHRPD:Q_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_0:q_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_A:z_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_B:X_,NETHOSTCONNECTIONSUBTYPEVALUES_GPRS:U_,NETHOSTCONNECTIONSUBTYPEVALUES_GSM:"gsm",NETHOSTCONNECTIONSUBTYPEVALUES_HSDPA:G_,NETHOSTCONNECTIONSUBTYPEVALUES_HSPA:W_,NETHOSTCONNECTIONSUBTYPEVALUES_HSPAP:Z_,NETHOSTCONNECTIONSUBTYPEVALUES_HSUPA:K_,NETHOSTCONNECTIONSUBTYPEVALUES_IDEN:Y_,NETHOSTCONNECTIONSUBTYPEVALUES_IWLAN:eS,NETHOSTCONNECTIONSUBTYPEVALUES_LTE:"lte",NETHOSTCONNECTIONSUBTYPEVALUES_LTE_CA:nS,NETHOSTCONNECTIONSUBTYPEVALUES_NR:"nr",NETHOSTCONNECTIONSUBTYPEVALUES_NRNSA:tS,NETHOSTCONNECTIONSUBTYPEVALUES_TD_SCDMA:J_,NETHOSTCONNECTIONSUBTYPEVALUES_UMTS:B_,NETHOSTCONNECTIONTYPEVALUES_CELL:y_,NETHOSTCONNECTIONTYPEVALUES_UNAVAILABLE:v_,NETHOSTCONNECTIONTYPEVALUES_UNKNOWN:b_,NETHOSTCONNECTIONTYPEVALUES_WIFI:m_,NETHOSTCONNECTIONTYPEVALUES_WIRED:g_,NETTRANSPORTVALUES_INPROC:s_,NETTRANSPORTVALUES_IP:"ip",NETTRANSPORTVALUES_IP_TCP:r_,NETTRANSPORTVALUES_IP_UDP:o_,NETTRANSPORTVALUES_OTHER:l_,NETTRANSPORTVALUES_PIPE:a_,NETTRANSPORTVALUES_UNIX:i_,NetHostConnectionSubtypeValues:rS,NetHostConnectionTypeValues:w_,NetTransportValues:c_,OSTYPEVALUES_AIX:"aix",OSTYPEVALUES_DARWIN:$O,OSTYPEVALUES_DRAGONFLYBSD:zO,OSTYPEVALUES_FREEBSD:BO,OSTYPEVALUES_HPUX:HO,OSTYPEVALUES_LINUX:UO,OSTYPEVALUES_NETBSD:VO,OSTYPEVALUES_OPENBSD:qO,OSTYPEVALUES_SOLARIS:GO,OSTYPEVALUES_WINDOWS:FO,OSTYPEVALUES_Z_OS:KO,OsTypeValues:WO,RPCGRPCSTATUSCODEVALUES_ABORTED:10,RPCGRPCSTATUSCODEVALUES_ALREADY_EXISTS:6,RPCGRPCSTATUSCODEVALUES_CANCELLED:1,RPCGRPCSTATUSCODEVALUES_DATA_LOSS:15,RPCGRPCSTATUSCODEVALUES_DEADLINE_EXCEEDED:4,RPCGRPCSTATUSCODEVALUES_FAILED_PRECONDITION:9,RPCGRPCSTATUSCODEVALUES_INTERNAL:13,RPCGRPCSTATUSCODEVALUES_INVALID_ARGUMENT:3,RPCGRPCSTATUSCODEVALUES_NOT_FOUND:5,RPCGRPCSTATUSCODEVALUES_OK:0,RPCGRPCSTATUSCODEVALUES_OUT_OF_RANGE:11,RPCGRPCSTATUSCODEVALUES_PERMISSION_DENIED:7,RPCGRPCSTATUSCODEVALUES_RESOURCE_EXHAUSTED:8,RPCGRPCSTATUSCODEVALUES_UNAUTHENTICATED:16,RPCGRPCSTATUSCODEVALUES_UNAVAILABLE:14,RPCGRPCSTATUSCODEVALUES_UNIMPLEMENTED:12,RPCGRPCSTATUSCODEVALUES_UNKNOWN:2,RpcGrpcStatusCodeValues:bS,SEMATTRS_AWS_DYNAMODB_ATTRIBUTES_TO_GET:$b,SEMATTRS_AWS_DYNAMODB_ATTRIBUTE_DEFINITIONS:Zb,SEMATTRS_AWS_DYNAMODB_CONSISTENT_READ:Ib,SEMATTRS_AWS_DYNAMODB_CONSUMED_CAPACITY:Lb,SEMATTRS_AWS_DYNAMODB_COUNT:Xb,SEMATTRS_AWS_DYNAMODB_EXCLUSIVE_START_TABLE:Hb,SEMATTRS_AWS_DYNAMODB_GLOBAL_SECONDARY_INDEXES:qb,SEMATTRS_AWS_DYNAMODB_GLOBAL_SECONDARY_INDEX_UPDATES:Jb,SEMATTRS_AWS_DYNAMODB_INDEX_NAME:Bb,SEMATTRS_AWS_DYNAMODB_ITEM_COLLECTION_METRICS:Mb,SEMATTRS_AWS_DYNAMODB_LIMIT:Ub,SEMATTRS_AWS_DYNAMODB_LOCAL_SECONDARY_INDEXES:zb,SEMATTRS_AWS_DYNAMODB_PROJECTION:Fb,SEMATTRS_AWS_DYNAMODB_PROVISIONED_READ_CAPACITY:Db,SEMATTRS_AWS_DYNAMODB_PROVISIONED_WRITE_CAPACITY:jb,SEMATTRS_AWS_DYNAMODB_SCANNED_COUNT:Qb,SEMATTRS_AWS_DYNAMODB_SCAN_FORWARD:Kb,SEMATTRS_AWS_DYNAMODB_SEGMENT:Wb,SEMATTRS_AWS_DYNAMODB_SELECT:Vb,SEMATTRS_AWS_DYNAMODB_TABLE_COUNT:Gb,SEMATTRS_AWS_DYNAMODB_TABLE_NAMES:kb,SEMATTRS_AWS_DYNAMODB_TOTAL_SEGMENTS:Yb,SEMATTRS_AWS_LAMBDA_INVOKED_ARN:dv,SEMATTRS_CODE_FILEPATH:mb,SEMATTRS_CODE_FUNCTION:fb,SEMATTRS_CODE_LINENO:gb,SEMATTRS_CODE_NAMESPACE:hb,SEMATTRS_DB_CASSANDRA_CONSISTENCY_LEVEL:Ev,SEMATTRS_DB_CASSANDRA_COORDINATOR_DC:Av,SEMATTRS_DB_CASSANDRA_COORDINATOR_ID:Cv,SEMATTRS_DB_CASSANDRA_IDEMPOTENCE:Sv,SEMATTRS_DB_CASSANDRA_KEYSPACE:wv,SEMATTRS_DB_CASSANDRA_PAGE_SIZE:xv,SEMATTRS_DB_CASSANDRA_SPECULATIVE_EXECUTION_COUNT:Tv,SEMATTRS_DB_CASSANDRA_TABLE:_v,SEMATTRS_DB_CONNECTION_STRING:fv,SEMATTRS_DB_HBASE_NAMESPACE:Ov,SEMATTRS_DB_JDBC_DRIVER_CLASSNAME:mv,SEMATTRS_DB_MONGODB_COLLECTION:Rv,SEMATTRS_DB_MSSQL_INSTANCE_NAME:bv,SEMATTRS_DB_NAME:gv,SEMATTRS_DB_OPERATION:vv,SEMATTRS_DB_REDIS_DATABASE_INDEX:Nv,SEMATTRS_DB_SQL_TABLE:Pv,SEMATTRS_DB_STATEMENT:yv,SEMATTRS_DB_SYSTEM:pv,SEMATTRS_DB_USER:hv,SEMATTRS_ENDUSER_ID:lb,SEMATTRS_ENDUSER_ROLE:cb,SEMATTRS_ENDUSER_SCOPE:ub,SEMATTRS_EXCEPTION_ESCAPED:Dv,SEMATTRS_EXCEPTION_MESSAGE:Lv,SEMATTRS_EXCEPTION_STACKTRACE:Mv,SEMATTRS_EXCEPTION_TYPE:kv,SEMATTRS_FAAS_COLDSTART:zv,SEMATTRS_FAAS_CRON:qv,SEMATTRS_FAAS_DOCUMENT_COLLECTION:Fv,SEMATTRS_FAAS_DOCUMENT_NAME:Bv,SEMATTRS_FAAS_DOCUMENT_OPERATION:Uv,SEMATTRS_FAAS_DOCUMENT_TIME:$v,SEMATTRS_FAAS_EXECUTION:Iv,SEMATTRS_FAAS_INVOKED_NAME:Hv,SEMATTRS_FAAS_INVOKED_PROVIDER:Gv,SEMATTRS_FAAS_INVOKED_REGION:Kv,SEMATTRS_FAAS_TIME:Vv,SEMATTRS_FAAS_TRIGGER:jv,SEMATTRS_HTTP_CLIENT_IP:Pb,SEMATTRS_HTTP_FLAVOR:_b,SEMATTRS_HTTP_HOST:wb,SEMATTRS_HTTP_METHOD:yb,SEMATTRS_HTTP_REQUEST_CONTENT_LENGTH:Tb,SEMATTRS_HTTP_REQUEST_CONTENT_LENGTH_UNCOMPRESSED:Cb,SEMATTRS_HTTP_RESPONSE_CONTENT_LENGTH:Ab,SEMATTRS_HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED:Ob,SEMATTRS_HTTP_ROUTE:Rb,SEMATTRS_HTTP_SCHEME:xb,SEMATTRS_HTTP_SERVER_NAME:Nb,SEMATTRS_HTTP_STATUS_CODE:Eb,SEMATTRS_HTTP_TARGET:bb,SEMATTRS_HTTP_URL:vb,SEMATTRS_HTTP_USER_AGENT:Sb,SEMATTRS_MESSAGE_COMPRESSED_SIZE:Nw,SEMATTRS_MESSAGE_ID:Ow,SEMATTRS_MESSAGE_TYPE:Aw,SEMATTRS_MESSAGE_UNCOMPRESSED_SIZE:Rw,SEMATTRS_MESSAGING_CONSUMER_ID:pw,SEMATTRS_MESSAGING_CONVERSATION_ID:lw,SEMATTRS_MESSAGING_DESTINATION:tw,SEMATTRS_MESSAGING_DESTINATION_KIND:nw,SEMATTRS_MESSAGING_KAFKA_CLIENT_ID:gw,SEMATTRS_MESSAGING_KAFKA_CONSUMER_GROUP:mw,SEMATTRS_MESSAGING_KAFKA_MESSAGE_KEY:hw,SEMATTRS_MESSAGING_KAFKA_PARTITION:yw,SEMATTRS_MESSAGING_KAFKA_TOMBSTONE:vw,SEMATTRS_MESSAGING_MESSAGE_ID:sw,SEMATTRS_MESSAGING_MESSAGE_PAYLOAD_COMPRESSED_SIZE_BYTES:uw,SEMATTRS_MESSAGING_MESSAGE_PAYLOAD_SIZE_BYTES:cw,SEMATTRS_MESSAGING_OPERATION:dw,SEMATTRS_MESSAGING_PROTOCOL:ow,SEMATTRS_MESSAGING_PROTOCOL_VERSION:iw,SEMATTRS_MESSAGING_RABBITMQ_ROUTING_KEY:fw,SEMATTRS_MESSAGING_SYSTEM:ew,SEMATTRS_MESSAGING_TEMP_DESTINATION:rw,SEMATTRS_MESSAGING_URL:aw,SEMATTRS_NET_HOST_CARRIER_ICC:ab,SEMATTRS_NET_HOST_CARRIER_MCC:ob,SEMATTRS_NET_HOST_CARRIER_MNC:ib,SEMATTRS_NET_HOST_CARRIER_NAME:rb,SEMATTRS_NET_HOST_CONNECTION_SUBTYPE:nb,SEMATTRS_NET_HOST_CONNECTION_TYPE:tb,SEMATTRS_NET_HOST_IP:Zv,SEMATTRS_NET_HOST_NAME:eb,SEMATTRS_NET_HOST_PORT:Jv,SEMATTRS_NET_PEER_IP:Yv,SEMATTRS_NET_PEER_NAME:Qv,SEMATTRS_NET_PEER_PORT:Xv,SEMATTRS_NET_TRANSPORT:Wv,SEMATTRS_PEER_SERVICE:sb,SEMATTRS_RPC_GRPC_STATUS_CODE:Ew,SEMATTRS_RPC_JSONRPC_ERROR_CODE:Tw,SEMATTRS_RPC_JSONRPC_ERROR_MESSAGE:Cw,SEMATTRS_RPC_JSONRPC_REQUEST_ID:Sw,SEMATTRS_RPC_JSONRPC_VERSION:_w,SEMATTRS_RPC_METHOD:xw,SEMATTRS_RPC_SERVICE:ww,SEMATTRS_RPC_SYSTEM:bw,SEMATTRS_THREAD_ID:db,SEMATTRS_THREAD_NAME:pb,SEMRESATTRS_AWS_ECS_CLUSTER_ARN:oC,SEMRESATTRS_AWS_ECS_CONTAINER_ARN:rC,SEMRESATTRS_AWS_ECS_LAUNCHTYPE:iC,SEMRESATTRS_AWS_ECS_TASK_ARN:aC,SEMRESATTRS_AWS_ECS_TASK_FAMILY:sC,SEMRESATTRS_AWS_ECS_TASK_REVISION:lC,SEMRESATTRS_AWS_EKS_CLUSTER_ARN:cC,SEMRESATTRS_AWS_LOG_GROUP_ARNS:dC,SEMRESATTRS_AWS_LOG_GROUP_NAMES:uC,SEMRESATTRS_AWS_LOG_STREAM_ARNS:fC,SEMRESATTRS_AWS_LOG_STREAM_NAMES:pC,SEMRESATTRS_CLOUD_ACCOUNT_ID:JT,SEMRESATTRS_CLOUD_AVAILABILITY_ZONE:tC,SEMRESATTRS_CLOUD_PLATFORM:nC,SEMRESATTRS_CLOUD_PROVIDER:ZT,SEMRESATTRS_CLOUD_REGION:eC,SEMRESATTRS_CONTAINER_ID:mC,SEMRESATTRS_CONTAINER_IMAGE_NAME:yC,SEMRESATTRS_CONTAINER_IMAGE_TAG:vC,SEMRESATTRS_CONTAINER_NAME:hC,SEMRESATTRS_CONTAINER_RUNTIME:gC,SEMRESATTRS_DEPLOYMENT_ENVIRONMENT:bC,SEMRESATTRS_DEVICE_ID:wC,SEMRESATTRS_DEVICE_MODEL_IDENTIFIER:xC,SEMRESATTRS_DEVICE_MODEL_NAME:EC,SEMRESATTRS_FAAS_ID:SC,SEMRESATTRS_FAAS_INSTANCE:CC,SEMRESATTRS_FAAS_MAX_MEMORY:AC,SEMRESATTRS_FAAS_NAME:_C,SEMRESATTRS_FAAS_VERSION:TC,SEMRESATTRS_HOST_ARCH:PC,SEMRESATTRS_HOST_ID:OC,SEMRESATTRS_HOST_IMAGE_ID:LC,SEMRESATTRS_HOST_IMAGE_NAME:kC,SEMRESATTRS_HOST_IMAGE_VERSION:MC,SEMRESATTRS_HOST_NAME:NC,SEMRESATTRS_HOST_TYPE:RC,SEMRESATTRS_K8S_CLUSTER_NAME:DC,SEMRESATTRS_K8S_CONTAINER_NAME:BC,SEMRESATTRS_K8S_CRONJOB_NAME:JC,SEMRESATTRS_K8S_CRONJOB_UID:ZC,SEMRESATTRS_K8S_DAEMONSET_NAME:YC,SEMRESATTRS_K8S_DAEMONSET_UID:WC,SEMRESATTRS_K8S_DEPLOYMENT_NAME:HC,SEMRESATTRS_K8S_DEPLOYMENT_UID:zC,SEMRESATTRS_K8S_JOB_NAME:QC,SEMRESATTRS_K8S_JOB_UID:XC,SEMRESATTRS_K8S_NAMESPACE_NAME:FC,SEMRESATTRS_K8S_NODE_NAME:jC,SEMRESATTRS_K8S_NODE_UID:IC,SEMRESATTRS_K8S_POD_NAME:$C,SEMRESATTRS_K8S_POD_UID:UC,SEMRESATTRS_K8S_REPLICASET_NAME:qC,SEMRESATTRS_K8S_REPLICASET_UID:VC,SEMRESATTRS_K8S_STATEFULSET_NAME:KC,SEMRESATTRS_K8S_STATEFULSET_UID:GC,SEMRESATTRS_OS_DESCRIPTION:tA,SEMRESATTRS_OS_NAME:nA,SEMRESATTRS_OS_TYPE:eA,SEMRESATTRS_OS_VERSION:rA,SEMRESATTRS_PROCESS_COMMAND:sA,SEMRESATTRS_PROCESS_COMMAND_ARGS:cA,SEMRESATTRS_PROCESS_COMMAND_LINE:lA,SEMRESATTRS_PROCESS_EXECUTABLE_NAME:iA,SEMRESATTRS_PROCESS_EXECUTABLE_PATH:aA,SEMRESATTRS_PROCESS_OWNER:uA,SEMRESATTRS_PROCESS_PID:oA,SEMRESATTRS_PROCESS_RUNTIME_DESCRIPTION:fA,SEMRESATTRS_PROCESS_RUNTIME_NAME:dA,SEMRESATTRS_PROCESS_RUNTIME_VERSION:pA,SEMRESATTRS_SERVICE_INSTANCE_ID:gA,SEMRESATTRS_SERVICE_NAME:hA,SEMRESATTRS_SERVICE_NAMESPACE:mA,SEMRESATTRS_SERVICE_VERSION:yA,SEMRESATTRS_TELEMETRY_AUTO_VERSION:xA,SEMRESATTRS_TELEMETRY_SDK_LANGUAGE:bA,SEMRESATTRS_TELEMETRY_SDK_NAME:vA,SEMRESATTRS_TELEMETRY_SDK_VERSION:wA,SEMRESATTRS_WEBENGINE_DESCRIPTION:SA,SEMRESATTRS_WEBENGINE_NAME:EA,SEMRESATTRS_WEBENGINE_VERSION:_A,SemanticAttributes:Pw,SemanticResourceAttributes:TA,TELEMETRYSDKLANGUAGEVALUES_CPP:"cpp",TELEMETRYSDKLANGUAGEVALUES_DOTNET:nN,TELEMETRYSDKLANGUAGEVALUES_ERLANG:rN,TELEMETRYSDKLANGUAGEVALUES_GO:"go",TELEMETRYSDKLANGUAGEVALUES_JAVA:oN,TELEMETRYSDKLANGUAGEVALUES_NODEJS:iN,TELEMETRYSDKLANGUAGEVALUES_PHP:"php",TELEMETRYSDKLANGUAGEVALUES_PYTHON:aN,TELEMETRYSDKLANGUAGEVALUES_RUBY:sN,TELEMETRYSDKLANGUAGEVALUES_WEBJS:lN,TelemetrySdkLanguageValues:cN},Symbol.toStringTag,{value:"Module"}));var dN=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function pN(e){return e.setValue(dN,!0)}function fN(e){return!0===e.getValue(dN)}var hN=",",mN="baggage";function gN(e){return e.reduce((function(e,t){var n=""+e+(""!==e?hN:"")+t;return n.length>8192?e:n}),"")}function yN(e){return e.getAllEntries().map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),n=t[1],r=encodeURIComponent(t[0])+"="+encodeURIComponent(n.value);return void 0!==n.metadata&&(r+=";"+n.metadata.toString()),r}))}function vN(e){var t=e.split(";");if(!(t.length<=0)){var n=t.shift();if(n){var r=n.indexOf("=");if(!(r<=0)){var o,i=decodeURIComponent(n.substring(0,r).trim()),a=decodeURIComponent(n.substring(r+1).trim());return t.length>0&&(o=Gf(t.join(";"))),{key:i,value:a,metadata:o}}}}}function bN(e){return"string"!=typeof e||0===e.length?{}:e.split(hN).map((function(e){return vN(e)})).filter((function(e){return void 0!==e&&e.value.length>0})).reduce((function(e,t){return e[t.key]=t.value,e}),{})}const wN=Object.freeze(Object.defineProperty({__proto__:null,getKeyPairs:yN,parseKeyPairsIntoRecord:bN,parsePairKeyValue:vN,serializeKeyPairs:gN},Symbol.toStringTag,{value:"Module"}));var xN=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=ym.getBaggage(e);if(r&&!fN(e)){var o=gN(yN(r).filter((function(e){return e.length<=4096})).slice(0,180));o.length>0&&n.set(t,mN,o)}},e.prototype.extract=function(e,t,n){var r=n.get(t,mN),o=Array.isArray(r)?r.join(hN):r;if(!o)return e;var i={};return 0===o.length?e:(o.split(hN).forEach((function(e){var t=vN(e);if(t){var n={value:t.value};t.metadata&&(n.metadata=t.metadata),i[t.key]=n}})),0===Object.entries(i).length?e:ym.setBaggage(e,ym.createBaggage(i)))},e.prototype.fields=function(){return[mN]},e}(),EN=function(){function e(e,t){this._monotonicClock=t,this._epochMillis=e.now(),this._performanceMillis=t.now()}return e.prototype.now=function(){var e=this._monotonicClock.now()-this._performanceMillis;return this._epochMillis+e},e}(),_N=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},SN=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function TN(e){var t,n,r={};if("object"!=typeof e||null==e)return r;try{for(var o=_N(Object.entries(e)),i=o.next();!i.done;i=o.next()){var a=SN(i.value,2),s=a[0],l=a[1];CN(s)?AN(l)?r[s]=Array.isArray(l)?l.slice():l:im.warn("Invalid attribute value set for key: "+s):im.warn("Invalid attribute key: "+s)}}catch(c){t={error:c}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function CN(e){return"string"==typeof e&&e.length>0}function AN(e){return null==e||(Array.isArray(e)?function(e){var t,n,r;try{for(var o=_N(e),i=o.next();!i.done;i=o.next()){var a=i.value;if(null!=a){if(!r){if(ON(a)){r=typeof a;continue}return!1}if(typeof a!==r)return!1}}}catch(s){t={error:s}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return!0}(e):ON(e))}function ON(e){switch(typeof e){case"number":case"boolean":case"string":return!0}return!1}function NN(){return function(e){im.error(function(e){return"string"==typeof e?e:JSON.stringify(function(e){var t={},n=e;for(;null!==n;)Object.getOwnPropertyNames(n).forEach((function(e){if(!t[e]){var r=n[e];r&&(t[e]=String(r))}})),n=Object.getPrototypeOf(n);return t}(e))}(e))}}var RN,PN,kN=NN();function LN(e){try{kN(e)}catch(t){}}(PN=RN||(RN={})).AlwaysOff="always_off",PN.AlwaysOn="always_on",PN.ParentBasedAlwaysOff="parentbased_always_off",PN.ParentBasedAlwaysOn="parentbased_always_on",PN.ParentBasedTraceIdRatio="parentbased_traceidratio",PN.TraceIdRatio="traceidratio";var MN=["OTEL_SDK_DISABLED"];function DN(e){return MN.indexOf(e)>-1}var jN=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function IN(e){return jN.indexOf(e)>-1}var FN=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function UN(e){return FN.indexOf(e)>-1}var $N=1/0,BN=128,VN={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:If.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:RN.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function qN(e,t,n){if(void 0!==n[e]){var r=String(n[e]);t[e]="true"===r.toLowerCase()}}function zN(e,t,n,r,o){if(void 0===r&&(r=-1/0),void 0===o&&(o=1/0),void 0!==n[e]){var i=Number(n[e]);isNaN(i)||(t[e]=i<r?r:i>o?o:i)}}function HN(e,t,n,r){void 0===r&&(r=",");var o=n[e];"string"==typeof o&&(t[e]=o.split(r).map((function(e){return e.trim()})))}var GN={ALL:If.ALL,VERBOSE:If.VERBOSE,DEBUG:If.DEBUG,INFO:If.INFO,WARN:If.WARN,ERROR:If.ERROR,NONE:If.NONE};function KN(e,t,n){var r=n[e];if("string"==typeof r){var o=GN[r.toUpperCase()];null!=o&&(t[e]=o)}}function WN(e){var t={};for(var n in VN){var r=n;if("OTEL_LOG_LEVEL"===r)KN(r,t,e);else if(DN(r))qN(r,t,e);else if(IN(r))zN(r,t,e);else if(UN(r))HN(r,t,e);else{var o=e[r];null!=o&&(t[r]=String(o))}}return t}var YN="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{};function XN(){var e=WN(YN);return Object.assign({},VN,e)}function QN(){return WN(YN)}function ZN(e){return e>=48&&e<=57?e-48:e>=97&&e<=102?e-87:e-55}function JN(e){for(var t=new Uint8Array(e.length/2),n=0,r=0;r<e.length;r+=2){var o=ZN(e.charCodeAt(r)),i=ZN(e.charCodeAt(r+1));t[n++]=o<<4|i}return t}var eR=function(){return function(){this.generateTraceId=nR(16),this.generateSpanId=nR(8)}}(),tR=Array(32);function nR(e){return function(){for(var t=0;t<2*e;t++)tR[t]=Math.floor(16*Math.random())+48,tR[t]>=58&&(tR[t]+=39);return String.fromCharCode.apply(null,tR.slice(0,2*e))}}var rR,oR=performance,iR="1.24.1",aR=((rR={})[TA.TELEMETRY_SDK_NAME]="opentelemetry",rR[TA.PROCESS_RUNTIME_NAME]="browser",rR[TA.TELEMETRY_SDK_LANGUAGE]=cN.WEBJS,rR[TA.TELEMETRY_SDK_VERSION]=iR,rR);function sR(e){}var lR,cR,uR=Math.pow(10,6),dR=Math.pow(10,9);function pR(e){return[Math.trunc(e/1e3),Math.round(e%1e3*uR)]}function fR(){var e=oR.timeOrigin;if("number"!=typeof e){e=oR.timing&&oR.timing.fetchStart}return e}function hR(e){return wR(pR(fR()),pR("number"==typeof e?e:oR.now()))}function mR(e,t){var n=t[0]-e[0],r=t[1]-e[1];return r<0&&(n-=1,r+=dR),[n,r]}function gR(e){return e[0]*dR+e[1]}function yR(e){return 1e6*e[0]+e[1]/1e3}function vR(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}function bR(e){return vR(e)||"number"==typeof e||e instanceof Date}function wR(e,t){var n=[e[0]+t[0],e[1]+t[1]];return n[1]>=dR&&(n[1]-=dR,n[0]+=1),n}(cR=lR||(lR={}))[cR.SUCCESS=0]="SUCCESS",cR[cR.FAILED=1]="FAILED";var xR=function(){function e(e){var t;void 0===e&&(e={}),this._propagators=null!==(t=e.propagators)&&void 0!==t?t:[],this._fields=Array.from(new Set(this._propagators.map((function(e){return"function"==typeof e.fields?e.fields():[]})).reduce((function(e,t){return e.concat(t)}),[])))}return e.prototype.inject=function(e,t,n){var r,o;try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(this._propagators),a=i.next();!a.done;a=i.next()){var s=a.value;try{s.inject(e,t,n)}catch(l){im.warn("Failed to inject with "+s.constructor.name+". Err: "+l.message)}}}catch(c){r={error:c}}finally{try{a&&!a.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}},e.prototype.extract=function(e,t,n){return this._propagators.reduce((function(e,r){try{return r.extract(e,t,n)}catch(o){im.warn("Failed to inject with "+r.constructor.name+". Err: "+o.message)}return e}),e)},e.prototype.fields=function(){return this._fields.slice()},e}(),ER="[_0-9a-z-*/]",_R=new RegExp("^(?:"+("[a-z]"+ER+"{0,255}")+"|"+("[a-z0-9]"+ER+"{0,240}@[a-z]"+ER+"{0,13}")+")$"),SR=/^[ -~]{0,255}[!-~]$/,TR=/,|=/;var CR=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return _R.test(e)})(o)&&function(e){return SR.test(e)&&!TR.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),AR="traceparent",OR="tracestate",NR=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");function RR(e){var t=NR.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}var PR,kR=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!fN(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,AR,o),r.traceState&&n.set(t,OR,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,AR);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=RR(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,OR);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new CR("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[AR,OR]},e}(),LR=Kf("OpenTelemetry SDK Context Key RPC_METADATA");(PR||(PR={})).HTTP="http";var MR,DR,jR=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:qh.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),IR=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:qh.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),FR=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(LN(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new IR),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new IR,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new jR,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new IR,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new jR}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),UR=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?qh.RECORD_AND_SAMPLED:qh.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),$R="[object Null]",BR="[object Undefined]",VR=Function.prototype.toString,qR=VR.call(Object),zR=(MR=Object.getPrototypeOf,DR=Object,function(e){return MR(DR(e))}),HR=Object.prototype,GR=HR.hasOwnProperty,KR=Symbol?Symbol.toStringTag:void 0,WR=HR.toString;function YR(e){if(!function(e){return null!=e&&"object"==typeof e}(e)||"[object Object]"!==function(e){if(null==e)return void 0===e?BR:$R;return KR&&KR in Object(e)?function(e){var t=GR.call(e,KR),n=e[KR],r=!1;try{e[KR]=void 0,r=!0}catch(tme){}var o=WR.call(e);r&&(t?e[KR]=n:delete e[KR]);return o}(e):function(e){return WR.call(e)}(e)}(e))return!1;var t=zR(e);if(null===t)return!0;var n=GR.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&VR.call(n)===qR}function XR(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e.shift(),r=new WeakMap;e.length>0;)n=ZR(n,e.shift(),0,r);return n}function QR(e){return eP(e)?e.slice():e}function ZR(e,t,n,r){var o;if(void 0===n&&(n=0),!(n>20)){if(n++,rP(e)||rP(t)||tP(t))o=QR(t);else if(eP(e)){if(o=e.slice(),eP(t))for(var i=0,a=t.length;i<a;i++)o.push(QR(t[i]));else if(nP(t))for(i=0,a=(s=Object.keys(t)).length;i<a;i++){o[l=s[i]]=QR(t[l])}}else if(nP(e))if(nP(t)){if(!function(e,t){if(!YR(e)||!YR(t))return!1;return!0}(e,t))return t;o=Object.assign({},e);var s;for(i=0,a=(s=Object.keys(t)).length;i<a;i++){var l,c=t[l=s[i]];if(rP(c))void 0===c?delete o[l]:o[l]=c;else{var u=o[l],d=c;if(JR(e,l,r)||JR(t,l,r))delete o[l];else{if(nP(u)&&nP(d)){var p=r.get(u)||[],f=r.get(d)||[];p.push({obj:e,key:l}),f.push({obj:t,key:l}),r.set(u,p),r.set(d,f)}o[l]=ZR(o[l],c,n,r)}}}}else o=t;return o}}function JR(e,t,n){for(var r=n.get(e[t])||[],o=0,i=r.length;o<i;o++){var a=r[o];if(a.key===t&&a.obj===e)return!0}return!1}function eP(e){return Array.isArray(e)}function tP(e){return"function"==typeof e}function nP(e){return!rP(e)&&!eP(e)&&!tP(e)&&"object"==typeof e}function rP(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||void 0===e||e instanceof Date||e instanceof RegExp||null===e}var oP=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),iP=function(e){function t(n){var r=e.call(this,n)||this;return Object.setPrototypeOf(r,t.prototype),r}return oP(t,e),t}(Error);function aP(e,t){return"string"==typeof t?e===t:!!e.match(t)}var sP=function(){function e(){var e=this;this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))}return Object.defineProperty(e.prototype,"promise",{get:function(){return this._promise},enumerable:!1,configurable:!0}),e.prototype.resolve=function(e){this._resolve(e)},e.prototype.reject=function(e){this._reject(e)},e}(),lP=function(){function e(e,t){this._callback=e,this._that=t,this._isCalled=!1,this._deferred=new sP}return Object.defineProperty(e.prototype,"isCalled",{get:function(){return this._isCalled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"promise",{get:function(){return this._deferred.promise},enumerable:!1,configurable:!0}),e.prototype.call=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];if(!this._isCalled){this._isCalled=!0;try{Promise.resolve((e=this._callback).call.apply(e,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([this._that],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))).then((function(e){return t._deferred.resolve(e)}),(function(e){return t._deferred.reject(e)}))}catch(o){this._deferred.reject(o)}}return this._deferred.promise},e}();var cP={_export:function(e,t){return new Promise((function(n){om.with(pN(om.active()),(function(){e.export(t,(function(e){n(e)}))}))}))}};const uP=Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:jR,AlwaysOnSampler:IR,AnchoredClock:EN,BindOnceFuture:lP,CompositePropagator:xR,DEFAULT_ATTRIBUTE_COUNT_LIMIT:BN,DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,DEFAULT_ENVIRONMENT:VN,DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,get ExportResultCode(){return lR},ParentBasedSampler:FR,get RPCType(){return PR},RandomIdGenerator:eR,SDK_INFO:aR,TRACE_PARENT_HEADER:AR,TRACE_STATE_HEADER:OR,TimeoutError:iP,TraceIdRatioBasedSampler:UR,TraceState:CR,get TracesSamplerValues(){return RN},VERSION:iR,W3CBaggagePropagator:xN,W3CTraceContextPropagator:kR,_globalThis:YN,addHrTimes:wR,baggageUtils:wN,callWithTimeout:function(e,t){var n,r=new Promise((function(e,r){n=setTimeout((function(){r(new iP("Operation timed out."))}),t)}));return Promise.race([e,r]).then((function(e){return clearTimeout(n),e}),(function(e){throw clearTimeout(n),e}))},deleteRPCMetadata:function(e){return e.deleteValue(LR)},getEnv:XN,getEnvWithoutDefaults:QN,getRPCMetadata:function(e){return e.getValue(LR)},getTimeOrigin:fR,globalErrorHandler:LN,hexToBase64:function(e){return btoa(String.fromCharCode.apply(String,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(JN(e)),!1)))},hexToBinary:JN,hrTime:hR,hrTimeDuration:mR,hrTimeToMicroseconds:yR,hrTimeToMilliseconds:function(e){return 1e3*e[0]+e[1]/1e6},hrTimeToNanoseconds:gR,hrTimeToTimeStamp:function(e){var t=""+"0".repeat(9)+e[1]+"Z",n=t.substr(t.length-9-1);return new Date(1e3*e[0]).toISOString().replace("000Z",n)},internal:cP,isAttributeKey:CN,isAttributeValue:AN,isTimeInput:bR,isTimeInputHrTime:vR,isTracingSuppressed:fN,isUrlIgnored:function(e,t){var n,r;if(!t)return!1;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),i=o.next();!i.done;i=o.next()){if(aP(e,i.value))return!0}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return!1},isWrapped:function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped},loggingErrorHandler:NN,merge:XR,millisToHrTime:pR,otperformance:oR,parseEnvironment:WN,parseTraceParent:RR,sanitizeAttributes:TN,setGlobalErrorHandler:function(e){kN=e},setRPCMetadata:function(e,t){return e.setValue(LR,t)},suppressTracing:pN,timeInputToHrTime:function(e){if(vR(e))return e;if("number"==typeof e)return e<fR()?hR(e):pR(e);if(e instanceof Date)return pR(e.getTime());throw TypeError("Invalid input type")},unrefTimer:sR,unsuppressTracing:function(e){return e.deleteValue(dN)},urlMatches:aP},Symbol.toStringTag,{value:"Module"}));function dP(){return"unknown_service"}var pP=function(){return pP=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},pP.apply(this,arguments)},fP=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},hP=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},mP=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[hA]="unknown_service",t[bA]=aR[bA],t[vA]=aR[vA],t[wA]=aR[wA],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return fP(this,void 0,void 0,(function(){return hP(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=pP(pP({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return pP(pP(pP(pP({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),gP=new(function(){function e(){}return e.prototype.detect=function(){return new mP({})},e}()),yP=new(function(){function e(){}return e.prototype.detect=function(){return Promise.resolve(gP.detect())},e}()),vP=yP,bP=gP,wP=yP,xP=gP,EP=yP,_P=yP,SP=gP,TP=function(){return TP=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},TP.apply(this,arguments)},CP=new(function(){function e(){}return e.prototype.detect=function(e){var t,n,r,o;if(!("undefined"!=typeof navigator&&void 0===(null===(r=null===(n=global.process)||void 0===n?void 0:n.versions)||void 0===r?void 0:r.node)&&void 0===(null===(o=global.Bun)||void 0===o?void 0:o.version)))return mP.empty();var i=((t={})[TA.PROCESS_RUNTIME_NAME]="browser",t[TA.PROCESS_RUNTIME_DESCRIPTION]="Web Browser",t[TA.PROCESS_RUNTIME_VERSION]=navigator.userAgent,t);return this._getResourceAttributes(i,e)},e.prototype._getResourceAttributes=function(e,t){return""===e[TA.PROCESS_RUNTIME_VERSION]?(im.debug("BrowserDetector failed: Unable to find required browser resources. "),mP.empty()):new mP(TP({},e))},e}()),AP=new(function(){function e(){}return e.prototype.detect=function(e){return Promise.resolve(CP.detect(e))},e}()),OP=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},NP=new(function(){function e(){this._MAX_LENGTH=255,this._COMMA_SEPARATOR=",",this._LABEL_KEY_VALUE_SPLITTER="=",this._ERROR_MESSAGE_INVALID_CHARS="should be a ASCII string with a length greater than 0 and not exceed "+this._MAX_LENGTH+" characters.",this._ERROR_MESSAGE_INVALID_VALUE="should be a ASCII string with a length not exceed "+this._MAX_LENGTH+" characters."}return e.prototype.detect=function(e){var t={},n=XN(),r=n.OTEL_RESOURCE_ATTRIBUTES,o=n.OTEL_SERVICE_NAME;if(r)try{var i=this._parseResourceAttributes(r);Object.assign(t,i)}catch(tme){im.debug("EnvDetector failed: "+tme.message)}return o&&(t[hA]=o),new mP(t)},e.prototype._parseResourceAttributes=function(e){var t,n;if(!e)return{};var r={},o=e.split(this._COMMA_SEPARATOR,-1);try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(o),a=i.next();!a.done;a=i.next()){var s=a.value.split(this._LABEL_KEY_VALUE_SPLITTER,-1);if(2===s.length){var l=OP(s,2),c=l[0],u=l[1];if(c=c.trim(),u=u.trim().split(/^"|"$/).join(""),!this._isValidAndNotEmpty(c))throw new Error("Attribute key "+this._ERROR_MESSAGE_INVALID_CHARS);if(!this._isValid(u))throw new Error("Attribute value "+this._ERROR_MESSAGE_INVALID_VALUE);r[c]=decodeURIComponent(u)}}}catch(d){t={error:d}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r},e.prototype._isValid=function(e){return e.length<=this._MAX_LENGTH&&this._isBaggageOctetString(e)},e.prototype._isBaggageOctetString=function(e){for(var t=0;t<e.length;t++){var n=e.charCodeAt(t);if(n<33||44===n||59===n||92===n||n>126)return!1}return!0},e.prototype._isValidAndNotEmpty=function(e){return e.length>0&&this._isValid(e)},e}()),RP=new(function(){function e(){}return e.prototype.detect=function(e){return Promise.resolve(NP.detect(e))},e}()),PP=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},kP=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},LP=function(e){e.forEach((function(e){if(Object.keys(e.attributes).length>0){var t=JSON.stringify(e.attributes,null,4);im.verbose(t)}}))};const MP=za(Object.freeze(Object.defineProperty({__proto__:null,Resource:mP,browserDetector:AP,browserDetectorSync:CP,defaultServiceName:dP,detectResources:function(e){return void 0===e&&(e={}),PP(void 0,void 0,void 0,(function(){var t;return kP(this,(function(n){switch(n.label){case 0:return[4,Promise.all((e.detectors||[]).map((function(t){return PP(void 0,void 0,void 0,(function(){var n,r;return kP(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,t.detect(e)];case 1:return n=o.sent(),im.debug(t.constructor.name+" found resource.",n),[2,n];case 2:return r=o.sent(),im.debug(t.constructor.name+" failed: "+r.message),[2,mP.empty()];case 3:return[2]}}))}))})))];case 1:return t=n.sent(),LP(t),[2,t.reduce((function(e,t){return e.merge(t)}),mP.empty())]}}))}))},detectResourcesSync:function(e){var t;void 0===e&&(e={});var n=(null!==(t=e.detectors)&&void 0!==t?t:[]).map((function(t){try{var n,r=t.detect(e);if(null!==(o=r)&&"object"==typeof o&&"function"==typeof o.then){n=new mP({},PP(void 0,void 0,void 0,(function(){return kP(this,(function(e){switch(e.label){case 0:return[4,r];case 1:return[2,e.sent().attributes]}}))})))}else n=r;return n.waitForAsyncAttributes?n.waitForAsyncAttributes().then((function(){return im.debug(t.constructor.name+" found resource.",n)})):im.debug(t.constructor.name+" found resource.",n),n}catch(tme){return im.error(t.constructor.name+" failed: "+tme.message),mP.empty()}var o})),r=n.reduce((function(e,t){return e.merge(t)}),mP.empty());return r.waitForAsyncAttributes&&r.waitForAsyncAttributes().then((function(){LP(n)})),r},envDetector:RP,envDetectorSync:NP,hostDetector:vP,hostDetectorSync:bP,osDetector:wP,osDetectorSync:xP,processDetector:EP,processDetectorSync:_P,serviceInstanceIdDetectorSync:SP},Symbol.toStringTag,{value:"Module"})));var DP,jP=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},IP=function(){function e(e,t,n,r,o,i,a,s,l,c){void 0===a&&(a=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:Kh.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=n,this._spanContext=r,this.parentSpanId=i,this.kind=o,this.links=a;var u=Date.now();this._performanceStartTime=oR.now(),this._performanceOffset=u-(this._performanceStartTime+fR()),this._startTimeProvided=null!=s,this.startTime=this._getTime(null!=s?s:u),this.resource=e.resource,this.instrumentationLibrary=e.instrumentationLibrary,this._spanLimits=e.getSpanLimits(),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0,null!=c&&this.setAttributes(c),this._spanProcessor=e.getActiveSpanProcessor(),this._spanProcessor.onStart(this,t)}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return null==t||this._isSpanEnded()?this:0===e.length?(im.warn("Invalid attribute key: "+e),this):AN(t)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,e)?(this._droppedAttributesCount++,this):(this.attributes[e]=this._truncateToSize(t),this):(im.warn("Invalid attribute value set for key: "+e),this)},e.prototype.setAttributes=function(e){var t,n;try{for(var r=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=r.next();!o.done;o=r.next()){var i=jP(o.value,2);this.setAttribute(i[0],i[1])}}catch(a){t={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.addEvent=function(e,t,n){if(this._isSpanEnded())return this;if(0===this._spanLimits.eventCountLimit)return im.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(0===this._droppedEventsCount&&im.debug("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),bR(t)&&(bR(n)||(n=t),t=void 0);var r=TN(t);return this.events.push({name:e,attributes:r,time:this._getTime(n),droppedAttributesCount:0}),this},e.prototype.setStatus=function(e){return this._isSpanEnded()||(this.status=e),this},e.prototype.updateName=function(e){return this._isSpanEnded()||(this.name=e),this},e.prototype.end=function(e){this._isSpanEnded()?im.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once."):(this._ended=!0,this.endTime=this._getTime(e),this._duration=mR(this.startTime,this.endTime),this._duration[0]<0&&(im.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._droppedEventsCount>0&&im.warn("Dropped "+this._droppedEventsCount+" events because eventCountLimit reached"),this._spanProcessor.onEnd(this))},e.prototype._getTime=function(e){if("number"==typeof e&&e<oR.now())return hR(e+this._performanceOffset);if("number"==typeof e)return pR(e);if(e instanceof Date)return pR(e.getTime());if(vR(e))return e;if(this._startTimeProvided)return pR(Date.now());var t=oR.now()-this._performanceStartTime;return wR(this.startTime,pR(t))},e.prototype.isRecording=function(){return!1===this._ended},e.prototype.recordException=function(e,t){var n={};"string"==typeof e?n[Pw.EXCEPTION_MESSAGE]=e:e&&(e.code?n[Pw.EXCEPTION_TYPE]=e.code.toString():e.name&&(n[Pw.EXCEPTION_TYPE]=e.name),e.message&&(n[Pw.EXCEPTION_MESSAGE]=e.message),e.stack&&(n[Pw.EXCEPTION_STACKTRACE]=e.stack)),n[Pw.EXCEPTION_TYPE]||n[Pw.EXCEPTION_MESSAGE]?this.addEvent("exception",n,t):im.warn("Failed to record an exception "+e)},Object.defineProperty(e.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),e.prototype._isSpanEnded=function(){return this._ended&&im.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},e.prototype._truncateToLimitUtil=function(e,t){return e.length<=t?e:e.substr(0,t)},e.prototype._truncateToSize=function(e){var t=this,n=this._attributeValueLengthLimit;return n<=0?(im.warn("Attribute value limit must be positive, got "+n),e):"string"==typeof e?this._truncateToLimitUtil(e,n):Array.isArray(e)?e.map((function(e){return"string"==typeof e?t._truncateToLimitUtil(e,n):e})):e},e}();!function(e){e[e.NOT_RECORD=0]="NOT_RECORD",e[e.RECORD=1]="RECORD",e[e.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"}(DP||(DP={}));var FP=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:DP.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),UP=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:DP.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),$P=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(LN(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new UP),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new UP,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new FP,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new UP,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new FP}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),BP=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?DP.RECORD_AND_SAMPLED:DP.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),VP=XN(),qP=RN.AlwaysOn;function zP(){return{sampler:HP(VP),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:XN().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:XN().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:XN().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:XN().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:XN().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:XN().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:XN().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:XN().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function HP(e){switch(void 0===e&&(e=XN()),e.OTEL_TRACES_SAMPLER){case RN.AlwaysOn:return new UP;case RN.AlwaysOff:return new FP;case RN.ParentBasedAlwaysOn:return new $P({root:new UP});case RN.ParentBasedAlwaysOff:return new $P({root:new FP});case RN.TraceIdRatio:return new BP(GP(e));case RN.ParentBasedTraceIdRatio:return new $P({root:new BP(GP(e))});default:return im.error('OTEL_TRACES_SAMPLER value "'+e.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+qP+'".'),new UP}}function GP(e){if(void 0===e.OTEL_TRACES_SAMPLER_ARG||""===e.OTEL_TRACES_SAMPLER_ARG)return im.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to 1."),1;var t=Number(e.OTEL_TRACES_SAMPLER_ARG);return isNaN(t)?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to 1."),1):t<0||t>1?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to 1."),1):t}var KP=function(){function e(e,t){this._exporter=e,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var n=XN();this._maxExportBatchSize="number"==typeof(null==t?void 0:t.maxExportBatchSize)?t.maxExportBatchSize:n.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize="number"==typeof(null==t?void 0:t.maxQueueSize)?t.maxQueueSize:n.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis="number"==typeof(null==t?void 0:t.scheduledDelayMillis)?t.scheduledDelayMillis:n.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis="number"==typeof(null==t?void 0:t.exportTimeoutMillis)?t.exportTimeoutMillis:n.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new lP(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(im.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return e.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){this._shutdownOnce.isCalled||e.spanContext().traceFlags&gh.SAMPLED&&this._addToBuffer(e)},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){var e=this;return Promise.resolve().then((function(){return e.onShutdown()})).then((function(){return e._flushAll()})).then((function(){return e._exporter.shutdown()}))},e.prototype._addToBuffer=function(e){if(this._finishedSpans.length>=this._maxQueueSize)return 0===this._droppedSpansCount&&im.debug("maxQueueSize reached, dropping spans"),void this._droppedSpansCount++;this._droppedSpansCount>0&&(im.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(e),this._maybeStartTimer()},e.prototype._flushAll=function(){var e=this;return new Promise((function(t,n){for(var r=[],o=0,i=Math.ceil(e._finishedSpans.length/e._maxExportBatchSize);o<i;o++)r.push(e._flushOneBatch());Promise.all(r).then((function(){t()})).catch(n)}))},e.prototype._flushOneBatch=function(){var e=this;return this._clearTimer(),0===this._finishedSpans.length?Promise.resolve():new Promise((function(t,n){var r=setTimeout((function(){n(new Error("Timeout"))}),e._exportTimeoutMillis);om.with(pN(om.active()),(function(){var o;e._finishedSpans.length<=e._maxExportBatchSize?(o=e._finishedSpans,e._finishedSpans=[]):o=e._finishedSpans.splice(0,e._maxExportBatchSize);for(var i=function(){return e._exporter.export(o,(function(e){var o;clearTimeout(r),e.code===lR.SUCCESS?t():n(null!==(o=e.error)&&void 0!==o?o:new Error("BatchSpanProcessor: span export failed"))}))},a=null,s=0,l=o.length;s<l;s++){var c=o[s];c.resource.asyncAttributesPending&&c.resource.waitForAsyncAttributes&&(null!=a||(a=[]),a.push(c.resource.waitForAsyncAttributes()))}null===a?i():Promise.all(a).then(i,(function(e){LN(e),n(e)}))}))}))},e.prototype._maybeStartTimer=function(){var e=this;if(!this._isExporting){var t=function(){e._isExporting=!0,e._flushOneBatch().finally((function(){e._isExporting=!1,e._finishedSpans.length>0&&(e._clearTimer(),e._maybeStartTimer())})).catch((function(t){e._isExporting=!1,LN(t)}))};if(this._finishedSpans.length>=this._maxExportBatchSize)return t();void 0===this._timer&&(this._timer=setTimeout((function(){return t()}),this._scheduledDelayMillis))}},e.prototype._clearTimer=function(){void 0!==this._timer&&(clearTimeout(this._timer),this._timer=void 0)},e}(),WP=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YP=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.onInit(n),r}return WP(t,e),t.prototype.onInit=function(e){var t=this;!0!==(null==e?void 0:e.disableAutoFlushOnDocumentHide)&&"undefined"!=typeof document&&(this._visibilityChangeListener=function(){"hidden"===document.visibilityState&&t.forceFlush()},this._pageHideListener=function(){t.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},t.prototype.onShutdown=function(){"undefined"!=typeof document&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},t}(KP),XP=function(){return function(){this.generateTraceId=ZP(16),this.generateSpanId=ZP(8)}}(),QP=Array(32);function ZP(e){return function(){for(var t=0;t<2*e;t++)QP[t]=Math.floor(16*Math.random())+48,QP[t]>=58&&(QP[t]+=39);return String.fromCharCode.apply(null,QP.slice(0,2*e))}}var JP,ek,tk=function(){function e(e,t,n){this._tracerProvider=n;var r,o,i,a,s=(r=t,o={sampler:HP()},i=zP(),(a=Object.assign({},i,o,r)).generalLimits=Object.assign({},i.generalLimits,r.generalLimits||{}),a.spanLimits=Object.assign({},i.spanLimits,r.spanLimits||{}),a);this._sampler=s.sampler,this._generalLimits=s.generalLimits,this._spanLimits=s.spanLimits,this._idGenerator=t.idGenerator||new XP,this.resource=n.resource,this.instrumentationLibrary=e}return e.prototype.startSpan=function(e,t,n){var r,o,i;void 0===t&&(t={}),void 0===n&&(n=om.active()),t.root&&(n=bm.deleteSpan(n));var a=bm.getSpan(n);if(fN(n))return im.debug("Instrumentation suppressed, returning Noop Span"),bm.wrapSpanContext(Ch);var s,l,c,u=null==a?void 0:a.spanContext(),d=this._idGenerator.generateSpanId();u&&bm.isSpanContextValid(u)?(s=u.traceId,l=u.traceState,c=u.spanId):s=this._idGenerator.generateTraceId();var p=null!==(r=t.kind)&&void 0!==r?r:Hh.INTERNAL,f=(null!==(o=t.links)&&void 0!==o?o:[]).map((function(e){return{context:e.context,attributes:TN(e.attributes)}})),h=TN(t.attributes),m=this._sampler.shouldSample(n,s,e,p,h,f);l=null!==(i=m.traceState)&&void 0!==i?i:l;var g={traceId:s,spanId:d,traceFlags:m.decision===qh.RECORD_AND_SAMPLED?gh.SAMPLED:gh.NONE,traceState:l};if(m.decision===qh.NOT_RECORD)return im.debug("Recording is off, propagating context in a non-recording span"),bm.wrapSpanContext(g);var y=TN(Object.assign(h,m.attributes));return new IP(this,n,e,g,p,c,f,t.startTime,void 0,y)},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:om.active(),l=this.startSpan(e,o,s),c=bm.setSpan(s,l);return om.with(c,a,void 0,l)}},e.prototype.getGeneralLimits=function(){return this._generalLimits},e.prototype.getSpanLimits=function(){return this._spanLimits},e.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},e}(),nk=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},rk=function(){function e(e){this._spanProcessors=e}return e.prototype.forceFlush=function(){var e,t,n=[];try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.forceFlush())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e){Promise.all(n).then((function(){e()})).catch((function(t){LN(t||new Error("MultiSpanProcessor: forceFlush failed")),e()}))}))},e.prototype.onStart=function(e,t){var n,r;try{for(var o=nk(this._spanProcessors),i=o.next();!i.done;i=o.next()){i.value.onStart(e,t)}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}},e.prototype.onEnd=function(e){var t,n;try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){o.value.onEnd(e)}}catch(i){t={error:i}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.shutdown=function(){var e,t,n=[];try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.shutdown())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e,t){Promise.all(n).then((function(){e()}),t)}))},e}(),ok=function(){function e(){}return e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){},e.prototype.shutdown=function(){return Promise.resolve()},e.prototype.forceFlush=function(){return Promise.resolve()},e}();(ek=JP||(JP={}))[ek.resolved=0]="resolved",ek[ek.timeout=1]="timeout",ek[ek.error=2]="error",ek[ek.unresolved=3]="unresolved";var ik=function(){function e(e){var t;void 0===e&&(e={}),this._registeredSpanProcessors=[],this._tracers=new Map;var n=XR({},zP(),function(e){var t,n,r,o,i,a,s,l,c,u,d,p,f=Object.assign({},e.spanLimits),h=QN();return f.attributeCountLimit=null!==(a=null!==(i=null!==(o=null!==(n=null===(t=e.spanLimits)||void 0===t?void 0:t.attributeCountLimit)&&void 0!==n?n:null===(r=e.generalLimits)||void 0===r?void 0:r.attributeCountLimit)&&void 0!==o?o:h.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)&&void 0!==i?i:h.OTEL_ATTRIBUTE_COUNT_LIMIT)&&void 0!==a?a:BN,f.attributeValueLengthLimit=null!==(p=null!==(d=null!==(u=null!==(l=null===(s=e.spanLimits)||void 0===s?void 0:s.attributeValueLengthLimit)&&void 0!==l?l:null===(c=e.generalLimits)||void 0===c?void 0:c.attributeValueLengthLimit)&&void 0!==u?u:h.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==d?d:h.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==p?p:$N,Object.assign({},e,{spanLimits:f})}(e));this.resource=null!==(t=n.resource)&&void 0!==t?t:mP.empty(),this.resource=mP.default().merge(this.resource),this._config=Object.assign({},n,{resource:this.resource});var r=this._buildExporterFromEnv();if(void 0!==r){var o=new YP(r);this.activeSpanProcessor=o}else this.activeSpanProcessor=new ok}return e.prototype.getTracer=function(e,t,n){var r=e+"@"+(t||"")+":"+((null==n?void 0:n.schemaUrl)||"");return this._tracers.has(r)||this._tracers.set(r,new tk({name:e,version:t,schemaUrl:null==n?void 0:n.schemaUrl},this._config,this)),this._tracers.get(r)},e.prototype.addSpanProcessor=function(e){0===this._registeredSpanProcessors.length&&this.activeSpanProcessor.shutdown().catch((function(e){return im.error("Error while trying to shutdown current span processor",e)})),this._registeredSpanProcessors.push(e),this.activeSpanProcessor=new rk(this._registeredSpanProcessors)},e.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},e.prototype.register=function(e){void 0===e&&(e={}),bm.setGlobalTracerProvider(this),void 0===e.propagator&&(e.propagator=this._buildPropagatorFromEnv()),e.contextManager&&om.setGlobalContextManager(e.contextManager),e.propagator&&ym.setGlobalPropagator(e.propagator)},e.prototype.forceFlush=function(){var e=this._config.forceFlushTimeoutMillis,t=this._registeredSpanProcessors.map((function(t){return new Promise((function(n){var r,o=setTimeout((function(){n(new Error("Span processor did not completed within timeout period of "+e+" ms")),r=JP.timeout}),e);t.forceFlush().then((function(){clearTimeout(o),r!==JP.timeout&&n(r=JP.resolved)})).catch((function(e){clearTimeout(o),r=JP.error,n(e)}))}))}));return new Promise((function(e,n){Promise.all(t).then((function(t){var r=t.filter((function(e){return e!==JP.resolved}));r.length>0?n(r):e()})).catch((function(e){return n([e])}))}))},e.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},e.prototype._getPropagator=function(e){var t;return null===(t=this.constructor._registeredPropagators.get(e))||void 0===t?void 0:t()},e.prototype._getSpanExporter=function(e){var t;return null===(t=this.constructor._registeredExporters.get(e))||void 0===t?void 0:t()},e.prototype._buildPropagatorFromEnv=function(){var e=this,t=Array.from(new Set(XN().OTEL_PROPAGATORS)),n=t.map((function(t){var n=e._getPropagator(t);return n||im.warn('Propagator "'+t+'" requested through environment variable is unavailable.'),n})).reduce((function(e,t){return t&&e.push(t),e}),[]);return 0===n.length?void 0:1===t.length?n[0]:new xR({propagators:n})},e.prototype._buildExporterFromEnv=function(){var e=XN().OTEL_TRACES_EXPORTER;if("none"!==e&&""!==e){var t=this._getSpanExporter(e);return t||im.error('Exporter "'+e+'" requested through environment variable is unavailable.'),t}},e._registeredPropagators=new Map([["tracecontext",function(){return new kR}],["baggage",function(){return new xN}]]),e._registeredExporters=new Map,e}(),ak=function(){function e(){}return e.prototype.export=function(e,t){return this._sendSpans(e,t)},e.prototype.shutdown=function(){return this._sendSpans([]),this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype._exportInfo=function(e){var t;return{resource:{attributes:e.resource.attributes},traceId:e.spanContext().traceId,parentId:e.parentSpanId,traceState:null===(t=e.spanContext().traceState)||void 0===t?void 0:t.serialize(),name:e.name,id:e.spanContext().spanId,kind:e.kind,timestamp:yR(e.startTime),duration:yR(e.duration),attributes:e.attributes,status:e.status,events:e.events,links:e.links}},e.prototype._sendSpans=function(e,t){var n,r;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next());}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}if(t)return t({code:lR.SUCCESS})},e}(),sk=function(){function e(){this._finishedSpans=[],this._stopped=!1}return e.prototype.export=function(e,t){var n;if(this._stopped)return t({code:lR.FAILED,error:new Error("Exporter has been stopped")});(n=this._finishedSpans).push.apply(n,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)),setTimeout((function(){return t({code:lR.SUCCESS})}),0)},e.prototype.shutdown=function(){return this._stopped=!0,this._finishedSpans=[],this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype.reset=function(){this._finishedSpans=[]},e.prototype.getFinishedSpans=function(){return this._finishedSpans},e}(),lk=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},ck=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},uk=function(){function e(e){this._exporter=e,this._shutdownOnce=new lP(this._shutdown,this),this._unresolvedExports=new Set}return e.prototype.forceFlush=function(){return lk(this,void 0,void 0,(function(){return ck(this,(function(e){switch(e.label){case 0:return[4,Promise.all(Array.from(this._unresolvedExports))];case 1:return e.sent(),this._exporter.forceFlush?[4,this._exporter.forceFlush()]:[3,3];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){var t,n,r=this;if(!this._shutdownOnce.isCalled&&e.spanContext().traceFlags&gh.SAMPLED){var o=function(){return cP._export(r._exporter,[e]).then((function(e){var t;e.code!==lR.SUCCESS&&LN(null!==(t=e.error)&&void 0!==t?t:new Error("SimpleSpanProcessor: span export failed (status "+e+")"))})).catch((function(e){LN(e)}))};if(e.resource.asyncAttributesPending){var i=null===(n=(t=e.resource).waitForAsyncAttributes)||void 0===n?void 0:n.call(t).then((function(){return null!=i&&r._unresolvedExports.delete(i),o()}),(function(e){return LN(e)}));null!=i&&this._unresolvedExports.add(i)}else o()}},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){return this._exporter.shutdown()},e}();const dk=za(Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:FP,AlwaysOnSampler:UP,BasicTracerProvider:ik,BatchSpanProcessor:YP,ConsoleSpanExporter:ak,get ForceFlushState(){return JP},InMemorySpanExporter:sk,NoopSpanProcessor:ok,ParentBasedSampler:$P,RandomIdGenerator:XP,get SamplingDecision(){return DP},SimpleSpanProcessor:uk,Span:IP,TraceIdRatioBasedSampler:BP,Tracer:tk},Symbol.toStringTag,{value:"Module"})));var pk=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function fk(e){return e.setValue(pk,!0)}function hk(e){return!0===e.getValue(pk)}var mk="baggage";function gk(e){return e.getAllEntries().map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),n=t[1],r=encodeURIComponent(t[0])+"="+encodeURIComponent(n.value);return void 0!==n.metadata&&(r+=";"+n.metadata.toString()),r}))}var yk=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=ym.getBaggage(e);if(r&&!hk(e)){var o=function(e){return e.reduce((function(e,t){var n=e+(""!==e?",":"")+t;return n.length>8192?e:n}),"")}(gk(r).filter((function(e){return e.length<=4096})).slice(0,180));o.length>0&&n.set(t,mk,o)}},e.prototype.extract=function(e,t,n){var r=n.get(t,mk),o=Array.isArray(r)?r.join(","):r;if(!o)return e;var i={};return 0===o.length?e:(o.split(",").forEach((function(e){var t=function(e){var t=e.split(";");if(!(t.length<=0)){var n=t.shift();if(n){var r=n.indexOf("=");if(!(r<=0)){var o,i=decodeURIComponent(n.substring(0,r).trim()),a=decodeURIComponent(n.substring(r+1).trim());return t.length>0&&(o=Gf(t.join(";"))),{key:i,value:a,metadata:o}}}}}(e);if(t){var n={value:t.value};t.metadata&&(n.metadata=t.metadata),i[t.key]=n}})),0===Object.entries(i).length?e:ym.setBaggage(e,ym.createBaggage(i)))},e.prototype.fields=function(){return[mk]},e}(),vk=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},bk=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function wk(e){var t,n,r={};if("object"!=typeof e||null==e)return r;try{for(var o=vk(Object.entries(e)),i=o.next();!i.done;i=o.next()){var a=bk(i.value,2),s=a[0],l=a[1];xk(s)?Ek(l)?r[s]=Array.isArray(l)?l.slice():l:im.warn("Invalid attribute value set for key: "+s):im.warn("Invalid attribute key: "+s)}}catch(c){t={error:c}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function xk(e){return"string"==typeof e&&e.length>0}function Ek(e){return null==e||(Array.isArray(e)?function(e){var t,n,r;try{for(var o=vk(e),i=o.next();!i.done;i=o.next()){var a=i.value;if(null!=a){if(!r){if(_k(a)){r=typeof a;continue}return!1}if(typeof a!==r)return!1}}}catch(s){t={error:s}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return!0}(e):_k(e))}function _k(e){switch(typeof e){case"number":case"boolean":case"string":return!0}return!1}var Sk,Tk=function(e){im.error(function(e){return"string"==typeof e?e:JSON.stringify(function(e){for(var t={},n=e;null!==n;)Object.getOwnPropertyNames(n).forEach((function(e){if(!t[e]){var r=n[e];r&&(t[e]=String(r))}})),n=Object.getPrototypeOf(n);return t}(e))}(e))};function Ck(e){try{Tk(e)}catch(t){}}!function(e){e.AlwaysOff="always_off",e.AlwaysOn="always_on",e.ParentBasedAlwaysOff="parentbased_always_off",e.ParentBasedAlwaysOn="parentbased_always_on",e.ParentBasedTraceIdRatio="parentbased_traceidratio",e.TraceIdRatio="traceidratio"}(Sk||(Sk={}));var Ak=["OTEL_SDK_DISABLED"];function Ok(e){return Ak.indexOf(e)>-1}var Nk=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function Rk(e){return Nk.indexOf(e)>-1}var Pk=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function kk(e){return Pk.indexOf(e)>-1}var Lk=1/0,Mk=128,Dk={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:If.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:Sk.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function jk(e,t,n){if(void 0!==n[e]){var r=String(n[e]);t[e]="true"===r.toLowerCase()}}function Ik(e,t,n,r,o){if(void 0===r&&(r=-1/0),void 0===o&&(o=1/0),void 0!==n[e]){var i=Number(n[e]);isNaN(i)||(t[e]=i<r?r:i>o?o:i)}}function Fk(e,t,n,r){void 0===r&&(r=",");var o=n[e];"string"==typeof o&&(t[e]=o.split(r).map((function(e){return e.trim()})))}var Uk={ALL:If.ALL,VERBOSE:If.VERBOSE,DEBUG:If.DEBUG,INFO:If.INFO,WARN:If.WARN,ERROR:If.ERROR,NONE:If.NONE};function $k(e,t,n){var r=n[e];if("string"==typeof r){var o=Uk[r.toUpperCase()];null!=o&&(t[e]=o)}}function Bk(e){var t={};for(var n in Dk){var r=n;if("OTEL_LOG_LEVEL"===r)$k(r,t,e);else if(Ok(r))jk(r,t,e);else if(Rk(r))Ik(r,t,e);else if(kk(r))Fk(r,t,e);else{var o=e[r];null!=o&&(t[r]=String(o))}}return t}var Vk="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{};function qk(){var e=Bk(Vk);return Object.assign({},Dk,e)}var zk=performance;function Hk(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}var Gk,Kk=Hk(["aws.lambda.invoked_arn","db.system","db.connection_string","db.user","db.jdbc.driver_classname","db.name","db.statement","db.operation","db.mssql.instance_name","db.cassandra.keyspace","db.cassandra.page_size","db.cassandra.consistency_level","db.cassandra.table","db.cassandra.idempotence","db.cassandra.speculative_execution_count","db.cassandra.coordinator.id","db.cassandra.coordinator.dc","db.hbase.namespace","db.redis.database_index","db.mongodb.collection","db.sql.table","exception.type","exception.message","exception.stacktrace","exception.escaped","faas.trigger","faas.execution","faas.document.collection","faas.document.operation","faas.document.time","faas.document.name","faas.time","faas.cron","faas.coldstart","faas.invoked_name","faas.invoked_provider","faas.invoked_region","net.transport","net.peer.ip","net.peer.port","net.peer.name","net.host.ip","net.host.port","net.host.name","net.host.connection.type","net.host.connection.subtype","net.host.carrier.name","net.host.carrier.mcc","net.host.carrier.mnc","net.host.carrier.icc","peer.service","enduser.id","enduser.role","enduser.scope","thread.id","thread.name","code.function","code.namespace","code.filepath","code.lineno","http.method","http.url","http.target","http.host","http.scheme","http.status_code","http.flavor","http.user_agent","http.request_content_length","http.request_content_length_uncompressed","http.response_content_length","http.response_content_length_uncompressed","http.server_name","http.route","http.client_ip","aws.dynamodb.table_names","aws.dynamodb.consumed_capacity","aws.dynamodb.item_collection_metrics","aws.dynamodb.provisioned_read_capacity","aws.dynamodb.provisioned_write_capacity","aws.dynamodb.consistent_read","aws.dynamodb.projection","aws.dynamodb.limit","aws.dynamodb.attributes_to_get","aws.dynamodb.index_name","aws.dynamodb.select","aws.dynamodb.global_secondary_indexes","aws.dynamodb.local_secondary_indexes","aws.dynamodb.exclusive_start_table","aws.dynamodb.table_count","aws.dynamodb.scan_forward","aws.dynamodb.segment","aws.dynamodb.total_segments","aws.dynamodb.count","aws.dynamodb.scanned_count","aws.dynamodb.attribute_definitions","aws.dynamodb.global_secondary_index_updates","messaging.system","messaging.destination","messaging.destination_kind","messaging.temp_destination","messaging.protocol","messaging.protocol_version","messaging.url","messaging.message_id","messaging.conversation_id","messaging.message_payload_size_bytes","messaging.message_payload_compressed_size_bytes","messaging.operation","messaging.consumer_id","messaging.rabbitmq.routing_key","messaging.kafka.message_key","messaging.kafka.consumer_group","messaging.kafka.client_id","messaging.kafka.partition","messaging.kafka.tombstone","rpc.system","rpc.service","rpc.method","rpc.grpc.status_code","rpc.jsonrpc.version","rpc.jsonrpc.request_id","rpc.jsonrpc.error_code","rpc.jsonrpc.error_message","message.type","message.id","message.compressed_size","message.uncompressed_size"]),Wk="service.name",Yk="telemetry.sdk.name",Xk="telemetry.sdk.language",Qk="telemetry.sdk.version",Zk=Wk,Jk=Yk,eL=Xk,tL=Qk,nL=Hk(["cloud.provider","cloud.account.id","cloud.region","cloud.availability_zone","cloud.platform","aws.ecs.container.arn","aws.ecs.cluster.arn","aws.ecs.launchtype","aws.ecs.task.arn","aws.ecs.task.family","aws.ecs.task.revision","aws.eks.cluster.arn","aws.log.group.names","aws.log.group.arns","aws.log.stream.names","aws.log.stream.arns","container.name","container.id","container.runtime","container.image.name","container.image.tag","deployment.environment","device.id","device.model.identifier","device.model.name","faas.name","faas.id","faas.version","faas.instance","faas.max_memory","host.id","host.name","host.type","host.arch","host.image.name","host.image.id","host.image.version","k8s.cluster.name","k8s.node.name","k8s.node.uid","k8s.namespace.name","k8s.pod.uid","k8s.pod.name","k8s.container.name","k8s.replicaset.uid","k8s.replicaset.name","k8s.deployment.uid","k8s.deployment.name","k8s.statefulset.uid","k8s.statefulset.name","k8s.daemonset.uid","k8s.daemonset.name","k8s.job.uid","k8s.job.name","k8s.cronjob.uid","k8s.cronjob.name","os.type","os.description","os.name","os.version","process.pid","process.executable.name","process.executable.path","process.command","process.command_line","process.command_args","process.owner","process.runtime.name","process.runtime.version","process.runtime.description",Wk,"service.namespace","service.instance.id","service.version",Yk,Xk,Qk,"telemetry.auto.version","webengine.name","webengine.version","webengine.description"]),rL=Hk(["cpp","dotnet","erlang","go","java","nodejs","php","python","ruby","webjs"]),oL=((Gk={})[nL.TELEMETRY_SDK_NAME]="opentelemetry",Gk[nL.PROCESS_RUNTIME_NAME]="browser",Gk[nL.TELEMETRY_SDK_LANGUAGE]=rL.WEBJS,Gk[nL.TELEMETRY_SDK_VERSION]="1.24.1",Gk);var iL,aL=Math.pow(10,6),sL=Math.pow(10,9);function lL(e){return[Math.trunc(e/1e3),Math.round(e%1e3*aL)]}function cL(){var e=zk.timeOrigin;if("number"!=typeof e){e=zk.timing&&zk.timing.fetchStart}return e}function uL(e){return gL(lL(cL()),lL("number"==typeof e?e:zk.now()))}function dL(e){if(hL(e))return e;if("number"==typeof e)return e<cL()?uL(e):lL(e);if(e instanceof Date)return lL(e.getTime());throw TypeError("Invalid input type")}function pL(e){return e[0]*sL+e[1]}function fL(e){return 1e6*e[0]+e[1]/1e3}function hL(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}function mL(e){return hL(e)||"number"==typeof e||e instanceof Date}function gL(e,t){var n=[e[0]+t[0],e[1]+t[1]];return n[1]>=sL&&(n[1]-=sL,n[0]+=1),n}!function(e){e[e.SUCCESS=0]="SUCCESS",e[e.FAILED=1]="FAILED"}(iL||(iL={}));var yL=function(){function e(e){var t;void 0===e&&(e={}),this._propagators=null!==(t=e.propagators)&&void 0!==t?t:[],this._fields=Array.from(new Set(this._propagators.map((function(e){return"function"==typeof e.fields?e.fields():[]})).reduce((function(e,t){return e.concat(t)}),[])))}return e.prototype.inject=function(e,t,n){var r,o;try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(this._propagators),a=i.next();!a.done;a=i.next()){var s=a.value;try{s.inject(e,t,n)}catch(l){im.warn("Failed to inject with "+s.constructor.name+". Err: "+l.message)}}}catch(c){r={error:c}}finally{try{a&&!a.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}},e.prototype.extract=function(e,t,n){return this._propagators.reduce((function(e,r){try{return r.extract(e,t,n)}catch(o){im.warn("Failed to inject with "+r.constructor.name+". Err: "+o.message)}return e}),e)},e.prototype.fields=function(){return this._fields.slice()},e}(),vL="[_0-9a-z-*/]",bL=new RegExp("^(?:"+("[a-z]"+vL+"{0,255}")+"|"+("[a-z0-9]"+vL+"{0,240}@[a-z]"+vL+"{0,13}")+")$"),wL=/^[ -~]{0,255}[!-~]$/,xL=/,|=/;var EL=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return bL.test(e)})(o)&&function(e){return wL.test(e)&&!xL.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),_L="traceparent",SL="tracestate",TL=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");var CL=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!hk(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,_L,o),r.traceState&&n.set(t,SL,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,_L);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=function(e){var t=TL.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,SL);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new EL("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[_L,SL]},e}(),AL="[object Null]",OL="[object Undefined]",NL=Function.prototype.toString,RL=NL.call(Object),PL=function(e,t){return function(n){return e(t(n))}}(Object.getPrototypeOf,Object),kL=Object.prototype,LL=kL.hasOwnProperty,ML=Symbol?Symbol.toStringTag:void 0,DL=kL.toString;function jL(e){if(!function(e){return null!=e&&"object"==typeof e}(e)||"[object Object]"!==function(e){if(null==e)return void 0===e?OL:AL;return ML&&ML in Object(e)?function(e){var t=LL.call(e,ML),n=e[ML],r=!1;try{e[ML]=void 0,r=!0}catch(tme){}var o=DL.call(e);r&&(t?e[ML]=n:delete e[ML]);return o}(e):function(e){return DL.call(e)}(e)}(e))return!1;var t=PL(e);if(null===t)return!0;var n=LL.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&NL.call(n)===RL}function IL(e){return $L(e)?e.slice():e}function FL(e,t,n,r){var o;if(void 0===n&&(n=0),!(n>20)){if(n++,qL(e)||qL(t)||BL(t))o=IL(t);else if($L(e)){if(o=e.slice(),$L(t))for(var i=0,a=t.length;i<a;i++)o.push(IL(t[i]));else if(VL(t))for(i=0,a=(s=Object.keys(t)).length;i<a;i++){o[l=s[i]]=IL(t[l])}}else if(VL(e))if(VL(t)){if(!function(e,t){if(!jL(e)||!jL(t))return!1;return!0}(e,t))return t;o=Object.assign({},e);var s;for(i=0,a=(s=Object.keys(t)).length;i<a;i++){var l,c=t[l=s[i]];if(qL(c))void 0===c?delete o[l]:o[l]=c;else{var u=o[l],d=c;if(UL(e,l,r)||UL(t,l,r))delete o[l];else{if(VL(u)&&VL(d)){var p=r.get(u)||[],f=r.get(d)||[];p.push({obj:e,key:l}),f.push({obj:t,key:l}),r.set(u,p),r.set(d,f)}o[l]=FL(o[l],c,n,r)}}}}else o=t;return o}}function UL(e,t,n){for(var r=n.get(e[t])||[],o=0,i=r.length;o<i;o++){var a=r[o];if(a.key===t&&a.obj===e)return!0}return!1}function $L(e){return Array.isArray(e)}function BL(e){return"function"==typeof e}function VL(e){return!qL(e)&&!$L(e)&&!BL(e)&&"object"==typeof e}function qL(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||void 0===e||e instanceof Date||e instanceof RegExp||null===e}var zL=function(){function e(){var e=this;this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))}return Object.defineProperty(e.prototype,"promise",{get:function(){return this._promise},enumerable:!1,configurable:!0}),e.prototype.resolve=function(e){this._resolve(e)},e.prototype.reject=function(e){this._reject(e)},e}(),HL=function(){function e(e,t){this._callback=e,this._that=t,this._isCalled=!1,this._deferred=new zL}return Object.defineProperty(e.prototype,"isCalled",{get:function(){return this._isCalled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"promise",{get:function(){return this._deferred.promise},enumerable:!1,configurable:!0}),e.prototype.call=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];if(!this._isCalled){this._isCalled=!0;try{Promise.resolve((e=this._callback).call.apply(e,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([this._that],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))).then((function(e){return t._deferred.resolve(e)}),(function(e){return t._deferred.reject(e)}))}catch(o){this._deferred.reject(o)}}return this._deferred.promise},e}();var GL,KL={_export:function(e,t){return new Promise((function(n){om.with(fk(om.active()),(function(){e.export(t,(function(e){n(e)}))}))}))}},WL=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},YL=function(){function e(e,t,n,r,o,i,a,s,l,c){void 0===a&&(a=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:Kh.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=n,this._spanContext=r,this.parentSpanId=i,this.kind=o,this.links=a;var u=Date.now();this._performanceStartTime=zk.now(),this._performanceOffset=u-(this._performanceStartTime+cL()),this._startTimeProvided=null!=s,this.startTime=this._getTime(null!=s?s:u),this.resource=e.resource,this.instrumentationLibrary=e.instrumentationLibrary,this._spanLimits=e.getSpanLimits(),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0,null!=c&&this.setAttributes(c),this._spanProcessor=e.getActiveSpanProcessor(),this._spanProcessor.onStart(this,t)}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return null==t||this._isSpanEnded()?this:0===e.length?(im.warn("Invalid attribute key: "+e),this):Ek(t)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,e)?(this._droppedAttributesCount++,this):(this.attributes[e]=this._truncateToSize(t),this):(im.warn("Invalid attribute value set for key: "+e),this)},e.prototype.setAttributes=function(e){var t,n;try{for(var r=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=r.next();!o.done;o=r.next()){var i=WL(o.value,2);this.setAttribute(i[0],i[1])}}catch(a){t={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.addEvent=function(e,t,n){if(this._isSpanEnded())return this;if(0===this._spanLimits.eventCountLimit)return im.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(0===this._droppedEventsCount&&im.debug("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),mL(t)&&(mL(n)||(n=t),t=void 0);var r=wk(t);return this.events.push({name:e,attributes:r,time:this._getTime(n),droppedAttributesCount:0}),this},e.prototype.setStatus=function(e){return this._isSpanEnded()||(this.status=e),this},e.prototype.updateName=function(e){return this._isSpanEnded()||(this.name=e),this},e.prototype.end=function(e){this._isSpanEnded()?im.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once."):(this._ended=!0,this.endTime=this._getTime(e),this._duration=function(e,t){var n=t[0]-e[0],r=t[1]-e[1];return r<0&&(n-=1,r+=sL),[n,r]}(this.startTime,this.endTime),this._duration[0]<0&&(im.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._droppedEventsCount>0&&im.warn("Dropped "+this._droppedEventsCount+" events because eventCountLimit reached"),this._spanProcessor.onEnd(this))},e.prototype._getTime=function(e){if("number"==typeof e&&e<zk.now())return uL(e+this._performanceOffset);if("number"==typeof e)return lL(e);if(e instanceof Date)return lL(e.getTime());if(hL(e))return e;if(this._startTimeProvided)return lL(Date.now());var t=zk.now()-this._performanceStartTime;return gL(this.startTime,lL(t))},e.prototype.isRecording=function(){return!1===this._ended},e.prototype.recordException=function(e,t){var n={};"string"==typeof e?n[Kk.EXCEPTION_MESSAGE]=e:e&&(e.code?n[Kk.EXCEPTION_TYPE]=e.code.toString():e.name&&(n[Kk.EXCEPTION_TYPE]=e.name),e.message&&(n[Kk.EXCEPTION_MESSAGE]=e.message),e.stack&&(n[Kk.EXCEPTION_STACKTRACE]=e.stack)),n[Kk.EXCEPTION_TYPE]||n[Kk.EXCEPTION_MESSAGE]?this.addEvent("exception",n,t):im.warn("Failed to record an exception "+e)},Object.defineProperty(e.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),e.prototype._isSpanEnded=function(){return this._ended&&im.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},e.prototype._truncateToLimitUtil=function(e,t){return e.length<=t?e:e.substr(0,t)},e.prototype._truncateToSize=function(e){var t=this,n=this._attributeValueLengthLimit;return n<=0?(im.warn("Attribute value limit must be positive, got "+n),e):"string"==typeof e?this._truncateToLimitUtil(e,n):Array.isArray(e)?e.map((function(e){return"string"==typeof e?t._truncateToLimitUtil(e,n):e})):e},e}();!function(e){e[e.NOT_RECORD=0]="NOT_RECORD",e[e.RECORD=1]="RECORD",e[e.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"}(GL||(GL={}));var XL=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:GL.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),QL=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:GL.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),ZL=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(Ck(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new QL),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new QL,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new XL,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new QL,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new XL}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),JL=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?GL.RECORD_AND_SAMPLED:GL.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),eM=qk(),tM=Sk.AlwaysOn;function nM(){return{sampler:rM(eM),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:qk().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:qk().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:qk().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:qk().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:qk().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:qk().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:qk().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:qk().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function rM(e){switch(void 0===e&&(e=qk()),e.OTEL_TRACES_SAMPLER){case Sk.AlwaysOn:return new QL;case Sk.AlwaysOff:return new XL;case Sk.ParentBasedAlwaysOn:return new ZL({root:new QL});case Sk.ParentBasedAlwaysOff:return new ZL({root:new XL});case Sk.TraceIdRatio:return new JL(oM(e));case Sk.ParentBasedTraceIdRatio:return new ZL({root:new JL(oM(e))});default:return im.error('OTEL_TRACES_SAMPLER value "'+e.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+tM+'".'),new QL}}function oM(e){if(void 0===e.OTEL_TRACES_SAMPLER_ARG||""===e.OTEL_TRACES_SAMPLER_ARG)return im.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to 1."),1;var t=Number(e.OTEL_TRACES_SAMPLER_ARG);return isNaN(t)?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to 1."),1):t<0||t>1?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to 1."),1):t}function iM(e){var t,n,r,o,i,a,s,l,c,u,d,p,f=Object.assign({},e.spanLimits),h=Bk(Vk);return f.attributeCountLimit=null!==(a=null!==(i=null!==(o=null!==(n=null===(t=e.spanLimits)||void 0===t?void 0:t.attributeCountLimit)&&void 0!==n?n:null===(r=e.generalLimits)||void 0===r?void 0:r.attributeCountLimit)&&void 0!==o?o:h.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)&&void 0!==i?i:h.OTEL_ATTRIBUTE_COUNT_LIMIT)&&void 0!==a?a:Mk,f.attributeValueLengthLimit=null!==(p=null!==(d=null!==(u=null!==(l=null===(s=e.spanLimits)||void 0===s?void 0:s.attributeValueLengthLimit)&&void 0!==l?l:null===(c=e.generalLimits)||void 0===c?void 0:c.attributeValueLengthLimit)&&void 0!==u?u:h.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==d?d:h.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==p?p:Lk,Object.assign({},e,{spanLimits:f})}var aM=function(){function e(e,t){this._exporter=e,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var n=qk();this._maxExportBatchSize="number"==typeof(null==t?void 0:t.maxExportBatchSize)?t.maxExportBatchSize:n.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize="number"==typeof(null==t?void 0:t.maxQueueSize)?t.maxQueueSize:n.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis="number"==typeof(null==t?void 0:t.scheduledDelayMillis)?t.scheduledDelayMillis:n.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis="number"==typeof(null==t?void 0:t.exportTimeoutMillis)?t.exportTimeoutMillis:n.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new HL(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(im.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return e.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){this._shutdownOnce.isCalled||e.spanContext().traceFlags&gh.SAMPLED&&this._addToBuffer(e)},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){var e=this;return Promise.resolve().then((function(){return e.onShutdown()})).then((function(){return e._flushAll()})).then((function(){return e._exporter.shutdown()}))},e.prototype._addToBuffer=function(e){if(this._finishedSpans.length>=this._maxQueueSize)return 0===this._droppedSpansCount&&im.debug("maxQueueSize reached, dropping spans"),void this._droppedSpansCount++;this._droppedSpansCount>0&&(im.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(e),this._maybeStartTimer()},e.prototype._flushAll=function(){var e=this;return new Promise((function(t,n){for(var r=[],o=0,i=Math.ceil(e._finishedSpans.length/e._maxExportBatchSize);o<i;o++)r.push(e._flushOneBatch());Promise.all(r).then((function(){t()})).catch(n)}))},e.prototype._flushOneBatch=function(){var e=this;return this._clearTimer(),0===this._finishedSpans.length?Promise.resolve():new Promise((function(t,n){var r=setTimeout((function(){n(new Error("Timeout"))}),e._exportTimeoutMillis);om.with(fk(om.active()),(function(){var o;e._finishedSpans.length<=e._maxExportBatchSize?(o=e._finishedSpans,e._finishedSpans=[]):o=e._finishedSpans.splice(0,e._maxExportBatchSize);for(var i=function(){return e._exporter.export(o,(function(e){var o;clearTimeout(r),e.code===iL.SUCCESS?t():n(null!==(o=e.error)&&void 0!==o?o:new Error("BatchSpanProcessor: span export failed"))}))},a=null,s=0,l=o.length;s<l;s++){var c=o[s];c.resource.asyncAttributesPending&&c.resource.waitForAsyncAttributes&&(null!=a||(a=[]),a.push(c.resource.waitForAsyncAttributes()))}null===a?i():Promise.all(a).then(i,(function(e){Ck(e),n(e)}))}))}))},e.prototype._maybeStartTimer=function(){var e=this;if(!this._isExporting){var t=function(){e._isExporting=!0,e._flushOneBatch().finally((function(){e._isExporting=!1,e._finishedSpans.length>0&&(e._clearTimer(),e._maybeStartTimer())})).catch((function(t){e._isExporting=!1,Ck(t)}))};if(this._finishedSpans.length>=this._maxExportBatchSize)return t();void 0===this._timer&&(this._timer=setTimeout((function(){return t()}),this._scheduledDelayMillis))}},e.prototype._clearTimer=function(){void 0!==this._timer&&(clearTimeout(this._timer),this._timer=void 0)},e}(),sM=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),lM=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.onInit(n),r}return sM(t,e),t.prototype.onInit=function(e){var t=this;!0!==(null==e?void 0:e.disableAutoFlushOnDocumentHide)&&"undefined"!=typeof document&&(this._visibilityChangeListener=function(){"hidden"===document.visibilityState&&t.forceFlush()},this._pageHideListener=function(){t.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},t.prototype.onShutdown=function(){"undefined"!=typeof document&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},t}(aM),cM=function(){return function(){this.generateTraceId=dM(16),this.generateSpanId=dM(8)}}(),uM=Array(32);function dM(e){return function(){for(var t=0;t<2*e;t++)uM[t]=Math.floor(16*Math.random())+48,uM[t]>=58&&(uM[t]+=39);return String.fromCharCode.apply(null,uM.slice(0,2*e))}}var pM=function(){function e(e,t,n){this._tracerProvider=n;var r,o,i,a,s=(r=t,o={sampler:rM()},i=nM(),(a=Object.assign({},i,o,r)).generalLimits=Object.assign({},i.generalLimits,r.generalLimits||{}),a.spanLimits=Object.assign({},i.spanLimits,r.spanLimits||{}),a);this._sampler=s.sampler,this._generalLimits=s.generalLimits,this._spanLimits=s.spanLimits,this._idGenerator=t.idGenerator||new cM,this.resource=n.resource,this.instrumentationLibrary=e}return e.prototype.startSpan=function(e,t,n){var r,o,i;void 0===t&&(t={}),void 0===n&&(n=om.active()),t.root&&(n=bm.deleteSpan(n));var a=bm.getSpan(n);if(hk(n))return im.debug("Instrumentation suppressed, returning Noop Span"),bm.wrapSpanContext(Ch);var s,l,c,u=null==a?void 0:a.spanContext(),d=this._idGenerator.generateSpanId();u&&bm.isSpanContextValid(u)?(s=u.traceId,l=u.traceState,c=u.spanId):s=this._idGenerator.generateTraceId();var p=null!==(r=t.kind)&&void 0!==r?r:Hh.INTERNAL,f=(null!==(o=t.links)&&void 0!==o?o:[]).map((function(e){return{context:e.context,attributes:wk(e.attributes)}})),h=wk(t.attributes),m=this._sampler.shouldSample(n,s,e,p,h,f);l=null!==(i=m.traceState)&&void 0!==i?i:l;var g={traceId:s,spanId:d,traceFlags:m.decision===qh.RECORD_AND_SAMPLED?gh.SAMPLED:gh.NONE,traceState:l};if(m.decision===qh.NOT_RECORD)return im.debug("Recording is off, propagating context in a non-recording span"),bm.wrapSpanContext(g);var y=wk(Object.assign(h,m.attributes));return new YL(this,n,e,g,p,c,f,t.startTime,void 0,y)},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:om.active(),l=this.startSpan(e,o,s),c=bm.setSpan(s,l);return om.with(c,a,void 0,l)}},e.prototype.getGeneralLimits=function(){return this._generalLimits},e.prototype.getSpanLimits=function(){return this._spanLimits},e.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},e}();var fM,hM=function(){return hM=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},hM.apply(this,arguments)},mM=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},gM=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},yM=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[Zk]="unknown_service",t[eL]=oL[eL],t[Jk]=oL[Jk],t[tL]=oL[tL],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return mM(this,void 0,void 0,(function(){return gM(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=hM(hM({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return hM(hM(hM(hM({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),vM=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},bM=function(){function e(e){this._spanProcessors=e}return e.prototype.forceFlush=function(){var e,t,n=[];try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.forceFlush())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e){Promise.all(n).then((function(){e()})).catch((function(t){Ck(t||new Error("MultiSpanProcessor: forceFlush failed")),e()}))}))},e.prototype.onStart=function(e,t){var n,r;try{for(var o=vM(this._spanProcessors),i=o.next();!i.done;i=o.next()){i.value.onStart(e,t)}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}},e.prototype.onEnd=function(e){var t,n;try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){o.value.onEnd(e)}}catch(i){t={error:i}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.shutdown=function(){var e,t,n=[];try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.shutdown())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e,t){Promise.all(n).then((function(){e()}),t)}))},e}(),wM=function(){function e(){}return e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){},e.prototype.shutdown=function(){return Promise.resolve()},e.prototype.forceFlush=function(){return Promise.resolve()},e}();!function(e){e[e.resolved=0]="resolved",e[e.timeout=1]="timeout",e[e.error=2]="error",e[e.unresolved=3]="unresolved"}(fM||(fM={}));var xM,EM,_M,SM=function(){function e(e){var t;void 0===e&&(e={}),this._registeredSpanProcessors=[],this._tracers=new Map;var n=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e.shift(),r=new WeakMap;e.length>0;)n=FL(n,e.shift(),0,r);return n}({},nM(),iM(e));this.resource=null!==(t=n.resource)&&void 0!==t?t:yM.empty(),this.resource=yM.default().merge(this.resource),this._config=Object.assign({},n,{resource:this.resource});var r=this._buildExporterFromEnv();if(void 0!==r){var o=new lM(r);this.activeSpanProcessor=o}else this.activeSpanProcessor=new wM}return e.prototype.getTracer=function(e,t,n){var r=e+"@"+(t||"")+":"+((null==n?void 0:n.schemaUrl)||"");return this._tracers.has(r)||this._tracers.set(r,new pM({name:e,version:t,schemaUrl:null==n?void 0:n.schemaUrl},this._config,this)),this._tracers.get(r)},e.prototype.addSpanProcessor=function(e){0===this._registeredSpanProcessors.length&&this.activeSpanProcessor.shutdown().catch((function(e){return im.error("Error while trying to shutdown current span processor",e)})),this._registeredSpanProcessors.push(e),this.activeSpanProcessor=new bM(this._registeredSpanProcessors)},e.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},e.prototype.register=function(e){void 0===e&&(e={}),bm.setGlobalTracerProvider(this),void 0===e.propagator&&(e.propagator=this._buildPropagatorFromEnv()),e.contextManager&&om.setGlobalContextManager(e.contextManager),e.propagator&&ym.setGlobalPropagator(e.propagator)},e.prototype.forceFlush=function(){var e=this._config.forceFlushTimeoutMillis,t=this._registeredSpanProcessors.map((function(t){return new Promise((function(n){var r,o=setTimeout((function(){n(new Error("Span processor did not completed within timeout period of "+e+" ms")),r=fM.timeout}),e);t.forceFlush().then((function(){clearTimeout(o),r!==fM.timeout&&n(r=fM.resolved)})).catch((function(e){clearTimeout(o),r=fM.error,n(e)}))}))}));return new Promise((function(e,n){Promise.all(t).then((function(t){var r=t.filter((function(e){return e!==fM.resolved}));r.length>0?n(r):e()})).catch((function(e){return n([e])}))}))},e.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},e.prototype._getPropagator=function(e){var t;return null===(t=this.constructor._registeredPropagators.get(e))||void 0===t?void 0:t()},e.prototype._getSpanExporter=function(e){var t;return null===(t=this.constructor._registeredExporters.get(e))||void 0===t?void 0:t()},e.prototype._buildPropagatorFromEnv=function(){var e=this,t=Array.from(new Set(qk().OTEL_PROPAGATORS)),n=t.map((function(t){var n=e._getPropagator(t);return n||im.warn('Propagator "'+t+'" requested through environment variable is unavailable.'),n})).reduce((function(e,t){return t&&e.push(t),e}),[]);return 0===n.length?void 0:1===t.length?n[0]:new yL({propagators:n})},e.prototype._buildExporterFromEnv=function(){var e=qk().OTEL_TRACES_EXPORTER;if("none"!==e&&""!==e){var t=this._getSpanExporter(e);return t||im.error('Exporter "'+e+'" requested through environment variable is unavailable.'),t}},e._registeredPropagators=new Map([["tracecontext",function(){return new CL}],["baggage",function(){return new yk}]]),e._registeredExporters=new Map,e}(),TM=function(){function e(){}return e.prototype.export=function(e,t){return this._sendSpans(e,t)},e.prototype.shutdown=function(){return this._sendSpans([]),this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype._exportInfo=function(e){var t;return{resource:{attributes:e.resource.attributes},traceId:e.spanContext().traceId,parentId:e.parentSpanId,traceState:null===(t=e.spanContext().traceState)||void 0===t?void 0:t.serialize(),name:e.name,id:e.spanContext().spanId,kind:e.kind,timestamp:fL(e.startTime),duration:fL(e.duration),attributes:e.attributes,status:e.status,events:e.events,links:e.links}},e.prototype._sendSpans=function(e,t){var n,r;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next());}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}if(t)return t({code:iL.SUCCESS})},e}(),CM=function(){function e(){this._finishedSpans=[],this._stopped=!1}return e.prototype.export=function(e,t){var n;if(this._stopped)return t({code:iL.FAILED,error:new Error("Exporter has been stopped")});(n=this._finishedSpans).push.apply(n,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)),setTimeout((function(){return t({code:iL.SUCCESS})}),0)},e.prototype.shutdown=function(){return this._stopped=!0,this._finishedSpans=[],this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype.reset=function(){this._finishedSpans=[]},e.prototype.getFinishedSpans=function(){return this._finishedSpans},e}(),AM=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},OM=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},NM=function(){function e(e){this._exporter=e,this._shutdownOnce=new HL(this._shutdown,this),this._unresolvedExports=new Set}return e.prototype.forceFlush=function(){return AM(this,void 0,void 0,(function(){return OM(this,(function(e){switch(e.label){case 0:return[4,Promise.all(Array.from(this._unresolvedExports))];case 1:return e.sent(),this._exporter.forceFlush?[4,this._exporter.forceFlush()]:[3,3];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){var t,n,r=this;if(!this._shutdownOnce.isCalled&&e.spanContext().traceFlags&gh.SAMPLED){var o=function(){return KL._export(r._exporter,[e]).then((function(e){var t;e.code!==iL.SUCCESS&&Ck(null!==(t=e.error)&&void 0!==t?t:new Error("SimpleSpanProcessor: span export failed (status "+e+")"))})).catch((function(e){Ck(e)}))};if(e.resource.asyncAttributesPending){var i=null===(n=(t=e.resource).waitForAsyncAttributes)||void 0===n?void 0:n.call(t).then((function(){return null!=i&&r._unresolvedExports.delete(i),o()}),(function(e){return Ck(e)}));null!=i&&this._unresolvedExports.add(i)}else o()}},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){return this._exporter.shutdown()},e}(),RM=function(){function e(){this._enabled=!1,this._currentContext=Xf}return e.prototype._bindFunction=function(e,t){void 0===e&&(e=Xf);var n=this,r=function(){for(var r=this,o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];return n.with(e,(function(){return t.apply(r,o)}))};return Object.defineProperty(r,"length",{enumerable:!1,configurable:!0,writable:!1,value:t.length}),r},e.prototype.active=function(){return this._currentContext},e.prototype.bind=function(e,t){return void 0===e&&(e=this.active()),"function"==typeof t?this._bindFunction(e,t):t},e.prototype.disable=function(){return this._currentContext=Xf,this._enabled=!1,this},e.prototype.enable=function(){return this._enabled||(this._enabled=!0,this._currentContext=Xf),this},e.prototype.with=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=this._currentContext;this._currentContext=e||Xf;try{return t.call.apply(t,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(r),!1))}finally{this._currentContext=i}},e}(),PM=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kM=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;if(t.contextManager)throw"contextManager should be defined in register method not in constructor";if(t.propagator)throw"propagator should be defined in register method not in constructor";return n}return PM(t,e),t.prototype.register=function(t){void 0===t&&(t={}),void 0===t.contextManager&&(t.contextManager=new RM),t.contextManager&&t.contextManager.enable(),e.prototype.register.call(this,t)},t}(SM);function LM(e,t){return t in e}function MM(e,t,n,r){var o=void 0,i=void 0;LM(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=r||xM.FETCH_START;if(LM(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function DM(e,t){MM(e,xM.FETCH_START,t),MM(e,xM.DOMAIN_LOOKUP_START,t),MM(e,xM.DOMAIN_LOOKUP_END,t),MM(e,xM.CONNECT_START,t),LM(t,"name")&&t.name.startsWith("https:")&&MM(e,xM.SECURE_CONNECTION_START,t),MM(e,xM.CONNECT_END,t),MM(e,xM.REQUEST_START,t),MM(e,xM.RESPONSE_START,t),MM(e,xM.RESPONSE_END,t);var n=t[xM.ENCODED_BODY_SIZE];void 0!==n&&e.setAttribute(Kk.HTTP_RESPONSE_CONTENT_LENGTH,n);var r=t[xM.DECODED_BODY_SIZE];void 0!==r&&n!==r&&e.setAttribute(Kk.HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED,r)}function jM(e){return e.slice().sort((function(e,t){var n=e[xM.FETCH_START],r=t[xM.FETCH_START];return n>r?1:n<r?-1:0}))}function IM(){return"undefined"!=typeof location?location.origin:void 0}function FM(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(_M||(_M=document.createElement("a")),_M);return t.href=e,t}function UM(e,t){if(e.nodeType===Node.DOCUMENT_NODE)return"/";var n=function(e,t){var n=e.nodeType,r=function(e){if(!e.parentNode)return 0;var t=[e.nodeType];e.nodeType===Node.CDATA_SECTION_NODE&&t.push(Node.TEXT_NODE);var n=Array.from(e.parentNode.childNodes);if(n=n.filter((function(n){var r=n.localName;return t.indexOf(n.nodeType)>=0&&r===e.localName})),n.length>=1)return n.indexOf(e)+1;return 0}(e),o="";if(n===Node.ELEMENT_NODE){var i=e.getAttribute("id");if(t&&i)return'//*[@id="'+i+'"]';o=e.localName}else if(n===Node.TEXT_NODE||n===Node.CDATA_SECTION_NODE)o="text()";else{if(n!==Node.COMMENT_NODE)return"";o="comment()"}if(o&&r>1)return"/"+o+"["+r+"]";return"/"+o}(e,t);if(t&&n.indexOf("@id")>0)return n;var r="";return e.parentNode&&(r+=UM(e.parentNode,!1)),r+=n}(EM=xM||(xM={})).CONNECT_END="connectEnd",EM.CONNECT_START="connectStart",EM.DECODED_BODY_SIZE="decodedBodySize",EM.DOM_COMPLETE="domComplete",EM.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",EM.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",EM.DOM_INTERACTIVE="domInteractive",EM.DOMAIN_LOOKUP_END="domainLookupEnd",EM.DOMAIN_LOOKUP_START="domainLookupStart",EM.ENCODED_BODY_SIZE="encodedBodySize",EM.FETCH_START="fetchStart",EM.LOAD_EVENT_END="loadEventEnd",EM.LOAD_EVENT_START="loadEventStart",EM.NAVIGATION_START="navigationStart",EM.REDIRECT_END="redirectEnd",EM.REDIRECT_START="redirectStart",EM.REQUEST_START="requestStart",EM.RESPONSE_END="responseEnd",EM.RESPONSE_START="responseStart",EM.SECURE_CONNECTION_START="secureConnectionStart",EM.UNLOAD_EVENT_END="unloadEventEnd",EM.UNLOAD_EVENT_START="unloadEventStart";const $M=za(Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:XL,AlwaysOnSampler:QL,BasicTracerProvider:SM,BatchSpanProcessor:lM,ConsoleSpanExporter:TM,get ForceFlushState(){return fM},InMemorySpanExporter:CM,NoopSpanProcessor:wM,ParentBasedSampler:ZL,get PerformanceTimingNames(){return xM},RandomIdGenerator:cM,get SamplingDecision(){return GL},SimpleSpanProcessor:NM,Span:YL,StackContextManager:RM,TraceIdRatioBasedSampler:JL,Tracer:pM,WebTracerProvider:kM,addSpanNetworkEvent:MM,addSpanNetworkEvents:DM,getElementXPath:UM,getResource:function(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=FM(e),s=function(e,t,n,r,o,i){var a=pL(t),s=pL(n),l=r.filter((function(t){var n=pL(dL(t[xM.FETCH_START])),r=pL(dL(t[xM.RESPONSE_END]));return t.initiatorType.toLowerCase()===(i||"xmlhttprequest")&&t.name===e&&n>=a&&r<=s}));l.length>0&&(l=l.filter((function(e){return!o.has(e)})));return l}(e=a.toString(),t,n,r,o,i);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=jM(s);if(a.origin!==IM()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=pL(n),i=pL(dL(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=pL(dL(c[xM.FETCH_START])),d=o-pL(dL(c[xM.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[xM.RESPONSE_END],n);return u[xM.FETCH_START]<c[xM.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}},hasKey:LM,normalizeUrl:function(e){return FM(e).href},parseUrl:FM,shouldPropagateTraceHeaders:function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),FM(e).origin===IM()||n.some((function(t){return n=e,"string"==typeof(r=t)?n===r:!!n.match(r);var n,r}))},sortResources:jM},Symbol.toStringTag,{value:"Module"}))),BM=za(uN);var VM={};Object.defineProperty(VM,"__esModule",{value:!0}),VM.SessionIdSpanProcessor=void 0;const qM=Array(32);function zM(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}VM.SessionIdSpanProcessor=class{constructor(){var e;this._idGenerator=(e=16,function(){for(let t=0;t<2*e;t++)qM[t]=Math.floor(16*Math.random())+48,qM[t]>=58&&(qM[t]+=39);return String.fromCharCode.apply(null,qM.slice(0,2*e))}),this._sessionId=this._idGenerator()}onStart(e){e.setAttribute("session.id",this._sessionId)}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var HM,GM="service.name",KM="telemetry.sdk.name",WM="telemetry.sdk.language",YM="telemetry.sdk.version",XM=GM,QM=KM,ZM=WM,JM=YM,eD=zM(["cloud.provider","cloud.account.id","cloud.region","cloud.availability_zone","cloud.platform","aws.ecs.container.arn","aws.ecs.cluster.arn","aws.ecs.launchtype","aws.ecs.task.arn","aws.ecs.task.family","aws.ecs.task.revision","aws.eks.cluster.arn","aws.log.group.names","aws.log.group.arns","aws.log.stream.names","aws.log.stream.arns","container.name","container.id","container.runtime","container.image.name","container.image.tag","deployment.environment","device.id","device.model.identifier","device.model.name","faas.name","faas.id","faas.version","faas.instance","faas.max_memory","host.id","host.name","host.type","host.arch","host.image.name","host.image.id","host.image.version","k8s.cluster.name","k8s.node.name","k8s.node.uid","k8s.namespace.name","k8s.pod.uid","k8s.pod.name","k8s.container.name","k8s.replicaset.uid","k8s.replicaset.name","k8s.deployment.uid","k8s.deployment.name","k8s.statefulset.uid","k8s.statefulset.name","k8s.daemonset.uid","k8s.daemonset.name","k8s.job.uid","k8s.job.name","k8s.cronjob.uid","k8s.cronjob.name","os.type","os.description","os.name","os.version","process.pid","process.executable.name","process.executable.path","process.command","process.command_line","process.command_args","process.owner","process.runtime.name","process.runtime.version","process.runtime.description",GM,"service.namespace","service.instance.id","service.version",KM,WM,YM,"telemetry.auto.version","webengine.name","webengine.version","webengine.description"]),tD=zM(["cpp","dotnet","erlang","go","java","nodejs","php","python","ruby","webjs"]),nD=((HM={})[eD.TELEMETRY_SDK_NAME]="opentelemetry",HM[eD.PROCESS_RUNTIME_NAME]="browser",HM[eD.TELEMETRY_SDK_LANGUAGE]=tD.WEBJS,HM[eD.TELEMETRY_SDK_VERSION]="1.24.1",HM);var rD=function(){return rD=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},rD.apply(this,arguments)},oD=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},iD=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},aD=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[XM]="unknown_service",t[ZM]=nD[ZM],t[QM]=nD[QM],t[JM]=nD[JM],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return oD(this,void 0,void 0,(function(){return iD(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=rD(rD({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return rD(rD(rD(rD({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),sD="browser.platform",lD="browser.brands",cD="browser.mobile",uD="browser.language",dD="browser.user_agent",pD=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},fD=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};var hD=new(function(){function e(){}return e.prototype.detect=function(e){return pD(this,void 0,void 0,(function(){var t;return fD(this,(function(n){return"undefined"!=typeof navigator?(t=function(){var e={},t=navigator.userAgentData;t?(e[sD]=t.platform,e[lD]=t.brands.map((function(e){return e.brand+" "+e.version})),e[cD]=t.mobile):e[dD]=navigator.userAgent;return e[uD]=navigator.language,e}(),[2,this._getResourceAttributes(t,e)]):[2,aD.empty()]}))}))},e.prototype._getResourceAttributes=function(e,t){return e[dD]||e[sD]?new aD(e):(im.debug("BrowserDetector failed: Unable to find required browser resources. "),aD.empty())},e}());const mD=za(Object.freeze(Object.defineProperty({__proto__:null,browserDetector:hD},Symbol.toStringTag,{value:"Module"})));Object.defineProperty(Cf,"__esModule",{value:!0}),Cf.WebSDK=void 0;const gD=qm,yD=MP,vD=dk,bD=$M,wD=BM,xD=VM,ED=mD;Cf.WebSDK=class{constructor(e={}){var t,n,r,o;if(this._resource=null!==(t=e.resource)&&void 0!==t?t:new yD.Resource({}),this._resourceDetectors=null!==(n=e.resourceDetectors)&&void 0!==n?n:[ED.browserDetector],this._serviceName=e.serviceName,this._autoDetectResources=null===(r=e.autoDetectResources)||void 0===r||r,e.spanProcessor||e.traceExporter){const t={};e.sampler&&(t.sampler=e.sampler),e.spanLimits&&(t.spanLimits=e.spanLimits),e.idGenerator&&(t.idGenerator=e.idGenerator);const n=null!==(o=e.spanProcessor)&&void 0!==o?o:new vD.BatchSpanProcessor(e.traceExporter);this._tracerProviderConfig={tracerConfig:t,spanProcessor:n,contextManager:e.contextManager,textMapPropagator:e.textMapPropagator}}let i=[];e.instrumentations&&(i=e.instrumentations),this._instrumentations=i}start(){var e,t,n;if(this._disabled)return;if((0,gD.registerInstrumentations)({instrumentations:this._instrumentations}),this._autoDetectResources){this._resource=this._resource.merge((0,yD.detectResourcesSync)({detectors:this._resourceDetectors}))}this._resource=void 0===this._serviceName?this._resource:this._resource.merge(new yD.Resource({[wD.SEMRESATTRS_SERVICE_NAME]:this._serviceName}));const r=new bD.WebTracerProvider(Object.assign(Object.assign({},null===(e=this._tracerProviderConfig)||void 0===e?void 0:e.tracerConfig),{resource:this._resource}));this._tracerProvider=r,this._tracerProviderConfig&&r.addSpanProcessor(this._tracerProviderConfig.spanProcessor),r.register({contextManager:null===(t=this._tracerProviderConfig)||void 0===t?void 0:t.contextManager,propagator:null===(n=this._tracerProviderConfig)||void 0===n?void 0:n.textMapPropagator}),r.addSpanProcessor(new xD.SessionIdSpanProcessor)}getResourceAttributes(){return this._resource.attributes}shutdown(){const e=[];return this._tracerProvider&&e.push(this._tracerProvider.shutdown()),Promise.all(e).then((()=>{}))}};var _D={},SD={},TD={};Object.defineProperty(TD,"__esModule",{value:!0}),TD.VERSION=void 0,TD.VERSION="0.3.0",Object.defineProperty(SD,"__esModule",{value:!0}),SD.configureHoneycombResource=void 0;const CD=MP,AD=TD;SD.configureHoneycombResource=function(){return new CD.Resource({"honeycomb.distro.version":AD.VERSION,"honeycomb.distro.runtime_version":"browser"})};var OD={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.configureEntryPageResource=e.defaultConfig=void 0;const t=MP;function n(e,t){if(e)return t}e.defaultConfig={path:!0,hash:!0,hostname:!0,referrer:!0,url:!1,search:!1},e.configureEntryPageResource=function(r){if(!1===r||!(null===window||void 0===window?void 0:window.location))return new t.Resource({});const o=function(t){if(!t)return e.defaultConfig;return Object.assign(Object.assign({},e.defaultConfig),t)}(r),{href:i,pathname:a,search:s,hash:l,hostname:c}=window.location,u={"entry_page.url":n(o.url,i),"entry_page.path":n(o.path,a),"entry_page.search":n(o.search,s),"entry_page.hash":n(o.hash,l),"entry_page.hostname":n(o.hostname,c),"entry_page.referrer":n(o.referrer,document.referrer)};return new t.Resource(u)}}(OD);var ND,RD,PD={},kD={exports:{}};ND=kD,RD=kD.exports,function(e,t){var n="function",r="undefined",o="object",i="string",a="major",s="model",l="name",c="type",u="vendor",d="version",p="architecture",f="console",h="mobile",m="tablet",g="smarttv",y="wearable",v="embedded",b="Amazon",w="Apple",x="ASUS",E="BlackBerry",_="Browser",S="Chrome",T="Firefox",C="Google",A="Huawei",O="LG",N="Microsoft",R="Motorola",P="Opera",k="Samsung",L="Sharp",M="Sony",D="Xiaomi",j="Zebra",I="Facebook",F="Chromium OS",U="Mac OS",$=" Browser",B=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},V=function(e,t){return typeof e===i&&-1!==q(t).indexOf(q(e))},q=function(e){return e.toLowerCase()},z=function(e,t){if(typeof e===i)return e=e.replace(/^\s\s*/,""),typeof t===r?e:e.substring(0,500)},H=function(e,r){for(var i,a,s,l,c,u,d=0;d<r.length&&!c;){var p=r[d],f=r[d+1];for(i=a=0;i<p.length&&!c&&p[i];)if(c=p[i++].exec(e))for(s=0;s<f.length;s++)u=c[++a],typeof(l=f[s])===o&&l.length>0?2===l.length?this[l[0]]=typeof l[1]==n?l[1].call(this,u):l[1]:3===l.length?this[l[0]]=typeof l[1]!==n||l[1].exec&&l[1].test?u?u.replace(l[1],l[2]):t:u?l[1].call(this,u,l[2]):t:4===l.length&&(this[l[0]]=u?l[3].call(this,u.replace(l[1],l[2])):t):this[l]=u||t;d+=2}},G=function(e,n){for(var r in n)if(typeof n[r]===o&&n[r].length>0){for(var i=0;i<n[r].length;i++)if(V(n[r][i],e))return"?"===r?t:r}else if(V(n[r],e))return"?"===r?t:r;return n.hasOwnProperty("*")?n["*"]:e},K={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},W={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[d,[l,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[d,[l,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[l,d],[/opios[\/ ]+([\w\.]+)/i],[d,[l,P+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[d,[l,P+" GX"]],[/\bopr\/([\w\.]+)/i],[d,[l,P]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[d,[l,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[d,[l,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[l,d],[/quark(?:pc)?\/([-\w\.]+)/i],[d,[l,"Quark"]],[/\bddg\/([\w\.]+)/i],[d,[l,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[d,[l,"UC"+_]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[d,[l,"WeChat"]],[/konqueror\/([\w\.]+)/i],[d,[l,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[d,[l,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[d,[l,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[d,[l,"Smart Lenovo "+_]],[/(avast|avg)\/([\w\.]+)/i],[[l,/(.+)/,"$1 Secure "+_],d],[/\bfocus\/([\w\.]+)/i],[d,[l,T+" Focus"]],[/\bopt\/([\w\.]+)/i],[d,[l,P+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[d,[l,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[d,[l,"Dolphin"]],[/coast\/([\w\.]+)/i],[d,[l,P+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[d,[l,"MIUI"+$]],[/fxios\/([\w\.-]+)/i],[d,[l,T]],[/\bqihoobrowser\/?([\w\.]*)/i],[d,[l,"360"]],[/\b(qq)\/([\w\.]+)/i],[[l,/(.+)/,"$1Browser"],d],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[l,/(.+)/,"$1"+$],d],[/samsungbrowser\/([\w\.]+)/i],[d,[l,k+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[d,[l,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[l,"Sogou Mobile"],d],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[l,d],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[l],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[d,l],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[l,I],d],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[l,d],[/\bgsa\/([\w\.]+) .*safari\//i],[d,[l,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[d,[l,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[d,[l,S+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[l,S+" WebView"],d],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[d,[l,"Android "+_]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[l,d],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[d,[l,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[d,l],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[l,[d,G,{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[l,d],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[l,"Netscape"],d],[/(wolvic|librewolf)\/([\w\.]+)/i],[l,d],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[d,[l,T+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i],[l,[d,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[l,[d,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[p,"amd64"]],[/(ia32(?=;))/i],[[p,q]],[/((?:i[346]|x)86)[;\)]/i],[[p,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[p,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[p,"armhf"]],[/windows (ce|mobile); ppc;/i],[[p,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[p,/ower/,"",q]],[/(sun4\w)[;\)]/i],[[p,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[p,q]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[s,[u,k],[c,m]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[s,[u,k],[c,h]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[s,[u,w],[c,h]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[s,[u,w],[c,m]],[/(macintosh);/i],[s,[u,w]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[s,[u,L],[c,h]],[/(?:honor)([-\w ]+)[;\)]/i],[s,[u,"Honor"],[c,h]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[s,[u,A],[c,m]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[s,[u,A],[c,h]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[s,/_/g," "],[u,D],[c,h]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[s,/_/g," "],[u,D],[c,m]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[s,[u,"OPPO"],[c,h]],[/\b(opd2\d{3}a?) bui/i],[s,[u,"OPPO"],[c,m]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[s,[u,"Vivo"],[c,h]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[s,[u,"Realme"],[c,h]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[s,[u,R],[c,h]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[s,[u,R],[c,m]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[s,[u,O],[c,m]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[s,[u,O],[c,h]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[s,[u,"Lenovo"],[c,m]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[s,/_/g," "],[u,"Nokia"],[c,h]],[/(pixel c)\b/i],[s,[u,C],[c,m]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[s,[u,C],[c,h]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[s,[u,M],[c,h]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[s,"Xperia Tablet"],[u,M],[c,m]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[s,[u,"OnePlus"],[c,h]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[s,[u,b],[c,m]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[s,/(.+)/g,"Fire Phone $1"],[u,b],[c,h]],[/(playbook);[-\w\),; ]+(rim)/i],[s,u,[c,m]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[s,[u,E],[c,h]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[s,[u,x],[c,m]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[s,[u,x],[c,h]],[/(nexus 9)/i],[s,[u,"HTC"],[c,m]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[u,[s,/_/g," "],[c,h]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[s,[u,"TCL"],[c,m]],[/(itel) ((\w+))/i],[[u,q],s,[c,G,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[s,[u,"Acer"],[c,m]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[s,[u,"Meizu"],[c,h]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[s,[u,"Ulefone"],[c,h]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[s,[u,"Energizer"],[c,h]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[s,[u,"Cat"],[c,h]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[s,[u,"Smartfren"],[c,h]],[/droid.+; (a(?:015|06[35]|142p?))/i],[s,[u,"Nothing"],[c,h]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[u,s,[c,h]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[u,s,[c,m]],[/(surface duo)/i],[s,[u,N],[c,m]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[s,[u,"Fairphone"],[c,h]],[/(u304aa)/i],[s,[u,"AT&T"],[c,h]],[/\bsie-(\w*)/i],[s,[u,"Siemens"],[c,h]],[/\b(rct\w+) b/i],[s,[u,"RCA"],[c,m]],[/\b(venue[\d ]{2,7}) b/i],[s,[u,"Dell"],[c,m]],[/\b(q(?:mv|ta)\w+) b/i],[s,[u,"Verizon"],[c,m]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[s,[u,"Barnes & Noble"],[c,m]],[/\b(tm\d{3}\w+) b/i],[s,[u,"NuVision"],[c,m]],[/\b(k88) b/i],[s,[u,"ZTE"],[c,m]],[/\b(nx\d{3}j) b/i],[s,[u,"ZTE"],[c,h]],[/\b(gen\d{3}) b.+49h/i],[s,[u,"Swiss"],[c,h]],[/\b(zur\d{3}) b/i],[s,[u,"Swiss"],[c,m]],[/\b((zeki)?tb.*\b) b/i],[s,[u,"Zeki"],[c,m]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[u,"Dragon Touch"],s,[c,m]],[/\b(ns-?\w{0,9}) b/i],[s,[u,"Insignia"],[c,m]],[/\b((nxa|next)-?\w{0,9}) b/i],[s,[u,"NextBook"],[c,m]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[u,"Voice"],s,[c,h]],[/\b(lvtel\-)?(v1[12]) b/i],[[u,"LvTel"],s,[c,h]],[/\b(ph-1) /i],[s,[u,"Essential"],[c,h]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[s,[u,"Envizen"],[c,m]],[/\b(trio[-\w\. ]+) b/i],[s,[u,"MachSpeed"],[c,m]],[/\btu_(1491) b/i],[s,[u,"Rotor"],[c,m]],[/(shield[\w ]+) b/i],[s,[u,"Nvidia"],[c,m]],[/(sprint) (\w+)/i],[u,s,[c,h]],[/(kin\.[onetw]{3})/i],[[s,/\./g," "],[u,N],[c,h]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[s,[u,j],[c,m]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[s,[u,j],[c,h]],[/smart-tv.+(samsung)/i],[u,[c,g]],[/hbbtv.+maple;(\d+)/i],[[s,/^/,"SmartTV"],[u,k],[c,g]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[u,O],[c,g]],[/(apple) ?tv/i],[u,[s,w+" TV"],[c,g]],[/crkey/i],[[s,S+"cast"],[u,C],[c,g]],[/droid.+aft(\w+)( bui|\))/i],[s,[u,b],[c,g]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[s,[u,L],[c,g]],[/(bravia[\w ]+)( bui|\))/i],[s,[u,M],[c,g]],[/(mitv-\w{5}) bui/i],[s,[u,D],[c,g]],[/Hbbtv.*(technisat) (.*);/i],[u,s,[c,g]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[u,z],[s,z],[c,g]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[c,g]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[u,s,[c,f]],[/droid.+; (shield) bui/i],[s,[u,"Nvidia"],[c,f]],[/(playstation [345portablevi]+)/i],[s,[u,M],[c,f]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[s,[u,N],[c,f]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[s,[u,k],[c,y]],[/((pebble))app/i],[u,s,[c,y]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[s,[u,w],[c,y]],[/droid.+; (glass) \d/i],[s,[u,C],[c,y]],[/droid.+; (wt63?0{2,3})\)/i],[s,[u,j],[c,y]],[/droid.+; (glass) \d/i],[s,[u,C],[c,y]],[/(pico) (4|neo3(?: link|pro)?)/i],[u,s,[c,y]],[/; (quest( \d| pro)?)/i],[s,[u,I],[c,y]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[u,[c,v]],[/(aeobc)\b/i],[s,[u,b],[c,v]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[s,[c,h]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[s,[c,m]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[c,m]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[c,h]],[/(android[-\w\. ]{0,9});.+buil/i],[s,[u,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[d,[l,"EdgeHTML"]],[/(arkweb)\/([\w\.]+)/i],[l,d],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[d,[l,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[l,d],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[d,l]],os:[[/microsoft (windows) (vista|xp)/i],[l,d],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[l,[d,G,K]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[d,G,K],[l,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[d,/_/g,"."],[l,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[l,U],[d,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[d,l],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[l,d],[/\(bb(10);/i],[d,[l,E]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[d,[l,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[d,[l,T+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[d,[l,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[d,[l,"watchOS"]],[/crkey\/([\d\.]+)/i],[d,[l,S+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[l,F],d],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[l,d],[/(sunos) ?([\w\.\d]*)/i],[[l,"Solaris"],d],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[l,d]]},Y=function(f,g){if(typeof f===o&&(g=f,f=t),!(this instanceof Y))return new Y(f,g).getResult();var y=typeof e!==r&&e.navigator?e.navigator:t,v=f||(y&&y.userAgent?y.userAgent:""),b=y&&y.userAgentData?y.userAgentData:t,w=g?function(e,t){var n={};for(var r in e)n[r]=t[r]&&t[r].length%2==0?t[r].concat(e[r]):e[r];return n}(W,g):W,x=y&&y.userAgent==v;return this.getBrowser=function(){var e,r={};return r[l]=t,r[d]=t,H.call(r,v,w.browser),r[a]=typeof(e=r[d])===i?e.replace(/[^\d\.]/g,"").split(".")[0]:t,x&&y&&y.brave&&typeof y.brave.isBrave==n&&(r[l]="Brave"),r},this.getCPU=function(){var e={};return e[p]=t,H.call(e,v,w.cpu),e},this.getDevice=function(){var e={};return e[u]=t,e[s]=t,e[c]=t,H.call(e,v,w.device),x&&!e[c]&&b&&b.mobile&&(e[c]=h),x&&"Macintosh"==e[s]&&y&&typeof y.standalone!==r&&y.maxTouchPoints&&y.maxTouchPoints>2&&(e[s]="iPad",e[c]=m),e},this.getEngine=function(){var e={};return e[l]=t,e[d]=t,H.call(e,v,w.engine),e},this.getOS=function(){var e={};return e[l]=t,e[d]=t,H.call(e,v,w.os),x&&!e[l]&&b&&b.platform&&"Unknown"!=b.platform&&(e[l]=b.platform.replace(/chrome os/i,F).replace(/macos/i,U)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return v},this.setUA=function(e){return v=typeof e===i&&e.length>500?z(e,500):e,this},this.setUA(v),this};Y.VERSION="1.0.40",Y.BROWSER=B([l,d,a]),Y.CPU=B([p]),Y.DEVICE=B([s,u,c,f,h,g,m,y,v]),Y.ENGINE=Y.OS=B([l,d]),ND.exports&&(RD=ND.exports=Y),RD.UAParser=Y;var X=typeof e!==r&&(e.jQuery||e.Zepto);if(X&&!X.ua){var Q=new Y;X.ua=Q.getResult(),X.ua.get=function(){return Q.getUA()},X.ua.set=function(e){Q.setUA(e);var t=Q.getResult();for(var n in t)X.ua[n]=t[n]}}}("object"==typeof window?window:Va);var LD=kD.exports;!function(e){var t=Va&&Va.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.configureBrowserAttributesResource=e.computeDeviceProperties=e.computeNetworkType=e.computeScreenSize=void 0;const n=MP,r=t(LD);e.computeScreenSize=e=>e<=768?"small":e>768&&e<=1024?"medium":e>1024?"large":"unknown";e.computeNetworkType=e=>{var t;return null!==(t=null==e?void 0:e.effectiveType)&&void 0!==t?t:"unknown"};e.computeDeviceProperties=e=>{const t=new r.default(e),{name:n,version:o}=t.getBrowser();return{browserName:null!=n?n:"unknown",browserVersion:null!=o?o:"unknown",deviceType:(i=t.getDevice().type,a=n,i||a?i||"desktop":"unknown")};var i,a},e.configureBrowserAttributesResource=function(){const{browserName:t,browserVersion:r,deviceType:o}=(0,e.computeDeviceProperties)(navigator.userAgent);return new n.Resource({"user_agent.original":navigator.userAgent,"browser.mobile":navigator.userAgent.includes("Mobi"),"browser.touch_screen_enabled":navigator.maxTouchPoints>0,"browser.language":navigator.language,"browser.name":t,"browser.version":r,"device.type":o,"network.effectiveType":(0,e.computeNetworkType)(navigator.connection),"screen.width":window.screen.width,"screen.height":window.screen.height,"screen.size":(0,e.computeScreenSize)(window.screen.width)})}}(PD);var MD={};Object.defineProperty(MD,"__esModule",{value:!0}),MD.mergeResources=void 0;const DD=MP;function jD(e){return e instanceof DD.Resource?e:new DD.Resource(e||{})}MD.mergeResources=function(e){let t=jD(e[0]);for(let n=1;n<e.length;n++){if(!e[n])continue;const r=jD(e[n]);t=t.merge(r)}return t};var ID={};const FD=za(xm);var UD={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getSampleRate=e.getTracesApiKey=e.getTracesEndpoint=e.maybeAppendTracesPath=e.isClassic=e.createHoneycombSDKLogMessage=e.defaultOptions=e.DEFAULT_SAMPLE_RATE=e.DEFAULT_SERVICE_NAME=e.DEFAULT_TRACES_ENDPOINT=e.TRACES_PATH=e.DEFAULT_API_ENDPOINT=void 0,e.DEFAULT_API_ENDPOINT="https://api.honeycomb.io",e.TRACES_PATH="v1/traces",e.DEFAULT_TRACES_ENDPOINT=`${e.DEFAULT_API_ENDPOINT}/${e.TRACES_PATH}`,e.DEFAULT_SERVICE_NAME="unknown_service",e.DEFAULT_SAMPLE_RATE=1,e.defaultOptions={apiKey:"",tracesApiKey:"",endpoint:e.DEFAULT_TRACES_ENDPOINT,tracesEndpoint:e.DEFAULT_TRACES_ENDPOINT,serviceName:e.DEFAULT_SERVICE_NAME,debug:!1,sampleRate:1,skipOptionsValidation:!1,localVisualizations:!1,webVitalsInstrumentationConfig:{enabled:!0}};e.createHoneycombSDKLogMessage=e=>`@honeycombio/opentelemetry-web: ${e}`;const t=/^[a-f0-9]*$/,n=/^hc[a-z]ic_[a-z0-9]*$/;function r(t){return t.endsWith(e.TRACES_PATH)||t.endsWith(`${e.TRACES_PATH}/`)?t:t.endsWith("/")?t+e.TRACES_PATH:t+"/"+e.TRACES_PATH}e.isClassic=function(e){return null!=e&&0!==e.length&&(32===e.length?t.test(e):64===e.length&&n.test(e))},e.maybeAppendTracesPath=r;e.getTracesEndpoint=t=>(null==t?void 0:t.tracesEndpoint)?t.tracesEndpoint:(null==t?void 0:t.endpoint)?r(t.endpoint):e.DEFAULT_TRACES_ENDPOINT;e.getTracesApiKey=e=>(null==e?void 0:e.tracesApiKey)||(null==e?void 0:e.apiKey);e.getSampleRate=t=>"number"==typeof(null==t?void 0:t.sampleRate)&&Number.isSafeInteger(null==t?void 0:t.sampleRate)&&(null==t?void 0:t.sampleRate)>=0?null==t?void 0:t.sampleRate:e.DEFAULT_SAMPLE_RATE}(UD);var $D={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateOptionsWarnings=e.FAILED_AUTH_FOR_LOCAL_VISUALIZATIONS=e.MISSING_FIELDS_FOR_LOCAL_VISUALIZATIONS=e.SAMPLER_OVERRIDE_WARNING=e.SKIPPING_OPTIONS_VALIDATION_MSG=e.MISSING_DATASET_ERROR=e.IGNORED_DATASET_ERROR=e.MISSING_SERVICE_NAME_ERROR=e.MISSING_API_KEY_ERROR=void 0;const t=UD;e.MISSING_API_KEY_ERROR=(0,t.createHoneycombSDKLogMessage)("❌ Missing API Key. Set `apiKey` in HoneycombOptions. Telemetry will not be exported."),e.MISSING_SERVICE_NAME_ERROR=(0,t.createHoneycombSDKLogMessage)(`❌ Missing Service Name. Set \`serviceName\` in HoneycombOptions. Defaulting to '${t.defaultOptions.serviceName}'`),e.IGNORED_DATASET_ERROR=(0,t.createHoneycombSDKLogMessage)("🔕 Dataset is ignored in favor of service name."),e.MISSING_DATASET_ERROR=(0,t.createHoneycombSDKLogMessage)("❌ Missing dataset. Specify either HONEYCOMB_DATASET environment variable or dataset in the options parameter."),e.SKIPPING_OPTIONS_VALIDATION_MSG=(0,t.createHoneycombSDKLogMessage)("⏭️ Skipping options validation. To re-enable, set skipOptionsValidation option or HONEYCOMB_SKIP_OPTIONS_VALIDATION to false."),e.SAMPLER_OVERRIDE_WARNING=(0,t.createHoneycombSDKLogMessage)("🔨 Default deterministic sampler has been overridden. Honeycomb requires a resource attribute called SampleRate to properly show weighted values. Non-deterministic sampleRate could lead to missing spans in Honeycomb. See our docs for more details. https://docs.honeycomb.io/getting-data-in/opentelemetry/node-distro/#sampling-without-the-honeycomb-sdk"),e.MISSING_FIELDS_FOR_LOCAL_VISUALIZATIONS=(0,t.createHoneycombSDKLogMessage)("🔕 Disabling local visualizations - must have both service name and API key configured."),e.FAILED_AUTH_FOR_LOCAL_VISUALIZATIONS=(0,t.createHoneycombSDKLogMessage)("🔕 Failed to get proper auth response from Honeycomb. No local visualization available.");e.validateOptionsWarnings=e=>{if(!(null==e?void 0:e.skipOptionsValidation))return(null==e?void 0:e.apiKey)&&(0,t.isClassic)(null==e?void 0:e.apiKey),(null==e?void 0:e.apiKey)&&(0,t.isClassic)(null==e?void 0:e.apiKey),e}}($D),Object.defineProperty(ID,"__esModule",{value:!0}),ID.configureDebug=void 0;const BD=FD,VD=UD,qD=$D;ID.configureDebug=function(e){if(!(null==e?void 0:e.debug))return;BD.diag.setLogger(new BD.DiagConsoleLogger,BD.DiagLogLevel.DEBUG),BD.diag.debug((0,VD.createHoneycombSDKLogMessage)("🐝 Honeycomb Web SDK Debug Mode Enabled 🐝"));const t=(0,VD.getTracesEndpoint)(e),n=Object.assign(Object.assign(Object.assign({},VD.defaultOptions),e),{tracesEndpoint:t});!function(e){const t=(0,VD.getTracesApiKey)(e)||"";if(!t)return void BD.diag.debug(qD.MISSING_API_KEY_ERROR);BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`API Key configured for traces: '${t}'`))}(n),function(e){const t=e.serviceName||VD.defaultOptions.serviceName;if(t===VD.defaultOptions.serviceName)return void BD.diag.debug(qD.MISSING_SERVICE_NAME_ERROR);BD.diag.debug(`@honeycombio/opentelemetry-web: Service Name configured for traces: '${t}'`)}(n),function(e){const t=(0,VD.getTracesEndpoint)(e);if(!t)return void BD.diag.debug((0,VD.createHoneycombSDKLogMessage)("No endpoint configured for traces"));BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`Endpoint configured for traces: '${t}'`))}(n),function(e){const t=(0,VD.getSampleRate)(e);if(!t)return void BD.diag.debug("No sampler configured for traces");BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`Sample Rate configured for traces: '${t}'`))}(n)};var zD={},HD={};Object.defineProperty(HD,"__esModule",{value:!0}),HD.BaggageSpanProcessor=void 0;const GD=FD;HD.BaggageSpanProcessor=class{constructor(){}onStart(e,t){var n,r;(null!==(r=null===(n=GD.propagation.getBaggage(t))||void 0===n?void 0:n.getAllEntries())&&void 0!==r?r:[]).forEach((t=>{e.setAttribute(t[0],t[1].value),GD.diag.debug(`@honeycombio/opentelemetry-web: 🚨 Baggage in all outgoing headers: ${t[0]}=${t[1].value} `)}))}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var KD={};Object.defineProperty(KD,"__esModule",{value:!0}),KD.BrowserAttributesSpanProcessor=void 0;KD.BrowserAttributesSpanProcessor=class{constructor(){}onStart(e){const{href:t,pathname:n,search:r,hash:o,hostname:i}=window.location;e.setAttributes({"browser.width":window.innerWidth,"browser.height":window.innerHeight,"page.hash":o,"page.url":t,"page.route":n,"page.hostname":i,"page.search":r})}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var WD={},YD=1e4;function XD(e){void 0===e&&(e={});var t={};return Object.entries(e).forEach((function(e){var n=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),r=n[0],o=n[1];void 0!==o?t[r]=String(o):im.warn('Header "'+r+'" has invalid value ('+o+") and will be ignored")})),t}function QD(e){return"number"==typeof e?e<=0?ZD(e,1e4):e:(n=Number(null!==(t=XN().OTEL_EXPORTER_OTLP_TRACES_TIMEOUT)&&void 0!==t?t:XN().OTEL_EXPORTER_OTLP_TIMEOUT))<=0?ZD(n,YD):n;var t,n}function ZD(e,t){return im.warn("Timeout must be greater than 0",e),t}var JD=function(){function e(e){void 0===e&&(e={}),this._sendingPromises=[],this.url=this.getDefaultUrl(e),"string"==typeof e.hostname&&(this.hostname=e.hostname),this.shutdown=this.shutdown.bind(this),this._shutdownOnce=new lP(this._shutdown,this),this._concurrencyLimit="number"==typeof e.concurrencyLimit?e.concurrencyLimit:30,this.timeoutMillis=QD(e.timeoutMillis),this.onInit(e)}return e.prototype.export=function(e,t){this._shutdownOnce.isCalled?t({code:lR.FAILED,error:new Error("Exporter has been shutdown")}):this._sendingPromises.length>=this._concurrencyLimit?t({code:lR.FAILED,error:new Error("Concurrent export limit reached")}):this._export(e).then((function(){t({code:lR.SUCCESS})})).catch((function(e){t({code:lR.FAILED,error:e})}))},e.prototype._export=function(e){var t=this;return new Promise((function(n,r){try{im.debug("items to be sent",e),t.send(e,n,r)}catch(tme){r(tme)}}))},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype.forceFlush=function(){return Promise.all(this._sendingPromises).then((function(){}))},e.prototype._shutdown=function(){return im.debug("shutdown started"),this.onShutdown(),this.forceFlush()},e}(),ej=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tj=function(e){function t(t,n,r){var o=e.call(this,t)||this;return o.name="OTLPExporterError",o.data=r,o.code=n,o}return ej(t,e),t}(Error),nj=function(){return nj=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},nj.apply(this,arguments)};function rj(e,t,n,r,o,i){var a,s,l=!1,c=setTimeout((function(){if(clearTimeout(a),l=!0,s.readyState===XMLHttpRequest.DONE){var e=new tj("Request Timeout");i(e)}else s.abort()}),r),u=function(r,d){void 0===r&&(r=5),void 0===d&&(d=1e3),(s=new XMLHttpRequest).open("POST",t);Object.entries(nj(nj({},{Accept:"application/json","Content-Type":"application/json"}),n)).forEach((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);s.setRequestHeader(t[0],t[1])})),s.send(e),s.onreadystatechange=function(){if(s.readyState===XMLHttpRequest.DONE&&!1===l)if(s.status>=200&&s.status<=299)im.debug("xhr success",e),o(),clearTimeout(c),clearTimeout(a);else if(s.status&&[429,502,503,504].includes(s.status)&&r>0){var t=void 0;d*=1.5,t=s.getResponseHeader("Retry-After")?function(e){if(null==e)return-1;var t=Number.parseInt(e,10);if(Number.isInteger(t))return t>0?1e3*t:-1;var n=new Date(e).getTime()-Date.now();return n>=0?n:0}(s.getResponseHeader("Retry-After")):Math.round(Math.random()*(5e3-d)+d),a=setTimeout((function(){u(r-1,d)}),t)}else{var n=new tj("Failed to export with XHR (status: "+s.status+")",s.status);i(n),clearTimeout(c),clearTimeout(a)}},s.onabort=function(){if(l){var e=new tj("Request Timeout");i(e)}clearTimeout(c),clearTimeout(a)},s.onerror=function(){if(l){var e=new tj("Request Timeout");i(e)}clearTimeout(c),clearTimeout(a)}};u()}var oj=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ij=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;return n._useXHR=!1,n._useXHR=!!t.headers||"function"!=typeof navigator.sendBeacon,n._headers=n._useXHR?Object.assign({},XD(t.headers),bN(XN().OTEL_EXPORTER_OTLP_HEADERS)):{},n}return oj(t,e),t.prototype.onInit=function(){},t.prototype.onShutdown=function(){},t.prototype.send=function(e,t,n){var r=this;if(this._shutdownOnce.isCalled)im.debug("Shutdown already started. Cannot send objects");else{var o=this.convert(e),i=JSON.stringify(o),a=new Promise((function(e,t){r._useXHR?rj(i,r.url,r._headers,r.timeoutMillis,e,t):function(e,t,n,r,o){navigator.sendBeacon(t,new Blob([e],n))?(im.debug("sendBeacon - can send",e),r()):o(new tj("sendBeacon - cannot send "+e))}(i,r.url,{type:"application/json"},e,t)})).then(t,n);this._sendingPromises.push(a);var s=function(){var e=r._sendingPromises.indexOf(a);r._sendingPromises.splice(e,1)};a.then(s,s)}},t}(JD);function aj(e){var t=BigInt(1e9);return BigInt(e[0])*t+BigInt(e[1])}function sj(e){var t,n=aj(e);return t=n,{low:Number(BigInt.asUintN(32,t)),high:Number(BigInt.asUintN(32,t>>BigInt(32)))}}var lj="undefined"!=typeof BigInt?function(e){return aj(e).toString()}:gR;function cj(e){return e}function uj(e){if(void 0!==e)return JN(e)}var dj={encodeHrTime:sj,encodeSpanContext:JN,encodeOptionalSpanContext:uj};function pj(e){return Object.keys(e).map((function(t){return fj(t,e[t])}))}function fj(e,t){return{key:e,value:hj(t)}}function hj(e){var t=typeof e;return"string"===t?{stringValue:e}:"number"===t?Number.isInteger(e)?{intValue:e}:{doubleValue:e}:"boolean"===t?{boolValue:e}:e instanceof Uint8Array?{bytesValue:e}:Array.isArray(e)?{arrayValue:{values:e.map(hj)}}:"object"===t&&null!=e?{kvlistValue:{values:Object.entries(e).map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);return fj(t[0],t[1])}))}}:{}}function mj(e,t){var n,r=e.spanContext(),o=e.status;return{traceId:t.encodeSpanContext(r.traceId),spanId:t.encodeSpanContext(r.spanId),parentSpanId:t.encodeOptionalSpanContext(e.parentSpanId),traceState:null===(n=r.traceState)||void 0===n?void 0:n.serialize(),name:e.name,kind:null==e.kind?0:e.kind+1,startTimeUnixNano:t.encodeHrTime(e.startTime),endTimeUnixNano:t.encodeHrTime(e.endTime),attributes:pj(e.attributes),droppedAttributesCount:e.droppedAttributesCount,events:e.events.map((function(e){return function(e,t){return{attributes:e.attributes?pj(e.attributes):[],name:e.name,timeUnixNano:t.encodeHrTime(e.time),droppedAttributesCount:e.droppedAttributesCount||0}}(e,t)})),droppedEventsCount:e.droppedEventsCount,status:{code:o.code,message:o.message},links:e.links.map((function(e){return function(e,t){var n;return{attributes:e.attributes?pj(e.attributes):[],spanId:t.encodeSpanContext(e.context.spanId),traceId:t.encodeSpanContext(e.context.traceId),traceState:null===(n=e.context.traceState)||void 0===n?void 0:n.serialize(),droppedAttributesCount:e.droppedAttributesCount||0}}(e,t)})),droppedLinksCount:e.droppedLinksCount}}function gj(e){return{attributes:pj(e.attributes),droppedAttributesCount:0}}var yj=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function vj(e,t){var n=function(e){var t,n;if(void 0===e)return dj;var r=null===(t=e.useLongBits)||void 0===t||t,o=null!==(n=e.useHex)&&void 0!==n&&n;return{encodeHrTime:r?sj:lj,encodeSpanContext:o?cj:JN,encodeOptionalSpanContext:o?cj:uj}}(t);return{resourceSpans:wj(e,n)}}function bj(e){var t,n,r=new Map;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next()){var a=i.value,s=r.get(a.resource);s||r.set(a.resource,s=new Map);var l=a.instrumentationLibrary.name+"@"+(a.instrumentationLibrary.version||"")+":"+(a.instrumentationLibrary.schemaUrl||""),c=s.get(l);c||s.set(l,c=[]),c.push(a)}}catch(u){t={error:u}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function wj(e,t){for(var n,r=[],o=bj(e).entries(),i=o.next();!i.done;){for(var a=yj(i.value,2),s=a[0],l=[],c=a[1].values(),u=c.next();!u.done;){var d=u.value;if(d.length>0){var p=d.map((function(e){return mj(e,t)}));l.push({scope:(n=d[0].instrumentationLibrary,{name:n.name,version:n.version}),spans:p,schemaUrl:d[0].instrumentationLibrary.schemaUrl})}u=c.next()}var f={resource:gj(s),scopeSpans:l,schemaUrl:void 0};r.push(f),i=o.next()}return r}var xj=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Ej="v1/traces",_j="http://localhost:4318/"+Ej,Sj=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;return n._headers=Object.assign(n._headers,bN(XN().OTEL_EXPORTER_OTLP_TRACES_HEADERS)),n}return xj(t,e),t.prototype.convert=function(e){return vj(e,{useHex:!0,useLongBits:!1})},t.prototype.getDefaultUrl=function(e){return"string"==typeof e.url?e.url:XN().OTEL_EXPORTER_OTLP_TRACES_ENDPOINT.length>0?function(e){try{var t=new URL(e);return""===t.pathname&&(t.pathname=t.pathname+"/"),t.toString()}catch(n){return im.warn("Could not parse export URL: '"+e+"'"),e}}(XN().OTEL_EXPORTER_OTLP_TRACES_ENDPOINT):XN().OTEL_EXPORTER_OTLP_ENDPOINT.length>0?(t=XN().OTEL_EXPORTER_OTLP_ENDPOINT,n=Ej,t.endsWith("/")||(t+="/"),t+n):_j;var t,n},t}(ij);const Tj=za(Object.freeze(Object.defineProperty({__proto__:null,OTLPTraceExporter:Sj},Symbol.toStringTag,{value:"Module"})));!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.configureHoneycombHttpJsonTraceExporter=e.DATASET_HEADER_KEY=e.TEAM_HEADER_KEY=void 0;const t=Tj,n=UD;e.TEAM_HEADER_KEY="x-honeycomb-team",e.DATASET_HEADER_KEY="x-honeycomb-dataset",e.configureHoneycombHttpJsonTraceExporter=function(r){const o=(0,n.getTracesApiKey)(r);return new t.OTLPTraceExporter({url:(0,n.getTracesEndpoint)(r),headers:Object.assign({[e.TEAM_HEADER_KEY]:o,[e.DATASET_HEADER_KEY]:(0,n.isClassic)(o)?null==r?void 0:r.dataset:void 0},null==r?void 0:r.headers)})}}(WD);var Cj={};const Aj=za(uP);var Oj=Va&&Va.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))};Object.defineProperty(Cj,"__esModule",{value:!0}),Cj.configureCompositeExporter=void 0;const Nj=Aj;Cj.configureCompositeExporter=function(e){return new Rj(e)};class Rj{constructor(e){this._exporters=e}export(e,t){this._exporters.forEach((n=>n.export(e,t))),t({code:Nj.ExportResultCode.SUCCESS})}shutdown(){return Oj(this,void 0,void 0,(function*(){const e=[];this._exporters.forEach((t=>e.push(t.shutdown()))),yield Promise.all(e)}))}}var Pj={};Object.defineProperty(Pj,"__esModule",{value:!0}),Pj.buildTraceUrl=Pj.configureConsoleTraceLinkExporter=void 0;const kj=Aj,Lj=UD;Pj.configureConsoleTraceLinkExporter=function(e){const t=(0,Lj.getTracesApiKey)(e);return new Mj(null==e?void 0:e.serviceName,t)};class Mj{constructor(e,t){if(this._traceUrl="",!e||!t)return;fetch("https://api.honeycomb.io/1/auth",{headers:{"x-honeycomb-team":t}}).then((e=>{if(e.ok)return e.json();throw new Error})).then((n=>{var r,o,i;const a=n;if(!(null===(r=a.team)||void 0===r?void 0:r.slug))throw new Error;this._traceUrl=Dj(t,e,null===(o=a.team)||void 0===o?void 0:o.slug,null===(i=a.environment)||void 0===i?void 0:i.slug)})).catch((()=>{}))}export(e,t){this._traceUrl&&e.forEach((e=>{})),t({code:kj.ExportResultCode.SUCCESS})}shutdown(){return Promise.resolve()}}function Dj(e,t,n,r){let o=`https://ui.honeycomb.io/${n}`;return!(0,Lj.isClassic)(e)&&r&&(o+=`/environments/${r}`),o+=`/datasets/${t}/trace?trace_id`,o}Pj.buildTraceUrl=Dj,Object.defineProperty(zD,"__esModule",{value:!0}),zD.CompositeSpanProcessor=zD.configureSpanProcessors=void 0;const jj=HD,Ij=KD,Fj=dk,Uj=WD,$j=Cj,Bj=Pj;zD.configureSpanProcessors=e=>{const t=new Vj,n=[];return(null==e?void 0:e.localVisualizations)&&n.push((0,Bj.configureConsoleTraceLinkExporter)(e)),(null==e?void 0:e.traceExporter)&&n.push(null==e?void 0:e.traceExporter),t.addProcessor(new Fj.BatchSpanProcessor((0,$j.configureCompositeExporter)([(0,Uj.configureHoneycombHttpJsonTraceExporter)(e),...n]))),t.addProcessor(new jj.BaggageSpanProcessor),t.addProcessor(new Ij.BrowserAttributesSpanProcessor),(null==e?void 0:e.spanProcessor)&&t.addProcessor(null==e?void 0:e.spanProcessor),t};class Vj{constructor(){this.spanProcessors=[]}addProcessor(e){this.spanProcessors.push(e)}getSpanProcessors(){return this.spanProcessors}onStart(e,t){this.spanProcessors.forEach((n=>{n.onStart(e,t)}))}onEnd(e){this.spanProcessors.forEach((t=>{t.onEnd(e)}))}forceFlush(){return Promise.all(this.spanProcessors.map((e=>e.forceFlush()))).then((()=>{}))}shutdown(){return Promise.all(this.spanProcessors.map((e=>e.forceFlush()))).then((()=>{}))}}zD.CompositeSpanProcessor=Vj;var qj={};Object.defineProperty(qj,"__esModule",{value:!0}),qj.DeterministicSampler=qj.configureDeterministicSampler=void 0;const zj=dk,Hj=UD;qj.configureDeterministicSampler=e=>{const t=(0,Hj.getSampleRate)(e);return new Gj(t)};class Gj{constructor(e){switch(this._sampleRate=e,e){case 0:this._sampler=new zj.AlwaysOffSampler;break;case 1:this._sampler=new zj.AlwaysOnSampler;break;default:this._sampler=new zj.TraceIdRatioBasedSampler(1/e);break}}shouldSample(e,t,n,r,o,i){const a=this._sampler.shouldSample(e,t,n,r,o,i);return Object.assign(Object.assign({},a),{attributes:Object.assign(Object.assign({},a.attributes),{SampleRate:this._sampleRate})})}toString(){return`DeterministicSampler(${this._sampler.toString()})`}}qj.DeterministicSampler=Gj;var Kj={},Wj={exports:{}};!function(e,t){!function(e){var t,n,r=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},o=function(e){if("loading"===document.readyState)return"loading";var t=r();if(t){if(e<t.domInteractive)return"loading";if(0===t.domContentLoadedEventStart||e<t.domContentLoadedEventStart)return"dom-interactive";if(0===t.domComplete||e<t.domComplete)return"dom-content-loaded"}return"complete"},i=function(e){var t=e.nodeName;return 1===e.nodeType?t.toLowerCase():t.toUpperCase().replace(/^#/,"")},a=function(e,t){var n="";try{for(;e&&9!==e.nodeType;){var r=e,o=r.id?"#"+r.id:i(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+o.length>(t||100)-1)return n||o;if(n=n?o+">"+n:o,r.id)break;e=r.parentNode}}catch(a){}return n},s=-1,l=function(){return s},c=function(e){addEventListener("pageshow",(function(t){t.persisted&&(s=t.timeStamp,e(t))}),!0)},u=function(){var e=r();return e&&e.activationStart||0},d=function(e,t){var n=r(),o="navigate";return l()>=0?o="back-forward-cache":n&&(document.prerendering||u()>0?o="prerender":document.wasDiscarded?o="restore":n.type&&(o=n.type.replace(/_/g,"-"))),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:o}},p=function(e,t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(o){}},f=function(e,t,n,r){var o,i;return function(a){var s,l;t.value>=0&&(a||r)&&((i=t.value-(o||0))||void 0===o)&&(o=t.value,t.delta=i,t.rating=(s=t.value)>(l=n)[1]?"poor":s>l[0]?"needs-improvement":"good",e(t))}},h=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},m=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},g=function(e){var t=!1;return function(){t||(e(),t=!0)}},y=-1,v=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},b=function(e){"hidden"===document.visibilityState&&y>-1&&(y="visibilitychange"===e.type?e.timeStamp:0,x())},w=function(){addEventListener("visibilitychange",b,!0),addEventListener("prerenderingchange",b,!0)},x=function(){removeEventListener("visibilitychange",b,!0),removeEventListener("prerenderingchange",b,!0)},E=function(){return y<0&&(y=v(),w(),c((function(){setTimeout((function(){y=v(),w()}),0)}))),{get firstHiddenTime(){return y}}},_=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},S=[1800,3e3],T=function(e,t){t=t||{},_((function(){var n,r=E(),o=d("FCP"),i=p("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(i.disconnect(),e.startTime<r.firstHiddenTime&&(o.value=Math.max(e.startTime-u(),0),o.entries.push(e),n(!0)))}))}));i&&(n=f(e,o,S,t.reportAllChanges),c((function(r){o=d("FCP"),n=f(e,o,S,t.reportAllChanges),h((function(){o.value=performance.now()-r.timeStamp,n(!0)}))})))}))},C=[.1,.25],A=0,O=1/0,N=0,R=function(e){e.forEach((function(e){e.interactionId&&(O=Math.min(O,e.interactionId),N=Math.max(N,e.interactionId),A=N?(N-O)/7+1:0)}))},P=function(){return t?A:performance.interactionCount||0},k=function(){"interactionCount"in performance||t||(t=p("event",R,{type:"event",buffered:!0,durationThreshold:0}))},L=[],M=new Map,D=0,j=function(){var e=Math.min(L.length-1,Math.floor((P()-D)/50));return L[e]},I=[],F=function(e){if(I.forEach((function(t){return t(e)})),e.interactionId||"first-input"===e.entryType){var t=L[L.length-1],n=M.get(e.interactionId);if(n||L.length<10||e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===n.entries[0].startTime&&n.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};M.set(r.id,r),L.push(r)}L.sort((function(e,t){return t.latency-e.latency})),L.length>10&&L.splice(10).forEach((function(e){return M.delete(e.id)}))}}},U=function(e){var t=self.requestIdleCallback||self.setTimeout,n=-1;return e=g(e),"hidden"===document.visibilityState?e():(n=t(e),m(e)),n},$=[200,500],B=function(e,t){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(t=t||{},_((function(){var n;k();var r,o=d("INP"),i=function(e){U((function(){e.forEach(F);var t=j();t&&t.latency!==o.value&&(o.value=t.latency,o.entries=t.entries,r())}))},a=p("event",i,{durationThreshold:null!==(n=t.durationThreshold)&&void 0!==n?n:40});r=f(e,o,$,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),m((function(){i(a.takeRecords()),r(!0)})),c((function(){D=P(),L.length=0,M.clear(),o=d("INP"),r=f(e,o,$,t.reportAllChanges)})))})))},V=[],q=[],z=0,H=new WeakMap,G=new Map,K=-1,W=function(e){V=V.concat(e),Y()},Y=function(){K<0&&(K=U(X))},X=function(){G.size>10&&G.forEach((function(e,t){M.has(t)||G.delete(t)}));var e=L.map((function(e){return H.get(e.entries[0])})),t=q.length-50;q=q.filter((function(n,r){return r>=t||e.includes(n)}));for(var n=new Set,r=0;r<q.length;r++){var o=q[r];te(o.startTime,o.processingEnd).forEach((function(e){n.add(e)}))}var i=V.length-1-50;V=V.filter((function(e,t){return e.startTime>z&&t>i||n.has(e)})),K=-1};I.push((function(e){e.interactionId&&e.target&&!G.has(e.interactionId)&&G.set(e.interactionId,e.target)}),(function(e){var t,n=e.startTime+e.duration;z=Math.max(z,e.processingEnd);for(var r=q.length-1;r>=0;r--){var o=q[r];if(Math.abs(n-o.renderTime)<=8){(t=o).startTime=Math.min(e.startTime,t.startTime),t.processingStart=Math.min(e.processingStart,t.processingStart),t.processingEnd=Math.max(e.processingEnd,t.processingEnd),t.entries.push(e);break}}t||q.push(t={startTime:e.startTime,processingStart:e.processingStart,processingEnd:e.processingEnd,renderTime:n,entries:[e]}),(e.interactionId||"first-input"===e.entryType)&&H.set(e,t),Y()}));var Q,Z,J,ee,te=function(e,t){for(var n,r=[],o=0;n=V[o];o++)if(!(n.startTime+n.duration<e)){if(n.startTime>t)break;r.push(n)}return r},ne=[2500,4e3],re={},oe=[800,1800],ie=function e(t){document.prerendering?_((function(){return e(t)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(t)}),!0):setTimeout(t,0)},ae=function(e,t){t=t||{};var n=d("TTFB"),o=f(e,n,oe,t.reportAllChanges);ie((function(){var i=r();i&&(n.value=Math.max(i.responseStart-u(),0),n.entries=[i],o(!0),c((function(){n=d("TTFB",0),(o=f(e,n,oe,t.reportAllChanges))(!0)})))}))},se={passive:!0,capture:!0},le=new Date,ce=function(e,t){Q||(Q=t,Z=e,J=new Date,pe(removeEventListener),ue())},ue=function(){if(Z>=0&&Z<J-le){var e={entryType:"first-input",name:Q.type,target:Q.target,cancelable:Q.cancelable,startTime:Q.timeStamp,processingStart:Q.timeStamp+Z};ee.forEach((function(t){t(e)})),ee=[]}},de=function(e){if(e.cancelable){var t=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?(n=t,r=e,o=function(){ce(n,r),a()},i=function(){a()},a=function(){removeEventListener("pointerup",o,se),removeEventListener("pointercancel",i,se)},addEventListener("pointerup",o,se),addEventListener("pointercancel",i,se)):ce(t,e)}var n,r,o,i,a},pe=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(t){return e(t,de,se)}))},fe=[100,300],he=function(e,t){t=t||{},_((function(){var n,r=E(),o=d("FID"),i=function(e){e.startTime<r.firstHiddenTime&&(o.value=e.processingStart-e.startTime,o.entries.push(e),n(!0))},a=function(e){e.forEach(i)},s=p("first-input",a);n=f(e,o,fe,t.reportAllChanges),s&&(m(g((function(){a(s.takeRecords()),s.disconnect()}))),c((function(){o=d("FID"),n=f(e,o,fe,t.reportAllChanges),ee=[],Z=-1,Q=null,pe(addEventListener),ee.push(i),ue()})))}))};e.CLSThresholds=C,e.FCPThresholds=S,e.FIDThresholds=fe,e.INPThresholds=$,e.LCPThresholds=ne,e.TTFBThresholds=oe,e.onCLS=function(e,t){var n,r;n=function(t){var n=function(e){var t,n={};if(e.entries.length){var r=e.entries.reduce((function(e,t){return e&&e.value>t.value?e:t}));if(r&&r.sources&&r.sources.length){var i=(t=r.sources).find((function(e){return e.node&&1===e.node.nodeType}))||t[0];i&&(n={largestShiftTarget:a(i.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:i,largestShiftEntry:r,loadState:o(r.startTime)})}}return Object.assign(e,{attribution:n})}(t);e(n)},r=(r=t)||{},T(g((function(){var e,t=d("CLS",0),o=0,i=[],a=function(n){n.forEach((function(e){e.hadRecentInput||(o&&e.startTime-i[i.length-1].startTime<1e3&&e.startTime-i[0].startTime<5e3?(o+=e.value,i.push(e)):(o=e.value,i=[e]))})),o>t.value&&(t.value=o,t.entries=i,e())},s=p("layout-shift",a);s&&(e=f(n,t,C,r.reportAllChanges),m((function(){a(s.takeRecords()),e(!0)})),c((function(){o=0,t=d("CLS",0),e=f(n,t,C,r.reportAllChanges),h((function(){return e()}))})),setTimeout(e,0))})))},e.onFCP=function(e,t){T((function(t){var n=function(e){var t={timeToFirstByte:0,firstByteToFCP:e.value,loadState:o(l())};if(e.entries.length){var n=r(),i=e.entries[e.entries.length-1];if(n){var a=Math.max(0,n.responseStart-(n.activationStart||0));t={timeToFirstByte:a,firstByteToFCP:e.value-a,loadState:o(e.entries[0].startTime),navigationEntry:n,fcpEntry:i}}}return Object.assign(e,{attribution:t})}(t);e(n)}),t)},e.onFID=function(e,t){he((function(t){var n,r,i,s=(i={eventTarget:a((r=(n=t).entries[0]).target),eventType:r.name,eventTime:r.startTime,eventEntry:r,loadState:o(r.startTime)},Object.assign(n,{attribution:i}));e(s)}),t)},e.onINP=function(e,t){n||(n=p("long-animation-frame",W)),B((function(t){var n,r,i,s,l,c,u,d,p,f,h,m,g=(i=H.get(r=(n=t).entries[0]),s=r.processingStart,l=i.processingEnd,c=i.entries.sort((function(e,t){return e.processingStart-t.processingStart})),u=te(r.startTime,l),d=n.entries.find((function(e){return e.target})),p=d&&d.target||G.get(r.interactionId),f=[r.startTime+r.duration,l].concat(u.map((function(e){return e.startTime+e.duration}))),h=Math.max.apply(Math,f),m={interactionTarget:a(p),interactionTargetElement:p,interactionType:r.name.startsWith("key")?"keyboard":"pointer",interactionTime:r.startTime,nextPaintTime:h,processedEventEntries:c,longAnimationFrameEntries:u,inputDelay:s-r.startTime,processingDuration:l-s,presentationDelay:Math.max(h-l,0),loadState:o(r.startTime)},Object.assign(n,{attribution:m}));e(g)}),t)},e.onLCP=function(e,t){var n,o;n=function(t){var n=function(e){var t={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:e.value};if(e.entries.length){var n=r();if(n){var o=n.activationStart||0,i=e.entries[e.entries.length-1],s=i.url&&performance.getEntriesByType("resource").filter((function(e){return e.name===i.url}))[0],l=Math.max(0,n.responseStart-o),c=Math.max(l,s?(s.requestStart||s.startTime)-o:0),u=Math.max(c,s?s.responseEnd-o:0),d=Math.max(u,i.startTime-o);t={element:a(i.element),timeToFirstByte:l,resourceLoadDelay:c-l,resourceLoadDuration:u-c,elementRenderDelay:d-u,navigationEntry:n,lcpEntry:i},i.url&&(t.url=i.url),s&&(t.lcpResourceEntry=s)}}return Object.assign(e,{attribution:t})}(t);e(n)},o=(o=t)||{},_((function(){var e,t=E(),r=d("LCP"),i=function(n){o.reportAllChanges||(n=n.slice(-1)),n.forEach((function(n){n.startTime<t.firstHiddenTime&&(r.value=Math.max(n.startTime-u(),0),r.entries=[n],e())}))},a=p("largest-contentful-paint",i);if(a){e=f(n,r,ne,o.reportAllChanges);var s=g((function(){re[r.id]||(i(a.takeRecords()),a.disconnect(),re[r.id]=!0,e(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return U(s)}),{once:!0,capture:!0})})),m(s),c((function(t){r=d("LCP"),e=f(n,r,ne,o.reportAllChanges),h((function(){r.value=performance.now()-t.timeStamp,re[r.id]=!0,e(!0)}))}))}}))},e.onTTFB=function(e,t){ae((function(t){var n=function(e){var t={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(e.entries.length){var n=e.entries[0],r=n.activationStart||0,o=Math.max((n.workerStart||n.fetchStart)-r,0),i=Math.max(n.domainLookupStart-r,0),a=Math.max(n.connectStart-r,0),s=Math.max(n.connectEnd-r,0);t={waitingDuration:o,cacheDuration:i-o,dnsDuration:a-i,connectionDuration:s-a,requestDuration:e.value-s,navigationEntry:n}}return Object.assign(e,{attribution:t})}(t);e(n)}),t)}}(t)}(0,Wj.exports);var Yj=Wj.exports,Xj=Va&&Va.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),Qj=Va&&Va.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Zj=Va&&Va.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&Xj(t,e,n);return Qj(t,e),t};Object.defineProperty(Kj,"__esModule",{value:!0}),Kj.WebVitalsInstrumentation=Kj.InstrumentationAbstract=void 0;const Jj=Yj,eI=TD,tI=FD,nI=Zj(Dm);let rI=class{constructor(e,t,n={}){this.instrumentationName=e,this.instrumentationVersion=t,this._wrap=nI.wrap,this._unwrap=nI.unwrap,this._massWrap=nI.massWrap,this._massUnwrap=nI.massUnwrap,this._config=Object.assign({enabled:!0},n),this._diag=tI.diag.createComponentLogger({namespace:e}),this._tracer=tI.trace.getTracer(e,t),this._meter=tI.metrics.getMeter(e,t),this._updateMetricInstruments()}get meter(){return this._meter}setMeterProvider(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()}_updateMetricInstruments(){}getConfig(){return this._config}setConfig(e={}){this._config=Object.assign({},e)}setTracerProvider(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)}get tracer(){return this._tracer}};Kj.InstrumentationAbstract=rI;Kj.WebVitalsInstrumentation=class extends rI{constructor({enabled:e=!0,vitalsToTrack:t=["CLS","LCP","INP"],lcp:n,cls:r,inp:o,fid:i,fcp:a,ttfb:s}={}){super("@honeycombio/instrumentation-web-vitals",eI.VERSION,{enabled:e,vitalsToTrack:t,lcp:n,cls:r,inp:o,fid:i,fcp:a,ttfb:s}),this.onReportCLS=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{largestShiftTarget:o,largestShiftTime:i,largestShiftValue:a,loadState:s,largestShiftEntry:l}=r,c=this.getAttrPrefix(n),u=this.tracer.startSpan(n);u.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${c}.largest_shift_target`]:o,[`${c}.element`]:o,[`${c}.largest_shift_time`]:i,[`${c}.largest_shift_value`]:a,[`${c}.load_state`]:s,[`${c}.had_recent_input`]:null==l?void 0:l.hadRecentInput})),t&&t(e,u),u.end()},this.onReportLCP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{element:o,url:i,timeToFirstByte:a,resourceLoadDelay:s,resourceLoadDuration:l,elementRenderDelay:c}=r,u=this.getAttrPrefix(n),d=this.tracer.startSpan(n);d.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${u}.element`]:o,[`${u}.url`]:i,[`${u}.time_to_first_byte`]:a,[`${u}.resource_load_delay`]:s,[`${u}.resource_load_duration`]:l,[`${u}.element_render_delay`]:c,[`${u}.resource_load_time`]:l})),t&&t(e,d),d.end()},this.onReportINP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{inputDelay:o,interactionTarget:i,interactionTime:a,interactionType:s,loadState:l,nextPaintTime:c,presentationDelay:u,processingDuration:d}=r,p=this.getAttrPrefix(n),f=this.tracer.startSpan(n);f.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${p}.input_delay`]:o,[`${p}.interaction_target`]:i,[`${p}.interaction_time`]:a,[`${p}.interaction_type`]:s,[`${p}.load_state`]:l,[`${p}.next_paint_time`]:c,[`${p}.presentation_delay`]:u,[`${p}.processing_duration`]:d,[`${p}.element`]:i,[`${p}.event_type`]:s})),t&&t(e,f),f.end()},this.onReportFCP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{timeToFirstByte:o,firstByteToFCP:i,loadState:a}=r,s=this.getAttrPrefix(n),l=this.tracer.startSpan(n);l.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${s}.time_to_first_byte`]:o,[`${s}.time_since_first_byte`]:i,[`${s}.load_state`]:a})),t&&t(e,l),l.end()},this.onReportFID=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{eventTarget:o,eventType:i,loadState:a}=r,s=this.getAttrPrefix(n),l=this.tracer.startSpan(n);l.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${s}.element`]:o,[`${s}.event_type`]:i,[`${s}.load_state`]:a})),t&&t(e,l),l.end()},this.onReportTTFB=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{cacheDuration:o,connectionDuration:i,dnsDuration:a,requestDuration:s,waitingDuration:l}=r,c=this.getAttrPrefix(n),u=this.tracer.startSpan(n);u.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${c}.waiting_duration`]:l,[`${c}.dns_duration`]:a,[`${c}.connection_duration`]:i,[`${c}.request_duration`]:s,[`${c}.cache_duration`]:o,[`${c}.waiting_time`]:l,[`${c}.dns_time`]:a,[`${c}.connection_time`]:i,[`${c}.request_time`]:s})),t&&t(e,u),u.end()},this.vitalsToTrack=[...t],this.lcpOpts=n,this.clsOpts=r,this.inpOpts=o,this.fidOpts=i,this.fcpOpts=a,this.ttfbOpts=s,this._isEnabled=e,this._setupWebVitalsCallbacks()}init(){}_setupWebVitalsCallbacks(){this.vitalsToTrack.includes("CLS")&&(0,Jj.onCLS)((e=>{var t;this.onReportCLS(e,null===(t=this.clsOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.clsOpts),this.vitalsToTrack.includes("LCP")&&(0,Jj.onLCP)((e=>{var t;this.onReportLCP(e,null===(t=this.lcpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.lcpOpts),this.vitalsToTrack.includes("INP")&&(0,Jj.onINP)((e=>{var t;this.onReportINP(e,null===(t=this.inpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.inpOpts),this.vitalsToTrack.includes("FID")&&(0,Jj.onFID)((e=>{var t;this.onReportFID(e,null===(t=this.fidOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.fidOpts),this.vitalsToTrack.includes("TTFB")&&(0,Jj.onTTFB)((e=>{var t;this.onReportTTFB(e,null===(t=this.ttfbOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.ttfbOpts),this.vitalsToTrack.includes("FCP")&&(0,Jj.onFCP)((e=>{var t;this.onReportFCP(e,null===(t=this.fcpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.fcpOpts)}getAttrPrefix(e){return e.toLowerCase()}getSharedAttributes(e){const{name:t,id:n,delta:r,rating:o,value:i,navigationType:a}=e,s=this.getAttrPrefix(t);return{[`${s}.id`]:n,[`${s}.delta`]:r,[`${s}.value`]:i,[`${s}.rating`]:o,[`${s}.navigation_type`]:a}}disable(){this.isEnabled()?(this._isEnabled=!1,this._diag.debug("Instrumentation disabled")):this._diag.debug("Instrumentation already disabled")}enable(){this.isEnabled()?this._diag.debug("Instrumentation already enabled"):(this._isEnabled=!0,this._diag.debug("Instrumentation enabled"),this._diag.debug(`Sending spans for ${this.vitalsToTrack.join(",")}`))}isEnabled(){return this._isEnabled}},Object.defineProperty(_D,"__esModule",{value:!0}),_D.HoneycombWebSDK=void 0;const oI=Cf,iI=SD,aI=OD,sI=PD,lI=MD,cI=ID,uI=zD,dI=qj,pI=$D,fI=Kj;_D.HoneycombWebSDK=class extends oI.WebSDK{constructor(e){var t;const n=[...(null==e?void 0:e.instrumentations)||[]];!1!==(null===(t=null==e?void 0:e.webVitalsInstrumentationConfig)||void 0===t?void 0:t.enabled)&&n.push(new fI.WebVitalsInstrumentation(null==e?void 0:e.webVitalsInstrumentationConfig)),super(Object.assign(Object.assign({},e),{instrumentations:n,resource:(0,lI.mergeResources)([(0,sI.configureBrowserAttributesResource)(),(0,aI.configureEntryPageResource)(null==e?void 0:e.entryPageAttributes),null==e?void 0:e.resource,null==e?void 0:e.resourceAttributes,(0,iI.configureHoneycombResource)()]),sampler:(0,dI.configureDeterministicSampler)(e),spanProcessor:(0,uI.configureSpanProcessors)(e)})),(0,pI.validateOptionsWarnings)(e),(null==e?void 0:e.debug)&&(0,cI.configureDebug)(e)}},function(e){var t=Va&&Va.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=Va&&Va.__exportStar||function(e,n){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(n,r)||t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Cf,e),n(_D,e),n(Kj,e)}(Tf);var hI=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");var mI="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},gI=performance,yI="http.method",vI="http.url",bI="http.host",wI="http.scheme",xI="http.status_code",EI="http.user_agent",_I="http.request_content_length_uncompressed",SI="http.response_content_length",TI="http.response_content_length_uncompressed",CI=Math.pow(10,6),AI=Math.pow(10,9);function OI(e){return[Math.trunc(e/1e3),Math.round(e%1e3*CI)]}function NI(){var e=gI.timeOrigin;if("number"!=typeof e){e=gI.timing&&gI.timing.fetchStart}return e}function RI(e){return function(e,t){var n=[e[0]+t[0],e[1]+t[1]];n[1]>=AI&&(n[1]-=AI,n[0]+=1);return n}(OI(NI()),OI("number"==typeof e?e:gI.now()))}function PI(e){if(t=e,Array.isArray(t)&&2===t.length&&"number"==typeof t[0]&&"number"==typeof t[1])return e;if("number"==typeof e)return e<NI()?RI(e):OI(e);if(e instanceof Date)return OI(e.getTime());throw TypeError("Invalid input type");var t}function kI(e){return e[0]*AI+e[1]}var LI="[_0-9a-z-*/]",MI=new RegExp("^(?:"+("[a-z]"+LI+"{0,255}")+"|"+("[a-z0-9]"+LI+"{0,240}@[a-z]"+LI+"{0,13}")+")$"),DI=/^[ -~]{0,255}[!-~]$/,jI=/,|=/;var II=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return MI.test(e)})(o)&&function(e){return DI.test(e)&&!jI.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),FI="traceparent",UI="tracestate",$I=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");var BI=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!function(e){return!0===e.getValue(hI)}(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,FI,o),r.traceState&&n.set(t,UI,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,FI);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=function(e){var t=$I.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,UI);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new II("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[FI,UI]},e}();function VI(e,t){return"string"==typeof t?e===t:!!e.match(t)}function qI(e,t){var n,r;if(!t)return!1;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),i=o.next();!i.done;i=o.next()){if(VI(e,i.value))return!0}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return!1}var zI=function(){function e(){}return e.prototype.emit=function(e){},e}(),HI=new zI,GI=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new zI},e}()),KI=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):HI},e}(),WI=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new KI(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:GI},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),YI="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},XI=Symbol.for("io.opentelemetry.js.api.logs"),QI=YI;var ZI,JI,eF=function(){function e(){this._proxyLoggerProvider=new WI}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return QI[XI]?this.getLoggerProvider():(QI[XI]=(t=1,n=e,r=GI,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=QI[XI])||void 0===e?void 0:e.call(QI,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete QI[XI],this._proxyLoggerProvider=new WI},e}().getInstance(),tF=function(){return tF=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},tF.apply(this,arguments)},nF=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=eF.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=tF({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),rF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oF=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return rF(t,e),t}(nF);function iF(e,t,n){var r,o;try{o=e()}catch(tme){r=tme}finally{return t(r,o),o}}function aF(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}(JI=ZI||(ZI={})).DOCUMENT_LOAD="documentLoad",JI.DOCUMENT_FETCH="documentFetch",JI.RESOURCE_FETCH="resourceFetch";var sF,lF;(lF=sF||(sF={})).FIRST_PAINT="firstPaint",lF.FIRST_CONTENTFUL_PAINT="firstContentfulPaint";var cF={"first-paint":sF.FIRST_PAINT,"first-contentful-paint":sF.FIRST_CONTENTFUL_PAINT},uF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dF=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-document-load","0.44.1",t)||this;return n.component="document-load",n.version="1",n.moduleName=n.component,n}return uF(t,e),t.prototype.init=function(){},t.prototype._onDocumentLoaded=function(){var e=this;window.setTimeout((function(){e._collectPerformance()}))},t.prototype._addResourcesSpans=function(e){var t,n,r=this,o=null===(n=(t=gI).getEntriesByType)||void 0===n?void 0:n.call(t,"resource");o&&o.forEach((function(t){r._initResourceSpan(t,e)}))},t.prototype._collectPerformance=function(){var e=this,t=Array.from(document.getElementsByTagName("meta")).find((function(e){return e.getAttribute("name")===FI})),n=function(){var e,t,n={},r=null===(t=(e=gI).getEntriesByType)||void 0===t?void 0:t.call(e,"navigation")[0];if(r)Object.values(xM).forEach((function(e){if(LM(r,e)){var t=r[e];"number"==typeof t&&(n[e]=t)}}));else{var o=gI.timing;o&&Object.values(xM).forEach((function(e){if(LM(o,e)){var t=o[e];"number"==typeof t&&(n[e]=t)}}))}return n}();om.with(ym.extract(Xf,{traceparent:t&&t.content||""}),(function(){var t,r=e._startSpan(ZI.DOCUMENT_LOAD,xM.FETCH_START,n);r&&(om.with(bm.setSpan(om.active(),r),(function(){var t=e._startSpan(ZI.DOCUMENT_FETCH,xM.FETCH_START,n);t&&(t.setAttribute(vI,location.href),om.with(bm.setSpan(om.active(),t),(function(){var r;e.getConfig().ignoreNetworkEvents||DM(t,n),e._addCustomAttributesOnSpan(t,null===(r=e.getConfig().applyCustomAttributesOnSpan)||void 0===r?void 0:r.documentFetch),e._endSpan(t,xM.RESPONSE_END,n)})))})),r.setAttribute(vI,location.href),r.setAttribute(EI,navigator.userAgent),e._addResourcesSpans(r),e.getConfig().ignoreNetworkEvents||(MM(r,xM.FETCH_START,n),MM(r,xM.UNLOAD_EVENT_START,n),MM(r,xM.UNLOAD_EVENT_END,n),MM(r,xM.DOM_INTERACTIVE,n),MM(r,xM.DOM_CONTENT_LOADED_EVENT_START,n),MM(r,xM.DOM_CONTENT_LOADED_EVENT_END,n),MM(r,xM.DOM_COMPLETE,n),MM(r,xM.LOAD_EVENT_START,n),MM(r,xM.LOAD_EVENT_END,n)),e.getConfig().ignorePerformancePaintEvents||function(e){var t,n,r=null===(n=(t=gI).getEntriesByType)||void 0===n?void 0:n.call(t,"paint");r&&r.forEach((function(t){var n=t.name,r=t.startTime;LM(cF,n)&&e.addEvent(cF[n],r)}))}(r),e._addCustomAttributesOnSpan(r,null===(t=e.getConfig().applyCustomAttributesOnSpan)||void 0===t?void 0:t.documentLoad),e._endSpan(r,xM.LOAD_EVENT_END,n))}))},t.prototype._endSpan=function(e,t,n){e&&(LM(n,t)?e.end(n[t]):e.end())},t.prototype._initResourceSpan=function(e,t){var n,r=this._startSpan(ZI.RESOURCE_FETCH,xM.FETCH_START,e,t);r&&(r.setAttribute(vI,e.name),this.getConfig().ignoreNetworkEvents||DM(r,e),this._addCustomAttributesOnResourceSpan(r,e,null===(n=this.getConfig().applyCustomAttributesOnSpan)||void 0===n?void 0:n.resourceFetch),this._endSpan(r,xM.RESPONSE_END,e))},t.prototype._startSpan=function(e,t,n,r){if(LM(n,t)&&"number"==typeof n[t])return this.tracer.startSpan(e,{startTime:n[t]},r?bm.setSpan(om.active(),r):void 0)},t.prototype._waitForPageLoad=function(){"complete"===window.document.readyState?this._onDocumentLoaded():(this._onDocumentLoaded=this._onDocumentLoaded.bind(this),window.addEventListener("load",this._onDocumentLoaded))},t.prototype._addCustomAttributesOnSpan=function(e,t){var n=this;t&&iF((function(){return t(e)}),(function(e){e&&n._diag.error("addCustomAttributesOnSpan",e)}))},t.prototype._addCustomAttributesOnResourceSpan=function(e,t,n){var r=this;n&&iF((function(){return n(e,t)}),(function(e){e&&r._diag.error("addCustomAttributesOnResourceSpan",e)}))},t.prototype.enable=function(){window.removeEventListener("load",this._onDocumentLoaded),this._waitForPageLoad()},t.prototype.disable=function(){window.removeEventListener("load",this._onDocumentLoaded)},t}(oF),pF=function(){function e(){}return e.prototype.emit=function(e){},e}(),fF=new pF,hF=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new pF},e}()),mF=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):fF},e}(),gF=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new mF(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:hF},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),yF="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},vF=Symbol.for("io.opentelemetry.js.api.logs"),bF=yF;var wF,xF,EF,_F=function(){function e(){this._proxyLoggerProvider=new gF}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return bF[vF]?this.getLoggerProvider():(bF[vF]=(t=1,n=e,r=hF,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=bF[vF])||void 0===e?void 0:e.call(bF,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete bF[vF],this._proxyLoggerProvider=new gF},e}().getInstance(),SF=function(){return SF=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},SF.apply(this,arguments)},TF=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=_F.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=SF({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),CF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),AF=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return CF(t,e),t}(TF);function OF(e,t){return t in e}function NF(e,t,n,r){var o=void 0,i=void 0;OF(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=wF.FETCH_START;if(OF(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function RF(e,t,n){void 0===n&&(n=!1),n||(NF(e,wF.FETCH_START,t),NF(e,wF.DOMAIN_LOOKUP_START,t),NF(e,wF.DOMAIN_LOOKUP_END,t),NF(e,wF.CONNECT_START,t),OF(t,"name")&&t.name.startsWith("https:")&&NF(e,wF.SECURE_CONNECTION_START,t),NF(e,wF.CONNECT_END,t),NF(e,wF.REQUEST_START,t),NF(e,wF.RESPONSE_START,t),NF(e,wF.RESPONSE_END,t));var r=t[wF.ENCODED_BODY_SIZE];void 0!==r&&e.setAttribute(SI,r);var o=t[wF.DECODED_BODY_SIZE];void 0!==o&&r!==o&&e.setAttribute(TI,o)}function PF(){return"undefined"!=typeof location?location.origin:void 0}function kF(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=LF(e),s=function(e,t,n,r,o,i){var a=kI(t),s=kI(n),l=r.filter((function(t){var n=kI(PI(t[wF.FETCH_START])),r=kI(PI(t[wF.RESPONSE_END]));return t.initiatorType.toLowerCase()===i&&t.name===e&&n>=a&&r<=s}));l.length>0&&(l=l.filter((function(e){return!o.has(e)})));return l}(e=a.toString(),t,n,r,o,i);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=function(e){return e.slice().sort((function(e,t){var n=e[wF.FETCH_START],r=t[wF.FETCH_START];return n>r?1:n<r?-1:0}))}(s);if(a.origin!==PF()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=kI(n),i=kI(PI(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=kI(PI(c[wF.FETCH_START])),d=o-kI(PI(c[wF.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[wF.RESPONSE_END],n);return u[wF.FETCH_START]<c[wF.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}}function LF(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(xF||(xF=document.createElement("a")),xF);return t.href=e,t}!function(e){e.CONNECT_END="connectEnd",e.CONNECT_START="connectStart",e.DECODED_BODY_SIZE="decodedBodySize",e.DOM_COMPLETE="domComplete",e.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",e.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",e.DOM_INTERACTIVE="domInteractive",e.DOMAIN_LOOKUP_END="domainLookupEnd",e.DOMAIN_LOOKUP_START="domainLookupStart",e.ENCODED_BODY_SIZE="encodedBodySize",e.FETCH_START="fetchStart",e.LOAD_EVENT_END="loadEventEnd",e.LOAD_EVENT_START="loadEventStart",e.NAVIGATION_START="navigationStart",e.REDIRECT_END="redirectEnd",e.REDIRECT_START="redirectStart",e.REQUEST_START="requestStart",e.RESPONSE_END="responseEnd",e.RESPONSE_START="responseStart",e.SECURE_CONNECTION_START="secureConnectionStart",e.UNLOAD_EVENT_END="unloadEventEnd",e.UNLOAD_EVENT_START="unloadEventStart"}(wF||(wF={})),function(e){e.COMPONENT="component",e.HTTP_ERROR_NAME="http.error_name",e.HTTP_STATUS_TEXT="http.status_text"}(EF||(EF={}));var MF=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},DF=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},jF=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},IF=im.createComponentLogger({namespace:"@opentelemetry/opentelemetry-instrumentation-fetch/utils"});function FF(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(e[0]instanceof URL||"string"==typeof e[0]){var n=e[1];if(!(null==n?void 0:n.body))return Promise.resolve();if(n.body instanceof ReadableStream){var r=function(e){if(!e.pipeThrough)return IF.warn("Platform has ReadableStream but not pipeThrough!"),{body:e,length:Promise.resolve(void 0)};var t,n=0,r=new Promise((function(e){t=e})),o=new TransformStream({start:function(){},transform:function(e,t){return MF(this,void 0,void 0,(function(){var r;return DF(this,(function(o){switch(o.label){case 0:return[4,e];case 1:return r=o.sent(),n+=r.byteLength,t.enqueue(e),[2]}}))}))},flush:function(){t(n)}});return{body:e.pipeThrough(o),length:r}}(n.body),o=r.length;return n.body=r.body,o}return Promise.resolve(function(e){if("undefined"!=typeof Document&&e instanceof Document)return(new XMLSerializer).serializeToString(document).length;if(e instanceof Blob)return e.size;if(void 0!==e.byteLength)return e.byteLength;if(e instanceof FormData)return function(e){var t,n,r=0;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e.entries()),i=o.next();!i.done;i=o.next()){var a=jF(i.value,2),s=a[1];r+=a[0].length,s instanceof Blob?r+=s.size:r+=s.length}}catch(l){t={error:l}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}(e);if(e instanceof URLSearchParams)return $F(e.toString());if("string"==typeof e)return $F(e);return void IF.warn("unknown body type")}(n.body))}var i=e[0];return(null==i?void 0:i.body)?i.clone().text().then((function(e){return $F(e)})):Promise.resolve()}var UF=new TextEncoder;function $F(e){return UF.encode(e).byteLength}var BF,VF,qF="0.57.2",zF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HF="object"==typeof process&&"node"===(null===(BF=process.release)||void 0===BF?void 0:BF.name),GF=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-fetch",qF,t)||this;return n.component="fetch",n.version=qF,n.moduleName=n.component,n._usedResources=new WeakSet,n._tasksCount=0,n}return zF(t,e),t.prototype.init=function(){},t.prototype._addChildSpan=function(e,t){var n=this.tracer.startSpan("CORS Preflight",{startTime:t[wF.FETCH_START]},bm.setSpan(om.active(),e));RF(n,t,this.getConfig().ignoreNetworkEvents),n.end(t[wF.RESPONSE_END])},t.prototype._addFinalSpanAttributes=function(e,t){var n=LF(t.url);e.setAttribute(xI,t.status),null!=t.statusText&&e.setAttribute(EF.HTTP_STATUS_TEXT,t.statusText),e.setAttribute(bI,n.host),e.setAttribute(wI,n.protocol.replace(":","")),"undefined"!=typeof navigator&&e.setAttribute(EI,navigator.userAgent)},t.prototype._addHeaders=function(e,t){if(!function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),LF(e).origin===PF()||n.some((function(t){return VI(e,t)}))}(t,this.getConfig().propagateTraceHeaderCorsUrls)){var n={};return ym.inject(om.active(),n),void(Object.keys(n).length>0&&this._diag.debug("headers inject skipped due to CORS policy"))}if(e instanceof Request)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else if(e.headers instanceof Headers)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else if(e.headers instanceof Map)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else{n={};ym.inject(om.active(),n),e.headers=Object.assign({},n,e.headers||{})}},t.prototype._clearResources=function(){0===this._tasksCount&&this.getConfig().clearTimingResources&&(performance.clearResourceTimings(),this._usedResources=new WeakSet)},t.prototype._createSpan=function(e,t){var n;if(void 0===t&&(t={}),!qI(e,this.getConfig().ignoreUrls)){var r=(t.method||"GET").toUpperCase();return this.tracer.startSpan("HTTP "+r,{kind:Hh.CLIENT,attributes:(n={},n[EF.COMPONENT]=this.moduleName,n[yI]=r,n[vI]=e,n)})}this._diag.debug("ignoring span as url matches ignored url")},t.prototype._findResourceAndAddNetworkEvents=function(e,t,n){var r=t.entries;if(!r.length){if(!performance.getEntriesByType)return;r=performance.getEntriesByType("resource")}var o=kF(t.spanUrl,t.startTime,n,r,this._usedResources,"fetch");if(o.mainRequest){var i=o.mainRequest;this._markResourceAsUsed(i);var a=o.corsPreFlightRequest;a&&(this._addChildSpan(e,a),this._markResourceAsUsed(a)),RF(e,i,this.getConfig().ignoreNetworkEvents)}},t.prototype._markResourceAsUsed=function(e){this._usedResources.add(e)},t.prototype._endSpan=function(e,t,n){var r=this,o=OI(Date.now()),i=RI();this._addFinalSpanAttributes(e,n),setTimeout((function(){var n;null===(n=t.observer)||void 0===n||n.disconnect(),r._findResourceAndAddNetworkEvents(e,t,i),r._tasksCount--,r._clearResources(),e.end(o)}),300)},t.prototype._patchConstructor=function(){var e=this;return function(t){var n=e;return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var o=this,i=LF(e[0]instanceof Request?e[0].url:String(e[0])).href,a=e[0]instanceof Request?e[0]:e[1]||{},s=n._createSpan(i,a);if(!s)return t.apply(this,e);var l=n._prepareSpanData(i);function c(e,t){n._applyAttributesAfterFetch(e,a,t),n._endSpan(e,l,{status:t.status||0,statusText:t.message,url:i})}function u(e,t){n._applyAttributesAfterFetch(e,a,t),n._endSpan(e,l,t.status>=200&&t.status<400?t:{status:t.status,statusText:t.statusText,url:i})}function d(e,t,n){try{var r=n.clone(),o=n.clone(),i=r.body;if(i){var a=i.getReader(),s=function(){a.read().then((function(t){t.done?u(e,o):s()}),(function(t){c(e,t)}))};s()}else u(e,n)}finally{t(n)}}function p(e,t,n){try{c(e,n)}finally{t(n)}}return n.getConfig().measureRequestSize&&FF.apply(void 0,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)).then((function(e){e&&s.setAttribute(_I,e)})).catch((function(e){n._diag.warn("getFetchBodyLength",e)})),new Promise((function(e,r){return om.with(bm.setSpan(om.active(),s),(function(){return n._addHeaders(a,i),n._tasksCount++,t.apply(o,a instanceof Request?[a]:[i,a]).then(d.bind(o,s,e),p.bind(o,s,r))}))}))}}},t.prototype._applyAttributesAfterFetch=function(e,t,n){var r=this,o=this.getConfig().applyCustomAttributesOnSpan;o&&function(e,t){var n,r;try{r=e()}catch(tme){n=tme}finally{return t(n,r),r}}((function(){return o(e,t,n)}),(function(e){e&&r._diag.error("applyCustomAttributesOnSpan",e)}))},t.prototype._prepareSpanData=function(e){var t=RI(),n=[];if("function"!=typeof PerformanceObserver)return{entries:n,startTime:t,spanUrl:e};var r=new PerformanceObserver((function(t){t.getEntries().forEach((function(t){"fetch"===t.initiatorType&&t.name===e&&n.push(t)}))}));return r.observe({entryTypes:["resource"]}),{entries:n,observer:r,startTime:t,spanUrl:e}},t.prototype.enable=function(){HF?this._diag.warn("this instrumentation is intended for web usage only, it does not instrument Node.js's fetch()"):(function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}(fetch)&&(this._unwrap(mI,"fetch"),this._diag.debug("removing previous patch for constructor")),this._wrap(mI,"fetch",this._patchConstructor()))},t.prototype.disable=function(){HF||(this._unwrap(mI,"fetch"),this._usedResources=new WeakSet)},t}(AF);!function(e){e.EVENT_TYPE="event_type",e.TARGET_ELEMENT="target_element",e.TARGET_XPATH="target_xpath",e.HTTP_URL="http.url"}(VF||(VF={}));var KF="0.44.1",WF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YF=["click"];function XF(){return!1}var QF=function(e){function t(t){var n;void 0===t&&(t={});var r=e.call(this,"@opentelemetry/instrumentation-user-interaction",KF,t)||this;return r.version=KF,r.moduleName="user-interaction",r._spansData=new WeakMap,r._wrappedListeners=new WeakMap,r._eventsSpanMap=new WeakMap,r._eventNames=new Set(null!==(n=null==t?void 0:t.eventNames)&&void 0!==n?n:YF),r._shouldPreventSpanCreation="function"==typeof(null==t?void 0:t.shouldPreventSpanCreation)?t.shouldPreventSpanCreation:XF,r}return WF(t,e),t.prototype.init=function(){},t.prototype._checkForTimeout=function(e,t){var n=this._spansData.get(t);n&&("setTimeout"===e.source?n.hrTimeLastTimeout=RI():"Promise.then"!==e.source&&"setTimeout"!==e.source&&(n.hrTimeLastTimeout=void 0))},t.prototype._allowEventName=function(e){return this._eventNames.has(e)},t.prototype._createSpan=function(e,t,n){var r;if(e instanceof HTMLElement&&e.getAttribute&&!e.hasAttribute("disabled")&&this._allowEventName(t)){var o=UM(e,!0);try{var i=this.tracer.startSpan(t,{attributes:(r={},r[VF.EVENT_TYPE]=t,r[VF.TARGET_ELEMENT]=e.tagName,r[VF.TARGET_XPATH]=o,r[VF.HTTP_URL]=window.location.href,r)},n?bm.setSpan(om.active(),n):void 0);if(!0===this._shouldPreventSpanCreation(t,e,i))return;return this._spansData.set(i,{taskCount:0}),i}catch(tme){this._diag.error("failed to start create new user interaction span",tme)}}},t.prototype._decrementTask=function(e){var t=this._spansData.get(e);t&&(t.taskCount--,0===t.taskCount&&this._tryToEndSpan(e,t.hrTimeLastTimeout))},t.prototype._getCurrentSpan=function(e){var t=e.get("OT_ZONE_CONTEXT");return t?bm.getSpan(t):t},t.prototype._incrementTask=function(e){var t=this._spansData.get(e);t&&t.taskCount++},t.prototype.addPatchedListener=function(e,t,n,r){var o=this._wrappedListeners.get(n);o||this._wrappedListeners.set(n,o=new Map);var i=o.get(t);return i||o.set(t,i=new Map),!i.has(e)&&(i.set(e,r),!0)},t.prototype.removePatchedListener=function(e,t,n){var r=this._wrappedListeners.get(n);if(r){var o=r.get(t);if(o){var i=o.get(e);return i&&(o.delete(e),0===o.size&&(r.delete(t),0===r.size&&this._wrappedListeners.delete(n))),i}}},t.prototype._invokeListener=function(e,t,n){return"function"==typeof e?e.apply(t,n):e.handleEvent(n[0])},t.prototype._patchAddEventListener=function(){var e=this;return function(t){return function(n,r,o){if(!r)return t.call(this,n,r,o);var i=o&&"object"==typeof o&&o.once,a=function(){for(var t,o=this,a=[],s=0;s<arguments.length;s++)a[s]=arguments[s];var l=a[0],c=null==l?void 0:l.target;l&&(t=e._eventsSpanMap.get(l)),i&&e.removePatchedListener(this,n,r);var u=e._createSpan(c,n,t);return u?(l&&e._eventsSpanMap.set(l,u),om.with(bm.setSpan(om.active(),u),(function(){var t=e._invokeListener(r,o,a);return u.end(),t}))):e._invokeListener(r,this,a)};return e.addPatchedListener(this,n,r,a)?t.call(this,n,a,o):void 0}}},t.prototype._patchRemoveEventListener=function(){var e=this;return function(t){return function(n,r,o){var i=e.removePatchedListener(this,n,r);return t.call(this,n,i||r,o)}}},t.prototype._getPatchableEventTargets=function(){return window.EventTarget?[EventTarget.prototype]:[Node.prototype,Window.prototype]},t.prototype._patchHistoryApi=function(){this._unpatchHistoryApi(),this._wrap(history,"replaceState",this._patchHistoryMethod()),this._wrap(history,"pushState",this._patchHistoryMethod()),this._wrap(history,"back",this._patchHistoryMethod()),this._wrap(history,"forward",this._patchHistoryMethod()),this._wrap(history,"go",this._patchHistoryMethod())},t.prototype._patchHistoryMethod=function(){var e=this;return function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var o=""+location.pathname+location.hash+location.search,i=t.apply(this,n),a=""+location.pathname+location.hash+location.search;return o!==a&&e._updateInteractionName(a),i}}},t.prototype._unpatchHistoryApi=function(){aF(history.replaceState)&&this._unwrap(history,"replaceState"),aF(history.pushState)&&this._unwrap(history,"pushState"),aF(history.back)&&this._unwrap(history,"back"),aF(history.forward)&&this._unwrap(history,"forward"),aF(history.go)&&this._unwrap(history,"go")},t.prototype._updateInteractionName=function(e){var t=bm.getSpan(om.active());t&&"function"==typeof t.updateName&&t.updateName("Navigation: "+e)},t.prototype._patchZoneCancelTask=function(){var e=this;return function(t){return function(n){var r=Zone.current,o=e._getCurrentSpan(r);return o&&e._shouldCountTask(n,r)&&e._decrementTask(o),t.call(this,n)}}},t.prototype._patchZoneScheduleTask=function(){var e=this;return function(t){return function(n){var r=Zone.current,o=e._getCurrentSpan(r);return o&&e._shouldCountTask(n,r)&&(e._incrementTask(o),e._checkForTimeout(n,o)),t.call(this,n)}}},t.prototype._patchZoneRunTask=function(){var e=this;return function(t){return function(n,r,o){var i,a=Array.isArray(o)&&o[0]instanceof Event?o[0]:void 0,s=null==a?void 0:a.target,l=this;if(s){if(i=e._createSpan(s,n.eventName))return e._incrementTask(i),l.run((function(){try{return om.with(bm.setSpan(om.active(),i),(function(){var e=Zone.current;return n._zone=e,t.call(e,n,r,o)}))}finally{e._decrementTask(i)}}))}else i=e._getCurrentSpan(l);try{return t.call(l,n,r,o)}finally{i&&e._shouldCountTask(n,l)&&e._decrementTask(i)}}}},t.prototype._shouldCountTask=function(e,t){if(e._zone&&(t=e._zone),!t||!e.data||e.data.isPeriodic)return!1;var n=this._getCurrentSpan(t);return!!n&&(!!this._spansData.get(n)&&("macroTask"===e.type||"microTask"===e.type))},t.prototype._tryToEndSpan=function(e,t){e&&(this._spansData.get(e)&&(e.end(t),this._spansData.delete(e)))},t.prototype.enable=function(){var e=this,t=this._getZoneWithPrototype();(this._diag.debug("applying patch to",this.moduleName,this.version,"zone:",!!t),t)?(aF(t.prototype.runTask)&&(this._unwrap(t.prototype,"runTask"),this._diag.debug("removing previous patch from method runTask")),aF(t.prototype.scheduleTask)&&(this._unwrap(t.prototype,"scheduleTask"),this._diag.debug("removing previous patch from method scheduleTask")),aF(t.prototype.cancelTask)&&(this._unwrap(t.prototype,"cancelTask"),this._diag.debug("removing previous patch from method cancelTask")),this._zonePatched=!0,this._wrap(t.prototype,"runTask",this._patchZoneRunTask()),this._wrap(t.prototype,"scheduleTask",this._patchZoneScheduleTask()),this._wrap(t.prototype,"cancelTask",this._patchZoneCancelTask())):(this._zonePatched=!1,this._getPatchableEventTargets().forEach((function(t){aF(t.addEventListener)&&(e._unwrap(t,"addEventListener"),e._diag.debug("removing previous patch from method addEventListener")),aF(t.removeEventListener)&&(e._unwrap(t,"removeEventListener"),e._diag.debug("removing previous patch from method removeEventListener")),e._wrap(t,"addEventListener",e._patchAddEventListener()),e._wrap(t,"removeEventListener",e._patchRemoveEventListener())})));this._patchHistoryApi()},t.prototype.disable=function(){var e=this,t=this._getZoneWithPrototype();(this._diag.debug("removing patch from",this.moduleName,this.version,"zone:",!!t),t&&this._zonePatched)?(aF(t.prototype.runTask)&&this._unwrap(t.prototype,"runTask"),aF(t.prototype.scheduleTask)&&this._unwrap(t.prototype,"scheduleTask"),aF(t.prototype.cancelTask)&&this._unwrap(t.prototype,"cancelTask")):this._getPatchableEventTargets().forEach((function(t){aF(t.addEventListener)&&e._unwrap(t,"addEventListener"),aF(t.removeEventListener)&&e._unwrap(t,"removeEventListener")}));this._unpatchHistoryApi()},t.prototype._getZoneWithPrototype=function(){return window.Zone},t}(oF),ZF=function(){function e(){}return e.prototype.emit=function(e){},e}(),JF=new ZF,eU=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new ZF},e}()),tU=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):JF},e}(),nU=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new tU(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:eU},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),rU="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},oU=Symbol.for("io.opentelemetry.js.api.logs"),iU=rU;var aU,sU,lU,cU=function(){function e(){this._proxyLoggerProvider=new nU}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return iU[oU]?this.getLoggerProvider():(iU[oU]=(t=1,n=e,r=eU,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=iU[oU])||void 0===e?void 0:e.call(iU,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete iU[oU],this._proxyLoggerProvider=new nU},e}().getInstance(),uU=function(){return uU=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},uU.apply(this,arguments)},dU=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=cU.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=uU({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),pU=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),fU=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return pU(t,e),t}(dU);function hU(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}function mU(e,t){return t in e}function gU(e,t,n,r){var o=void 0,i=void 0;mU(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=aU.FETCH_START;if(mU(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function yU(e,t,n){void 0===n&&(n=!1),n||(gU(e,aU.FETCH_START,t),gU(e,aU.DOMAIN_LOOKUP_START,t),gU(e,aU.DOMAIN_LOOKUP_END,t),gU(e,aU.CONNECT_START,t),mU(t,"name")&&t.name.startsWith("https:")&&gU(e,aU.SECURE_CONNECTION_START,t),gU(e,aU.CONNECT_END,t),gU(e,aU.REQUEST_START,t),gU(e,aU.RESPONSE_START,t),gU(e,aU.RESPONSE_END,t));var r=t[aU.ENCODED_BODY_SIZE];void 0!==r&&e.setAttribute(SI,r);var o=t[aU.DECODED_BODY_SIZE];void 0!==o&&r!==o&&e.setAttribute(TI,o)}function vU(){return"undefined"!=typeof location?location.origin:void 0}function bU(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=wU(e),s=function(e,t,n,r,o){var i=kI(t),a=kI(n),s=r.filter((function(t){var n=kI(PI(t[aU.FETCH_START])),r=kI(PI(t[aU.RESPONSE_END]));return"xmlhttprequest"===t.initiatorType.toLowerCase()&&t.name===e&&n>=i&&r<=a}));s.length>0&&(s=s.filter((function(e){return!o.has(e)})));return s}(e=a.toString(),t,n,r,o);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=function(e){return e.slice().sort((function(e,t){var n=e[aU.FETCH_START],r=t[aU.FETCH_START];return n>r?1:n<r?-1:0}))}(s);if(a.origin!==vU()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=kI(n),i=kI(PI(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=kI(PI(c[aU.FETCH_START])),d=o-kI(PI(c[aU.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[aU.RESPONSE_END],n);return u[aU.FETCH_START]<c[aU.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}}function wU(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(sU||(sU=document.createElement("a")),sU);return t.href=e,t}!function(e){e.CONNECT_END="connectEnd",e.CONNECT_START="connectStart",e.DECODED_BODY_SIZE="decodedBodySize",e.DOM_COMPLETE="domComplete",e.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",e.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",e.DOM_INTERACTIVE="domInteractive",e.DOMAIN_LOOKUP_END="domainLookupEnd",e.DOMAIN_LOOKUP_START="domainLookupStart",e.ENCODED_BODY_SIZE="encodedBodySize",e.FETCH_START="fetchStart",e.LOAD_EVENT_END="loadEventEnd",e.LOAD_EVENT_START="loadEventStart",e.NAVIGATION_START="navigationStart",e.REDIRECT_END="redirectEnd",e.REDIRECT_START="redirectStart",e.REQUEST_START="requestStart",e.RESPONSE_END="responseEnd",e.RESPONSE_START="responseStart",e.SECURE_CONNECTION_START="secureConnectionStart",e.UNLOAD_EVENT_END="unloadEventEnd",e.UNLOAD_EVENT_START="unloadEventStart"}(aU||(aU={})),function(e){e.METHOD_OPEN="open",e.METHOD_SEND="send",e.EVENT_ABORT="abort",e.EVENT_ERROR="error",e.EVENT_LOAD="loaded",e.EVENT_TIMEOUT="timeout"}(lU||(lU={}));var xU=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},EU=im.createComponentLogger({namespace:"@opentelemetry/opentelemetry-instrumentation-xml-http-request/utils"});function _U(e){return"undefined"!=typeof Document&&e instanceof Document?(new XMLSerializer).serializeToString(document).length:e instanceof Blob?e.size:void 0!==e.byteLength?e.byteLength:e instanceof FormData?function(e){var t,n,r=0;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e.entries()),i=o.next();!i.done;i=o.next()){var a=xU(i.value,2),s=a[1];r+=a[0].length,s instanceof Blob?r+=s.size:r+=s.length}}catch(l){t={error:l}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}(e):e instanceof URLSearchParams?TU(e.toString()):"string"==typeof e?TU(e):void EU.warn("unknown body type")}var SU=new TextEncoder;function TU(e){return SU.encode(e).byteLength}var CU,AU="0.57.2";!function(e){e.HTTP_STATUS_TEXT="http.status_text"}(CU||(CU={}));var OU=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NU=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-xml-http-request",AU,t)||this;return n.component="xml-http-request",n.version=AU,n.moduleName=n.component,n._tasksCount=0,n._xhrMem=new WeakMap,n._usedResources=new WeakSet,n}return OU(t,e),t.prototype.init=function(){},t.prototype._addHeaders=function(e,t){if(!function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),wU(e).origin===vU()||n.some((function(t){return VI(e,t)}))}(wU(t).href,this.getConfig().propagateTraceHeaderCorsUrls)){var n={};return ym.inject(om.active(),n),void(Object.keys(n).length>0&&this._diag.debug("headers inject skipped due to CORS policy"))}var r={};ym.inject(om.active(),r),Object.keys(r).forEach((function(t){e.setRequestHeader(t,String(r[t]))}))},t.prototype._addChildSpan=function(e,t){var n=this;om.with(bm.setSpan(om.active(),e),(function(){var e=n.tracer.startSpan("CORS Preflight",{startTime:t[aU.FETCH_START]});yU(e,t,n.getConfig().ignoreNetworkEvents),e.end(t[aU.RESPONSE_END])}))},t.prototype._addFinalSpanAttributes=function(e,t,n){if("string"==typeof n){var r=wU(n);void 0!==t.status&&e.setAttribute(xI,t.status),void 0!==t.statusText&&e.setAttribute(CU.HTTP_STATUS_TEXT,t.statusText),e.setAttribute(bI,r.host),e.setAttribute(wI,r.protocol.replace(":","")),e.setAttribute(EI,navigator.userAgent)}},t.prototype._applyAttributesAfterXHR=function(e,t){var n=this,r=this.getConfig().applyCustomAttributesOnSpan;"function"==typeof r&&function(e,t){var n,r;try{r=e()}catch(tme){n=tme}finally{return t(n,r),r}}((function(){return r(e,t)}),(function(e){e&&n._diag.error("applyCustomAttributesOnSpan",e)}))},t.prototype._addResourceObserver=function(e,t){var n=this._xhrMem.get(e);n&&"function"==typeof PerformanceObserver&&"function"==typeof PerformanceResourceTiming&&(n.createdResources={observer:new PerformanceObserver((function(e){var r=e.getEntries(),o=wU(t);r.forEach((function(e){"xmlhttprequest"===e.initiatorType&&e.name===o.href&&n.createdResources&&n.createdResources.entries.push(e)}))})),entries:[]},n.createdResources.observer.observe({entryTypes:["resource"]}))},t.prototype._clearResources=function(){0===this._tasksCount&&this.getConfig().clearTimingResources&&(gI.clearResourceTimings(),this._xhrMem=new WeakMap,this._usedResources=new WeakSet)},t.prototype._findResourceAndAddNetworkEvents=function(e,t,n,r,o){if(n&&r&&o&&e.createdResources){var i=e.createdResources.entries;i&&i.length||(i=gI.getEntriesByType("resource"));var a=bU(wU(n).href,r,o,i,this._usedResources);if(a.mainRequest){var s=a.mainRequest;this._markResourceAsUsed(s);var l=a.corsPreFlightRequest;l&&(this._addChildSpan(t,l),this._markResourceAsUsed(l)),yU(t,s,this.getConfig().ignoreNetworkEvents)}}},t.prototype._cleanPreviousSpanInformation=function(e){var t=this._xhrMem.get(e);if(t){var n=t.callbackToRemoveEvents;n&&n(),this._xhrMem.delete(e)}},t.prototype._createSpan=function(e,t,n){var r;if(!qI(t,this.getConfig().ignoreUrls)){var o=n.toUpperCase(),i=this.tracer.startSpan(o,{kind:Hh.CLIENT,attributes:(r={},r[yI]=n,r[vI]=wU(t).toString(),r)});return i.addEvent(lU.METHOD_OPEN),this._cleanPreviousSpanInformation(e),this._xhrMem.set(e,{span:i,spanUrl:t}),i}this._diag.debug("ignoring span as url matches ignored url")},t.prototype._markResourceAsUsed=function(e){this._usedResources.add(e)},t.prototype._patchOpen=function(){var e=this;return function(t){var n=e;return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return n._createSpan(this,e[1],e[0]),t.apply(this,e)}}},t.prototype._patchSend=function(){var e=this;function t(t,n){var r=e._xhrMem.get(n);if(r){r.status=n.status,r.statusText=n.statusText,e._xhrMem.delete(n),r.span&&e._applyAttributesAfterXHR(r.span,n);var o=RI(),i=Date.now();setTimeout((function(){!function(t,n,r,o){var i=n.callbackToRemoveEvents;"function"==typeof i&&i();var a=n.span,s=n.spanUrl;a&&(e._findResourceAndAddNetworkEvents(n,a,s,n.sendStartTime,r),a.addEvent(t,o),e._addFinalSpanAttributes(a,n,s),a.end(o),e._tasksCount--),e._clearResources()}(t,r,o,i)}),300)}}function n(){t(lU.EVENT_ERROR,this)}function r(){t(lU.EVENT_ABORT,this)}function o(){t(lU.EVENT_TIMEOUT,this)}function i(){t(this.status<299?lU.EVENT_LOAD:lU.EVENT_ERROR,this)}return function(t){return function(){for(var a=this,s=[],l=0;l<arguments.length;l++)s[l]=arguments[l];var c=e._xhrMem.get(this);if(!c)return t.apply(this,s);var u=c.span,d=c.spanUrl;if(u&&d){if(e.getConfig().measureRequestSize&&(null==s?void 0:s[0])){var p=_U(s[0]);void 0!==p&&u.setAttribute(_I,p)}om.with(bm.setSpan(om.active(),u),(function(){e._tasksCount++,c.sendStartTime=RI(),u.addEvent(lU.METHOD_SEND),a.addEventListener("abort",r),a.addEventListener("error",n),a.addEventListener("load",i),a.addEventListener("timeout",o),c.callbackToRemoveEvents=function(){!function(t){t.removeEventListener("abort",r),t.removeEventListener("error",n),t.removeEventListener("load",i),t.removeEventListener("timeout",o);var a=e._xhrMem.get(t);a&&(a.callbackToRemoveEvents=void 0)}(a),c.createdResources&&c.createdResources.observer.disconnect()},e._addHeaders(a,d),e._addResourceObserver(a,d)}))}return t.apply(this,s)}}},t.prototype.enable=function(){this._diag.debug("applying patch to",this.moduleName,this.version),hU(XMLHttpRequest.prototype.open)&&(this._unwrap(XMLHttpRequest.prototype,"open"),this._diag.debug("removing previous patch from method open")),hU(XMLHttpRequest.prototype.send)&&(this._unwrap(XMLHttpRequest.prototype,"send"),this._diag.debug("removing previous patch from method send")),this._wrap(XMLHttpRequest.prototype,"open",this._patchOpen()),this._wrap(XMLHttpRequest.prototype,"send",this._patchSend())},t.prototype.disable=function(){this._diag.debug("removing patch from",this.moduleName,this.version),this._unwrap(XMLHttpRequest.prototype,"open"),this._unwrap(XMLHttpRequest.prototype,"send"),this._tasksCount=0,this._xhrMem=new WeakMap,this._usedResources=new WeakSet},t}(fU),RU={"@opentelemetry/instrumentation-document-load":dF,"@opentelemetry/instrumentation-fetch":GF,"@opentelemetry/instrumentation-user-interaction":QF,"@opentelemetry/instrumentation-xml-http-request":NU};function PU(e){var t;void 0===e&&(e={});for(var n=0,r=Object.keys(e);n<r.length;n++){var o=r[n];Object.prototype.hasOwnProperty.call(RU,o)||im.error('Provided instrumentation name "'+o+'" not found')}for(var i=[],a=0,s=Object.keys(RU);a<s.length;a++){var l=s[a],c=RU[l],u=null!==(t=e[l])&&void 0!==t?t:{};if(!1!==u.enabled)try{im.debug("Loading instrumentation for "+l),i.push(new c(u))}catch(tme){im.error(tme)}else im.debug("Disabling instrumentation for "+l)}return i}let kU=!1;const LU=[/.*launchdarkly\.com.*/i,/.*\/api\/telemetry.*/i,new RegExp(`^(?!${Ee.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}/).*`)],MU={ignoreNetworkEvents:!0,propagateTraceHeaderCorsUrls:[new RegExp(Ee)],ignoreUrls:LU},DU=({tenantExternalId:e,partnerId:t,debug:r})=>{const o=(()=>{const{ldClient:e}=n.useContext(nl.reactContext);return e})(),i=o?.variation("show-fe-honeycomb-logs",!1);if(kU||!i)return null;try{ym.setGlobalPropagator(new BI);const n=new Tf.HoneycombWebSDK({tracesEndpoint:`${Ee}/telemetry`,serviceName:"sdk-client",debug:r,skipOptionsValidation:!0,instrumentations:[PU({"@opentelemetry/instrumentation-xml-http-request":{...MU,ignoreUrls:LU},"@opentelemetry/instrumentation-fetch":{...MU,ignoreUrls:LU},"@opentelemetry/instrumentation-document-load":{enabled:!1},"@opentelemetry/instrumentation-user-interaction":{enabled:!1}})],resourceAttributes:{"tenant.externalId":e,"partner.id":t}});n.start(),kU=!0,window.addEventListener("beforeunload",(()=>{n.shutdown().catch((e=>{}))}))}catch(tme){return null}return null};function jU(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function IU(...e){return t=>{let n=!1;const r=e.map((e=>{const r=jU(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():jU(e[t],null)}}}}function FU(...e){return i.useCallback(IU(...e),e)}var UU=i.forwardRef(((e,n)=>{const{children:r,...o}=e,a=i.Children.toArray(r),s=a.find(VU);if(s){const e=s.props.children,r=a.map((t=>t===s?i.Children.count(e)>1?i.Children.only(null):i.isValidElement(e)?e.props.children:null:t));return t.jsx($U,{...o,ref:n,children:i.isValidElement(e)?i.cloneElement(e,void 0,r):null})}return t.jsx($U,{...o,ref:n,children:r})}));UU.displayName="Slot";var $U=i.forwardRef(((e,t)=>{const{children:n,...r}=e;if(i.isValidElement(n)){const e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(n),o=function(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==i.Fragment&&(o.ref=t?IU(t,e):e),i.cloneElement(n,o)}return i.Children.count(n)>1?i.Children.only(null):null}));$U.displayName="SlotClone";var BU=({children:e})=>t.jsx(t.Fragment,{children:e});function VU(e){return i.isValidElement(e)&&e.type===BU}var qU=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,n)=>{const r=i.forwardRef(((e,r)=>{const{asChild:o,...i}=e,a=o?UU:n;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),t.jsx(a,{...i,ref:r})}));return r.displayName=`Primitive.${n}`,{...e,[n]:r}}),{}),zU=i.forwardRef(((e,n)=>t.jsx(qU.span,{...e,ref:n,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})));function HU(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}function GU(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function KU(...e){return t=>{let n=!1;const r=e.map((e=>{const r=GU(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():GU(e[t],null)}}}}function WU(...e){return i.useCallback(KU(...e),e)}function YU(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return i.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}zU.displayName="VisuallyHidden";var XU=globalThis?.document?i.useLayoutEffect:()=>{},QU=i[" useId ".trim().toString()]||(()=>{}),ZU=0;function JU(e){const[t,n]=i.useState(QU());return XU((()=>{n((e=>e??String(ZU++)))}),[e]),e||(t?`radix-${t}`:"")}function e$(e){const t=i.useRef(e);return i.useEffect((()=>{t.current=e})),i.useMemo((()=>(...e)=>t.current?.(...e)),[])}function t$({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=function({defaultProp:e,onChange:t}){const n=i.useState(e),[r]=n,o=i.useRef(r),a=e$(t);return i.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}({defaultProp:t,onChange:n}),a=void 0!==e,s=a?e:r,l=e$(n);return[s,i.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&l(n)}else o(t)}),[a,e,o,l])]}function n$(e){const n=r$(e),r=i.forwardRef(((e,r)=>{const{children:o,...a}=e,s=i.Children.toArray(o),l=s.find(i$);if(l){const e=l.props.children,o=s.map((t=>t===l?i.Children.count(e)>1?i.Children.only(null):i.isValidElement(e)?e.props.children:null:t));return t.jsx(n,{...a,ref:r,children:i.isValidElement(e)?i.cloneElement(e,void 0,o):null})}return t.jsx(n,{...a,ref:r,children:o})}));return r.displayName=`${e}.Slot`,r}function r$(e){const t=i.forwardRef(((e,t)=>{const{children:n,...r}=e;if(i.isValidElement(n)){const e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(n),o=function(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==i.Fragment&&(o.ref=t?KU(t,e):e),i.cloneElement(n,o)}return i.Children.count(n)>1?i.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var o$=Symbol("radix.slottable");function i$(e){return i.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===o$}var a$=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,n)=>{const r=n$(`Primitive.${n}`),o=i.forwardRef(((e,o)=>{const{asChild:i,...a}=e,s=i?r:n;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),t.jsx(s,{...a,ref:o})}));return o.displayName=`Primitive.${n}`,{...e,[n]:o}}),{});var s$,l$="dismissableLayer.update",c$="dismissableLayer.pointerDownOutside",u$="dismissableLayer.focusOutside",d$=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),p$=i.forwardRef(((e,n)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:l,onDismiss:c,...u}=e,d=i.useContext(d$),[p,f]=i.useState(null),h=p?.ownerDocument??globalThis?.document,[,m]=i.useState({}),g=WU(n,(e=>f(e))),y=Array.from(d.layers),[v]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=y.indexOf(v),w=p?y.indexOf(p):-1,x=d.layersWithOutsidePointerEventsDisabled.size>0,E=w>=b,_=function(e,t=globalThis?.document){const n=e$(e),r=i.useRef(!1),o=i.useRef((()=>{}));return i.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){h$(c$,n,i,{discrete:!0})};const i={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...d.branches].some((e=>e.contains(t)));E&&!n&&(a?.(e),l?.(e),e.defaultPrevented||c?.())}),h),S=function(e,t=globalThis?.document){const n=e$(e),r=i.useRef(!1);return i.useEffect((()=>{const e=e=>{if(e.target&&!r.current){h$(u$,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...d.branches].some((e=>e.contains(t)))||(s?.(e),l?.(e),e.defaultPrevented||c?.())}),h);return function(e,t=globalThis?.document){const n=e$(e);i.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}((e=>{w===d.layers.size-1&&(o?.(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))}),h),i.useEffect((()=>{if(p)return r&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(s$=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(p)),d.layers.add(p),f$(),()=>{r&&1===d.layersWithOutsidePointerEventsDisabled.size&&(h.body.style.pointerEvents=s$)}}),[p,h,r,d]),i.useEffect((()=>()=>{p&&(d.layers.delete(p),d.layersWithOutsidePointerEventsDisabled.delete(p),f$())}),[p,d]),i.useEffect((()=>{const e=()=>m({});return document.addEventListener(l$,e),()=>document.removeEventListener(l$,e)}),[]),t.jsx(a$.div,{...u,ref:g,style:{pointerEvents:x?E?"auto":"none":void 0,...e.style},onFocusCapture:HU(e.onFocusCapture,S.onFocusCapture),onBlurCapture:HU(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:HU(e.onPointerDownCapture,_.onPointerDownCapture)})}));p$.displayName="DismissableLayer";function f$(){const e=new CustomEvent(l$);document.dispatchEvent(e)}function h$(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?function(e,t){e&&a.flushSync((()=>e.dispatchEvent(t)))}(o,i):o.dispatchEvent(i)}i.forwardRef(((e,n)=>{const r=i.useContext(d$),o=i.useRef(null),a=WU(n,o);return i.useEffect((()=>{const e=o.current;if(e)return r.branches.add(e),()=>{r.branches.delete(e)}}),[r.branches]),t.jsx(a$.div,{...e,ref:a})})).displayName="DismissableLayerBranch";var m$="focusScope.autoFocusOnMount",g$="focusScope.autoFocusOnUnmount",y$={bubbles:!1,cancelable:!0},v$=i.forwardRef(((e,n)=>{const{loop:r=!1,trapped:o=!1,onMountAutoFocus:a,onUnmountAutoFocus:s,...l}=e,[c,u]=i.useState(null),d=e$(a),p=e$(s),f=i.useRef(null),h=WU(n,(e=>u(e))),m=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect((()=>{if(o){let e=function(e){if(m.paused||!c)return;const t=e.target;c.contains(t)?f.current=t:E$(f.current,{select:!0})},t=function(e){if(m.paused||!c)return;const t=e.relatedTarget;null!==t&&(c.contains(t)||E$(f.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&E$(c)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return c&&r.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[o,c,m.paused]),i.useEffect((()=>{if(c){_$.add(m);const t=document.activeElement;if(!c.contains(t)){const n=new CustomEvent(m$,y$);c.addEventListener(m$,d),c.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(E$(r,{select:t}),document.activeElement!==n)return}((e=b$(c),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&E$(c))}return()=>{c.removeEventListener(m$,d),setTimeout((()=>{const e=new CustomEvent(g$,y$);c.addEventListener(g$,p),c.dispatchEvent(e),e.defaultPrevented||E$(t??document.body,{select:!0}),c.removeEventListener(g$,p),_$.remove(m)}),0)}}var e}),[c,d,p,m]);const g=i.useCallback((e=>{if(!r&&!o)return;if(m.paused)return;const t=document.activeElement;if("Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey&&t){const n=e.currentTarget,[o,i]=function(e){const t=b$(e),n=w$(t,e),r=w$(t.reverse(),e);return[n,r]}(n);o&&i?e.shiftKey||t!==i?e.shiftKey&&t===o&&(e.preventDefault(),r&&E$(i,{select:!0})):(e.preventDefault(),r&&E$(o,{select:!0})):t===n&&e.preventDefault()}}),[r,o,m.paused]);return t.jsx(a$.div,{tabIndex:-1,...l,ref:h,onKeyDown:g})}));function b$(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.disabled||e.hidden||"INPUT"===e.tagName&&"hidden"===e.type?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}function w$(e,t){for(const n of e)if(!x$(n,{upTo:t}))return n}function x$(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function E$(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}v$.displayName="FocusScope";var _$=function(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=S$(e,t),e.unshift(t)},remove(t){e=S$(e,t),e[0]?.resume()}}}();function S$(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var T$=i.forwardRef(((e,n)=>{const{container:o,...a}=e,[s,l]=i.useState(!1);XU((()=>l(!0)),[]);const c=o||s&&globalThis?.document?.body;return c?r.createPortal(t.jsx(a$.div,{...a,ref:n}),c):null}));T$.displayName="Portal";var C$=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=i.useState(),r=i.useRef({}),o=i.useRef(e),a=i.useRef("none"),s=e?"mounted":"unmounted",[l,c]=function(e,t){return i.useReducer(((e,n)=>t[e][n]??e),e)}(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect((()=>{const e=A$(r.current);a.current="mounted"===l?e:"none"}),[l]),XU((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=A$(t);if(e)c("MOUNT");else if("none"===i||"none"===t?.display)c("UNMOUNT");else{c(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}o.current=e}}),[e,c]),XU((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=i=>{const a=A$(r.current).includes(i.animationName);if(i.target===t&&a&&(c("ANIMATION_END"),!o.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(a.current=A$(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}c("ANIMATION_END")}),[t,c]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:i.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),o="function"==typeof n?n({present:r.isPresent}):i.Children.only(n),a=WU(r.ref,function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(o));return"function"==typeof n||r.isPresent?i.cloneElement(o,{ref:a}):null};function A$(e){return e?.animationName||"none"}C$.displayName="Presence";var O$=0;function N$(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var R$=function(){return R$=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},R$.apply(this,arguments)};function P$(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}"function"==typeof SuppressedError&&SuppressedError;var k$="right-scroll-bar-position",L$="width-before-scroll-bar";function M$(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var D$="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,j$=new WeakMap;function I$(e,t){var r=function(e,t){var r=n.useState((function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(e){var t=r.value;t!==e&&(r.value=e,r.callback(e,t))}}}}))[0];return r.callback=t,r.facade}(null,(function(t){return e.forEach((function(e){return M$(e,t)}))}));return D$((function(){var t=j$.get(r);if(t){var n=new Set(t),o=new Set(e),i=r.current;n.forEach((function(e){o.has(e)||M$(e,null)})),o.forEach((function(e){n.has(e)||M$(e,i)}))}j$.set(r,e)}),[e]),r}function F$(e){return e}var U$=function(e){var t=e.sideCar,n=P$(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return i.createElement(r,R$({},n))};U$.isSideCarExport=!0;var $$=function(e){void 0===e&&(e={});var t=function(e,t){void 0===t&&(t=F$);var n=[],r=!1;return{read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var o=t(e,r);return n.push(o),function(){n=n.filter((function(e){return e!==o}))}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var o=n;n=[],o.forEach(e),t=n}var i=function(){var n=t;t=[],n.forEach(e)},a=function(){return Promise.resolve().then(i)};a(),n={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),n}}}}}(null);return t.options=R$({async:!0,ssr:!1},e),t}(),B$=function(){},V$=i.forwardRef((function(e,t){var n=i.useRef(null),r=i.useState({onScrollCapture:B$,onWheelCapture:B$,onTouchMoveCapture:B$}),o=r[0],a=r[1],s=e.forwardProps,l=e.children,c=e.className,u=e.removeScrollBar,d=e.enabled,p=e.shards,f=e.sideCar,h=e.noIsolation,m=e.inert,g=e.allowPinchZoom,y=e.as,v=void 0===y?"div":y,b=e.gapMode,w=P$(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=f,E=I$([n,t]),_=R$(R$({},w),o);return i.createElement(i.Fragment,null,d&&i.createElement(x,{sideCar:$$,removeScrollBar:u,shards:p,noIsolation:h,inert:m,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:b}),s?i.cloneElement(i.Children.only(l),R$(R$({},_),{ref:E})):i.createElement(v,R$({},_,{className:c,ref:E}),l))}));V$.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},V$.classNames={fullWidth:L$,zeroRight:k$};function q$(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=function(){if("undefined"!=typeof __webpack_nonce__)return __webpack_nonce__}();return t&&e.setAttribute("nonce",t),e}var z$=function(){var e=0,t=null;return{add:function(n){var r,o;0==e&&(t=q$())&&(o=n,(r=t).styleSheet?r.styleSheet.cssText=o:r.appendChild(document.createTextNode(o)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){! --e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},H$=function(){var e,t=(e=z$(),function(t,n){i.useEffect((function(){return e.add(t),function(){e.remove()}}),[t&&n])});return function(e){return t(e.styles,e.dynamic),null}},G$={left:0,top:0,right:0,gap:0},K$=function(e){return parseInt(e||"",10)||0},W$=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return G$;var t=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingTop":"marginTop"],r=t["padding"===e?"paddingRight":"marginRight"];return[K$(t["padding"===e?"paddingLeft":"marginLeft"]),K$(n),K$(r)]}(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Y$=H$(),X$="data-scroll-locked",Q$=function(e,t,n,r){var o=e.left,i=e.top,a=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(s,"px ").concat(r,";\n }\n body[").concat(X$,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(k$," {\n right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(L$," {\n margin-right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(k$," .").concat(k$," {\n right: 0 ").concat(r,";\n }\n \n .").concat(L$," .").concat(L$," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(X$,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},Z$=function(){var e=parseInt(document.body.getAttribute(X$)||"0",10);return isFinite(e)?e:0},J$=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=void 0===r?"margin":r;i.useEffect((function(){return document.body.setAttribute(X$,(Z$()+1).toString()),function(){var e=Z$()-1;e<=0?document.body.removeAttribute(X$):document.body.setAttribute(X$,e.toString())}}),[]);var a=i.useMemo((function(){return W$(o)}),[o]);return i.createElement(Y$,{styles:Q$(a,!t,o,n?"":"!important")})},eB=!1;if("undefined"!=typeof window)try{var tB=Object.defineProperty({},"passive",{get:function(){return eB=!0,!0}});window.addEventListener("test",tB,tB),window.removeEventListener("test",tB,tB)}catch(nme){eB=!1}var nB=!!eB&&{passive:!1},rB=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!function(e){return"TEXTAREA"===e.tagName}(e)&&"visible"===n[t])},oB=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),iB(e,r)){var o=aB(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},iB=function(e,t){return"v"===e?function(e){return rB(e,"overflowY")}(t):function(e){return rB(e,"overflowX")}(t)},aB=function(e,t){return"v"===e?[(n=t).scrollTop,n.scrollHeight,n.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var n},sB=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},lB=function(e){return[e.deltaX,e.deltaY]},cB=function(e){return e&&"current"in e?e.current:e},uB=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},dB=0,pB=[];function fB(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const hB=(mB=function(e){var t=i.useRef([]),n=i.useRef([0,0]),r=i.useRef(),o=i.useState(dB++)[0],a=i.useState(H$)[0],s=i.useRef(e);i.useEffect((function(){s.current=e}),[e]),i.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([e.lockRef.current],(e.shards||[]).map(cB),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(o))})),function(){document.body.classList.remove("block-interactivity-".concat(o)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(o))}))}}}),[e.inert,e.lockRef.current,e.shards]);var l=i.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!s.current.allowPinchZoom;var o,i=sB(e),a=n.current,l="deltaX"in e?e.deltaX:a[0]-i[0],c="deltaY"in e?e.deltaY:a[1]-i[1],u=e.target,d=Math.abs(l)>Math.abs(c)?"h":"v";if("touches"in e&&"h"===d&&"range"===u.type)return!1;var p=oB(d,u);if(!p)return!0;if(p?o=d:(o="v"===d?"h":"v",p=oB(d,u)),!p)return!1;if(!r.current&&"changedTouches"in e&&(l||c)&&(r.current=o),!o)return!0;var f=r.current||o;return function(e,t,n,r){var o=function(e,t){return"h"===e&&"rtl"===t?-1:1}(e,window.getComputedStyle(t).direction),i=o*r,a=n.target,s=t.contains(a),l=!1,c=i>0,u=0,d=0;do{var p=aB(e,a),f=p[0],h=p[1]-p[2]-o*f;(f||h)&&iB(e,a)&&(u+=h,d+=f),a=a instanceof ShadowRoot?a.host:a.parentNode}while(!s&&a!==document.body||s&&(t.contains(a)||t===a));return(c&&Math.abs(u)<1||!c&&Math.abs(d)<1)&&(l=!0),l}(f,t,e,"h"===f?l:c)}),[]),c=i.useCallback((function(e){var n=e;if(pB.length&&pB[pB.length-1]===a){var r="deltaY"in n?lB(n):sB(n),o=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&(t=e.delta)[0]===(o=r)[0]&&t[1]===o[1];var t,o}))[0];if(o&&o.should)n.cancelable&&n.preventDefault();else if(!o){var i=(s.current.shards||[]).map(cB).filter(Boolean).filter((function(e){return e.contains(n.target)}));(i.length>0?l(n,i[0]):!s.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),u=i.useCallback((function(e,n,r,o){var i={name:e,delta:n,target:r,should:o,shadowParent:fB(r)};t.current.push(i),setTimeout((function(){t.current=t.current.filter((function(e){return e!==i}))}),1)}),[]),d=i.useCallback((function(e){n.current=sB(e),r.current=void 0}),[]),p=i.useCallback((function(t){u(t.type,lB(t),t.target,l(t,e.lockRef.current))}),[]),f=i.useCallback((function(t){u(t.type,sB(t),t.target,l(t,e.lockRef.current))}),[]);i.useEffect((function(){return pB.push(a),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:f}),document.addEventListener("wheel",c,nB),document.addEventListener("touchmove",c,nB),document.addEventListener("touchstart",d,nB),function(){pB=pB.filter((function(e){return e!==a})),document.removeEventListener("wheel",c,nB),document.removeEventListener("touchmove",c,nB),document.removeEventListener("touchstart",d,nB)}}),[]);var h=e.removeScrollBar;return i.createElement(i.Fragment,null,e.inert?i.createElement(a,{styles:uB(o)}):null,h?i.createElement(J$,{gapMode:e.gapMode}):null)},$$.useMedium(mB),U$);var mB,gB=i.forwardRef((function(e,t){return i.createElement(V$,R$({},e,{ref:t,sideCar:hB}))}));gB.classNames=V$.classNames;var yB=new WeakMap,vB=new WeakMap,bB={},wB=0,xB=function(e){return e&&(e.host||xB(e.parentNode))},EB=function(e,t,n,r){var o=function(e,t){return t.map((function(t){if(e.contains(t))return t;var n=xB(t);return n&&e.contains(n)?n:null})).filter((function(e){return Boolean(e)}))}(t,Array.isArray(e)?e:[e]);bB[n]||(bB[n]=new WeakMap);var i=bB[n],a=[],s=new Set,l=new Set(o),c=function(e){e&&!s.has(e)&&(s.add(e),c(e.parentNode))};o.forEach(c);var u=function(e){e&&!l.has(e)&&Array.prototype.forEach.call(e.children,(function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),o=null!==t&&"false"!==t,l=(yB.get(e)||0)+1,c=(i.get(e)||0)+1;yB.set(e,l),i.set(e,c),a.push(e),1===l&&o&&vB.set(e,!0),1===c&&e.setAttribute(n,"true"),o||e.setAttribute(r,"true")}catch(tme){}}))};return u(t),s.clear(),wB++,function(){a.forEach((function(e){var t=yB.get(e)-1,o=i.get(e)-1;yB.set(e,t),i.set(e,o),t||(vB.has(e)||e.removeAttribute(r),vB.delete(e)),o||e.removeAttribute(n)})),--wB||(yB=new WeakMap,yB=new WeakMap,vB=new WeakMap,bB={})}},_B=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body}(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),EB(r,o,n,"aria-hidden")):function(){return null}},SB="Dialog",[TB,CB]=function(e,n=[]){let r=[];const o=()=>{const t=r.map((e=>i.createContext(e)));return function(n){const r=n?.[e]||t;return i.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return o.scopeName=e,[function(n,o){const a=i.createContext(o),s=r.length;r=[...r,o];const l=n=>{const{scope:r,children:o,...l}=n,c=r?.[e]?.[s]||a,u=i.useMemo((()=>l),Object.values(l));return t.jsx(c.Provider,{value:u,children:o})};return l.displayName=n+"Provider",[l,function(t,r){const l=i.useContext(r?.[e]?.[s]||a);if(l)return l;if(void 0!==o)return o;throw new Error(`\`${t}\` must be used within \`${n}\``)}]},YU(o,...n)]}(SB),[AB,OB]=TB(SB),NB=e=>{const{__scopeDialog:n,children:r,open:o,defaultOpen:a,onOpenChange:s,modal:l=!0}=e,c=i.useRef(null),u=i.useRef(null),[d=!1,p]=t$({prop:o,defaultProp:a,onChange:s});return t.jsx(AB,{scope:n,triggerRef:c,contentRef:u,contentId:JU(),titleId:JU(),descriptionId:JU(),open:d,onOpenChange:p,onOpenToggle:i.useCallback((()=>p((e=>!e))),[p]),modal:l,children:r})};NB.displayName=SB;var RB="DialogTrigger";i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(RB,r),a=WU(n,i.triggerRef);return t.jsx(a$.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":XB(i.open),...o,ref:a,onClick:HU(e.onClick,i.onOpenToggle)})})).displayName=RB;var PB="DialogPortal",[kB,LB]=TB(PB,{forceMount:void 0}),MB=e=>{const{__scopeDialog:n,forceMount:r,children:o,container:a}=e,s=OB(PB,n);return t.jsx(kB,{scope:n,forceMount:r,children:i.Children.map(o,(e=>t.jsx(C$,{present:r||s.open,children:t.jsx(T$,{asChild:!0,container:a,children:e})})))})};MB.displayName=PB;var DB="DialogOverlay",jB=i.forwardRef(((e,n)=>{const r=LB(DB,e.__scopeDialog),{forceMount:o=r.forceMount,...i}=e,a=OB(DB,e.__scopeDialog);return a.modal?t.jsx(C$,{present:o||a.open,children:t.jsx(FB,{...i,ref:n})}):null}));jB.displayName=DB;var IB=n$("DialogOverlay.RemoveScroll"),FB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(DB,r);return t.jsx(gB,{as:IB,allowPinchZoom:!0,shards:[i.contentRef],children:t.jsx(a$.div,{"data-state":XB(i.open),...o,ref:n,style:{pointerEvents:"auto",...o.style}})})})),UB="DialogContent",$B=i.forwardRef(((e,n)=>{const r=LB(UB,e.__scopeDialog),{forceMount:o=r.forceMount,...i}=e,a=OB(UB,e.__scopeDialog);return t.jsx(C$,{present:o||a.open,children:t.jsx(a.modal?BB:VB,{...i,ref:n})})}));$B.displayName=UB;var BB=i.forwardRef(((e,n)=>{const r=OB(UB,e.__scopeDialog),o=i.useRef(null),a=WU(n,r.contentRef,o);return i.useEffect((()=>{const e=o.current;if(e)return _B(e)}),[]),t.jsx(qB,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:HU(e.onCloseAutoFocus,(e=>{e.preventDefault(),r.triggerRef.current?.focus()})),onPointerDownOutside:HU(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent;(2===t.button||0===t.button&&!0===t.ctrlKey)&&e.preventDefault()})),onFocusOutside:HU(e.onFocusOutside,(e=>e.preventDefault()))})})),VB=i.forwardRef(((e,n)=>{const r=OB(UB,e.__scopeDialog),o=i.useRef(!1),a=i.useRef(!1);return t.jsx(qB,{...e,ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(o.current||r.triggerRef.current?.focus(),t.preventDefault()),o.current=!1,a.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(o.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const n=t.target,i=r.triggerRef.current?.contains(n);i&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),qB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,...l}=e,c=OB(UB,r),u=i.useRef(null),d=WU(n,u);return i.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??N$()),document.body.insertAdjacentElement("beforeend",e[1]??N$()),O$++,()=>{1===O$&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),O$--}}),[]),t.jsxs(t.Fragment,{children:[t.jsx(v$,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:a,onUnmountAutoFocus:s,children:t.jsx(p$,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":XB(c.open),...l,ref:d,onDismiss:()=>c.onOpenChange(!1)})}),t.jsxs(t.Fragment,{children:[t.jsx(eV,{titleId:c.titleId}),t.jsx(tV,{contentRef:u,descriptionId:c.descriptionId})]})]})})),zB="DialogTitle",HB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(zB,r);return t.jsx(a$.h2,{id:i.titleId,...o,ref:n})}));HB.displayName=zB;var GB="DialogDescription",KB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(GB,r);return t.jsx(a$.p,{id:i.descriptionId,...o,ref:n})}));KB.displayName=GB;var WB="DialogClose",YB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(WB,r);return t.jsx(a$.button,{type:"button",...o,ref:n,onClick:HU(e.onClick,(()=>i.onOpenChange(!1)))})}));function XB(e){return e?"open":"closed"}YB.displayName=WB;var QB="DialogTitleWarning",[ZB,JB]=function(e,n){const r=i.createContext(n),o=e=>{const{children:n,...o}=e,a=i.useMemo((()=>o),Object.values(o));return t.jsx(r.Provider,{value:a,children:n})};return o.displayName=e+"Provider",[o,function(t){const o=i.useContext(r);if(o)return o;if(void 0!==n)return n;throw new Error(`\`${t}\` must be used within \`${e}\``)}]}(QB,{contentName:UB,titleName:zB,docsSlug:"dialog"}),eV=({titleId:e})=>{const t=JB(QB);return i.useEffect((()=>{if(e){document.getElementById(e)}}),[`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.\n\nIf you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`,e]),null},tV=({contentRef:e,descriptionId:t})=>{const n=JB("DialogDescriptionWarning");return i.useEffect((()=>{const n=e.current?.getAttribute("aria-describedby");if(t&&n){document.getElementById(t)}}),[`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${n.contentName}}.`,e,t]),null},nV=NB,rV=MB,oV=jB,iV=$B,aV=HB,sV=KB,lV=YB;function cV(...e){return Vd(Xc(e))}const uV=nV,dV=({...e})=>t.jsx(rV,{children:t.jsx("div",{"data-reach-root":!0,children:e.children})}),pV=i.forwardRef((({className:e,...n},r)=>t.jsx(oV,{ref:r,className:cV("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n})));pV.displayName=oV.displayName;const fV=i.forwardRef((({className:e,children:n,hideCloseButton:r=!1,...o},i)=>t.jsxs(dV,{children:[t.jsx(pV,{}),t.jsxs(iV,{ref:i,className:cV("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),onInteractOutside:e=>{e.composedPath().some((e=>"classList"in e&&Array.from(e.classList).includes("pac-item")))&&e.preventDefault()},...o,children:[n,!r&&t.jsxs(lV,{className:"absolute right-6 top-6 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[t.jsx(Yu,{className:"h-6 w-6"}),t.jsx("span",{className:"sr-only",children:"Close"})]})]})]})));fV.displayName=iV.displayName;const hV=({className:e,...n})=>t.jsx("div",{className:cV("flex flex-col space-y-1.5 text-center sm:text-left",e),...n});hV.displayName="DialogHeader";const mV=i.forwardRef((({className:e,...n},r)=>t.jsx(aV,{ref:r,className:cV("text-lg font-semibold leading-none tracking-tight text-foreground",e),...n})));mV.displayName=aV.displayName;const gV=i.forwardRef((({className:e,...n},r)=>t.jsx(sV,{ref:r,className:cV("text-sm text-muted-foreground",e),...n})));gV.displayName=sV.displayName;i.forwardRef((({className:e,children:n,...r},o)=>t.jsx(zU,{ref:o,className:cV(e),...r,children:n}))).displayName="DialogVisuallyHidden";const yV=n.createContext({});function vV(e){const t=n.useRef(null);return null===t.current&&(t.current=e()),t.current}const bV=n.createContext(null),wV=n.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});class xV extends i.Component{getSnapshotBeforeUpdate(e){const t=this.props.childRef.current;if(t&&e.isPresent&&!this.props.isPresent){const e=t.offsetParent,n=e instanceof HTMLElement&&e.offsetWidth||0,r=this.props.sizeRef.current;r.height=t.offsetHeight||0,r.width=t.offsetWidth||0,r.top=t.offsetTop,r.left=t.offsetLeft,r.right=n-r.width-r.left}return null}componentDidUpdate(){}render(){return this.props.children}}function EV({children:e,isPresent:r,anchorX:o}){const a=n.useId(),s=n.useRef(null),l=n.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:c}=n.useContext(wV);return n.useInsertionEffect((()=>{const{width:e,height:t,top:n,left:i,right:u}=l.current;if(r||!s.current||!e||!t)return;const d="left"===o?`left: ${i}`:`right: ${u}`;s.current.dataset.motionPopId=a;const p=document.createElement("style");return c&&(p.nonce=c),document.head.appendChild(p),p.sheet&&p.sheet.insertRule(`\n [data-motion-pop-id="${a}"] {\n position: absolute !important;\n width: ${e}px !important;\n height: ${t}px !important;\n ${d}px !important;\n top: ${n}px !important;\n }\n `),()=>{document.head.removeChild(p)}}),[r]),t.jsx(xV,{isPresent:r,childRef:s,sizeRef:l,children:i.cloneElement(e,{ref:s})})}const _V=({children:e,initial:r,isPresent:o,onExitComplete:a,custom:s,presenceAffectsLayout:l,mode:c,anchorX:u})=>{const d=vV(SV),p=n.useId(),f=n.useCallback((e=>{d.set(e,!0);for(const t of d.values())if(!t)return;a&&a()}),[d,a]),h=n.useMemo((()=>({id:p,initial:r,isPresent:o,custom:s,onExitComplete:f,register:e=>(d.set(e,!1),()=>d.delete(e))})),l?[Math.random(),f]:[o,f]);return n.useMemo((()=>{d.forEach(((e,t)=>d.set(t,!1)))}),[o]),i.useEffect((()=>{!o&&!d.size&&a&&a()}),[o]),"popLayout"===c&&(e=t.jsx(EV,{isPresent:o,anchorX:u,children:e})),t.jsx(bV.Provider,{value:h,children:e})};function SV(){return new Map}function TV(e=!0){const t=n.useContext(bV);if(null===t)return[!0,null];const{isPresent:r,onExitComplete:o,register:i}=t,a=n.useId();n.useEffect((()=>{e&&i(a)}),[e]);const s=n.useCallback((()=>e&&o&&o(a)),[a,o,e]);return!r&&o?[!1,s]:[!0]}const CV=e=>e.key||"";function AV(e){const t=[];return n.Children.forEach(e,(e=>{n.isValidElement(e)&&t.push(e)})),t}const OV="undefined"!=typeof window,NV=OV?n.useLayoutEffect:n.useEffect,RV=({children:e,custom:r,initial:o=!0,onExitComplete:i,presenceAffectsLayout:a=!0,mode:s="sync",propagate:l=!1,anchorX:c="left"})=>{const[u,d]=TV(l),p=n.useMemo((()=>AV(e)),[e]),f=l&&!u?[]:p.map(CV),h=n.useRef(!0),m=n.useRef(p),g=vV((()=>new Map)),[y,v]=n.useState(p),[b,w]=n.useState(p);NV((()=>{h.current=!1,m.current=p;for(let e=0;e<b.length;e++){const t=CV(b[e]);f.includes(t)?g.delete(t):!0!==g.get(t)&&g.set(t,!1)}}),[b,f.length,f.join("-")]);const x=[];if(p!==y){let e=[...p];for(let t=0;t<b.length;t++){const n=b[t],r=CV(n);f.includes(r)||(e.splice(t,0,n),x.push(n))}return"wait"===s&&x.length&&(e=x),w(AV(e)),v(p),null}process;const{forceRender:E}=n.useContext(yV);return t.jsx(t.Fragment,{children:b.map((e=>{const n=CV(e),y=!(l&&!u)&&(p===b||f.includes(n));return t.jsx(_V,{isPresent:y,initial:!(h.current&&!o)&&void 0,custom:r,presenceAffectsLayout:a,mode:s,onExitComplete:y?void 0:()=>{if(!g.has(n))return;g.set(n,!0);let e=!0;g.forEach((t=>{t||(e=!1)})),e&&(null==E||E(),w(m.current),l&&(null==d||d()),i&&i())},anchorX:c,children:e},n)}))})},PV=e=>e;let kV=PV,LV=PV;function MV(e){let t;return()=>(void 0===t&&(t=e()),t)}"production"!==process.env.NODE_ENV&&(kV=(e,t)=>{},LV=(e,t)=>{if(!e)throw new Error(t)});const DV=(e,t,n)=>{const r=t-e;return 0===r?1:(n-e)/r},jV=e=>1e3*e,IV=e=>e/1e3,FV=!1,UV=["read","resolveKeyframes","update","preRender","render","postRender"],$V={value:null};function BV(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,a=UV.reduce(((e,n)=>(e[n]=function(e,t){let n=new Set,r=new Set,o=!1,i=!1;const a=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1},l=0;function c(t){a.has(t)&&(u.schedule(t),e()),l++,t(s)}const u={schedule:(e,t=!1,i=!1)=>{const s=i&&o?n:r;return t&&a.add(e),s.has(e)||s.add(e),e},cancel:e=>{r.delete(e),a.delete(e)},process:e=>{s=e,o?i=!0:(o=!0,[n,r]=[r,n],n.forEach(c),t&&$V.value&&$V.value.frameloop[t].push(l),l=0,n.clear(),o=!1,i&&(i=!1,u.process(e)))}};return u}(i,t?n:void 0),e)),{}),{read:s,resolveKeyframes:l,update:c,preRender:u,render:d,postRender:p}=a,f=()=>{const i=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(i-o.timestamp,40),1),o.timestamp=i,o.isProcessing=!0,s.process(o),l.process(o),c.process(o),u.process(o),d.process(o),p.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(f))};return{schedule:UV.reduce(((t,i)=>{const s=a[i];return t[i]=(t,i=!1,a=!1)=>(n||(n=!0,r=!0,o.isProcessing||e(f)),s.schedule(t,i,a)),t}),{}),cancel:e=>{for(let t=0;t<UV.length;t++)a[UV[t]].cancel(e)},state:o,steps:a}}const{schedule:VV,cancel:qV,state:zV,steps:HV}=BV("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:PV,!0),GV=n.createContext({strict:!1}),KV={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},WV={};for(const ome in KV)WV[ome]={isEnabled:e=>KV[ome].some((t=>!!e[t]))};const YV=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function XV(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||YV.has(e)}let QV=e=>!XV(e);try{(ZV=require("@emotion/is-prop-valid").default)&&(QV=e=>e.startsWith("on")?!XV(e):ZV(e))}catch(rme){}var ZV;const JV=new Set;function eq(e,t,n){e||JV.has(t)||JV.add(t)}function tq(e){if("undefined"==typeof Proxy)return e;const t=new Map;return new Proxy(((...t)=>("production"!==process.env.NODE_ENV&&eq(!1,"motion() is deprecated. Use motion.create() instead."),e(...t))),{get:(n,r)=>"create"===r?e:(t.has(r)||t.set(r,e(r)),t.get(r))})}const nq=n.createContext({});function rq(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}function oq(e){return"string"==typeof e||Array.isArray(e)}const iq=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],aq=["initial",...iq];function sq(e){return rq(e.animate)||aq.some((t=>oq(e[t])))}function lq(e){return Boolean(sq(e)||e.variants)}function cq(e){const{initial:t,animate:r}=function(e,t){if(sq(e)){const{initial:t,animate:n}=e;return{initial:!1===t||oq(t)?t:void 0,animate:oq(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,n.useContext(nq));return n.useMemo((()=>({initial:t,animate:r})),[uq(t),uq(r)])}function uq(e){return Array.isArray(e)?e.join(" "):e}const dq=Symbol.for("motionComponentSymbol");function pq(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function fq(e,t,r){return n.useCallback((n=>{n&&e.onMount&&e.onMount(n),t&&(n?t.mount(n):t.unmount()),r&&("function"==typeof r?r(n):pq(r)&&(r.current=n))}),[t])}const hq=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),mq="data-"+hq("framerAppearId"),{schedule:gq}=BV(queueMicrotask,!1),yq=n.createContext({});function vq(e,t,r,o,i){var a,s;const{visualElement:l}=n.useContext(nq),c=n.useContext(GV),u=n.useContext(bV),d=n.useContext(wV).reducedMotion,p=n.useRef(null);o=o||c.renderer,!p.current&&o&&(p.current=o(e,{visualState:t,parent:l,props:r,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:d}));const f=p.current,h=n.useContext(yq);!f||f.projection||!i||"html"!==f.type&&"svg"!==f.type||function(e,t,n,r){const{layoutId:o,layout:i,drag:a,dragConstraints:s,layoutScroll:l,layoutRoot:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:bq(e.parent)),e.projection.setOptions({layoutId:o,layout:i,alwaysMeasureLayout:Boolean(a)||s&&pq(s),visualElement:e,animationType:"string"==typeof i?i:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:c})}(p.current,r,i,h);const m=n.useRef(!1);n.useInsertionEffect((()=>{f&&m.current&&f.update(r,u)}));const g=r[mq],y=n.useRef(Boolean(g)&&!(null===(a=window.MotionHandoffIsComplete)||void 0===a?void 0:a.call(window,g))&&(null===(s=window.MotionHasOptimisedAnimation)||void 0===s?void 0:s.call(window,g)));return NV((()=>{f&&(m.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),gq.render(f.render),y.current&&f.animationState&&f.animationState.animateChanges())})),n.useEffect((()=>{f&&(!y.current&&f.animationState&&f.animationState.animateChanges(),y.current&&(queueMicrotask((()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)})),y.current=!1))})),f}function bq(e){if(e)return!1!==e.options.allowProjection?e.projection:bq(e.parent)}function wq({preloadedFeatures:e,createVisualElement:r,useRender:o,useVisualState:i,Component:a}){var s,l;function c(s,l){let c;const u={...n.useContext(wV),...s,layoutId:xq(s)},{isStatic:d}=u,p=cq(s),f=i(s,d);if(!d&&OV){!function(e,t){const r=n.useContext(GV).strict;if("production"!==process.env.NODE_ENV&&t&&r){const t="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?kV(!1,t):LV(!1,t)}}(u,e);const t=function(e){const{drag:t,layout:n}=WV;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(u);c=t.MeasureLayout,p.visualElement=vq(a,f,u,r,t.ProjectionNode)}return t.jsxs(nq.Provider,{value:p,children:[c&&p.visualElement?t.jsx(c,{visualElement:p.visualElement,...u}):null,o(a,s,fq(f,p.visualElement,l),f,d,p.visualElement)]})}e&&function(e){for(const t in e)WV[t]={...WV[t],...e[t]}}(e),c.displayName=`motion.${"string"==typeof a?a:`create(${null!==(l=null!==(s=a.displayName)&&void 0!==s?s:a.name)&&void 0!==l?l:""})`}`;const u=n.forwardRef(c);return u[dq]=a,u}function xq({layoutId:e}){const t=n.useContext(yV).id;return t&&void 0!==e?t+"-"+e:e}const Eq=e=>t=>"string"==typeof t&&t.startsWith(e),_q=Eq("--"),Sq=Eq("var(--"),Tq=e=>!!Sq(e)&&Cq.test(e.split("/*")[0].trim()),Cq=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Aq={};const Oq=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Nq=new Set(Oq);function Rq(e,{layout:t,layoutId:n}){return Nq.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!Aq[e]||"opacity"===e)}const Pq=e=>Boolean(e&&e.getVelocity),kq=(e,t)=>t&&"number"==typeof e?t.transform(e):e,Lq=(e,t,n)=>n>t?t:n<e?e:n,Mq={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},Dq={...Mq,transform:e=>Lq(0,1,e)},jq={...Mq,default:1},Iq=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),Fq=Iq("deg"),Uq=Iq("%"),$q=Iq("px"),Bq=Iq("vh"),Vq=Iq("vw"),qq={...Uq,parse:e=>Uq.parse(e)/100,transform:e=>Uq.transform(100*e)},zq={borderWidth:$q,borderTopWidth:$q,borderRightWidth:$q,borderBottomWidth:$q,borderLeftWidth:$q,borderRadius:$q,radius:$q,borderTopLeftRadius:$q,borderTopRightRadius:$q,borderBottomRightRadius:$q,borderBottomLeftRadius:$q,width:$q,maxWidth:$q,height:$q,maxHeight:$q,top:$q,right:$q,bottom:$q,left:$q,padding:$q,paddingTop:$q,paddingRight:$q,paddingBottom:$q,paddingLeft:$q,margin:$q,marginTop:$q,marginRight:$q,marginBottom:$q,marginLeft:$q,backgroundPositionX:$q,backgroundPositionY:$q},Hq={rotate:Fq,rotateX:Fq,rotateY:Fq,rotateZ:Fq,scale:jq,scaleX:jq,scaleY:jq,scaleZ:jq,skew:Fq,skewX:Fq,skewY:Fq,distance:$q,translateX:$q,translateY:$q,translateZ:$q,x:$q,y:$q,z:$q,perspective:$q,transformPerspective:$q,opacity:Dq,originX:qq,originY:qq,originZ:$q},Gq={...Mq,transform:Math.round},Kq={...zq,...Hq,zIndex:Gq,size:$q,fillOpacity:Dq,strokeOpacity:Dq,numOctaves:Gq},Wq={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Yq=Oq.length;function Xq(e,t,n){const{style:r,vars:o,transformOrigin:i}=e;let a=!1,s=!1;for(const l in t){const e=t[l];if(Nq.has(l))a=!0;else if(_q(l))o[l]=e;else{const t=kq(e,Kq[l]);l.startsWith("origin")?(s=!0,i[l]=t):r[l]=t}}if(t.transform||(a||n?r.transform=function(e,t,n){let r="",o=!0;for(let i=0;i<Yq;i++){const a=Oq[i],s=e[a];if(void 0===s)continue;let l=!0;if(l="number"==typeof s?s===(a.startsWith("scale")?1:0):0===parseFloat(s),!l||n){const e=kq(s,Kq[a]);l||(o=!1,r+=`${Wq[a]||a}(${e}) `),n&&(t[a]=e)}}return r=r.trim(),n?r=n(t,o?"":r):o&&(r="none"),r}(t,e.transform,n):r.transform&&(r.transform="none")),s){const{originX:e="50%",originY:t="50%",originZ:n=0}=i;r.transformOrigin=`${e} ${t} ${n}`}}const Qq=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Zq(e,t,n){for(const r in t)Pq(t[r])||Rq(r,n)||(e[r]=t[r])}function Jq(e,t){const r={};return Zq(r,e.style||{},e),Object.assign(r,function({transformTemplate:e},t){return n.useMemo((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{}};return Xq(n,t,e),Object.assign({},n.vars,n.style)}),[t])}(e,t)),r}function ez(e,t){const n={},r=Jq(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const tz=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function nz(e){return"string"==typeof e&&!e.includes("-")&&!!(tz.indexOf(e)>-1||/[A-Z]/u.test(e))}const rz={offset:"stroke-dashoffset",array:"stroke-dasharray"},oz={offset:"strokeDashoffset",array:"strokeDasharray"};function iz(e,t,n){return"string"==typeof e?e:$q.transform(t+n*e)}function az(e,{attrX:t,attrY:n,attrScale:r,originX:o,originY:i,pathLength:a,pathSpacing:s=1,pathOffset:l=0,...c},u,d){if(Xq(e,c,d),u)return void(e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox));e.attrs=e.style,e.style={};const{attrs:p,style:f,dimensions:h}=e;p.transform&&(h&&(f.transform=p.transform),delete p.transform),h&&(void 0!==o||void 0!==i||f.transform)&&(f.transformOrigin=function(e,t,n){return`${iz(t,e.x,e.width)} ${iz(n,e.y,e.height)}`}(h,void 0!==o?o:.5,void 0!==i?i:.5)),void 0!==t&&(p.x=t),void 0!==n&&(p.y=n),void 0!==r&&(p.scale=r),void 0!==a&&function(e,t,n=1,r=0,o=!0){e.pathLength=1;const i=o?rz:oz;e[i.offset]=$q.transform(-r);const a=$q.transform(t),s=$q.transform(n);e[i.array]=`${a} ${s}`}(p,a,s,l,!1)}const sz=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}}),lz=e=>"string"==typeof e&&"svg"===e.toLowerCase();function cz(e,t,r,o){const i=n.useMemo((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return az(n,t,lz(o),e.transformTemplate),{...n.attrs,style:{...n.style}}}),[t]);if(e.style){const t={};Zq(t,e.style,e),i.style={...t,...i.style}}return i}function uz(e=!1){return(t,r,o,{latestValues:i},a)=>{const s=(nz(t)?cz:ez)(r,i,a,t),l=function(e,t,n){const r={};for(const o in e)"values"===o&&"object"==typeof e.values||(QV(o)||!0===n&&XV(o)||!t&&!XV(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}(r,"string"==typeof t,e),c=t!==n.Fragment?{...l,...s,ref:o}:{},{children:u}=r,d=n.useMemo((()=>Pq(u)?u.get():u),[u]);return n.createElement(t,{...c,children:d})}}function dz(e){const t=[{},{}];return null==e||e.values.forEach(((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()})),t}function pz(e,t,n,r){if("function"==typeof t){const[o,i]=dz(r);t=t(void 0!==n?n:e.custom,o,i)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){const[o,i]=dz(r);t=t(void 0!==n?n:e.custom,o,i)}return t}const fz=e=>Array.isArray(e);function hz(e){const t=Pq(e)?e.get():e;return n=t,Boolean(n&&"object"==typeof n&&n.mix&&n.toValue)?t.toValue():t;var n}const mz=e=>(t,r)=>{const o=n.useContext(nq),i=n.useContext(bV),a=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},r,o,i){const a={latestValues:gz(r,o,i,e),renderState:t()};return n&&(a.onMount=e=>n({props:r,current:e,...a}),a.onUpdate=e=>n(e)),a}(e,t,o,i);return r?a():vV(a)};function gz(e,t,n,r){const o={},i=r(e,{});for(const p in i)o[p]=hz(i[p]);let{initial:a,animate:s}=e;const l=sq(e),c=lq(e);t&&c&&!l&&!1!==e.inherit&&(void 0===a&&(a=t.initial),void 0===s&&(s=t.animate));let u=!!n&&!1===n.initial;u=u||!1===a;const d=u?s:a;if(d&&"boolean"!=typeof d&&!rq(d)){const t=Array.isArray(d)?d:[d];for(let n=0;n<t.length;n++){const r=pz(e,t[n]);if(r){const{transitionEnd:e,transition:t,...n}=r;for(const r in n){let e=n[r];if(Array.isArray(e)){e=e[u?e.length-1:0]}null!==e&&(o[r]=e)}for(const r in e)o[r]=e[r]}}}return o}function yz(e,t,n){var r;const{style:o}=e,i={};for(const a in o)(Pq(o[a])||t.style&&Pq(t.style[a])||Rq(a,e)||void 0!==(null===(r=null==n?void 0:n.getValue(a))||void 0===r?void 0:r.liveStyle))&&(i[a]=o[a]);return i}const vz={useVisualState:mz({scrapeMotionValuesFromProps:yz,createRenderState:Qq})};function bz(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(tme){t.dimensions={x:0,y:0,width:0,height:0}}}function wz(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const i in n)e.style.setProperty(i,n[i])}const xz=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Ez(e,t,n,r){wz(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(xz.has(o)?o:hq(o),t.attrs[o])}function _z(e,t,n){const r=yz(e,t,n);for(const o in e)if(Pq(e[o])||Pq(t[o])){r[-1!==Oq.indexOf(o)?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o]=e[o]}return r}const Sz=["x","y","width","height","cx","cy","r"],Tz={useVisualState:mz({scrapeMotionValuesFromProps:_z,createRenderState:sz,onUpdate:({props:e,prevProps:t,current:n,renderState:r,latestValues:o})=>{if(!n)return;let i=!!e.drag;if(!i)for(const s in o)if(Nq.has(s)){i=!0;break}if(!i)return;let a=!t;if(t)for(let s=0;s<Sz.length;s++){const n=Sz[s];e[n]!==t[n]&&(a=!0)}a&&VV.read((()=>{bz(n,r),VV.render((()=>{az(r,o,lz(n.tagName),e.transformTemplate),Ez(n,r)}))}))}})};function Cz(e,t){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return wq({...nz(n)?Tz:vz,preloadedFeatures:e,useRender:uz(r),createVisualElement:t,Component:n})}}function Az(e,t,n){const r=e.getProps();return pz(r,t,void 0!==n?n:r.custom,e)}const Oz=MV((()=>void 0!==window.ScrollTimeline));class Nz{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map((e=>"finished"in e?e.finished:e)))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e,t){const n=this.animations.map((n=>Oz()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0));return()=>{n.forEach(((e,t)=>{e&&e(),this.animations[t].stop()}))}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach((t=>t[e]()))}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class Rz extends Nz{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}function Pz(e,t){return e?e[t]||e.default||e:void 0}const kz=2e4;function Lz(e){let t=0;let n=e.next(t);for(;!n.done&&t<kz;)t+=50,n=e.next(t);return t>=kz?1/0:t}function Mz(e){return"function"==typeof e}function Dz(e,t){e.timeline=t,e.onfinish=null}const jz=e=>Array.isArray(e)&&"number"==typeof e[0],Iz={linearEasing:void 0};function Fz(e,t){const n=MV(e);return()=>{var e;return null!==(e=Iz[t])&&void 0!==e?e:n()}}const Uz=Fz((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(tme){return!1}return!0}),"linearEasing"),$z=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let i=0;i<o;i++)r+=e(DV(0,o-1,i))+", ";return`linear(${r.substring(0,r.length-2)})`};function Bz(e){return Boolean("function"==typeof e&&Uz()||!e||"string"==typeof e&&(e in qz||Uz())||jz(e)||Array.isArray(e)&&e.every(Bz))}const Vz=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,qz={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Vz([0,.65,.55,1]),circOut:Vz([.55,0,1,.45]),backIn:Vz([.31,.01,.66,-.59]),backOut:Vz([.33,1.53,.69,.99])};function zz(e,t){return e?"function"==typeof e&&Uz()?$z(e,t):jz(e)?Vz(e):Array.isArray(e)?e.map((e=>zz(e,t)||qz.easeOut)):qz[e]:void 0}const Hz={x:!1,y:!1};function Gz(){return Hz.x||Hz.y}function Kz(e,t){const n=function(e){if(e instanceof Element)return[e];if("string"==typeof e){const t=document.querySelectorAll(e);return t?Array.from(t):[]}return Array.from(e)}(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function Wz(e){return!("touch"===e.pointerType||Gz())}const Yz=(e,t)=>!!t&&(e===t||Yz(e,t.parentElement)),Xz=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary,Qz=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);const Zz=new WeakSet;function Jz(e){return t=>{"Enter"===t.key&&e(t)}}function eH(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function tH(e){return Xz(e)&&!Gz()}function nH(e,t,n={}){const[r,o,i]=Kz(e,n),a=e=>{const r=e.currentTarget;if(!tH(e)||Zz.has(r))return;Zz.add(r);const i=t(r,e),a=(e,t)=>{window.removeEventListener("pointerup",s),window.removeEventListener("pointercancel",l),tH(e)&&Zz.has(r)&&(Zz.delete(r),"function"==typeof i&&i(e,{success:t}))},s=e=>{a(e,n.useGlobalTarget||Yz(r,e.target))},l=e=>{a(e,!1)};window.addEventListener("pointerup",s,o),window.addEventListener("pointercancel",l,o)};return r.forEach((e=>{(function(e){return Qz.has(e.tagName)||-1!==e.tabIndex})(e)||null!==e.getAttribute("tabindex")||(e.tabIndex=0);(n.useGlobalTarget?window:e).addEventListener("pointerdown",a,o),e.addEventListener("focus",(e=>((e,t)=>{const n=e.currentTarget;if(!n)return;const r=Jz((()=>{if(Zz.has(n))return;eH(n,"down");const e=Jz((()=>{eH(n,"up")}));n.addEventListener("keyup",e,t),n.addEventListener("blur",(()=>eH(n,"cancel")),t)}));n.addEventListener("keydown",r,t),n.addEventListener("blur",(()=>n.removeEventListener("keydown",r)),t)})(e,o)),o)})),i}const rH=new Set(["width","height","top","left","right","bottom",...Oq]);let oH;function iH(){oH=void 0}const aH={now:()=>(void 0===oH&&aH.set(zV.isProcessing||FV?zV.timestamp:performance.now()),oH),set:e=>{oH=e,queueMicrotask(iH)}};function sH(e,t){-1===e.indexOf(t)&&e.push(t)}function lH(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class cH{constructor(){this.subscriptions=[]}add(e){return sH(this.subscriptions,e),()=>lH(this.subscriptions,e)}notify(e,t,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(let o=0;o<r;o++){const r=this.subscriptions[o];r&&r(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}function uH(e,t){return t?e*(1e3/t):0}class dH{constructor(e,t={}){this.version="12.4.0",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{const n=aH.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=aH.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=!isNaN(parseFloat(this.current)))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return"production"!==process.env.NODE_ENV&&eq(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new cH);const n=this.events[e].add(t);return"change"===e?()=>{n(),VV.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=aH.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;const t=Math.min(this.updatedAt-this.prevUpdatedAt,30);return uH(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function pH(e,t){return new dH(e,t)}function fH(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,pH(n))}function hH(e,t){const n=e.getValue("willChange");if(r=n,Boolean(Pq(r)&&r.add))return n.add(t);var r}function mH(e){return e.props[mq]}const gH=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function yH(e,t,n,r){if(e===t&&n===r)return PV;const o=t=>function(e,t,n,r,o){let i,a,s=0;do{a=t+(n-t)/2,i=gH(a,r,o)-e,i>0?n=a:t=a}while(Math.abs(i)>1e-7&&++s<12);return a}(t,0,1,e,n);return e=>0===e||1===e?e:gH(o(e),t,r)}const vH=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,bH=e=>t=>1-e(1-t),wH=yH(.33,1.53,.69,.99),xH=bH(wH),EH=vH(xH),_H=e=>(e*=2)<1?.5*xH(e):.5*(2-Math.pow(2,-10*(e-1))),SH=e=>1-Math.sin(Math.acos(e)),TH=bH(SH),CH=vH(SH),AH=e=>/^0[^.\s]+$/u.test(e);const OH=e=>Math.round(1e5*e)/1e5,NH=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const RH=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,PH=(e,t)=>n=>Boolean("string"==typeof n&&RH.test(n)&&n.startsWith(e)||t&&!function(e){return null==e}(n)&&Object.prototype.hasOwnProperty.call(n,t)),kH=(e,t,n)=>r=>{if("string"!=typeof r)return r;const[o,i,a,s]=r.match(NH);return{[e]:parseFloat(o),[t]:parseFloat(i),[n]:parseFloat(a),alpha:void 0!==s?parseFloat(s):1}},LH={...Mq,transform:e=>Math.round((e=>Lq(0,255,e))(e))},MH={test:PH("rgb","red"),parse:kH("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+LH.transform(e)+", "+LH.transform(t)+", "+LH.transform(n)+", "+OH(Dq.transform(r))+")"};const DH={test:PH("#"),parse:function(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}},transform:MH.transform},jH={test:PH("hsl","hue"),parse:kH("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Uq.transform(OH(t))+", "+Uq.transform(OH(n))+", "+OH(Dq.transform(r))+")"},IH={test:e=>MH.test(e)||DH.test(e)||jH.test(e),parse:e=>MH.test(e)?MH.parse(e):jH.test(e)?jH.parse(e):DH.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?MH.transform(e):jH.transform(e)},FH=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const UH="number",$H="color",BH=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function VH(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let i=0;const a=t.replace(BH,(e=>(IH.test(e)?(r.color.push(i),o.push($H),n.push(IH.parse(e))):e.startsWith("var(")?(r.var.push(i),o.push("var"),n.push(e)):(r.number.push(i),o.push(UH),n.push(parseFloat(e))),++i,"${}"))).split("${}");return{values:n,split:a,indexes:r,types:o}}function qH(e){return VH(e).values}function zH(e){const{split:t,types:n}=VH(e),r=t.length;return e=>{let o="";for(let i=0;i<r;i++)if(o+=t[i],void 0!==e[i]){const t=n[i];o+=t===UH?OH(e[i]):t===$H?IH.transform(e[i]):e[i]}return o}}const HH=e=>"number"==typeof e?0:e;const GH={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(NH))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(FH))||void 0===n?void 0:n.length)||0)>0},parse:qH,createTransformer:zH,getAnimatableNone:function(e){const t=qH(e);return zH(e)(t.map(HH))}},KH=new Set(["brightness","contrast","saturate","opacity"]);function WH(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[r]=n.match(NH)||[];if(!r)return e;const o=n.replace(r,"");let i=KH.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+o+")"}const YH=/\b([a-z-]*)\(.*?\)/gu,XH={...GH,getAnimatableNone:e=>{const t=e.match(YH);return t?t.map(WH).join(" "):e}},QH={...Kq,color:IH,backgroundColor:IH,outlineColor:IH,fill:IH,stroke:IH,borderColor:IH,borderTopColor:IH,borderRightColor:IH,borderBottomColor:IH,borderLeftColor:IH,filter:XH,WebkitFilter:XH},ZH=e=>QH[e];function JH(e,t){let n=ZH(e);return n!==XH&&(n=GH),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const eG=new Set(["auto","none","0"]);const tG=e=>e===Mq||e===$q,nG=(e,t)=>parseFloat(e.split(", ")[t]),rG=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/u);if(o)return nG(o[1],t);{const t=r.match(/^matrix\((.+)\)$/u);return t?nG(t[1],e):0}},oG=new Set(["x","y","z"]),iG=Oq.filter((e=>!oG.has(e)));const aG={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:rG(4,13),y:rG(5,14)};aG.translateX=aG.x,aG.translateY=aG.y;const sG=new Set;let lG=!1,cG=!1;function uG(){if(cG){const e=Array.from(sG).filter((e=>e.needsMeasurement)),t=new Set(e.map((e=>e.element))),n=new Map;t.forEach((e=>{const t=function(e){const t=[];return iG.forEach((n=>{const r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),t}(e);t.length&&(n.set(e,t),e.render())})),e.forEach((e=>e.measureInitialState())),t.forEach((e=>{e.render();const t=n.get(e);t&&t.forEach((([t,n])=>{var r;null===(r=e.getValue(t))||void 0===r||r.set(n)}))})),e.forEach((e=>e.measureEndState())),e.forEach((e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)}))}cG=!1,lG=!1,sG.forEach((e=>e.complete())),sG.clear()}function dG(){sG.forEach((e=>{e.readKeyframes(),e.needsMeasurement&&(cG=!0)}))}class pG{constructor(e,t,n,r,o,i=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=o,this.isAsync=i}scheduleResolve(){this.isScheduled=!0,this.isAsync?(sG.add(this),lG||(lG=!0,VV.read(dG),VV.resolveKeyframes(uG))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;for(let o=0;o<e.length;o++)if(null===e[o])if(0===o){const o=null==r?void 0:r.get(),i=e[e.length-1];if(void 0!==o)e[0]=o;else if(n&&t){const r=n.readValue(t,i);null!=r&&(e[0]=r)}void 0===e[0]&&(e[0]=i),r&&void 0===o&&r.set(e[0])}else e[o]=e[o-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),sG.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,sG.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const fG=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),hG=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function mG(e,t,n=1){LV(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=function(e){const t=hG.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${null!=n?n:r}`,o]}(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const e=i.trim();return fG(e)?parseFloat(e):e}return Tq(o)?mG(o,t,n+1):o}const gG=e=>t=>t.test(e),yG=[Mq,$q,Uq,Fq,Vq,Bq,{test:e=>"auto"===e,parse:e=>e}],vG=e=>yG.find(gG(e));class bG extends pG{constructor(e,t,n,r,o){super(e,t,n,r,o,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let s=0;s<e.length;s++){let n=e[s];if("string"==typeof n&&(n=n.trim(),Tq(n))){const r=mG(n,t.current);void 0!==r&&(e[s]=r),s===e.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!rH.has(n)||2!==e.length)return;const[r,o]=e,i=vG(r),a=vG(o);if(i!==a)if(tG(i)&&tG(a))for(let s=0;s<e.length;s++){const t=e[s];"string"==typeof t&&(e[s]=parseFloat(t))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:t}=this,n=[];for(let o=0;o<e.length;o++)("number"==typeof(r=e[o])?0===r:null===r||"none"===r||"0"===r||AH(r))&&n.push(o);var r;n.length&&function(e,t,n){let r,o=0;for(;o<e.length&&!r;){const t=e[o];"string"==typeof t&&!eG.has(t)&&VH(t).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=JH(n,r)}(e,n,t)}measureInitialState(){const{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=aG[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;const r=t[t.length-1];void 0!==r&&e.getValue(n,r).jump(r,!1)}measureEndState(){var e;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const o=t.getValue(n);o&&o.jump(this.measuredOrigin,!1);const i=r.length-1,a=r[i];r[i]=aG[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==a&&void 0===this.finalKeyframe&&(this.finalKeyframe=a),(null===(e=this.removedTransforms)||void 0===e?void 0:e.length)&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}const wG=(e,t)=>"zIndex"!==t&&(!("number"!=typeof e&&!Array.isArray(e))||!("string"!=typeof e||!GH.test(e)&&"0"!==e||e.startsWith("url(")));const xG=e=>null!==e;function EG(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(xG),i=t&&"loop"!==n&&t%2==1?0:o.length-1;return i&&void 0!==r?r:o[i]}class _G{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:i="loop",...a}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=aH.now(),this.options={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:o,repeatType:i,...a},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(dG(),uG()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=aH.now(),this.hasAttemptedResolve=!0;const{name:n,type:r,velocity:o,delay:i,onComplete:a,onUpdate:s,isGenerator:l}=this.options;if(!l&&!function(e,t,n,r){const o=e[0];if(null===o)return!1;if("display"===t||"visibility"===t)return!0;const i=e[e.length-1],a=wG(o,t),s=wG(i,t);return kV(a===s,`You are trying to animate ${t} from "${o}" to "${i}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${i} via the \`style\` property.`),!(!a||!s)&&(function(e){const t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||("spring"===n||Mz(n))&&r)}(e,n,r,o)){if(!i)return s&&s(EG(e,this.options,t)),a&&a(),void this.resolveFinishedPromise();this.options.duration=0}const c=this.initPlayback(e,t);!1!==c&&(this._resolved={keyframes:e,finalKeyframe:t,...c},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise((e=>{this.resolveFinishedPromise=e}))}}const SG=(e,t,n)=>e+(t-e)*n;function TG(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function CG(e,t){return n=>n>0?t:e}const AG=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},OG=[DH,MH,jH];function NG(e){const t=(n=e,OG.find((e=>e.test(n))));var n;if(kV(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`),!Boolean(t))return!1;let r=t.parse(e);return t===jH&&(r=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let o=0,i=0,a=0;if(t/=100){const r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;o=TG(s,r,e+1/3),i=TG(s,r,e),a=TG(s,r,e-1/3)}else o=i=a=n;return{red:Math.round(255*o),green:Math.round(255*i),blue:Math.round(255*a),alpha:r}}(r)),r}const RG=(e,t)=>{const n=NG(e),r=NG(t);if(!n||!r)return CG(e,t);const o={...n};return e=>(o.red=AG(n.red,r.red,e),o.green=AG(n.green,r.green,e),o.blue=AG(n.blue,r.blue,e),o.alpha=SG(n.alpha,r.alpha,e),MH.transform(o))},PG=(e,t)=>n=>t(e(n)),kG=(...e)=>e.reduce(PG),LG=new Set(["none","hidden"]);function MG(e,t){return n=>SG(e,t,n)}function DG(e){return"number"==typeof e?MG:"string"==typeof e?Tq(e)?CG:IH.test(e)?RG:FG:Array.isArray(e)?jG:"object"==typeof e?IH.test(e)?RG:IG:CG}function jG(e,t){const n=[...e],r=n.length,o=e.map(((e,n)=>DG(e)(e,t[n])));return e=>{for(let t=0;t<r;t++)n[t]=o[t](e);return n}}function IG(e,t){const n={...e,...t},r={};for(const o in n)void 0!==e[o]&&void 0!==t[o]&&(r[o]=DG(e[o])(e[o],t[o]));return e=>{for(const t in r)n[t]=r[t](e);return n}}const FG=(e,t)=>{const n=GH.createTransformer(t),r=VH(e),o=VH(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?LG.has(e)&&!o.values.length||LG.has(t)&&!r.values.length?function(e,t){return LG.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):kG(jG(function(e,t){var n;const r=[],o={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const a=t.types[i],s=null!==(n=e.values[e.indexes[a][o[a]]])&&void 0!==n?n:0;r[i]=s,o[a]++}return r}(r,o),o.values),n):(kV(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),CG(e,t))};function UG(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return SG(e,t,n);return DG(e)(e,t)}function $G(e,t,n){const r=Math.max(t-5,0);return uH(n-e(r),t-r)}const BG=100,VG=10,qG=1,zG=0,HG=800,GG=.3,KG=.3,WG={granular:.01,default:2},YG={granular:.005,default:.5},XG=.01,QG=10,ZG=.05,JG=1;function eK({duration:e=HG,bounce:t=GG,velocity:n=zG,mass:r=qG}){let o,i;kV(e<=jV(QG),"Spring duration must be 10 seconds or less");let a=1-t;a=Lq(ZG,JG,a),e=Lq(XG,QG,IV(e)),a<1?(o=t=>{const r=t*a,o=r*e;return.001-(r-n)/nK(t,a)*Math.exp(-o)},i=t=>{const r=t*a*e,i=r*n+n,s=Math.pow(a,2)*Math.pow(t,2)*e,l=Math.exp(-r),c=nK(Math.pow(t,2),a);return(.001-o(t)>0?-1:1)*((i-s)*l)/c}):(o=t=>Math.exp(-t*e)*((t-n)*e+1)-.001,i=t=>Math.exp(-t*e)*(e*e*(n-t)));const s=function(e,t,n){let r=n;for(let o=1;o<tK;o++)r-=e(r)/t(r);return r}(o,i,5/e);if(e=jV(e),isNaN(s))return{stiffness:BG,damping:VG,duration:e};{const t=Math.pow(s,2)*r;return{stiffness:t,damping:2*a*Math.sqrt(r*t),duration:e}}}const tK=12;function nK(e,t){return e*Math.sqrt(1-t*t)}const rK=["duration","bounce"],oK=["stiffness","damping","mass"];function iK(e,t){return t.some((t=>void 0!==e[t]))}function aK(e=KG,t=GG){const n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const i=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],s={done:!1,value:i},{stiffness:l,damping:c,mass:u,duration:d,velocity:p,isResolvedFromDuration:f}=function(e){let t={velocity:zG,stiffness:BG,damping:VG,mass:qG,isResolvedFromDuration:!1,...e};if(!iK(e,oK)&&iK(e,rK))if(e.visualDuration){const n=2*Math.PI/(1.2*e.visualDuration),r=n*n,o=2*Lq(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:qG,stiffness:r,damping:o}}else{const n=eK(e);t={...t,...n,mass:qG},t.isResolvedFromDuration=!0}return t}({...n,velocity:-IV(n.velocity||0)}),h=p||0,m=c/(2*Math.sqrt(l*u)),g=a-i,y=IV(Math.sqrt(l/u)),v=Math.abs(g)<5;let b;if(r||(r=v?WG.granular:WG.default),o||(o=v?YG.granular:YG.default),m<1){const e=nK(y,m);b=t=>{const n=Math.exp(-m*y*t);return a-n*((h+m*y*g)/e*Math.sin(e*t)+g*Math.cos(e*t))}}else if(1===m)b=e=>a-Math.exp(-y*e)*(g+(h+y*g)*e);else{const e=y*Math.sqrt(m*m-1);b=t=>{const n=Math.exp(-m*y*t),r=Math.min(e*t,300);return a-n*((h+m*y*g)*Math.sinh(r)+e*g*Math.cosh(r))/e}}const w={calculatedDuration:f&&d||null,next:e=>{const t=b(e);if(f)s.done=e>=d;else{let n=0;m<1&&(n=0===e?jV(h):$G(b,e,t));const i=Math.abs(n)<=r,l=Math.abs(a-t)<=o;s.done=i&&l}return s.value=s.done?a:t,s},toString:()=>{const e=Math.min(Lz(w),kz),t=$z((t=>w.next(e*t).value),e,30);return e+"ms "+t}};return w}function sK({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:a,min:s,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],p={done:!1,value:d},f=e=>void 0===s?l:void 0===l||Math.abs(s-e)<Math.abs(l-e)?s:l;let h=n*t;const m=d+h,g=void 0===a?m:a(m);g!==m&&(h=g-d);const y=e=>-h*Math.exp(-e/r),v=e=>g+y(e),b=e=>{const t=y(e),n=v(e);p.done=Math.abs(t)<=c,p.value=p.done?g:n};let w,x;const E=e=>{var t;(t=p.value,void 0!==s&&t<s||void 0!==l&&t>l)&&(w=e,x=aK({keyframes:[p.value,f(p.value)],velocity:$G(v,e,p.value),damping:o,stiffness:i,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:e=>{let t=!1;return x||void 0!==w||(t=!0,b(e),E(e)),void 0!==w&&e>=w?x.next(e-w):(!t&&b(e),p)}}}const lK=yH(.42,0,1,1),cK=yH(0,0,.58,1),uK=yH(.42,0,.58,1),dK={linear:PV,easeIn:lK,easeInOut:uK,easeOut:cK,circIn:SH,circInOut:CH,circOut:TH,backIn:xH,backInOut:EH,backOut:wH,anticipate:_H},pK=e=>{if(jz(e)){LV(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return yH(t,n,r,o)}return"string"==typeof e?(LV(void 0!==dK[e],`Invalid easing type '${e}'`),dK[e]):e};function fK(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const i=e.length;if(LV(i===t.length,"Both input and output ranges must be the same length"),1===i)return()=>t[0];if(2===i&&t[0]===t[1])return()=>t[1];const a=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=function(e,t,n){const r=[],o=n||UG,i=e.length-1;for(let a=0;a<i;a++){let n=o(e[a],e[a+1]);if(t){const e=Array.isArray(t)?t[a]||PV:t;n=kG(e,n)}r.push(n)}return r}(t,r,o),l=s.length,c=n=>{if(a&&n<e[0])return t[0];let r=0;if(l>1)for(;r<e.length-2&&!(n<e[r+1]);r++);return s[r](DV(e[r],e[r+1],n))};return n?t=>c(Lq(e[0],e[i-1],t)):c}function hK(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++)e.push(SG(n,1,DV(0,t,r)))}(t,e.length-1),t}function mK({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=(e=>Array.isArray(e)&&"number"!=typeof e[0])(r)?r.map(pK):pK(r),i={done:!1,value:t[0]},a=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:hK(t),e),s=fK(a,t,{ease:Array.isArray(o)?o:(l=t,c=o,l.map((()=>c||uK)).splice(0,l.length-1))});var l,c;return{calculatedDuration:e,next:t=>(i.value=s(t),i.done=t>=e,i)}}const gK=e=>{const t=({timestamp:t})=>e(t);return{start:()=>VV.update(t,!0),stop:()=>qV(t),now:()=>zV.isProcessing?zV.timestamp:aH.now()}},yK={decay:sK,inertia:sK,tween:mK,keyframes:mK,spring:aK},vK=e=>e/100;class bK extends _G{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:e}=this.options;e&&e()};const{name:t,motionValue:n,element:r,keyframes:o}=this.options;this.resolver=new((null==r?void 0:r.KeyframeResolver)||pG)(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){const{type:t="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:o,velocity:i=0}=this.options,a=Mz(t)?t:yK[t]||mK;let s,l;a!==mK&&"number"!=typeof e[0]&&("production"!==process.env.NODE_ENV&&LV(2===e.length,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`),s=kG(vK,UG(e[0],e[1])),e=[0,100]);const c=a({...this.options,keyframes:e});"mirror"===o&&(l=a({...this.options,keyframes:[...e].reverse(),velocity:-i})),null===c.calculatedDuration&&(c.calculatedDuration=Lz(c));const{calculatedDuration:u}=c,d=u+r;return{generator:c,mirroredGenerator:l,mapPercentToKeyframes:s,calculatedDuration:u,resolvedDuration:d,totalDuration:d*(n+1)-r}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){const{resolved:n}=this;if(!n){const{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}const{finalKeyframe:r,generator:o,mirroredGenerator:i,mapPercentToKeyframes:a,keyframes:s,calculatedDuration:l,totalDuration:c,resolvedDuration:u}=n;if(null===this.startTime)return o.next(0);const{delay:d,repeat:p,repeatType:f,repeatDelay:h,onUpdate:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),this.currentTime=t?e:null!==this.holdTime?this.holdTime:Math.round(e-this.startTime)*this.speed;const g=this.currentTime-d*(this.speed>=0?1:-1),y=this.speed>=0?g<0:g>c;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=c);let v=this.currentTime,b=o;if(p){const e=Math.min(this.currentTime,c)/u;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,p+1);Boolean(t%2)&&("reverse"===f?(n=1-n,h&&(n-=h/u)):"mirror"===f&&(b=i)),v=Lq(0,1,n)*u}const w=y?{done:!1,value:s[0]}:b.next(v);a&&(w.value=a(w.value));let{done:x}=w;y||null===l||(x=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const E=null===this.holdTime&&("finished"===this.state||"running"===this.state&&x);return E&&void 0!==r&&(w.value=EG(s,this.options,r)),m&&m(w.value),E&&this.finish(),w}get duration(){const{resolved:e}=this;return e?IV(e.calculatedDuration):0}get time(){return IV(this.currentTime)}set time(e){this.currentTime=e=jV(e),null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=IV(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:e=gK,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e((e=>this.tick(e)))),t&&t();const r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;this._resolved?(this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const wK=new Set(["opacity","clipPath","filter","transform"]);function xK(e,t,n,{delay:r=0,duration:o=300,repeat:i=0,repeatType:a="loop",ease:s="easeInOut",times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=zz(s,o);Array.isArray(u)&&(c.easing=u);return e.animate(c,{delay:r,duration:o,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:"reverse"===a?"alternate":"normal"})}const EK=MV((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));const _K={anticipate:_H,backInOut:EH,circInOut:CH};class SK extends _G{constructor(e){super(e);const{name:t,motionValue:n,element:r,keyframes:o}=this.options;this.resolver=new bG(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}initPlayback(e,t){let{duration:n=300,times:r,ease:o,type:i,motionValue:a,name:s,startTime:l}=this.options;if(!a.owner||!a.owner.current)return!1;var c;if("string"==typeof o&&Uz()&&o in _K&&(o=_K[o]),Mz((c=this.options).type)||"spring"===c.type||!Bz(c.ease)){const{onComplete:t,onUpdate:a,motionValue:s,element:l,...c}=this.options,u=function(e,t){const n=new bK({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:e[0]};const o=[];let i=0;for(;!r.done&&i<2e4;)r=n.sample(i),o.push(r.value),i+=10;return{times:void 0,keyframes:o,duration:i-10,ease:"linear"}}(e,c);1===(e=u.keyframes).length&&(e[1]=e[0]),n=u.duration,r=u.times,o=u.ease,i="keyframes"}const u=xK(a.owner.current,s,e,{...this.options,duration:n,times:r,ease:o});return u.startTime=null!=l?l:this.calcStartTime(),this.pendingTimeline?(Dz(u,this.pendingTimeline),this.pendingTimeline=void 0):u.onfinish=()=>{const{onComplete:n}=this.options;a.set(EG(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:u,duration:n,times:r,type:i,ease:o,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:t}=e;return IV(t)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:t}=e;return IV(t.currentTime||0)}set time(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.currentTime=jV(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:t}=e;return t.playbackRate}set speed(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:t}=e;return t.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){const{resolved:t}=this;if(!t)return PV;const{animation:n}=t;Dz(n,e)}else this.pendingTimeline=e;return PV}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:t,keyframes:n,duration:r,type:o,ease:i,times:a}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){const{motionValue:e,onUpdate:t,onComplete:s,element:l,...c}=this.options,u=new bK({...c,keyframes:n,duration:r,type:o,ease:i,times:a,isGenerator:!0}),d=jV(this.time);e.setWithVelocity(u.sample(d-10).value,u.sample(d).value,10)}const{onStop:s}=this.options;s&&s(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:i,type:a}=e;if(!(t&&t.owner&&t.owner.current instanceof HTMLElement))return!1;const{onUpdate:s,transformTemplate:l}=t.owner.getProps();return EK()&&n&&wK.has(n)&&!s&&!l&&!r&&"mirror"!==o&&0!==i&&"inertia"!==a}}const TK={type:"spring",stiffness:500,damping:25,restSpeed:10},CK={type:"keyframes",duration:.8},AK={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},OK=(e,{keyframes:t})=>t.length>2?CK:Nq.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:TK:AK;const NK=(e,t,n,r={},o,i)=>a=>{const s=Pz(r,e)||{},l=s.delay||r.delay||0;let{elapsed:c=0}=r;c-=jV(l);let u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...s,delay:-c,onUpdate:e=>{t.set(e),s.onUpdate&&s.onUpdate(e)},onComplete:()=>{a(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:i?void 0:o};(function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:i,repeatType:a,repeatDelay:s,from:l,elapsed:c,...u}){return!!Object.keys(u).length})(s)||(u={...u,...OK(e,u)}),u.duration&&(u.duration=jV(u.duration)),u.repeatDelay&&(u.repeatDelay=jV(u.repeatDelay)),void 0!==u.from&&(u.keyframes[0]=u.from);let d=!1;if((!1===u.type||0===u.duration&&!u.repeatDelay)&&(u.duration=0,0===u.delay&&(d=!0)),d&&!i&&void 0!==t.get()){const e=EG(u.keyframes,s);if(void 0!==e)return VV.update((()=>{u.onUpdate(e),u.onComplete()})),new Rz([])}return!i&&SK.supports(u)?new SK(u):new bK(u)};function RK({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}function PK(e,t,{delay:n=0,transitionOverride:r,type:o}={}){var i;let{transition:a=e.getDefaultTransition(),transitionEnd:s,...l}=t;r&&(a=r);const c=[],u=o&&e.animationState&&e.animationState.getState()[o];for(const d in l){const t=e.getValue(d,null!==(i=e.latestValues[d])&&void 0!==i?i:null),r=l[d];if(void 0===r||u&&RK(u,d))continue;const o={delay:n,...Pz(a||{},d)};let s=!1;if(window.MotionHandoffAnimation){const t=mH(e);if(t){const e=window.MotionHandoffAnimation(t,d,VV);null!==e&&(o.startTime=e,s=!0)}}hH(e,d),t.start(NK(d,t,r,e.shouldReduceMotion&&rH.has(d)?{type:!1}:o,e,s));const p=t.animation;p&&c.push(p)}return s&&Promise.all(c).then((()=>{VV.update((()=>{s&&function(e,t){const n=Az(e,t);let{transitionEnd:r={},transition:o={},...i}=n||{};i={...i,...r};for(const s in i)fH(e,s,fz(a=i[s])?a[a.length-1]||0:a);var a}(e,s)}))})),c}function kK(e,t,n={}){var r;const o=Az(e,t,"exit"===n.type?null===(r=e.presenceContext)||void 0===r?void 0:r.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(i=n.transitionOverride);const a=o?()=>Promise.all(PK(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(r=0)=>{const{delayChildren:o=0,staggerChildren:a,staggerDirection:s}=i;return function(e,t,n=0,r=0,o=1,i){const a=[],s=(e.variantChildren.size-1)*r,l=1===o?(e=0)=>e*r:(e=0)=>s-e*r;return Array.from(e.variantChildren).sort(LK).forEach(((e,r)=>{e.notify("AnimationStart",t),a.push(kK(e,t,{...i,delay:n+l(r)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(a)}(e,t,o+r,a,s,n)}:()=>Promise.resolve(),{when:l}=i;if(l){const[e,t]="beforeChildren"===l?[a,s]:[s,a];return e().then((()=>t()))}return Promise.all([a(),s(n.delay)])}function LK(e,t){return e.sortNodePosition(t)}function MK(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const DK=aq.length;function jK(e){if(!e)return;if(!e.isControllingVariants){const t=e.parent&&jK(e.parent)||{};return void 0!==e.props.initial&&(t.initial=e.props.initial),t}const t={};for(let n=0;n<DK;n++){const r=aq[n],o=e.props[r];(oq(o)||!1===o)&&(t[r]=o)}return t}const IK=[...iq].reverse(),FK=iq.length;function UK(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t)){const o=t.map((t=>kK(e,t,n)));r=Promise.all(o)}else if("string"==typeof t)r=kK(e,t,n);else{const o="function"==typeof t?Az(e,t,n.custom):t;r=Promise.all(PK(e,o,n))}return r.then((()=>{e.notify("AnimationComplete",t)}))}(e,t,n))))}function $K(e){let t=UK(e),n=qK(),r=!0;const o=t=>(n,r)=>{var o;const i=Az(e,r,"exit"===t?null===(o=e.presenceContext)||void 0===o?void 0:o.custom:void 0);if(i){const{transition:e,transitionEnd:t,...r}=i;n={...n,...r,...t}}return n};function i(i){const{props:a}=e,s=jK(e.parent)||{},l=[],c=new Set;let u={},d=1/0;for(let t=0;t<FK;t++){const p=IK[t],f=n[p],h=void 0!==a[p]?a[p]:s[p],m=oq(h),g=p===i?f.isActive:null;!1===g&&(d=t);let y=h===s[p]&&h!==a[p]&&m;if(y&&r&&e.manuallyAnimateOnMount&&(y=!1),f.protectedKeys={...u},!f.isActive&&null===g||!h&&!f.prevProp||rq(h)||"boolean"==typeof h)continue;const v=BK(f.prevProp,h);let b=v||p===i&&f.isActive&&!y&&m||t>d&&m,w=!1;const x=Array.isArray(h)?h:[h];let E=x.reduce(o(p),{});!1===g&&(E={});const{prevResolvedValues:_={}}=f,S={..._,...E},T=t=>{b=!0,c.has(t)&&(w=!0,c.delete(t)),f.needsAnimating[t]=!0;const n=e.getValue(t);n&&(n.liveStyle=!1)};for(const e in S){const t=E[e],n=_[e];if(u.hasOwnProperty(e))continue;let r=!1;r=fz(t)&&fz(n)?!MK(t,n):t!==n,r?null!=t?T(e):c.add(e):void 0!==t&&c.has(e)?T(e):f.protectedKeys[e]=!0}f.prevProp=h,f.prevResolvedValues=E,f.isActive&&(u={...u,...E}),r&&e.blockInitialAnimation&&(b=!1);b&&(!(y&&v)||w)&&l.push(...x.map((e=>({animation:e,options:{type:p}}))))}if(c.size){const t={};c.forEach((n=>{const r=e.getBaseTarget(n),o=e.getValue(n);o&&(o.liveStyle=!0),t[n]=null!=r?r:null})),l.push({animation:t})}let p=Boolean(l.length);return!r||!1!==a.initial&&a.initial!==a.animate||e.manuallyAnimateOnMount||(p=!1),r=!1,p?t(l):Promise.resolve()}return{animateChanges:i,setActive:function(t,r){var o;if(n[t].isActive===r)return Promise.resolve();null===(o=e.variantChildren)||void 0===o||o.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,r)})),n[t].isActive=r;const a=i(t);for(const e in n)n[e].protectedKeys={};return a},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=qK(),r=!0}}}function BK(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!MK(t,e)}function VK(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function qK(){return{animate:VK(!0),whileInView:VK(),whileHover:VK(),whileTap:VK(),whileDrag:VK(),whileFocus:VK(),exit:VK()}}class zK{constructor(e){this.isMounted=!1,this.node=e}update(){}}let HK=0;const GK={animation:{Feature:class extends zK{constructor(e){super(e),e.animationState||(e.animationState=$K(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();rq(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}},exit:{Feature:class extends zK{constructor(){super(...arguments),this.id=HK++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;const r=this.node.animationState.setActive("exit",!e);t&&!e&&r.then((()=>{t(this.id)}))}mount(){const{register:e,onExitComplete:t}=this.node.presenceContext||{};t&&t(this.id),e&&(this.unmount=e(this.id))}unmount(){}}}};function KK(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function WK(e){return{point:{x:e.pageX,y:e.pageY}}}function YK(e,t,n,r){return KK(e,t,(e=>t=>Xz(t)&&e(t,WK(t)))(n),r)}const XK=(e,t)=>Math.abs(e-t);class QK{constructor(e,t,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:o=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=eW(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=XK(e.x,t.x),r=XK(e.y,t.y);return Math.sqrt(n**2+r**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:r}=e,{timestamp:o}=zV;this.history.push({...r,timestamp:o});const{onStart:i,onMove:a}=this.handlers;t||(i&&i(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),a&&a(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=ZK(t,this.transformPagePoint),VV.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();const{onEnd:n,onSessionEnd:r,resumeAnimation:o}=this.handlers;if(this.dragSnapToOrigin&&o&&o(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const i=eW("pointercancel"===e.type?this.lastMoveEventInfo:ZK(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,i),r&&r(e,i)},!Xz(e))return;this.dragSnapToOrigin=o,this.handlers=t,this.transformPagePoint=n,this.contextWindow=r||window;const i=ZK(WK(e),this.transformPagePoint),{point:a}=i,{timestamp:s}=zV;this.history=[{...a,timestamp:s}];const{onSessionStart:l}=t;l&&l(e,eW(i,this.history)),this.removeListeners=kG(YK(this.contextWindow,"pointermove",this.handlePointerMove),YK(this.contextWindow,"pointerup",this.handlePointerUp),YK(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),qV(this.updatePoint)}}function ZK(e,t){return t?{point:t(e.point)}:e}function JK(e,t){return{x:e.x-t.x,y:e.y-t.y}}function eW({point:e},t){return{point:e,delta:JK(e,nW(t)),offset:JK(e,tW(t)),velocity:rW(t,.1)}}function tW(e){return e[0]}function nW(e){return e[e.length-1]}function rW(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=nW(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>jV(t)));)n--;if(!r)return{x:0,y:0};const i=IV(o.timestamp-r.timestamp);if(0===i)return{x:0,y:0};const a={x:(o.x-r.x)/i,y:(o.y-r.y)/i};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function oW(e){return e.max-e.min}function iW(e,t,n,r=.5){e.origin=r,e.originPoint=SG(t.min,t.max,e.origin),e.scale=oW(n)/oW(t),e.translate=SG(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function aW(e,t,n,r){iW(e.x,t.x,n.x,r?r.originX:void 0),iW(e.y,t.y,n.y,r?r.originY:void 0)}function sW(e,t,n){e.min=n.min+t.min,e.max=e.min+oW(t)}function lW(e,t,n){e.min=t.min-n.min,e.max=e.min+oW(t)}function cW(e,t,n){lW(e.x,t.x,n.x),lW(e.y,t.y,n.y)}function uW(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function dW(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}const pW=.35;function fW(e,t,n){return{min:hW(e,t),max:hW(e,n)}}function hW(e,t){return"number"==typeof e?e:e[t]||0}const mW=()=>({x:{min:0,max:0},y:{min:0,max:0}});function gW(e){return[e("x"),e("y")]}function yW({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function vW(e){return void 0===e||1===e}function bW({scale:e,scaleX:t,scaleY:n}){return!vW(e)||!vW(t)||!vW(n)}function wW(e){return bW(e)||xW(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function xW(e){return EW(e.x)||EW(e.y)}function EW(e){return e&&"0%"!==e}function _W(e,t,n){return n+t*(e-n)}function SW(e,t,n,r,o){return void 0!==o&&(e=_W(e,o,r)),_W(e,n,r)+t}function TW(e,t=0,n=1,r,o){e.min=SW(e.min,t,n,r,o),e.max=SW(e.max,t,n,r,o)}function CW(e,{x:t,y:n}){TW(e.x,t.translate,t.scale,t.originPoint),TW(e.y,n.translate,n.scale,n.originPoint)}const AW=.999999999999,OW=1.0000000000001;function NW(e,t){e.min=e.min+t,e.max=e.max+t}function RW(e,t,n,r,o=.5){TW(e,t,n,SG(e.min,e.max,o),r)}function PW(e,t){RW(e.x,t.x,t.scaleX,t.scale,t.originX),RW(e.y,t.y,t.scaleY,t.scale,t.originY)}function kW(e,t){return yW(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}const LW=({current:e})=>e?e.ownerDocument.defaultView:null,MW=new WeakMap;class DW{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic={x:{min:0,max:0},y:{min:0,max:0}},this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:r}=this.getProps();this.panSession=new QK(e,{onSessionStart:e=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(WK(e).point)},onStart:(e,t)=>{const{drag:n,dragPropagation:r,onDragStart:o}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===(i=n)||"y"===i?Hz[i]?null:(Hz[i]=!0,()=>{Hz[i]=!1}):Hz.x||Hz.y?null:(Hz.x=Hz.y=!0,()=>{Hz.x=Hz.y=!1}),!this.openDragLock))return;var i;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),gW((e=>{let t=this.getAxisMotionValue(e).get()||0;if(Uq.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[e];if(r){t=oW(r)*(parseFloat(t)/100)}}}this.originPoint[e]=t})),o&&VV.postRender((()=>o(e,t))),hH(this.visualElement,"transform");const{animationState:a}=this.visualElement;a&&a.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:o,onDrag:i}=this.getProps();if(!n&&!this.openDragLock)return;const{offset:a}=t;if(r&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(a),void(null!==this.currentDirection&&o&&o(this.currentDirection));this.updateAxis("x",t.point,a),this.updateAxis("y",t.point,a),this.visualElement.render(),i&&i(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>gW((e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:LW(this.visualElement)})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:r}=t;this.startAnimation(r);const{onDragEnd:o}=this.getProps();o&&VV.postRender((()=>o(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:r}=this.getProps();if(!n||!jW(e,r,this.currentDirection))return;const o=this.getAxisMotionValue(e);let i=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(i=function(e,{min:t,max:n},r){return void 0!==t&&e<t?e=r?SG(t,e,r.min):Math.max(e,t):void 0!==n&&e>n&&(e=r?SG(n,e,r.max):Math.min(e,n)),e}(i,this.constraints[e],this.elastic[e])),o.set(i)}resolveConstraints(){var e;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,o=this.constraints;t&&pq(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!t||!r)&&function(e,{top:t,left:n,bottom:r,right:o}){return{x:uW(e.x,n,o),y:uW(e.y,t,r)}}(r.layoutBox,t),this.elastic=function(e=pW){return!1===e?e=0:!0===e&&(e=pW),{x:fW(e,"left","right"),y:fW(e,"top","bottom")}}(n),o!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&gW((e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(r.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!pq(e))return!1;const n=e.current;LV(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const o=function(e,t,n){const r=kW(e,n),{scroll:o}=t;return o&&(NW(r.x,o.offset.x),NW(r.y,o.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let i=function(e,t){return{x:dW(e.x,t.x),y:dW(e.y,t.y)}}(r.layout.layoutBox,o);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(i));this.hasMutatedConstraints=!!e,e&&(i=yW(e))}return i}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:r,dragTransition:o,dragSnapToOrigin:i,onDragTransitionEnd:a}=this.getProps(),s=this.constraints||{},l=gW((a=>{if(!jW(a,t,this.currentDirection))return;let l=s&&s[a]||{};i&&(l={min:0,max:0});const c={type:"inertia",velocity:n?e[a]:0,bounceStiffness:r?200:1e6,bounceDamping:r?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...o,...l};return this.startAxisValueAnimation(a,c)}));return Promise.all(l).then(a)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return hH(this.visualElement,e),n.start(NK(e,n,0,t,this.visualElement,!1))}stopAnimation(){gW((e=>this.getAxisMotionValue(e).stop()))}pauseAnimation(){gW((e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()}))}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){const t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps(),r=n[t];return r||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){gW((t=>{const{drag:n}=this.getProps();if(!jW(t,n,this.currentDirection))return;const{projection:r}=this.visualElement,o=this.getAxisMotionValue(t);if(r&&r.layout){const{min:n,max:i}=r.layout.layoutBox[t];o.set(e[t]-SG(n,i,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!pq(t)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};gW((e=>{const t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){const n=t.get();r[e]=function(e,t){let n=.5;const r=oW(e),o=oW(t);return o>r?n=DV(t.min,t.max-r,e.min):r>o&&(n=DV(e.min,e.max-o,t.min)),Lq(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),gW((t=>{if(!jW(t,e,null))return;const n=this.getAxisMotionValue(t),{min:o,max:i}=this.constraints[t];n.set(SG(o,i,r[t]))}))}addListeners(){if(!this.visualElement.current)return;MW.set(this.visualElement,this);const e=YK(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();pq(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),VV.read(t);const o=KK(window,"resize",(()=>this.scalePositionWithinConstraints())),i=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(gW((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{o(),e(),r(),i&&i()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:o=!1,dragElastic:i=pW,dragMomentum:a=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:o,dragElastic:i,dragMomentum:a}}}function jW(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const IW=e=>(t,n)=>{e&&VV.postRender((()=>e(t,n)))};const FW={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function UW(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const $W={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!$q.test(e))return e;e=parseFloat(e)}return`${UW(e,t.target.x)}% ${UW(e,t.target.y)}%`}},BW={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=GH.parse(e);if(o.length>5)return r;const i=GH.createTransformer(e),a="number"!=typeof o[0]?1:0,s=n.x.scale*t.x,l=n.y.scale*t.y;o[0+a]/=s,o[1+a]/=l;const c=SG(s,l,.5);return"number"==typeof o[2+a]&&(o[2+a]/=c),"number"==typeof o[3+a]&&(o[3+a]/=c),i(o)}};class VW extends n.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:o}=e;!function(e){for(const t in e)Aq[t]=e[t],_q(t)&&(Aq[t].isCSSVariable=!0)}(zW),o&&(t.group&&t.group.add(o),n&&n.register&&r&&n.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",(()=>{this.safeToRemove()})),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),FW.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:r,isPresent:o}=this.props,i=n.projection;return i?(i.isPresent=o,r||e.layoutDependency!==t||void 0===t?i.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?i.promote():i.relegate()||VV.postRender((()=>{const e=i.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),gq.postRender((()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function qW(e){const[r,o]=TV(),i=n.useContext(yV);return t.jsx(VW,{...e,layoutGroup:i,switchLayoutGroup:n.useContext(yq),isPresent:r,safeToRemove:o})}const zW={borderRadius:{...$W,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:$W,borderTopRightRadius:$W,borderBottomLeftRadius:$W,borderBottomRightRadius:$W,boxShadow:BW};const HW=(e,t)=>e.depth-t.depth;class GW{constructor(){this.children=[],this.isDirty=!1}add(e){sH(this.children,e),this.isDirty=!0}remove(e){lH(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(HW),this.isDirty=!1,this.children.forEach(e)}}const KW=["TopLeft","TopRight","BottomLeft","BottomRight"],WW=KW.length,YW=e=>"string"==typeof e?parseFloat(e):e,XW=e=>"number"==typeof e||$q.test(e);function QW(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const ZW=eY(0,.5,TH),JW=eY(.5,.95,PV);function eY(e,t,n){return r=>r<e?0:r>t?1:n(DV(e,t,r))}function tY(e,t){e.min=t.min,e.max=t.max}function nY(e,t){tY(e.x,t.x),tY(e.y,t.y)}function rY(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function oY(e,t,n,r,o){return e=_W(e-=t,1/n,r),void 0!==o&&(e=_W(e,1/o,r)),e}function iY(e,t,[n,r,o],i,a){!function(e,t=0,n=1,r=.5,o,i=e,a=e){Uq.test(t)&&(t=parseFloat(t),t=SG(a.min,a.max,t/100)-a.min);if("number"!=typeof t)return;let s=SG(i.min,i.max,r);e===i&&(s-=t),e.min=oY(e.min,t,n,s,o),e.max=oY(e.max,t,n,s,o)}(e,t[n],t[r],t[o],t.scale,i,a)}const aY=["x","scaleX","originX"],sY=["y","scaleY","originY"];function lY(e,t,n,r){iY(e.x,t,aY,n?n.x:void 0,r?r.x:void 0),iY(e.y,t,sY,n?n.y:void 0,r?r.y:void 0)}function cY(e){return 0===e.translate&&1===e.scale}function uY(e){return cY(e.x)&&cY(e.y)}function dY(e,t){return e.min===t.min&&e.max===t.max}function pY(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function fY(e,t){return pY(e.x,t.x)&&pY(e.y,t.y)}function hY(e){return oW(e.x)/oW(e.y)}function mY(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class gY{constructor(){this.members=[]}add(e){sH(this.members,e),e.scheduleRender()}remove(e){if(lH(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let r=t;r>=0;r--){const e=this.members[r];if(!1!==e.isPresent){n=e;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const yY=["","X","Y","Z"],vY={visibility:"hidden"};let bY=0;function wY(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function xY(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=mH(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",VV,!(t||r))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&xY(r)}function EY({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(e={},n=(null==t?void 0:t())){this.id=bY++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(TY),this.nodes.forEach(kY),this.nodes.forEach(LY),this.nodes.forEach(CY)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let t=0;t<this.path.length;t++)this.path[t].shouldResetTransform=!0;this.root===this&&(this.nodes=new GW)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new cH),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){const n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;var r;this.isSVG=(r=t)instanceof SVGElement&&"svg"!==r.tagName,this.instance=t;const{layoutId:o,layout:i,visualElement:a}=this.options;if(a&&!a.current&&a.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(i||o)&&(this.isLayoutDirty=!0),e){let n;const r=()=>this.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=aH.now(),r=({timestamp:o})=>{const i=o-n;i>=t&&(qV(r),e(i-t))};return VV.read(r,!0),()=>qV(r)}(r,250),FW.hasAnimatedSinceResize&&(FW.hasAnimatedSinceResize=!1,this.nodes.forEach(PY))}))}o&&this.root.registerSharedNode(o,this),!1!==this.options.animate&&a&&(o||i)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const o=this.options.transition||a.getDefaultTransition()||UY,{onLayoutAnimationStart:i,onLayoutAnimationComplete:s}=a.getProps(),l=!this.targetLayout||!fY(this.targetLayout,r),c=!t&&n;if(this.options.layoutRoot||this.resumeFrom||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...Pz(o,"layout"),onPlay:i,onComplete:s};(a.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||PY(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,qV(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(MY),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&xY(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let o=0;o<this.path.length;o++){const e=this.path[o];e.shouldResetTransform=!0,e.updateScroll("snapshot"),e.options.layoutRoot&&e.willUpdate(!1)}const{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;const r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(OY);this.isUpdating||this.nodes.forEach(NY),this.isUpdating=!1,this.nodes.forEach(RY),this.nodes.forEach(_Y),this.nodes.forEach(SY),this.clearAllSnapshots();const e=aH.now();zV.delta=Lq(0,1e3/60,e-zV.timestamp),zV.timestamp=e,zV.isProcessing=!0,HV.update.process(zV),HV.preRender.process(zV),HV.render.process(zV),zV.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,gq.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(AY),this.sharedNodes.forEach(DY)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,VV.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){VV.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure(),!this.snapshot||oW(this.snapshot.measuredBox.x)||oW(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let n=0;n<this.path.length;n++){this.path[n].updateScroll()}const e=this.layout;this.layout=this.measure(!1),this.layoutCorrected={x:{min:0,max:0},y:{min:0,max:0}},this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){const t=r(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!o)return;const e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!uY(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,i=r!==this.prevTransformTemplateValue;e&&(t||wW(this.latestValues)||i)&&(o(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){const t=this.measurePageBox();let n=this.removeElementScroll(t);var r;return e&&(n=this.removeTransform(n)),VY((r=n).x),VY(r.y),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var e;const{visualElement:t}=this.options;if(!t)return{x:{min:0,max:0},y:{min:0,max:0}};const n=t.measureViewportBox();if(!((null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)||this.path.some(zY))){const{scroll:e}=this.root;e&&(NW(n.x,e.offset.x),NW(n.y,e.offset.y))}return n}removeElementScroll(e){var t;const n={x:{min:0,max:0},y:{min:0,max:0}};if(nY(n,e),null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)return n;for(let r=0;r<this.path.length;r++){const t=this.path[r],{scroll:o,options:i}=t;t!==this.root&&o&&i.layoutScroll&&(o.wasRoot&&nY(n,e),NW(n.x,o.offset.x),NW(n.y,o.offset.y))}return n}applyTransform(e,t=!1){const n={x:{min:0,max:0},y:{min:0,max:0}};nY(n,e);for(let r=0;r<this.path.length;r++){const e=this.path[r];!t&&e.options.layoutScroll&&e.scroll&&e!==e.root&&PW(n,{x:-e.scroll.offset.x,y:-e.scroll.offset.y}),wW(e.latestValues)&&PW(n,e.latestValues)}return wW(this.latestValues)&&PW(n,this.latestValues),n}removeTransform(e){const t={x:{min:0,max:0},y:{min:0,max:0}};nY(t,e);for(let n=0;n<this.path.length;n++){const e=this.path[n];if(!e.instance)continue;if(!wW(e.latestValues))continue;bW(e.latestValues)&&e.updateSnapshot();const r={x:{min:0,max:0},y:{min:0,max:0}};nY(r,e.measurePageBox()),lY(t,e.latestValues,e.snapshot?e.snapshot.layoutBox:void 0,r)}return wW(this.latestValues)&&lY(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==zV.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const r=Boolean(this.resumingFrom)||this!==n;if(!(e||r&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:o,layoutId:i}=this.options;if(this.layout&&(o||i)){if(this.resolvedRelativeTargetAt=zV.timestamp,!this.targetDelta&&!this.relativeTarget){const e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},cW(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),nY(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}var a,s,l;if(this.relativeTarget||this.targetDelta)if(this.target||(this.target={x:{min:0,max:0},y:{min:0,max:0}},this.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}}),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),sW((a=this.target).x,(s=this.relativeTarget).x,(l=this.relativeParent.target).x),sW(a.y,s.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):nY(this.target,this.layout.layoutBox),CW(this.target,this.targetDelta)):nY(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const e=this.getClosestProjectingParent();e&&Boolean(e.resumingFrom)===Boolean(this.resumingFrom)&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},cW(this.relativeTargetOrigin,this.target,e.target),nY(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}}}getClosestProjectingParent(){if(this.parent&&!bW(this.parent.latestValues)&&!xW(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;const t=this.getLead(),n=Boolean(this.resumingFrom)||this!==t;let r=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===zV.timestamp&&(r=!1),r)return;const{layout:o,layoutId:i}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!o&&!i)return;nY(this.layoutCorrected,this.layout.layoutBox);const a=this.treeScale.x,s=this.treeScale.y;!function(e,t,n,r=!1){const o=n.length;if(!o)return;let i,a;t.x=t.y=1;for(let s=0;s<o;s++){i=n[s],a=i.projectionDelta;const{visualElement:o}=i.options;o&&o.props.style&&"contents"===o.props.style.display||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&PW(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,CW(e,a)),r&&wW(i.latestValues)&&PW(e,i.latestValues))}t.x<OW&&t.x>AW&&(t.x=1),t.y<OW&&t.y>AW&&(t.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!t.layout||t.target||1===this.treeScale.x&&1===this.treeScale.y||(t.target=t.layout.layoutBox,t.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}});const{target:l}=t;l?(this.projectionDelta&&this.prevProjectionDelta?(rY(this.prevProjectionDelta.x,this.projectionDelta.x),rY(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),aW(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===a&&this.treeScale.y===s&&mY(this.projectionDelta.x,this.prevProjectionDelta.x)&&mY(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l))):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDeltaWithTransform={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}}setAnimationOrigin(e,t=!1){const n=this.snapshot,r=n?n.latestValues:{},o={...this.latestValues},i={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const a={x:{min:0,max:0},y:{min:0,max:0}},s=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(s&&!c&&!0===this.options.crossfade&&!this.path.some(FY));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;var l,p,f,h,m,g;jY(i.x,e.x,n),jY(i.y,e.y,n),this.setTargetDelta(i),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(cW(a,this.layout.layoutBox,this.relativeParent.layout.layoutBox),IY((f=this.relativeTarget).x,(h=this.relativeTargetOrigin).x,(m=a).x,g=n),IY(f.y,h.y,m.y,g),d&&(dY((l=this.relativeTarget).x,(p=d).x)&&dY(l.y,p.y))&&(this.isProjectionDirty=!1),d||(d={x:{min:0,max:0},y:{min:0,max:0}}),nY(d,this.relativeTarget)),s&&(this.animationValues=o,function(e,t,n,r,o,i){o?(e.opacity=SG(0,void 0!==n.opacity?n.opacity:1,ZW(r)),e.opacityExit=SG(void 0!==t.opacity?t.opacity:1,0,JW(r))):i&&(e.opacity=SG(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let a=0;a<WW;a++){const o=`border${KW[a]}Radius`;let i=QW(t,o),s=QW(n,o);void 0===i&&void 0===s||(i||(i=0),s||(s=0),0===i||0===s||XW(i)===XW(s)?(e[o]=Math.max(SG(YW(i),YW(s),r),0),(Uq.test(s)||Uq.test(i))&&(e[o]+="%")):e[o]=s)}(t.rotate||n.rotate)&&(e.rotate=SG(t.rotate||0,n.rotate||0,r))}(o,r,this.latestValues,n,u,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(qV(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=VV.update((()=>{FW.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const r=Pq(e)?e:pH(e);return r.start(NK("",r,t,n)),r.animation}(0,1e3,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onStop:()=>{},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:r,latestValues:o}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&qY(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||{x:{min:0,max:0},y:{min:0,max:0}};const t=oW(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const r=oW(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}nY(t,n),PW(t,o),aW(this.projectionDeltaWithTransform,this.layoutCorrected,t,o)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new gY);this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;const r={};n.z&&wY("z",e,r,this.animationValues);for(let o=0;o<yY.length;o++)wY(`rotate${yY[o]}`,e,r,this.animationValues),wY(`skew${yY[o]}`,e,r,this.animationValues);e.render();for(const o in r)e.setStaticValue(o,r[o]),this.animationValues&&(this.animationValues[o]=r[o]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return vY;const r={visibility:""},o=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=hz(null==e?void 0:e.pointerEvents)||"",r.transform=o?o(this.latestValues,""):"none",r;const i=this.getLead();if(!this.projectionDelta||!this.layout||!i.target){const t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=hz(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!wW(this.latestValues)&&(t.transform=o?o({},""):"none",this.hasProjected=!1),t}const a=i.animationValues||i.latestValues;this.applyTransformsToTarget(),r.transform=function(e,t,n){let r="";const o=e.x.translate/t.x,i=e.y.translate/t.y,a=(null==n?void 0:n.z)||0;if((o||i||a)&&(r=`translate3d(${o}px, ${i}px, ${a}px) `),1===t.x&&1===t.y||(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:e,rotate:t,rotateX:o,rotateY:i,skewX:a,skewY:s}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),o&&(r+=`rotateX(${o}deg) `),i&&(r+=`rotateY(${i}deg) `),a&&(r+=`skewX(${a}deg) `),s&&(r+=`skewY(${s}deg) `)}const s=e.x.scale*t.x,l=e.y.scale*t.y;return 1===s&&1===l||(r+=`scale(${s}, ${l})`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,a),o&&(r.transform=o(a,r.transform));const{x:s,y:l}=this.projectionDelta;r.transformOrigin=`${100*s.origin}% ${100*l.origin}% 0`,r.opacity=i.animationValues?i===this?null!==(n=null!==(t=a.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:a.opacityExit:i===this?void 0!==a.opacity?a.opacity:"":void 0!==a.opacityExit?a.opacityExit:0;for(const c in Aq){if(void 0===a[c])continue;const{correct:e,applyTo:t,isCSSVariable:n}=Aq[c],o="none"===r.transform?a[c]:e(a[c],i);if(t){const e=t.length;for(let n=0;n<e;n++)r[t[n]]=o}else n?this.options.visualElement.renderState.vars[c]=o:r[c]=o}return this.options.layoutId&&(r.pointerEvents=i===this?hz(null==e?void 0:e.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(OY),this.root.sharedNodes.clear()}}}function _Y(e){e.updateLayout()}function SY(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:r}=e.layout,{animationType:o}=e.options,i=n.source!==e.layout.source;"size"===o?gW((e=>{const r=i?n.measuredBox[e]:n.layoutBox[e],o=oW(r);r.min=t[e].min,r.max=r.min+o})):qY(o,n.layoutBox,t)&&gW((r=>{const o=i?n.measuredBox[r]:n.layoutBox[r],a=oW(t[r]);o.max=o.min+a,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+a)}));const a={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};aW(a,t,n.layoutBox);const s={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};i?aW(s,e.applyTransform(r,!0),n.measuredBox):aW(s,t,n.layoutBox);const l=!uY(a);let c=!1;if(!e.resumeFrom){const r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:o,layout:i}=r;if(o&&i){const a={x:{min:0,max:0},y:{min:0,max:0}};cW(a,n.layoutBox,o.layoutBox);const s={x:{min:0,max:0},y:{min:0,max:0}};cW(s,t,i.layoutBox),fY(a,s)||(c=!0),r.options.layoutRoot&&(e.relativeTarget=s,e.relativeTargetOrigin=a,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:s,layoutDelta:a,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function TY(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function CY(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function AY(e){e.clearSnapshot()}function OY(e){e.clearMeasurements()}function NY(e){e.isLayoutDirty=!1}function RY(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function PY(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function kY(e){e.resolveTargetDelta()}function LY(e){e.calcProjection()}function MY(e){e.resetSkewAndRotation()}function DY(e){e.removeLeadSnapshot()}function jY(e,t,n){e.translate=SG(t.translate,0,n),e.scale=SG(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function IY(e,t,n,r){e.min=SG(t.min,n.min,r),e.max=SG(t.max,n.max,r)}function FY(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const UY={duration:.45,ease:[.4,0,.1,1]},$Y=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),BY=$Y("applewebkit/")&&!$Y("chrome/")?Math.round:PV;function VY(e){e.min=BY(e.min),e.max=BY(e.max)}function qY(e,t,n){return"position"===e||"preserve-aspect"===e&&(r=hY(t),o=hY(n),i=.2,!(Math.abs(r-o)<=i));var r,o,i}function zY(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}const HY=EY({attachResizeListener:(e,t)=>KK(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),GY={current:void 0},KY=EY({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!GY.current){const e=new HY({});e.mount(window),e.setOptions({layoutScroll:!0}),GY.current=e}return GY.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),WY={pan:{Feature:class extends zK{constructor(){super(...arguments),this.removePointerDownListener=PV}onPointerDown(e){this.session=new QK(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:LW(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:IW(e),onStart:IW(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&VV.postRender((()=>r(e,t)))}}}mount(){this.removePointerDownListener=YK(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends zK{constructor(e){super(e),this.removeGroupControls=PV,this.removeListeners=PV,this.controls=new DW(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||PV}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:KY,MeasureLayout:qW}};function YY(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover","Start"===n);const o=r["onHover"+n];o&&VV.postRender((()=>o(t,WK(t))))}function XY(e,t,n){const{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap","Start"===n);const o=r["onTap"+("End"===n?"":n)];o&&VV.postRender((()=>o(t,WK(t))))}const QY=new WeakMap,ZY=new WeakMap,JY=e=>{const t=QY.get(e.target);t&&t(e)},eX=e=>{e.forEach(JY)};function tX(e,t,n){const r=function({root:e,...t}){const n=e||document;ZY.has(n)||ZY.set(n,{});const r=ZY.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(eX,{root:e,...t})),r[o]}(t);return QY.set(e,n),r.observe(e),()=>{QY.delete(e),r.unobserve(e)}}const nX={some:0,all:1};const rX={inView:{Feature:class extends zK{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:o}=e;return tX(this.node.current,{root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:nX[r]},(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,o&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),i=t?n:r;i&&i(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends zK{mount(){const{current:e}=this.node;e&&(this.unmount=nH(e,((e,t)=>(XY(this.node,t,"Start"),(e,{success:t})=>XY(this.node,e,t?"End":"Cancel"))),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends zK{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(tme){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=kG(KK(this.node.current,"focus",(()=>this.onFocus())),KK(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends zK{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[r,o,i]=Kz(e,n),a=e=>{if(!Wz(e))return;const{target:n}=e,r=t(n,e);if("function"!=typeof r||!n)return;const i=e=>{Wz(e)&&(r(e),n.removeEventListener("pointerleave",i))};n.addEventListener("pointerleave",i,o)};return r.forEach((e=>{e.addEventListener("pointerenter",a,o)})),i}(e,((e,t)=>(YY(this.node,t,"Start"),e=>YY(this.node,e,"End")))))}unmount(){}}}},oX={layout:{ProjectionNode:KY,MeasureLayout:qW}},iX={current:null},aX={current:!1};const sX=[...yG,IH,GH],lX=new WeakMap;const cX=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class uX{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:o,visualState:i},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=pG,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const e=aH.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,VV.render(this.render,!1,!0))};const{latestValues:s,renderState:l,onUpdate:c}=i;this.onUpdate=c,this.latestValues=s,this.baseTarget={...s},this.initialValues=t.initial?{...s}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=Boolean(o),this.isControllingVariants=sq(t),this.isVariantNode=lq(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(e&&e.current);const{willChange:u,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(const p in d){const e=d[p];void 0!==s[p]&&Pq(e)&&e.set(s[p],!1)}}mount(e){this.current=e,lX.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((e,t)=>this.bindToMotionValue(t,e))),aX.current||function(){if(aX.current=!0,OV)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>iX.current=e.matches;e.addListener(t),t()}else iX.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||iX.current),"production"!==process.env.NODE_ENV&&eq(!0!==this.shouldReduceMotion,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),qV(this.notifyUpdate),qV(this.render),this.valueSubscriptions.forEach((e=>e())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const n=Nq.has(e);n&&this.onBindTransform&&this.onBindTransform();const r=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&VV.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),o=t.on("renderRequest",this.scheduleRender);let i;window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,(()=>{r(),o(),i&&i(),t.owner&&t.stop()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in WV){const t=WV[e];if(!t)continue;const{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){const t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let n=0;n<cX.length;n++){const t=cX[n];this.propEventSubscriptions[t]&&(this.propEventSubscriptions[t](),delete this.propEventSubscriptions[t]);const r=e["on"+t];r&&(this.propEventSubscriptions[t]=this.on(t,r))}this.prevMotionValues=function(e,t,n){for(const r in t){const o=t[r],i=n[r];if(Pq(o))e.addValue(r,o),"development"===process.env.NODE_ENV&&eq("12.4.0"===o.version,`Attempting to mix Motion versions ${o.version} with 12.4.0 may not work as expected.`);else if(Pq(i))e.addValue(r,pH(o,{owner:e}));else if(i!==o)if(e.hasValue(r)){const t=e.getValue(r);!0===t.liveStyle?t.jump(o):t.hasAnimated||t.set(o)}else{const t=e.getStaticValue(r);e.addValue(r,pH(void 0!==t?t:o,{owner:e}))}}for(const r in n)void 0===t[r]&&e.removeValue(r);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){const t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){const n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=pH(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let r=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];return null!=r&&("string"==typeof r&&(fG(r)||AH(r))?r=parseFloat(r):!sX.find(gG(r))&&GH.test(t)&&(r=JH(e,t)),this.setBaseTarget(e,Pq(r)?r.get():r)),Pq(r)?r.get():r}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props;let r;if("string"==typeof n||"object"==typeof n){const o=pz(this.props,n,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);o&&(r=o[e])}if(n&&void 0!==r)return r;const o=this.getBaseTargetFromProps(this.props,e);return void 0===o||Pq(o)?void 0!==this.initialValues[e]&&void 0===r?void 0:this.baseTarget[e]:o}on(e,t){return this.events[e]||(this.events[e]=new cH),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class dX extends uX{constructor(){super(...arguments),this.KeyframeResolver=bG}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Pq(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}}class pX extends dX{constructor(){super(...arguments),this.type="html",this.renderInstance=wz}readValueFromInstance(e,t){if(Nq.has(t)){const e=ZH(t);return e&&e.default||0}{const n=window.getComputedStyle(e),r=(_q(t)?n.getPropertyValue(t):n[t])||0;return"string"==typeof r?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return kW(e,t)}build(e,t,n){Xq(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return yz(e,t,n)}}class fX extends dX{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=mW,this.updateDimensions=()=>{this.current&&!this.renderState.dimensions&&bz(this.current,this.renderState)}}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(Nq.has(t)){const e=ZH(t);return e&&e.default||0}return t=xz.has(t)?t:hq(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return _z(e,t,n)}onBindTransform(){this.current&&!this.renderState.dimensions&&VV.postRender(this.updateDimensions)}build(e,t,n){az(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,r){Ez(e,t,0,r)}mount(e){this.isSVGTag=lz(e.tagName),super.mount(e)}}const hX=tq(Cz({...GK,...rX,...WY,...oX},((e,t)=>nz(e)?new fX(t):new pX(t,{allowProjection:e!==n.Fragment})))),mX="0123456789abcdef";class gX{constructor(e){this.bytes=e}static ofInner(e){if(16!==e.length)throw new TypeError("not 128-bit length");return new gX(e)}static fromFieldsV7(e,t,n,r){if(!Number.isInteger(e)||!Number.isInteger(t)||!Number.isInteger(n)||!Number.isInteger(r)||e<0||t<0||n<0||r<0||e>0xffffffffffff||t>4095||n>1073741823||r>4294967295)throw new RangeError("invalid field value");const o=new Uint8Array(16);return o[0]=e/2**40,o[1]=e/2**32,o[2]=e/2**24,o[3]=e/65536,o[4]=e/256,o[5]=e,o[6]=112|t>>>8,o[7]=t,o[8]=128|n>>>24,o[9]=n>>>16,o[10]=n>>>8,o[11]=n,o[12]=r>>>24,o[13]=r>>>16,o[14]=r>>>8,o[15]=r,new gX(o)}static parse(e){var t,n,r,o;let i;switch(e.length){case 32:i=null===(t=/^[0-9a-f]{32}$/i.exec(e))||void 0===t?void 0:t[0];break;case 36:i=null===(n=/^([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})$/i.exec(e))||void 0===n?void 0:n.slice(1,6).join("");break;case 38:i=null===(r=/^\{([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})\}$/i.exec(e))||void 0===r?void 0:r.slice(1,6).join("");break;case 45:i=null===(o=/^urn:uuid:([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})$/i.exec(e))||void 0===o?void 0:o.slice(1,6).join("")}if(i){const e=new Uint8Array(16);for(let t=0;t<16;t+=4){const n=parseInt(i.substring(2*t,2*t+8),16);e[t+0]=n>>>24,e[t+1]=n>>>16,e[t+2]=n>>>8,e[t+3]=n}return new gX(e)}throw new SyntaxError("could not parse UUID string")}toString(){let e="";for(let t=0;t<this.bytes.length;t++)e+=mX.charAt(this.bytes[t]>>>4),e+=mX.charAt(15&this.bytes[t]),3!==t&&5!==t&&7!==t&&9!==t||(e+="-");return e}toHex(){let e="";for(let t=0;t<this.bytes.length;t++)e+=mX.charAt(this.bytes[t]>>>4),e+=mX.charAt(15&this.bytes[t]);return e}toJSON(){return this.toString()}getVariant(){const e=this.bytes[8]>>>4;if(e<0)throw new Error("unreachable");if(e<=7)return this.bytes.every((e=>0===e))?"NIL":"VAR_0";if(e<=11)return"VAR_10";if(e<=13)return"VAR_110";if(e<=15)return this.bytes.every((e=>255===e))?"MAX":"VAR_RESERVED";throw new Error("unreachable")}getVersion(){return"VAR_10"===this.getVariant()?this.bytes[6]>>>4:void 0}clone(){return new gX(this.bytes.slice(0))}equals(e){return 0===this.compareTo(e)}compareTo(e){for(let t=0;t<16;t++){const n=this.bytes[t]-e.bytes[t];if(0!==n)return Math.sign(n)}return 0}}class yX{constructor(e){this.timestamp=0,this.counter=0,this.random=null!=e?e:vX()}generate(){return this.generateOrResetCore(Date.now(),1e4)}generateOrAbort(){return this.generateOrAbortCore(Date.now(),1e4)}generateOrResetCore(e,t){let n=this.generateOrAbortCore(e,t);return void 0===n&&(this.timestamp=0,n=this.generateOrAbortCore(e,t)),n}generateOrAbortCore(e,t){if(!Number.isInteger(e)||e<1||e>0xffffffffffff)throw new RangeError("`unixTsMs` must be a 48-bit positive integer");if(t<0||t>0xffffffffffff)throw new RangeError("`rollbackAllowance` out of reasonable range");if(e>this.timestamp)this.timestamp=e,this.resetCounter();else{if(!(e+t>=this.timestamp))return;this.counter++,this.counter>4398046511103&&(this.timestamp++,this.resetCounter())}return gX.fromFieldsV7(this.timestamp,Math.trunc(this.counter/2**30),this.counter&2**30-1,this.random.nextUint32())}resetCounter(){this.counter=1024*this.random.nextUint32()+(1023&this.random.nextUint32())}generateV4(){const e=new Uint8Array(Uint32Array.of(this.random.nextUint32(),this.random.nextUint32(),this.random.nextUint32(),this.random.nextUint32()).buffer);return e[6]=64|e[6]>>>4,e[8]=128|e[8]>>>2,gX.ofInner(e)}}const vX=()=>{if("undefined"!=typeof crypto&&void 0!==crypto.getRandomValues)return new bX;if("undefined"!=typeof UUIDV7_DENY_WEAK_RNG&&UUIDV7_DENY_WEAK_RNG)throw new Error("no cryptographically strong RNG available");return{nextUint32:()=>65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random())}};class bX{constructor(){this.buffer=new Uint32Array(8),this.cursor=65535}nextUint32(){return this.cursor>=this.buffer.length&&(crypto.getRandomValues(this.buffer),this.cursor=0),this.buffer[this.cursor++]}}let wX;const xX=()=>(wX||(wX=new yX)).generate();const EX={all:["stripo"],token:()=>[...EX.all,"token"],editorData:()=>[...EX.all,"editorData"],templates:()=>[...EX.all,"templates"],demoTemplate:()=>[...EX.templates(),"demo"]},_X=async()=>(await Ae(`${p}/editor-data`)).data,SX=e=>ge({queryKey:["stripo","templates",e],queryFn:()=>(async e=>(await Ae(`${p}/template/${e}`)).data)(e),...xe}),TX=({text:e,textSpeed:r=2e3,textColor:o="text-muted-foreground"})=>{const[i,a]=n.useState(0),s=Array.isArray(e)?e:e?[e]:[];return n.useEffect((()=>{if(s.length<=1)return;if(i>=s.length-1)return;const e=setInterval((()=>{a((e=>e<s.length-1?e+1:e))}),r);return()=>clearInterval(e)}),[s.length,r,i]),t.jsxs("div",{className:"flex flex-col items-center justify-center gap-3 @container",children:[t.jsxs("div",{className:"relative h-8 w-8",children:[t.jsx("div",{className:"absolute inset-0 rounded-full border-2 border-primary/20"}),t.jsx("div",{className:"absolute inset-0 animate-spin rounded-full border-2 border-primary border-t-transparent"})]}),s.length>0&&t.jsx("div",{className:`text-center text-sm ${o} animate-fade-in min-w-[200px] max-w-[300px] px-4`,children:t.jsx("div",{className:"break-words",children:s[i]})},i),t.jsx("style",{children:"\n .animate-fade-in {\n animation: fadeIn 0.5s ease-in-out;\n }\n @keyframes fadeIn {\n from {\n opacity: 0;\n transform: translateY(5px);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n }\n "})]})},CX=({children:e,className:n})=>t.jsx(hX.div,{initial:{opacity:0,filter:"blur(8px)"},animate:{opacity:1,filter:"blur(0px)"},exit:{opacity:0,filter:"blur(8px)"},transition:{duration:.3,ease:"easeInOut"},className:n,children:e}),AX={CloseButton:Yu,DropdownMenuTrigger:lu,UserIcon:Gu,UsersIcon:Ku,UserEdit:zu,ScheduleButton:au,SendButton:Iu,BackButton:cu,NextButton:uu,MergeField:Hu,PlusIcon:Mu,AlertCircleIcon:fu,OneTimeBroadcast:Nu,PatronEntersList:_u,DateMilestone:au,RealtimeActivity:iu,EmailIcon:Cu,SmsIcon:Ru,MessagesSent:Tu,LinksClicked:ku,OpenRate:wu,SpamComplies:Vu,TotalBounceRate:Vu,UnsubscribeRate:Uu},OX=e=>({...AX,...e||{}}),NX=Jc(["reach-styles-module__base___gfFyc"],{variants:{variant:{default:"reach-styles-module__default___ny1h7",destructive:"reach-styles-module__destructive___XjBvS",outline:"reach-styles-module__outline___gFp3i",secondary:"reach-styles-module__secondary___Pd-e3",ghost:"reach-styles-module__ghost___GcnJq",link:"reach-styles-module__link___EgS2H"},size:{default:"reach-styles-module__sizeDefault___8kU5A",sm:"reach-styles-module__sizeSm___zPIEh",lg:"reach-styles-module__sizeLg___D2G8z",icon:"reach-styles-module__sizeIcon___5XkYW"}},defaultVariants:{variant:"default",size:"default"}}),RX=i.forwardRef((({className:e,variant:n,size:r,asChild:o=!1,...i},a)=>t.jsx(o?UU:"button",{className:qd(NX({variant:n,size:r,className:e})),ref:a,...i})));RX.displayName="Button";var PX=(e=>(e.ChooseAutomationType="choose-automation-type",e.SetAutomationName="set-automation-name",e))(PX||{});const kX=({onClose:e,currentStep:n,setCurrentStep:r,isDisabled:o,createAutomation:i,disableBackButton:a})=>t.jsx("div",{children:t.jsxs("div",{className:"flex justify-end space-x-4",children:[t.jsx(RX,{variant:"secondary",className:"px-4 py-2",onClick:()=>{if(a)e?.(!1);else if(n===PX.ChooseAutomationType)e?.(!1);else{if(n!==PX.SetAutomationName)throw new Error("Invalid step");r(PX.ChooseAutomationType)}},children:n===PX.ChooseAutomationType||a?"Cancel":"Back"}),t.jsx(RX,{className:"px-4 py-2",onClick:()=>{o||n!==PX.SetAutomationName||i()},disabled:o,children:n===PX.SetAutomationName?"Create":"Next"})]})}),LX=({onClick:e,title:n,subtitle:r,icon:o,selected:i,disabled:a=!1})=>t.jsxs("button",{onClick:e,className:"flex flex-col items-center justify-center rounded-lg border-[3px] p-6 transition-all duration-300 ease-in-out "+(a?"opacity-50 cursor-not-allowed":i?"scale-[1.02] hover:scale-[1.04] [border-color:hsl(var(--reach-primary))] [background-color:hsl(var(--reach-primary)/0.05)]":"border-gray-200 hover:[border-color:hsl(var(--reach-primary))] hover:bg-gray-50"),children:[o,t.jsxs("div",{className:"text-center mt-3",children:[t.jsx("div",{className:"text-sm font-medium text-gray-900",children:n}),t.jsx("div",{className:"text-xs text-gray-500 mt-1",children:r})]})]}),MX="text-3xl mb-8",DX="grid grid-cols-2 gap-6",jX="relative p-6 rounded-lg",IX="mb-4 flex items-center justify-center",FX="text-lg font-medium mb-2",UX="text-sm text-muted-foreground",$X="absolute top-3 right-3 bg-gray-100 text-gray-600 text-xs px-2 py-1 rounded-full",BX=({onNext:e,iconDefinitions:n})=>t.jsxs("div",{className:jX,children:[t.jsx("h1",{className:MX,children:"Choose Your Automation Type"}),t.jsxs("div",{className:DX,children:[t.jsx(LX,{onClick:()=>{e(Me.ONE_TIME)},title:`${tf("engage:one_time")} Broadcast`,subtitle:"Send a single message to your current list, like announcing a sale or newsletter.",icon:t.jsx(n.OneTimeBroadcast,{}),selected:!1}),t.jsx(LX,{onClick:()=>{},title:"Patron Enters a List",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.PatronEntersList,{}),selected:!1,disabled:!0}),t.jsx(LX,{onClick:()=>{},title:"Date Milestone",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.DateMilestone,{}),selected:!1,disabled:!0}),t.jsx(LX,{onClick:()=>{},title:"Realtime Activity",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.RealtimeActivity,{}),selected:!1,disabled:!0})]})]});function VX(e,t){throw new Error(`Unreachable case statement: ${JSON.stringify(e)}. Valid values are: ${Object.values(t).join(", ")}`)}const qX=i.forwardRef((({className:e,type:n,...r},o)=>t.jsx("input",{type:n,className:qd("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:o,...r})));qX.displayName="Input";const zX=i.forwardRef((({className:e,...n},r)=>t.jsx("textarea",{className:qd("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n})));zX.displayName="Textarea";const HX=({iconDefinitions:e})=>t.jsxs("div",{children:[t.jsx("div",{className:IX,children:t.jsx(e.OneTimeBroadcast,{})}),t.jsxs("h3",{className:FX,children:[tf("engage:one_time")," Broadcast"]}),t.jsx("p",{className:UX,children:"Send a single message to your current list, like announcing a sale or newsletter."})]}),GX=({iconDefinitions:e})=>t.jsxs("div",{children:[t.jsx("div",{className:$X,children:"Coming Soon"}),t.jsx("div",{className:IX,children:t.jsx(e.RealtimeActivity,{})}),t.jsx("h3",{className:FX,children:"Realtime Activity"}),t.jsx("p",{className:UX,children:"Responds to immediate actions your contacts take, like abandoned carts, form submissions, or appointment bookings."})]}),KX=({selectedType:e,setAutomationName:n,automationName:r,iconDefinitions:o,setAutomationDescription:i,automationDescription:a})=>t.jsxs("div",{className:"flex flex-col items-center justify-center p-8 max-w-lg mx-auto",children:[t.jsxs("h2",{className:"text-2xl font-semibold mb-8 text-center",children:["Name Your ",tf("engage:automation")]}),t.jsxs("div",{className:"w-full space-y-6",children:[t.jsx("div",{className:"bg-gray-50 p-6 rounded-xl items-center justify-center text-center",children:(()=>{switch(e){case Me.ONE_TIME:return t.jsx(HX,{iconDefinitions:o});case Me.TRIGGER_BASED:return t.jsx(GX,{iconDefinitions:o});default:throw VX(e,Me)}})()}),t.jsxs("div",{className:"space-y-6",children:[t.jsxs("div",{children:[t.jsxs("div",{className:"flex items-baseline justify-between mb-2",children:[t.jsx("label",{htmlFor:"automationName",className:"block text-sm font-medium text-gray-900",children:"Name"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"Only visible to your team"})]}),t.jsx(qX,{id:"automationName",type:"text",value:r,onChange:e=>n(e.target.value),className:"w-full px-4 py-2 border border-gray-300 rounded-md focus:ring-indigo-500 focus:border-indigo-500 shadow-sm",placeholder:"e.g. April Newsletter Campaign",autoFocus:!0})]}),t.jsxs("div",{children:[t.jsxs("div",{className:"flex items-baseline justify-between mb-2",children:[t.jsx("label",{htmlFor:"automationDescription",className:"block text-sm font-medium text-gray-900",children:"Description"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"Optional"})]}),t.jsx(zX,{id:"automationDescription",value:a,onChange:e=>i(e.target.value),className:"w-full min-h-[80px] resize-none",placeholder:`Add any helpful context for your team. If left blank, we'll generate one for you when you start the ${tf("engage:automation")}`})]})]})]})]}),WX=({onClose:e,iconDefinitions:r,automationType:o})=>{const{createAutomation:i,isCreating:a}=Pe(),[s,l]=n.useState(!1),c=OX(r),[u,f]=n.useState(o?PX.SetAutomationName:PX.ChooseAutomationType),[h,m]=n.useState(o?{name:void 0,description:void 0,type:o}:{name:void 0,description:void 0,type:void 0}),g=void 0!==h.name&&void 0!==h.type;n.useEffect((()=>{if(h.type&&!h.name){const e=new Date,t=e.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),n=e.toLocaleDateString([],{month:"long",day:"numeric"}),r=`${tf("engage:automation")} ${n} ${t}`,o="";m((e=>({...e,name:r,description:o})))}}),[h]);if(a||s)return t.jsx("div",{className:jX,children:t.jsx(TX,{text:["Creating Automation","Finishing up"]})});return t.jsxs("div",{className:"relative overflow-y-auto h-full p-8",children:[t.jsx(RV,{mode:"wait",children:t.jsx(CX,{children:(()=>{switch(u){case PX.ChooseAutomationType:return t.jsx(BX,{onNext:e=>{m({...h,type:e}),f(PX.SetAutomationName)},iconDefinitions:c});case PX.SetAutomationName:return h.type?t.jsx(KX,{iconDefinitions:c,selectedType:h.type,setAutomationName:e=>{m({...h,name:e})},automationName:h.name??"",setAutomationDescription:e=>{m({...h,description:e})},automationDescription:h.description??""}):null;default:throw function(e,t){throw new Error(`Unreachable case statement: ${JSON.stringify(e)}. Valid values are: ${Object.values(t).join(", ")}`)}(u,PX)}})()},u)}),t.jsx("div",{className:"pt-2",children:t.jsx(kX,{onClose:e,currentStep:u,setCurrentStep:f,isDisabled:!g,createAutomation:async()=>{if(!g||!h.name||!h.type)return;l(!0);i({name:h.name,type:h.type,description:h.description},{onSuccess:async t=>{if(t.id){const n=await(async e=>(await Ae(`${d}`,{method:"POST",body:JSON.stringify(e)})).data)({}),r=xX().toString();await Oe(t.id,{action:[{actionType:"send_communication",actionMetadata:{actionType:"send_communication",communicationGroupId:n.id,currentActionId:r}}]}),await(async e=>{const{automationId:t,actionId:n}=e;return(await Ae(`${p}/template/${t}/${n}`)).data})({automationId:t.id,actionId:r}),e?.(t.id)}else e?.("error")},onError:()=>{e?.("error")},onSettled:()=>{m({name:void 0,description:void 0,type:void 0})}})},disableBackButton:void 0!==o})})]})};function YX({open:e,setOpen:n,onClose:r,iconDefinitions:o,automationType:i}){return t.jsx(uV,{open:e,onOpenChange:n,children:t.jsxs(fV,{className:"flex max-h-[86vh] flex-col gap-0 overflow-visible max-w-4xl w-full p-0",children:[t.jsx(hV,{children:t.jsx("div",{className:"flex items-center justify-between",children:t.jsxs(zU,{children:[t.jsx(mV,{className:"text-3xl font-normal",children:"Create Automation"}),t.jsx(gV,{children:"Create a new automation to send messages to your customers."})]})})}),t.jsx(WX,{onClose:e=>{r?.(e),n(!1)},iconDefinitions:o,automationType:i})]})})}var XX={};Object.defineProperty(XX,"__esModule",{value:!0}),XX.parse=function(e,t){const n=new nQ,r=e.length;if(r<2)return n;const o=t?.decode||iQ;let i=0;do{const t=e.indexOf("=",i);if(-1===t)break;const a=e.indexOf(";",i),s=-1===a?r:a;if(t>s){i=e.lastIndexOf(";",t-1)+1;continue}const l=rQ(e,i,t),c=oQ(e,t,l),u=e.slice(l,c);if(void 0===n[u]){let r=rQ(e,t+1,s),i=oQ(e,s,r);const a=o(e.slice(r,i));n[u]=a}i=s+1}while(i<r);return n},XX.serialize=function(e,t,n){const r=n?.encode||encodeURIComponent;if(!QX.test(e))throw new TypeError(`argument name is invalid: ${e}`);const o=r(t);if(!ZX.test(o))throw new TypeError(`argument val is invalid: ${t}`);let i=e+"="+o;if(!n)return i;if(void 0!==n.maxAge){if(!Number.isInteger(n.maxAge))throw new TypeError(`option maxAge is invalid: ${n.maxAge}`);i+="; Max-Age="+n.maxAge}if(n.domain){if(!JX.test(n.domain))throw new TypeError(`option domain is invalid: ${n.domain}`);i+="; Domain="+n.domain}if(n.path){if(!eQ.test(n.path))throw new TypeError(`option path is invalid: ${n.path}`);i+="; Path="+n.path}if(n.expires){if(!function(e){return"[object Date]"===tQ.call(e)}
|
|
33
|
+
*/function ud(){let e,t,n=0,r="";for(;n<arguments.length;)(e=arguments[n++])&&(t=dd(e))&&(r&&(r+=" "),r+=t);return r}const dd=e=>{if("string"==typeof e)return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=dd(e[r]))&&(n&&(n+=" "),n+=t);return n};function pd(e,...t){let n,r,o,i=function(s){const l=t.reduce(((e,t)=>t(e)),e());return n=(e=>({cache:ad(e.cacheSize),parseClassName:sd(e),...Qu(e)}))(l),r=n.cache.get,o=n.cache.set,i=a,a(s)};function a(e){const t=r(e);if(t)return t;const i=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,i=[],a=e.trim().split(cd);let s="";for(let l=a.length-1;l>=0;l-=1){const e=a[l],{modifiers:t,hasImportantModifier:c,baseClassName:u,maybePostfixModifierPosition:d}=n(e);let p=Boolean(d),f=r(p?u.substring(0,d):u);if(!f){if(!p){s=e+(s.length>0?" "+s:s);continue}if(f=r(u),!f){s=e+(s.length>0?" "+s:s);continue}p=!1}const h=ld(t).join(":"),m=c?h+"!":h,g=m+f;if(i.includes(g))continue;i.push(g);const y=o(f,p);for(let n=0;n<y.length;++n)i.push(m+y[n]);s=e+(s.length>0?" "+s:s)}return s})(e,n);return o(e,i),i}return function(){return i(ud.apply(null,arguments))}}const fd=e=>{const t=t=>t[e]||[];return t.isThemeGetter=!0,t},hd=/^\[(?:([a-z-]+):)?(.+)\]$/i,md=/^\d+\/\d+$/,gd=new Set(["px","full","screen"]),yd=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,vd=/\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$/,bd=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,wd=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xd=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ed=e=>Sd(e)||gd.has(e)||md.test(e),_d=e=>Id(e,"length",Fd),Sd=e=>Boolean(e)&&!Number.isNaN(Number(e)),Td=e=>Id(e,"number",Sd),Cd=e=>Boolean(e)&&Number.isInteger(Number(e)),Ad=e=>e.endsWith("%")&&Sd(e.slice(0,-1)),Od=e=>hd.test(e),Nd=e=>yd.test(e),Rd=new Set(["length","size","percentage"]),Pd=e=>Id(e,Rd,Ud),kd=e=>Id(e,"position",Ud),Ld=new Set(["image","url"]),Md=e=>Id(e,Ld,Bd),Dd=e=>Id(e,"",$d),jd=()=>!0,Id=(e,t,n)=>{const r=hd.exec(e);return!!r&&(r[1]?"string"==typeof t?r[1]===t:t.has(r[1]):n(r[2]))},Fd=e=>vd.test(e)&&!bd.test(e),Ud=()=>!1,$d=e=>wd.test(e),Bd=e=>xd.test(e),Vd=pd((()=>{const e=fd("colors"),t=fd("spacing"),n=fd("blur"),r=fd("brightness"),o=fd("borderColor"),i=fd("borderRadius"),a=fd("borderSpacing"),s=fd("borderWidth"),l=fd("contrast"),c=fd("grayscale"),u=fd("hueRotate"),d=fd("invert"),p=fd("gap"),f=fd("gradientColorStops"),h=fd("gradientColorStopPositions"),m=fd("inset"),g=fd("margin"),y=fd("opacity"),v=fd("padding"),b=fd("saturate"),w=fd("scale"),x=fd("sepia"),E=fd("skew"),_=fd("space"),S=fd("translate"),T=()=>["auto",Od,t],C=()=>[Od,t],A=()=>["",Ed,_d],O=()=>["auto",Sd,Od],N=()=>["","0",Od],R=()=>[Sd,Od];return{cacheSize:500,separator:":",theme:{colors:[jd],spacing:[Ed,_d],blur:["none","",Nd,Od],brightness:R(),borderColor:[e],borderRadius:["none","","full",Nd,Od],borderSpacing:C(),borderWidth:A(),contrast:R(),grayscale:N(),hueRotate:R(),invert:N(),gap:C(),gradientColorStops:[e],gradientColorStopPositions:[Ad,_d],inset:T(),margin:T(),opacity:R(),padding:C(),saturate:R(),scale:R(),sepia:N(),skew:R(),space:C(),translate:C()},classGroups:{aspect:[{aspect:["auto","square","video",Od]}],container:["container"],columns:[{columns:[Nd]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"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:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",Od]}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Cd,Od]}],basis:[{basis:T()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Od]}],grow:[{grow:N()}],shrink:[{shrink:N()}],order:[{order:["first","last","none",Cd,Od]}],"grid-cols":[{"grid-cols":[jd]}],"col-start-end":[{col:["auto",{span:["full",Cd,Od]},Od]}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":[jd]}],"row-start-end":[{row:["auto",{span:[Cd,Od]},Od]}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Od]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Od]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal","start","end","center","between","around","evenly","stretch"]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[_]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[_]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Od,t]}],"min-w":[{"min-w":[Od,t,"min","max","fit"]}],"max-w":[{"max-w":[Od,t,"none","full","min","max","fit","prose",{screen:[Nd]},Nd]}],h:[{h:[Od,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Od,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Od,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Od,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Nd,_d]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Td]}],"font-family":[{font:[jd]}],"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-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Od]}],"line-clamp":[{"line-clamp":["none",Sd,Td]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Ed,Od]}],"list-image":[{"list-image":["none",Od]}],"list-style-type":[{list:["none","disc","decimal",Od]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","none","wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Ed,_d]}],"underline-offset":[{"underline-offset":["auto",Ed,Od]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:C()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Od]}],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",Od]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",kd]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Pd]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Md]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[h]}],"gradient-via-pos":[{via:[h]}],"gradient-to-pos":[{to:[h]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:["solid","dashed","dotted","double","none","hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:["solid","dashed","dotted","double","none"]}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["","solid","dashed","dotted","double","none"]}],"outline-offset":[{"outline-offset":[Ed,Od]}],"outline-w":[{outline:[Ed,_d]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:A()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[Ed,_d]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Nd,Dd]}],"shadow-color":[{shadow:[jd]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Nd,Od]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[b]}],sepia:[{sepia:[x]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[b]}],"backdrop-sepia":[{"backdrop-sepia":[x]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Od]}],duration:[{duration:R()}],ease:[{ease:["linear","in","out","in-out",Od]}],delay:[{delay:R()}],animate:[{animate:["none","spin","ping","pulse","bounce",Od]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[w]}],"scale-x":[{"scale-x":[w]}],"scale-y":[{"scale-y":[w]}],rotate:[{rotate:[Cd,Od]}],"translate-x":[{"translate-x":[S]}],"translate-y":[{"translate-y":[S]}],"skew-x":[{"skew-x":[E]}],"skew-y":[{"skew-y":[E]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Od]}],accent:[{accent:["auto",e]}],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",Od]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":C()}],"scroll-mx":[{"scroll-mx":C()}],"scroll-my":[{"scroll-my":C()}],"scroll-ms":[{"scroll-ms":C()}],"scroll-me":[{"scroll-me":C()}],"scroll-mt":[{"scroll-mt":C()}],"scroll-mr":[{"scroll-mr":C()}],"scroll-mb":[{"scroll-mb":C()}],"scroll-ml":[{"scroll-ml":C()}],"scroll-p":[{"scroll-p":C()}],"scroll-px":[{"scroll-px":C()}],"scroll-py":[{"scroll-py":C()}],"scroll-ps":[{"scroll-ps":C()}],"scroll-pe":[{"scroll-pe":C()}],"scroll-pt":[{"scroll-pt":C()}],"scroll-pr":[{"scroll-pr":C()}],"scroll-pb":[{"scroll-pb":C()}],"scroll-pl":[{"scroll-pl":C()}],"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",Od]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Ed,_d,Td]}],stroke:[{stroke:[e,"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-s","border-color-e","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"]}}}));function qd(...e){return Vd(Xc(e))}const zd=Vc,Hd=i.forwardRef((({className:e,...n},r)=>t.jsx(qc,{ref:r,className:qd("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:top-0 sm:right-0 sm:bottom-auto sm:flex-col md:max-w-[420px]",e),...n})));Hd.displayName=qc.displayName;const Gd=Jc("group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Kd=i.forwardRef((({className:e,variant:n,...r},o)=>t.jsx(zc,{ref:o,className:qd(Gd({variant:n}),e),...r})));Kd.displayName=zc.displayName;i.forwardRef((({className:e,...n},r)=>t.jsx(Kc,{ref:r,className:qd("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium transition-colors hover:bg-secondary focus:outline-none focus:ring-1 focus:ring-ring disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-muted/40 group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground group-[.destructive]:focus:ring-destructive",e),...n}))).displayName=Kc.displayName;const Wd=i.forwardRef((({className:e,...n},r)=>t.jsx(Wc,{ref:r,className:qd("absolute right-1 top-1 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity hover:text-foreground focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...n,children:t.jsx(Yu,{className:"h-4 w-4"})})));Wd.displayName=Wc.displayName;const Yd=i.forwardRef((({className:e,...n},r)=>t.jsx(Hc,{ref:r,className:qd("text-sm font-semibold [&+div]:text-xs",e),...n})));Yd.displayName=Hc.displayName;const Xd=i.forwardRef((({className:e,...n},r)=>t.jsx(Gc,{ref:r,className:qd("text-sm opacity-90",e),...n})));function Qd(){const{toasts:e}=Rl();return t.jsxs(zd,{children:[e.map((function({id:e,title:n,description:r,action:o,...i}){return t.jsxs(Kd,{...i,children:[t.jsxs("div",{className:"grid gap-1",children:[n&&t.jsx(Yd,{children:n}),r&&t.jsx(Xd,{children:r})]}),o,t.jsx(Wd,{})]},e)})),t.jsx(Hd,{})]})}Xd.displayName=Gc.displayName;const Zd=(e,r,o,i)=>{const a=n.createContext({state:o});return{Context:a,Provider:({children:s})=>{const[l,c]=n.useReducer(e,o),u=n.useMemo((()=>Object.keys(r).reduce(((e,t)=>({...e,[t]:r[t](c)})),{})),[c]);n.useEffect((()=>{const e=[];return i?.length&&i.forEach((({eventName:t,handler:n})=>{const r=n(c),o=ve.subscribe(t,r);e.push(o)})),()=>e.forEach((e=>e()))}),[c]);const d=n.useMemo((()=>({state:l,...u})),[l,u]);return t.jsx(a.Provider,{value:d,children:s})}}},Jd=[{eventName:be,handler:e=>()=>{e({type:"SET_AUTHENTICATED",payload:!1}),e({type:"SET_REAUTHING",payload:!0})}},{eventName:we,handler:e=>()=>{e({type:"SET_AUTHENTICATED",payload:!0})}}],{Provider:ep}=Zd(((e,t)=>{switch(t.type){case"SET_AUTHENTICATED":return{...e,isAuthenticated:t.payload,error:null,reauthing:!1};case"SET_LOADING":return{...e,loading:t.payload};case"SET_ERROR":return{...e,error:t.payload,isAuthenticated:!1,reauthing:!1};case"SET_REAUTHING":return e.reauthing&&t.payload?e:{...e,reauthing:t.payload};default:return e}}),{handleReauth:e=>async t=>{if(t){e({type:"SET_REAUTHING",payload:!0});try{t()}catch(n){e({type:"SET_ERROR",payload:n instanceof Error?n.message:"Reauthorization failed"})}}else e({type:"SET_ERROR",payload:"No reauth callback provided"})}},{isAuthenticated:!1,loading:!1,error:null,reauthing:!1},Jd),tp={background:"0 0% 100%",foreground:"225 15% 16%",card:"0 0% 100%","card-foreground":"225 15% 16%",popover:"0 0% 100%","popover-foreground":"225 15% 16%",primary:"210 30% 25%","primary-foreground":"0 0% 100%",secondary:"210 15% 94%","secondary-foreground":"210 30% 25%",muted:"210 10% 96%","muted-foreground":"220 10% 45%",accent:"210 15% 94%","accent-foreground":"210 30% 25%",destructive:"0 84.2% 60.2%","destructive-foreground":"0 0% 100%",border:"220 13% 90%",input:"220 13% 90%",ring:"210 30% 25%","chart-1":"210 50% 50%","chart-2":"260 50% 55%","chart-3":"150 50% 45%","chart-4":"325 50% 55%","chart-5":"45 80% 55%",radius:"0.625rem","font-body":'Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif',"font-heading":'"Plus Jakarta Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif'},np=e=>{if(/^\d+\s+\d+(?:\.\d+)?%\s+\d+(?:\.\d+)?%$/.test(e.trim()))return e.trim();try{const t=(e=>{const t=document.createElement("div");t.style.color=e,document.body.appendChild(t);const n=window.getComputedStyle(t).color;return document.body.removeChild(t),n})(e),[n,r,o]=(e=>{const t=e.match(/\d+/g);if(!t||t.length<3)throw new Error(`Invalid RGB color format: ${e}`);return[parseInt(t[0],10),parseInt(t[1],10),parseInt(t[2],10)]})(t);return((e,t,n)=>{e/=255,t/=255,n/=255;const r=Math.max(e,t,n),o=Math.min(e,t,n);let i=0,a=0;const s=(r+o)/2;if(r!==o){const l=r-o;switch(a=s>.5?l/(2-r-o):l/(r+o),r){case e:i=(t-n)/l+(t<n?6:0);break;case t:i=(n-e)/l+2;break;case n:i=(e-t)/l+4}i*=60}return`${Math.round(i)} ${Math.round(100*a)}% ${Math.round(100*s)}%`})(n,r,o)}catch(t){return e}},rp=e=>{const t=document.getElementById("reach-theme-styles");t&&t.remove();const n=document.createElement("style");n.id="reach-theme-styles";const r=`\n [data-reach-root] {\n ${Object.entries(tp).map((([t,n])=>{const r=e[t];let o=n;if(void 0!==r)if("radius"===t||"font-body"===t||"font-heading"===t)o=r;else if((e=>{if(/^\d+\s+\d+(?:\.\d+)?%\s+\d+(?:\.\d+)?%$/.test(e.trim()))return!0;if(["bg-","text-","border-","ring-","accent-","fill-","stroke-"].some((t=>e.trim().startsWith(t))))return!0;const t=document.createElement("div"),n=t.style.color;return t.style.color=e,t.style.color!==n})(r)){if(/^bg-/.test(r.trim())){const e=document.querySelector("[data-reach-root]");e&&e.classList.add(r.trim()),o=n}else try{o=np(r)}catch(i){}}return`--reach-${t}: ${o};`})).join("\n")}\n }\n\n /* Apply font families directly */\n [data-reach-root] {\n font-family: var(--reach-font-body);\n }\n \n [data-reach-root] h1,\n [data-reach-root] h2,\n [data-reach-root] h3,\n [data-reach-root] h4,\n [data-reach-root] h5,\n [data-reach-root] h6 {\n font-family: var(--reach-font-heading);\n }\n `;n.textContent=r,document.head.appendChild(n)},{Context:op,Provider:ip}=Zd(((e,t)=>{switch(t.type){case"set_theme":return{...e,loading:!1,error:null,theme:t.payload};case"set_loading":return{...e,loading:t.payload};case"set_error":return{...e,loading:!1,error:t.payload};default:return e}}),{setTheme:e=>t=>e({type:"set_theme",payload:t}),setLoading:e=>t=>e({type:"set_loading",payload:t}),setError:e=>t=>e({type:"set_error",payload:t})},{theme:null,loading:!0,error:null}),ap=({initialTheme:e,children:r})=>{const{setTheme:o,setLoading:i}=n.useContext(op),a=n.useRef(!1);return n.useEffect((()=>{e&&!a.current?(rp(e.styles),o(e),a.current=!0):i(!1)}),[e,o,i]),t.jsx(t.Fragment,{children:r})},sp=({initialTheme:e,children:n})=>t.jsx(ip,{children:t.jsx(ap,{initialTheme:e,children:n})}),lp=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,cp={"&":"&","&":"&","<":"<","<":"<",">":">",">":">","'":"'","'":"'",""":'"',""":'"'," ":" "," ":" ","©":"©","©":"©","®":"®","®":"®","…":"…","…":"…","/":"/","/":"/"},up=e=>cp[e];let dp={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:e=>e.replace(lp,up)};const pp={type:"3rdParty",init(e){((e={})=>{dp={...dp,...e}})(e.options.react)}},fp=n.createContext();function hp({i18n:e,defaultNS:t,children:r}){const o=n.useMemo((()=>({i18n:e,defaultNS:t})),[e,t]);return n.createElement(fp.Provider,{value:o},r)}const mp=e=>"string"==typeof e,gp=()=>{let e,t;const n=new Promise(((n,r)=>{e=n,t=r}));return n.resolve=e,n.reject=t,n},yp=e=>null==e?"":""+e,vp=/###/g,bp=e=>e&&e.indexOf("###")>-1?e.replace(vp,"."):e,wp=e=>!e||mp(e),xp=(e,t,n)=>{const r=mp(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(wp(e))return{};const t=bp(r[o]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return wp(e)?{}:{obj:e,k:bp(r[o])}},Ep=(e,t,n)=>{const{obj:r,k:o}=xp(e,t,Object);if(void 0!==r||1===t.length)return void(r[o]=n);let i=t[t.length-1],a=t.slice(0,t.length-1),s=xp(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=xp(e,a,Object),s?.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=n},_p=(e,t)=>{const{obj:n,k:r}=xp(e,t);if(n&&Object.prototype.hasOwnProperty.call(n,r))return n[r]},Sp=(e,t,n)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?mp(e[r])||e[r]instanceof String||mp(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):Sp(e[r],t[r],n):e[r]=t[r]);return e},Tp=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var Cp={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const Ap=e=>mp(e)?e.replace(/[&<>"'\/]/g,(e=>Cp[e])):e;const Op=[" ",",","?","!",";"],Np=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}(20),Rp=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(!e)return;if(e[t]){if(!Object.prototype.hasOwnProperty.call(e,t))return;return e[t]}const r=t.split(n);let o=e;for(let i=0;i<r.length;){if(!o||"object"!=typeof o)return;let e,t="";for(let a=i;a<r.length;++a)if(a!==i&&(t+=n),t+=r[a],e=o[t],void 0!==e){if(["string","number","boolean"].indexOf(typeof e)>-1&&a<r.length-1)continue;i+=a-i+1;break}o=e}return o},Pp=e=>e?.replace("_","-"),kp={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){}};class Lp{constructor(e){this.init(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{})}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||kp,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}warn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}error(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}deprecate(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,r){return r&&!this.debug?null:(mp(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new Lp(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new Lp(this.logger,e)}}var Mp=new Lp;class Dp{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach((e=>{this.observers[e]||(this.observers[e]=new Map);const n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)})),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(this.observers[e]){Array.from(this.observers[e].entries()).forEach((e=>{let[t,r]=e;for(let o=0;o<r;o++)t(...n)}))}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach((t=>{let[r,o]=t;for(let i=0;i<o;i++)r.apply(r,[e,...n])}))}}}class jp extends Dp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):mp(n)&&o?a.push(...n.split(o)):a.push(n)));const s=_p(this.data,a);return!s&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),!s&&i&&mp(n)?Rp(this.data?.[e]?.[t],n,o):s}addResource(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1};const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),Ep(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}addResources(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(const o in n)(mp(n[o])||Array.isArray(n[o]))&&this.addResource(e,t,o,n[o],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1,skipCopy:!1},a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let s=_p(this.data,a)||{};i.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?Sp(s,n,o):s={...s,...n},Ep(this.data,a,s),i.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find((e=>t[e]&&Object.keys(t[e]).length>0))}toJSON(){return this.data}}var Ip={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,o){return e.forEach((e=>{t=this.processors[e]?.process(t,n,r,o)??t})),t}};const Fp={};class Up extends Dp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};var n,r;super(),n=e,r=this,["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"].forEach((e=>{n[e]&&(r[e]=n[e])})),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=Mp.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){if(null==e)return!1;const t=this.resolve(e,arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}});return void 0!==t?.res}extractFromKey(e,t){let n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");const r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,n)=>{t=t||"",n=n||"";const r=Op.filter((e=>t.indexOf(e)<0&&n.indexOf(e)<0));if(0===r.length)return!0;const o=Np.getRegExp(`(${r.map((e=>"?"===e?"\\?":e)).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(n);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,n,r));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:mp(o)?[o]:o};const i=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(r)}return{key:e,namespaces:mp(o)?[o]:o}}translate(e,t,n){if("object"!=typeof t&&this.options.overloadTranslationOptionHandler&&(t=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof t&&(t={...t}),t||(t={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);const r=void 0!==t.returnDetails?t.returnDetails:this.options.returnDetails,o=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,{key:i,namespaces:a}=this.extractFromKey(e[e.length-1],t),s=a[a.length-1],l=t.lng||this.language,c=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if("cimode"===l?.toLowerCase()){if(c){const e=t.nsSeparator||this.options.nsSeparator;return r?{res:`${s}${e}${i}`,usedKey:i,exactUsedKey:i,usedLng:l,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:`${s}${e}${i}`}return r?{res:i,usedKey:i,exactUsedKey:i,usedLng:l,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:i}const u=this.resolve(e,t);let d=u?.res;const p=u?.usedKey||i,f=u?.exactUsedKey||i,h=Object.prototype.toString.apply(d),m=void 0!==t.joinArrays?t.joinArrays:this.options.joinArrays,g=!this.i18nFormat||this.i18nFormat.handleAsObject,y=!mp(d)&&"boolean"!=typeof d&&"number"!=typeof d;if(!(g&&d&&y&&["[object Number]","[object Function]","[object RegExp]"].indexOf(h)<0)||mp(m)&&Array.isArray(d))if(g&&mp(m)&&Array.isArray(d))d=d.join(m),d&&(d=this.extendTranslation(d,e,t,n));else{let r=!1,a=!1;const c=void 0!==t.count&&!mp(t.count),p=Up.hasDefaultValue(t),f=c?this.pluralResolver.getSuffix(l,t.count,t):"",h=t.ordinal&&c?this.pluralResolver.getSuffix(l,t.count,{ordinal:!1}):"",m=c&&!t.ordinal&&0===t.count,g=m&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${f}`]||t[`defaultValue${h}`]||t.defaultValue;!this.isValidLookup(d)&&p&&(r=!0,d=g),this.isValidLookup(d)||(a=!0,d=i);const y=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&a?void 0:d,v=p&&g!==d&&this.options.updateMissing;if(a||r||v){if(this.logger.log(v?"updateKey":"missingKey",l,s,i,v?g:d),o){const e=this.resolve(i,{...t,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const n=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if("fallback"===this.options.saveMissingTo&&n&&n[0])for(let t=0;t<n.length;t++)e.push(n[t]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(t.lng||this.language):e.push(t.lng||this.language);const r=(e,n,r)=>{const o=p&&r!==d?r:y;this.options.missingKeyHandler?this.options.missingKeyHandler(e,s,n,o,v,t):this.backendConnector?.saveMissing&&this.backendConnector.saveMissing(e,s,n,o,v,t),this.emit("missingKey",e,s,n,d)};this.options.saveMissing&&(this.options.saveMissingPlurals&&c?e.forEach((e=>{const n=this.pluralResolver.getSuffixes(e,t);m&&t[`defaultValue${this.options.pluralSeparator}zero`]&&n.indexOf(`${this.options.pluralSeparator}zero`)<0&&n.push(`${this.options.pluralSeparator}zero`),n.forEach((n=>{r([e],i+n,t[`defaultValue${n}`]||g)}))})):r(e,i,g))}d=this.extendTranslation(d,e,t,u,n),a&&d===i&&this.options.appendNamespaceToMissingKey&&(d=`${s}:${i}`),(a||r)&&this.options.parseMissingKeyHandler&&(d=this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${s}:${i}`:i,r?d:void 0))}else{if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(p,d,{...t,ns:a}):`key '${i} (${this.language})' returned an object instead of string.`;return r?(u.res=e,u.usedParams=this.getUsedParamsDetails(t),u):e}if(o){const e=Array.isArray(d),n=e?[]:{},r=e?f:p;for(const i in d)if(Object.prototype.hasOwnProperty.call(d,i)){const e=`${r}${o}${i}`;n[i]=this.translate(e,{...t,joinArrays:!1,ns:a}),n[i]===e&&(n[i]=d[i])}d=n}}return r?(u.res=d,u.usedParams=this.getUsedParamsDetails(t),u):d}extendTranslation(e,t,n,r,o){var i=this;if(this.i18nFormat?.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const a=mp(e)&&(void 0!==n?.interpolation?.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let s;if(a){const t=e.match(this.interpolator.nestingRegexp);s=t&&t.length}let l=n.replace&&!mp(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(l={...this.options.interpolation.defaultVariables,...l}),e=this.interpolator.interpolate(e,l,n.lng||this.language||r.usedLng,n),a){const t=e.match(this.interpolator.nestingRegexp);s<(t&&t.length)&&(n.nest=!1)}!n.lng&&r&&r.res&&(n.lng=this.language||r.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,(function(){for(var e=arguments.length,r=new Array(e),a=0;a<e;a++)r[a]=arguments[a];return o?.[0]!==r[0]||n.context?i.translate(...r,t):(i.logger.warn(`It seems you are nesting recursively key: ${r[0]} in key: ${t[0]}`),null)}),n)),n.interpolation&&this.interpolator.reset()}const a=n.postProcess||this.options.postProcess,s=mp(a)?[a]:a;return null!=e&&s?.length&&!1!==n.applyPostProcessor&&(e=Ip.handle(s,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e){let t,n,r,o,i,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return mp(e)&&(e=[e]),e.forEach((e=>{if(this.isValidLookup(t))return;const s=this.extractFromKey(e,a),l=s.key;n=l;let c=s.namespaces;this.options.fallbackNS&&(c=c.concat(this.options.fallbackNS));const u=void 0!==a.count&&!mp(a.count),d=u&&!a.ordinal&&0===a.count,p=void 0!==a.context&&(mp(a.context)||"number"==typeof a.context)&&""!==a.context,f=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);c.forEach((e=>{this.isValidLookup(t)||(i=e,Fp[`${f[0]}-${e}`]||!this.utils?.hasLoadedNamespace||this.utils?.hasLoadedNamespace(i)||(Fp[`${f[0]}-${e}`]=!0,this.logger.warn(`key "${n}" for languages "${f.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach((n=>{if(this.isValidLookup(t))return;o=n;const i=[l];if(this.i18nFormat?.addLookupKeys)this.i18nFormat.addLookupKeys(i,l,n,e,a);else{let e;u&&(e=this.pluralResolver.getSuffix(n,a.count,a));const t=`${this.options.pluralSeparator}zero`,r=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(u&&(i.push(l+e),a.ordinal&&0===e.indexOf(r)&&i.push(l+e.replace(r,this.options.pluralSeparator)),d&&i.push(l+t)),p){const n=`${l}${this.options.contextSeparator}${a.context}`;i.push(n),u&&(i.push(n+e),a.ordinal&&0===e.indexOf(r)&&i.push(n+e.replace(r,this.options.pluralSeparator)),d&&i.push(n+t))}}let s;for(;s=i.pop();)this.isValidLookup(t)||(r=s,t=this.getResource(n,e,s,a))})))}))})),{res:t,usedKey:n,exactUsedKey:r,usedLng:o,usedNS:i}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat?.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!mp(e.replace);let r=n?e.replace:e;if(n&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(const e of t)delete r[e]}return r}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}class $p{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Mp.create("languageUtils")}getScriptPartFromCode(e){if(!(e=Pp(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=Pp(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(mp(e)&&e.indexOf("-")>-1){let n;try{n=Intl.getCanonicalLocales(e)[0]}catch(t){}return n&&this.options.lowerCaseLng&&(n=n.toLowerCase()),n||(this.options.lowerCaseLng?e.toLowerCase():e)}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach((e=>{if(t)return;const n=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(n)||(t=n)})),!t&&this.options.supportedLngs&&e.forEach((e=>{if(t)return;const n=this.getLanguagePartFromCode(e);if(this.isSupportedCode(n))return t=n;t=this.options.supportedLngs.find((e=>e===n?e:e.indexOf("-")<0&&n.indexOf("-")<0?void 0:e.indexOf("-")>0&&n.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===n||0===e.indexOf(n)&&n.length>1?e:void 0))})),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),mp(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){const n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],o=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return mp(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):mp(e)&&o(this.formatLanguageCode(e)),n.forEach((e=>{r.indexOf(e)<0&&o(this.formatLanguageCode(e))})),r}}const Bp={zero:0,one:1,two:2,few:3,many:4,other:5},Vp={select:e=>1===e?"one":"other",resolvedOptions:()=>({pluralCategories:["one","other"]})};class qp{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=Mp.create("pluralResolver"),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=Pp("dev"===e?"en":e),r=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:n,type:r});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(n,{type:r})}catch(a){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),Vp;if(!e.match(/-|_/))return Vp;const n=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(n,t)}return this.pluralRulesCache[o]=i,i}needsPlural(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?.resolvedOptions().pluralCategories.length>1}getPluralFormsOfKey(e,t){return this.getSuffixes(e,arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}).map((e=>`${t}${e}`))}getSuffixes(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.getRule(e,t);return n||(n=this.getRule("dev",t)),n?n.resolvedOptions().pluralCategories.sort(((e,t)=>Bp[e]-Bp[t])).map((e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`)):[]}getSuffix(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=this.getRule(e,n);return r?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:(this.logger.warn(`no plural rule found for: ${e}`),this.getSuffix("dev",t,n))}}const zp=function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],i=((e,t,n)=>{const r=_p(e,n);return void 0!==r?r:_p(t,n)})(e,t,n);return!i&&o&&mp(n)&&(i=Rp(e,n,r),void 0===i&&(i=Rp(t,n,r))),i},Hp=e=>e.replace(/\$/g,"$$$$");class Gp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=Mp.create("interpolator"),this.options=e,this.format=e?.interpolation?.format||(e=>e),this.init(e)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:l,unescapeSuffix:c,unescapePrefix:u,nestingPrefix:d,nestingPrefixEscaped:p,nestingSuffix:f,nestingSuffixEscaped:h,nestingOptionsSeparator:m,maxReplaces:g,alwaysFormat:y}=e.interpolation;this.escape=void 0!==t?t:Ap,this.escapeValue=void 0===n||n,this.useRawValueToEscape=void 0!==r&&r,this.prefix=o?Tp(o):i||"{{",this.suffix=a?Tp(a):s||"}}",this.formatSeparator=l||",",this.unescapePrefix=c?"":u||"-",this.unescapeSuffix=this.unescapePrefix?"":c||"",this.nestingPrefix=d?Tp(d):p||Tp("$t("),this.nestingSuffix=f?Tp(f):h||Tp(")"),this.nestingOptionsSeparator=m||",",this.maxReplaces=g||1e3,this.alwaysFormat=void 0!==y&&y,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e?.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},l=e=>{if(e.indexOf(this.formatSeparator)<0){const o=zp(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,n,{...r,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(zp(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,n,{...r,...t,interpolationkey:i})};this.resetRegExp();const c=r?.missingInterpolationHandler||this.options.missingInterpolationHandler,u=void 0!==r?.interpolation?.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:e=>Hp(e)},{regex:this.regexp,safeValue:e=>Hp(this.escapeValue?this.escape(e):e)}].forEach((t=>{for(a=0;o=t.regex.exec(e);){const n=o[1].trim();if(i=l(n),void 0===i)if("function"==typeof c){const t=c(e,o,r);i=mp(t)?t:""}else if(r&&Object.prototype.hasOwnProperty.call(r,n))i="";else{if(u){i=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),i=""}else mp(i)||this.useRawValueToEscape||(i=yp(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),u?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}})),e}nest(e,t){let n,r,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const a=(e,t)=>{const n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;const r=e.split(new RegExp(`${n}[ ]*{`));let i=`{${r[1]}`;e=r[0],i=this.interpolate(i,o);const a=i.match(/'/g),s=i.match(/"/g);((a?.length??0)%2==0&&!s||s.length%2!=0)&&(i=i.replace(/'/g,'"'));try{o=JSON.parse(i),t&&(o={...t,...o})}catch(l){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,l),`${e}${n}${i}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,e};for(;n=this.nestingRegexp.exec(e);){let s=[];o={...i},o=o.replace&&!mp(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let l=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){const e=n[1].split(this.formatSeparator).map((e=>e.trim()));n[1]=e.shift(),s=e,l=!0}if(r=t(a.call(this,n[1].trim(),o),o),r&&n[0]===e&&!mp(r))return r;mp(r)||(r=yp(r)),r||(this.logger.warn(`missed to resolve ${n[1]} for nesting ${e}`),r=""),l&&(r=s.reduce(((e,t)=>this.format(e,t,i.lng,{...i,interpolationkey:n[1].trim()})),r.trim())),e=e.replace(n[0],r),this.regexp.lastIndex=0}return e}}const Kp=e=>{const t={};return(n,r,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=r+JSON.stringify(i);let s=t[a];return s||(s=e(Pp(r),o),t[a]=s),s(n)}};class Wp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=Mp.create("formatter"),this.options=e,this.formats={number:Kp(((e,t)=>{const n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)})),currency:Kp(((e,t)=>{const n=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>n.format(e)})),datetime:Kp(((e,t)=>{const n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)})),relativetime:Kp(((e,t)=>{const n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||"day")})),list:Kp(((e,t)=>{const n=new Intl.ListFormat(e,{...t});return e=>n.format(e)}))},this.init(e)}init(e){this.formatSeparator=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}}).interpolation.formatSeparator||","}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=Kp(t)}format(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find((e=>e.indexOf(")")>-1))){const e=o.findIndex((e=>e.indexOf(")")>-1));o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}return o.reduce(((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach((e=>{if(e){const[t,...r]=e.split(":"),o=r.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();n[i]||(n[i]=o),"false"===o&&(n[i]=!1),"true"===o&&(n[i]=!0),isNaN(o)||(n[i]=parseInt(o,10))}}))}return{formatName:t,formatOptions:n}})(t);if(this.formats[o]){let t=e;try{const a=r?.formatParams?.[r.interpolationkey]||{};t=this.formats[o](e,a.locale||a.lng||r.locale||r.lng||n,{...i,...r,...a})}catch(a){this.logger.warn(a)}return t}return this.logger.warn(`there was no format function for ${o}`),e}),e)}}class Yp extends Dp{constructor(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=Mp.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend?.init?.(n,r.backend,r)}queueLoad(e,t,n,r){const o={},i={},a={},s={};return e.forEach((e=>{let r=!0;t.forEach((t=>{const a=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,r=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))})),r||(a[e]=!0)})),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){const r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),!t&&n&&this.store.addResourceBundle(o,i,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);const a={};this.queue.forEach((n=>{((e,t,n)=>{const{obj:r,k:o}=xp(e,t,Object);r[o]=r[o]||[],r[o].push(n)})(n.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach((e=>{a[e]||(a[e]={});const t=n.loaded[e];t.length&&t.forEach((t=>{void 0===a[e][t]&&(a[e][t]=!0)}))})),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())})),this.emit("loaded",a),this.queue=this.queue.filter((e=>!e.done))}read(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,i=arguments.length>5?arguments[5]:void 0;if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&r<this.maxRetries?setTimeout((()=>{this.read.call(this,e,t,n,r+1,2*o,i)}),o):i(a,s)},s=this.backend[n].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const n=s(e,t);n&&"function"==typeof n.then?n.then((e=>a(null,e))).catch(a):a(null,n)}catch(l){a(l)}}prepareLoading(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();mp(e)&&(e=this.languageUtils.toResolveHierarchy(e)),mp(t)&&(t=[t]);const o=this.queueLoad(e,t,n,r);if(!o.toLoad.length)return o.pending.length||r(),null;o.toLoad.forEach((e=>{this.loadOne(e)}))}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=e.split("|"),r=n[0],o=n[1];this.read(r,o,"read",void 0,void 0,((n,i)=>{n&&this.logger.warn(`${t}loading namespace ${o} for language ${r} failed`,n),!n&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${r}`,i),this.loaded(e,n,i)}))}saveMissing(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:()=>{};if(!this.services?.utils?.hasLoadedNamespace||this.services?.utils?.hasLoadedNamespace(t)){if(null!=n&&""!==n){if(this.backend?.create){const l={...i,isUpdate:o},c=this.backend.create.bind(this.backend);if(c.length<6)try{let o;o=5===c.length?c(e,t,n,r,l):c(e,t,n,r),o&&"function"==typeof o.then?o.then((e=>a(null,e))).catch(a):a(null,o)}catch(s){a(s)}else c(e,t,n,r,a,l)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}else this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")}}const Xp=()=>({debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),mp(e[1])&&(t.defaultValue=e[1]),mp(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const n=e[3]||e[2];Object.keys(n).forEach((e=>{t[e]=n[e]}))}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),Qp=e=>(mp(e.ns)&&(e.ns=[e.ns]),mp(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),mp(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs?.indexOf?.("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),"boolean"==typeof e.initImmediate&&(e.initAsync=e.initImmediate),e),Zp=()=>{};class Jp extends Dp{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;var n;if(super(),this.options=Qp(e),this.services={},this.logger=Mp,this.modules={external:[]},n=this,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach((e=>{"function"==typeof n[e]&&(n[e]=n[e].bind(n))})),t&&!this.isInitialized&&!e.isClone){if(!this.options.initAsync)return this.init(e,t),this;setTimeout((()=>{this.init(e,t)}),0)}}init(){var e=this;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,"function"==typeof t&&(n=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&(mp(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=Xp();this.options={...r,...this.options,...Qp(t)},this.options.interpolation={...r.interpolation,...this.options.interpolation},void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator);const o=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let t;Mp.init(this.modules.logger?o(this.modules.logger):null,this.options),t=this.modules.formatter?this.modules.formatter:Wp;const n=new $p(this.options);this.store=new jp(this.options.resources,this.options);const i=this.services;i.logger=Mp,i.resourceStore=this.store,i.languageUtils=n,i.pluralResolver=new qp(n,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!t||this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format||(i.formatter=o(t),i.formatter.init(i,this.options),this.options.interpolation.format=i.formatter.format.bind(i.formatter)),i.interpolator=new Gp(this.options),i.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},i.backendConnector=new Yp(o(this.modules.backend),i.resourceStore,i,this.options),i.backendConnector.on("*",(function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)})),this.modules.languageDetector&&(i.languageDetector=o(this.modules.languageDetector),i.languageDetector.init&&i.languageDetector.init(i,this.options.detection,this.options)),this.modules.i18nFormat&&(i.i18nFormat=o(this.modules.i18nFormat),i.i18nFormat.init&&i.i18nFormat.init(this)),this.translator=new Up(this.services,this.options),this.translator.on("*",(function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)})),this.modules.external.forEach((e=>{e.init&&e.init(this)}))}if(this.format=this.options.interpolation.format,n||(n=Zp),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach((t=>{this[t]=function(){return e.store[t](...arguments)}}));["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach((t=>{this[t]=function(){return e.store[t](...arguments),e}}));const i=gp(),a=()=>{const e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),n(e,t)};if(this.languages&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initAsync?a():setTimeout(a,0),i}loadResources(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Zp;const n=mp(e)?e:this.language;if("function"==typeof e&&(t=e),!this.options.resources||this.options.partialBundledLanguages){if("cimode"===n?.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return t();const e=[],r=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach((t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)}))};if(n)r(n);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach((e=>r(e)))}this.options.preload?.forEach?.((e=>r(e))),this.services.backendConnector.load(e,this.options.ns,(e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),t(e)}))}else t(null)}reloadResources(e,t,n){const r=gp();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=Zp),this.services.backendConnector.reload(e,t,(e=>{r.resolve(),n(e)})),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&Ip.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(let t=0;t<this.languages.length;t++){const e=this.languages[t];if(!(["cimode","dev"].indexOf(e)>-1)&&this.store.hasLanguageSomeTranslations(e)){this.resolvedLanguage=e;break}}}changeLanguage(e,t){var n=this;this.isLanguageChangingTo=e;const r=gp();this.emit("languageChanging",e);const o=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(e,i)=>{i?(o(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,r.resolve((function(){return n.t(...arguments)})),t&&t(e,(function(){return n.t(...arguments)}))},a=t=>{e||t||!this.services.languageDetector||(t=[]);const n=mp(t)?t:this.services.languageUtils.getBestMatchFromCodes(t);n&&(this.language||o(n),this.translator.language||this.translator.changeLanguage(n),this.services.languageDetector?.cacheUserLanguage?.(n)),this.loadResources(n,(e=>{i(e,n)}))};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),r}getFixedT(e,t,n){var r=this;const o=function(e,t){let i;if("object"!=typeof t){for(var a=arguments.length,s=new Array(a>2?a-2:0),l=2;l<a;l++)s[l-2]=arguments[l];i=r.options.overloadTranslationOptionHandler([e,t].concat(s))}else i={...t};i.lng=i.lng||o.lng,i.lngs=i.lngs||o.lngs,i.ns=i.ns||o.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||n||o.keyPrefix);const c=r.options.keySeparator||".";let u;return u=i.keyPrefix&&Array.isArray(e)?e.map((e=>`${i.keyPrefix}${c}${e}`)):i.keyPrefix?`${i.keyPrefix}${c}${e}`:e,r.t(u,i)};return mp(e)?o.lng=e:o.lngs=e,o.ns=t,o.keyPrefix=n,o}t(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.translator?.translate(...t)}exists(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.translator?.exists(...t)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;const i=(e,t)=>{const n=this.services.backendConnector.state[`${e}|${t}`];return-1===n||0===n||2===n};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(n,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(n,e)||r&&!i(o,e)))}loadNamespaces(e,t){const n=gp();return this.options.ns?(mp(e)&&(e=[e]),e.forEach((e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)})),this.loadResources((e=>{n.resolve(),t&&t(e)})),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=gp();mp(e)&&(e=[e]);const r=this.options.preload||[],o=e.filter((e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e)));return o.length?(this.options.preload=r.concat(o),this.loadResources((e=>{n.resolve(),t&&t(e)})),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages?.length>0?this.languages[0]:this.language)),!e)return"rtl";const t=this.services?.languageUtils||new $p(Xp());return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){return new Jp(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)}cloneInstance(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Zp;const n=e.forkResourceStore;n&&delete e.forkResourceStore;const r={...this.options,...e,isClone:!0},o=new Jp(r);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));if(["store","services","language"].forEach((e=>{o[e]=this[e]})),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},n){const e=Object.keys(this.store.data).reduce(((e,t)=>(e[t]={...this.store.data[t]},Object.keys(e[t]).reduce(((n,r)=>(n[r]={...e[t][r]},n)),{}))),{});o.store=new jp(e,r),o.services.resourceStore=o.store}return o.translator=new Up(o.services,r),o.translator.on("*",(function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];o.emit(e,...n)})),o.init(r,t),o.translator.options=r,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const ef=Jp.createInstance();ef.createInstance=Jp.createInstance;const tf=ef.t,{slice:nf,forEach:rf}=[];const of=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/,af={create(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{path:"/",sameSite:"strict"};n&&(o.expires=new Date,o.expires.setTime(o.expires.getTime()+60*n*1e3)),r&&(o.domain=r),document.cookie=function(e,t){const n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{path:"/"};let r=`${e}=${encodeURIComponent(t)}`;if(n.maxAge>0){const e=n.maxAge-0;if(Number.isNaN(e))throw new Error("maxAge should be a Number");r+=`; Max-Age=${Math.floor(e)}`}if(n.domain){if(!of.test(n.domain))throw new TypeError("option domain is invalid");r+=`; Domain=${n.domain}`}if(n.path){if(!of.test(n.path))throw new TypeError("option path is invalid");r+=`; Path=${n.path}`}if(n.expires){if("function"!=typeof n.expires.toUTCString)throw new TypeError("option expires is invalid");r+=`; Expires=${n.expires.toUTCString()}`}if(n.httpOnly&&(r+="; HttpOnly"),n.secure&&(r+="; Secure"),n.sameSite)switch("string"==typeof n.sameSite?n.sameSite.toLowerCase():n.sameSite){case!0:r+="; SameSite=Strict";break;case"lax":r+="; SameSite=Lax";break;case"strict":r+="; SameSite=Strict";break;case"none":r+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return r}(e,encodeURIComponent(t),o)},read(e){const t=`${e}=`,n=document.cookie.split(";");for(let r=0;r<n.length;r++){let e=n[r];for(;" "===e.charAt(0);)e=e.substring(1,e.length);if(0===e.indexOf(t))return e.substring(t.length,e.length)}return null},remove(e){this.create(e,"",-1)}};var sf={name:"cookie",lookup(e){let{lookupCookie:t}=e;if(t&&"undefined"!=typeof document)return af.read(t)||void 0},cacheUserLanguage(e,t){let{lookupCookie:n,cookieMinutes:r,cookieDomain:o,cookieOptions:i}=t;n&&"undefined"!=typeof document&&af.create(n,e,r,o,i)}},lf={name:"querystring",lookup(e){let t,{lookupQuerystring:n}=e;if("undefined"!=typeof window){let{search:e}=window.location;!window.location.search&&window.location.hash?.indexOf("?")>-1&&(e=window.location.hash.substring(window.location.hash.indexOf("?")));const r=e.substring(1).split("&");for(let o=0;o<r.length;o++){const e=r[o].indexOf("=");if(e>0){r[o].substring(0,e)===n&&(t=r[o].substring(e+1))}}}return t}};let cf=null;const uf=()=>{if(null!==cf)return cf;try{cf="undefined"!==window&&null!==window.localStorage;const e="i18next.translate.boo";window.localStorage.setItem(e,"foo"),window.localStorage.removeItem(e)}catch(e){cf=!1}return cf};var df={name:"localStorage",lookup(e){let{lookupLocalStorage:t}=e;if(t&&uf())return window.localStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupLocalStorage:n}=t;n&&uf()&&window.localStorage.setItem(n,e)}};let pf=null;const ff=()=>{if(null!==pf)return pf;try{pf="undefined"!==window&&null!==window.sessionStorage;const e="i18next.translate.boo";window.sessionStorage.setItem(e,"foo"),window.sessionStorage.removeItem(e)}catch(e){pf=!1}return pf};var hf={name:"sessionStorage",lookup(e){let{lookupSessionStorage:t}=e;if(t&&ff())return window.sessionStorage.getItem(t)||void 0},cacheUserLanguage(e,t){let{lookupSessionStorage:n}=t;n&&ff()&&window.sessionStorage.setItem(n,e)}},mf={name:"navigator",lookup(e){const t=[];if("undefined"!=typeof navigator){const{languages:e,userLanguage:n,language:r}=navigator;if(e)for(let o=0;o<e.length;o++)t.push(e[o]);n&&t.push(n),r&&t.push(r)}return t.length>0?t:void 0}},gf={name:"htmlTag",lookup(e){let t,{htmlTag:n}=e;const r=n||("undefined"!=typeof document?document.documentElement:null);return r&&"function"==typeof r.getAttribute&&(t=r.getAttribute("lang")),t}},yf={name:"path",lookup(e){let{lookupFromPathIndex:t}=e;if("undefined"==typeof window)return;const n=window.location.pathname.match(/\/([a-zA-Z-]*)/g);if(!Array.isArray(n))return;const r="number"==typeof t?t:0;return n[r]?.replace("/","")}},vf={name:"subdomain",lookup(e){let{lookupFromSubdomainIndex:t}=e;const n="number"==typeof t?t+1:1,r="undefined"!=typeof window&&window.location?.hostname?.match(/^(\w{2,5})\.(([a-z0-9-]{1,63}\.[a-z]{2,6})|localhost)/i);if(r)return r[n]}};let bf=!1;try{document,bf=!0}catch(tme){}const wf=["querystring","cookie","localStorage","sessionStorage","navigator","htmlTag"];bf||wf.splice(1,1);class xf{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.type="languageDetector",this.detectors={},this.init(e,t)}init(){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.services=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{languageUtils:{}},this.options=function(e){return rf.call(nf.call(arguments,1),(t=>{if(t)for(const n in t)void 0===e[n]&&(e[n]=t[n])})),e}(e,this.options||{},{order:wf,lookupQuerystring:"lng",lookupCookie:"i18next",lookupLocalStorage:"i18nextLng",lookupSessionStorage:"i18nextLng",caches:["localStorage"],excludeCacheFor:["cimode"],convertDetectedLanguage:e=>e}),"string"==typeof this.options.convertDetectedLanguage&&this.options.convertDetectedLanguage.indexOf("15897")>-1&&(this.options.convertDetectedLanguage=e=>e.replace("-","_")),this.options.lookupFromUrlIndex&&(this.options.lookupFromPathIndex=this.options.lookupFromUrlIndex),this.i18nOptions=t,this.addDetector(sf),this.addDetector(lf),this.addDetector(df),this.addDetector(hf),this.addDetector(mf),this.addDetector(gf),this.addDetector(yf),this.addDetector(vf)}addDetector(e){return this.detectors[e.name]=e,this}detect(){let e=[];return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.order).forEach((t=>{if(this.detectors[t]){let n=this.detectors[t].lookup(this.options);n&&"string"==typeof n&&(n=[n]),n&&(e=e.concat(n))}})),e=e.map((e=>this.options.convertDetectedLanguage(e))),this.services&&this.services.languageUtils&&this.services.languageUtils.getBestMatchFromCodes?e:e.length>0?e[0]:null}cacheUserLanguage(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.options.caches;t&&(this.options.excludeCacheFor&&this.options.excludeCacheFor.indexOf(e)>-1||t.forEach((t=>{this.detectors[t]&&this.detectors[t].cacheUserLanguage(e,this.options)})))}}xf.type="languageDetector";const Ef={en:{common:{ad_spend:"Ad Spend",date:"Date",close:"Close",continue:"Continue",connected:"Connected",connecting:"Connecting...",reauthenticate:"Reauthenticate",account_settings:"Account Settings",manage_account_settings:"Manage your account settings",copy:"Copy",copied:"Copied",error:"An error occurred",filter:"Filter",finishingUp:"Finishing up...",loading:"Loading...",need_help:"Need help? let us know",next:"Next",next_steps:"Next steps:",number:"{{number}}",previous:"Previous",revenue:"Revenue",revenue_from_ads:"Revenue From Ads",roas:"ROAS",return_on_ad_spend:"Return on Ad Spend",select_dates:"Select dates",total_ads_spend:"Total Ads Spend",measure:{dashboard:{title:"Marketing ROI Dashboard",subtitle:"Track and analyze how your marketing efforts are driving sales",application_status_banner_title:"We are experiencing some issues",application_status_banner_description:"We are aware of an issue affecting the dashboard. We are working on it and will have it resolved soon.",no_metrics_banner_title:"We are unable to display any metrics for this date range",no_metrics_banner_description:"If you have just connected your ad accounts, your metrics should begin populating within the next 24 hours. Please check back soon.",reach_managed_campaign_banner:"Your ads are being managed by Reach. We’ll automatically optimize them to drive the best results."}},authentication:{required:"Authentication required",failed:"Authentication failed",connect_account_title:"Connect Your {{provider}} Account",connect_account_description:"To create and manage ad campaigns, please connect your {{provider}} account",connect_account_button:"Continue with {{provider}}",connect_account_TOS:"By connecting, you agree to our Terms of Service and Privacy Policy"},theme:{loading:"Loading theme...",error:"Error loading theme: {{message}}"},dates:{last_week:"Last week",last_month:"Last month",last_quarter:"Last quarter",last_year:"Last year"},campaigns:{setup:{card_header:"Run paid digital ads to get new leads & customers",title:"Create your first AI-driven Ad campaign in 4 simple clicks",description:"Welcome to the future of advertising! Our AI-powered campaign builder helps you effortlessly design and manage ads that reach your target audience with precision. Get started now to unlock the potential of automated, data-driven advertising.",button:"Set up paid ads",next_steps_description:"Already running ads? Track Your Marketing Results with a few clicks.",link_to_analytics:"Connect your existing accounts to get instant insights into your marketing performance."},how_it_works:{dialog_title:"How It Works",title:"Setup your ad campaign",step1:{title:"Set up budget & review your ads",description:"Define how much you want to spend, review the ad designs, and configure who you want to reach."},step2:{title:"We’ll publish & optimize your ads on Google",description:"We’ll do the hard work of publishing & continuously optimizing your ads on Google making sure you’re getting the best possible return on investment."},step3:{title:"See Customers & Results",description:"When a customer buys from you, we’ll notify you and show you the total revenue driven to your business from each dollar invested in ads. "}},ads_builder:{dialog_trigger:"New campaign",title:"Ads Builder",description:"Create your new ad campaign",review_ad_themes:"Review Ad Themes",example_ad_preview:"Example Ad Preview",example_ad_preview_description:"Here's an example of how prospective customers might see your ads. We will automagically tweak the copy based on your products offered, and improve targeting based on what results in the most dollars to your business."}},analytics:{setup_analytics:"Setup analytics",setup_analytics_description:"Let's get you started with analytics. Connect your data sources to start tracking your customers.",connect_data:{title:"Connect Your Data",description:"We bring all of your ads data together to give you a clear view of which customers are coming in from where."},install_pixel:{copied_to_clipboard:"Copied to clipboard",copied_to_clipboard_description:"The tracking pixel code has been copied to your clipboard.",title:"Install our Tracking Pixel",description:"In order to get a complete picture of how users are interacting with your website, it’s important for the Reach analytics code to be on every page of your website and within as many third-party tools that you use as possible.",card_title:"Install the Snippet inside the <HEAD> of every page",third_party_pages_your_tracking_pixel:"Your Tracking Pixel:",card_description:"Copy this following text and insert it inside of the <HEAD> tags on all pages.",error_generating_pixel_code:"Error generating pixel code - please contact your administrator",third_party_pages_question:"Do you use any websites or landing pages for marketing your business?",third_party_pages_yes:"Yes, I have marketing websites",third_party_pages_no:"No, I don't use any websites",third_party_pages_why_asking:"Why We're Asking For This",third_party_pages_why_asking_description:"Adding our tracking pixel to your website allows us to:",third_party_pages_why_asking_list_1:"Understand how visitors interact with your pages",third_party_pages_why_asking_list_2:"Measure which ads are driving visitors to your site",third_party_pages_why_asking_list_3:"Track conversions from your campaigns",third_party_pages_enter_marketing_website:"Enter your marketing website:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"We'll use this to help you install the tracking pixel",third_party_pages_select_your_website_platform:"Select your website platform:"},third_party_installation_guides:{title:"Installation Guides",description:"These guides will help you add the Reach analytics snippet to your website. The process works with any website builder or platform and most third-party tools.",installation_guide:"{{name}} Installation Guide",official_guide:"Official Guide",shopify:{step_1:"From your Shopify admin, go to Online Store > Themes",step_2:"Find the theme you want to edit, click the … button to open the actions menu, and then click Edit code",step_3:'Open "theme.liquid"',step_4:"Find the </head> tag",step_5:"Paste the code snippet from the section above just before it"},google_tag_manager:{step_1:"Go to https://tagmanager.google.com",step_2:"Sign in to your Google Account",step_3:"Click the Accounts tab, then select Create Account",step_4:"Enter an account name and select your country location",step_5:"In Container Setup, enter a container name (e.g., your website URL)",step_6:'Select "Web" as the container type',step_7:"Click Create and agree to the Terms of Service",step_8:"Once created, you'll receive two code snippets to install:",step_9:"• Place the first snippet in the <head> of your page",step_10:"• Place the second snippet immediately after the opening <body> tag",step_11:"In the Tags tab, click the + button to create a new tag",step_12:'Select "Google Analytics: Universal Analytics" as the tag type',special_note:"Make sure you have the Google Tag Manager container code already installed on your site before adding this tag."},hubspot:{step_1:"Go to Settings → Content → Pages",step_2:'In the upper left, select a domain to edit its settings. Or select "Default settings for all domains"',step_3:'Paste the code from the section above to the "Site Header HTML" field',step_4:'Click "Save"'},wordpress:{step_1:"We recommend using the popular WPCode Plugin",step_2:'In the plugin, select "+ Add Snippet"',step_3:'When presented with a menu of options, navigate to "Add Your Custom Code (New Snippet)" and select "Use snippet"',step_4:"Paste the code snippet from the section above",step_5:'For Insert Method, choose "Auto Insert"',step_6:'For Location, select "Site Wide Header"',step_7:"Be sure to save your snippet"},squarespace:{step_1:"Go to Settings → Advanced → Code Injection",step_2:'Paste the code from the section above into the "Header" field',step_3:'Click "Save"'},wix:{step_1:"Go to Settings → Custom Code",step_2:'Click "+ Add Custom Code"',step_3:"Paste the code from the section above",step_4:'Click "Apply"',step_5:'Set "Add Code to Pages" to "All Pages"'},webflow:{step_1:"Open your project settings",step_2:'Navigate to "Custom Code"',step_3:'Paste the code from the section above into the "Head Code" section',step_4:'Click "Save Changes"'},third_party_systems:{step_1:"Check if your third-party tools (lead forms, scheduling tools, etc.) allow custom code injection",step_2:'Look for options labeled "Custom Code", "Embed Code", or "Advanced Settings"',step_3:"Paste the same tracking code into these sections where available",step_4:"Common locations include:",step_5:"• Head section of your website (for tracking scripts and styles)",step_6:"• Footer section of your website (for tracking scripts and styles)",special_note:"This helps ensure consistent tracking across all your customer touchpoints, even when using external tools."},custom:{step_1:"Locate your website's HTML template or main layout file",step_2:"Find the </head> tag in your HTML",step_3:"Paste the code snippet just before the </head> tag",step_4:"Save the file and deploy your changes"}},success:{title:"Success!",description:"You have successfully connected your data sources and installed our tracking pixel.",what_next:"What happens next?",step_1:"Your ad data will start syncing automatically",step_2:"The pixel will begin tracking conversions on your site",step_3:"You'll see your first analytics reports within 24 hours"}},dashboard:{banners:{metrics_crunching:{title:"Crunching your data",description:"You have successfully connected your ad accounts. We're now crunching your data. Check back soon for relevant metrics."},revoked_accounts:{title:"Your ad accounts have been revoked",description:"Please reconnect your ad accounts to continue using the dashboard."}},roas_chart:{title:"Ad Spend vs Revenue Over Time",campaign_not_available:"Chart is not available for individual campaigns yet"},customer_acquisition:{title:"Client Acquisition",description:"See how many new clients you acquired from each channel",client:"Client",source:"Source",total_spent:"Total Spent",total_revenue:"Total Revenue",status:"Status",no_data:"No data available",source_breakdown:"Source",payment_status:"Payment Status",paid:"Paid",unpaid:"Unpaid",invoice_details:"Invoice Details",amount:"Amount",service:"Service",invoice_date:"Invoice Date"},channel_performance:{title:"Channel Performance",description:"See how each channel performs",channel:"Channel",spend:"Spend",revenue:"Revenue",roas:"ROAS",new_customers:"New Customers"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Overview",channel_performance:"Channel Performance",campaign_performance:"Campaign Performance",customer_acquisition:"Customer Acquisition",traffic_conversion:"Traffic Conversion"},metrics:{ads_spend:"Ads Spend",ads_spend_description:"The amount spent on ads in a given period. Sum of all sub-ads accounts (e.g. insta, google). Excluding agency fees",direct_measured_revenue:"Direct Measured Revenue",direct_measured_revenue_description:"The amount of revenue directly measured from ads",measured_revenue:"Measured Revenue",measured_revenue_description:"The amount of revenue measured from ads",direct_measured_conversions:"Direct Measured Conversions",direct_measured_conversions_description:"The amount of conversions directly measured from ads",measured_conversions:"Measured Conversions",measured_conversions_description:"The amount of conversions measured from ads",roas:"ROAS",roas_description:"This is the ratio of the revenue to the ads spend",impressions:"Impressions",impressions_description:"Number of times your ads were shown to potential customers",clicks:"Clicks/Actions",clicks_description:"Total interactions with your ads, including clicks and other actions",website_visitors:"Website Visitors",website_visitors_description:"Unique visitors to your website from advertising campaigns",new_leads:"New Leads",new_leads_description:"New potential customers who provided contact information",customer_ltv:"Customer LTV",customer_ltv_description:"Average lifetime value of customers acquired through ads",new_customers:"New Customers",new_customers_description:"New customers who made a purchase or took an action",new_leads_conversion_rate:"New Leads Conversion Rate",new_leads_conversion_rate_description:"The ratio of new leads to the total number of leads",new_customers_conversion_rate:"New Customers Conversion Rate",new_customers_conversion_rate_description:"The ratio of new customers to the total number of customers",cost_per_click:"Cost Per Click",cost_per_click_description:"The amount spent per click on your ads",click_conversion_rate:"Click Conversion Rate",click_conversion_rate_description:"The ratio of clicks to the total number of clicks",click_through_rate:"Click Through Rate",click_through_rate_description:"The ratio of clicks to the total number of impressions",conversion_rate:"Conversion Rate",conversion_rate_description:"The ratio of conversions to the total number of clicks",total_conversion:"Total Conversion",total_conversion_description:"The total number of conversions from your ads",cac:"CAC",cac_description:"The amount spent per customer acquisition",revenue_per_click:"Revenue Per Click",revenue_per_click_description:"The amount of revenue generated per click on your ads",revenue_per_new_customer:"Revenue Per New Customer",revenue_per_new_customer_description:"The amount of revenue generated per new customer",reengaged_customers:"Reengaged Customers",reengaged_customers_description:"The number of customers who have been reengaged with your ads",expected_revenue:"Expected Revenue",expected_revenue_description:"The amount of revenue you expect to generate from your ads",estimated_revenue:"Estimated Revenue",estimated_revenue_description:"The amount of revenue you expect to generate from your ads"},title:"Marketing Revenue Dashboard",settings_sheet:{setup:"Setup",connected_accounts:"Connected Accounts",setup_analytics:"Setup analytics",setup_analytics_description:"Configure your analytics tracking",setup_campaigns:"Setup campaigns",setup_campaigns_description:"Set up your first campaign",legal:"Legal",terms_of_service:"Terms of Service",privacy_policy:"Privacy Policy"}},setup:{how_it_works:{title:"How It Works",dialog_title:"Setup Marketing Insights",connect_ads_title:"Connect your Ads Accounts",connect_ads_description:"Link your advertising accounts from platforms like Google and Meta to consolidate all your campaign data in one place. This enables comprehensive tracking and analysis of your marketing spend.",install_pixel_title:"Install Our Tracking Pixel",install_pixel_description:"Add our lightweight tracking code to your website to accurately measure customer interactions and conversions. This simple integration helps identify which ads are driving real results for your business.",see_customers_results_title:"See Customers & Results",see_customers_results_description:"Get clear insights into your marketing performance with detailed analytics on customer acquisition, conversion rates, and return on ad spend. Make data-driven decisions to optimize your campaigns and grow your business.",still_have_more_questions:"Still have more questions?",get_started:"Get Started"},initial_setup:{wizard_title:"Connect your ad accounts and see exactly how your campaigns drive revenue",title:"Unlock Clear Insights into Your Marketing Performance",description:"Stop guessing and start knowing. Our performance dashboard gives you a complete view of your marketing efforts, including ad spend, conversions, and return on ad spend (ROAS).",description_2:"With a simple setup process, you’ll have actionable insights at your fingertips to help you make smarter decisions and grow your business.",setup_performance_analytics:"Setup Performance Analytics",next_steps_description:"If you're not running ads yet, you can launch your first AI-powered ad campaign in minutes.",next_steps_link:"We will prompt you to connect your ad accounts and set up your first campaign."}},oauth:{selectAccount:{title:"Select {{platform}} Account",description:"Choose the {{platform}} account you want to connect.",loading:"Loading accounts...",loadingPlatform:"Loading {{platform}} accounts...",loadingDescription:"Please wait while we fetch your available accounts...",noAccounts:"No {{platform}} accounts were found for your account.",noAccountsDescription:"Please make sure you have access to a {{platform}} account and try again.",selectAccountPlaceholder:"Select an account",searchPlaceholder:"Search accounts...",fetchAccounts:"Fetching accounts...",noAccountSelected:"No account selected",enableTrackingParams:"Enable Tracking Parameters",enableTrackingParamsDescription:"Append the reach campaign id parameter to your ad platform tracking settings. We will not overwrite any existing tracking parameters. Required for accurate tracking.",google:{selectAccountDescription:"Select the Google Ads account you want to connect to view your data. These will be linked to our MCC for optimal tracking.",mccAccounts:"MCC Accounts",directAccounts:"Direct Accounts"},meta:{selectAccountDescription:"Choose the Meta Ads account you want to connect to view your data."}},success:{connection:{title:"Connected successfully",description:"Your {{provider}} account has been connected."},revoke:{title:"Account revoked",description:"Your {{provider}} account has been revoked."}},error:{title:"Connection failed",description:"Failed to connect account"},revoke:{title:"Revoke access",description:"Are you sure? Revoking access will remove the connection you have and you will be unable to view your ad metrics.",cancel:"Cancel",revoke:"Revoke",error:{title:"Error",description:"Failed to revoke access"}}},magic_link:{get_started:"Get Started",description:"Reach will be embedded within your platform dashboard but until then, you can get started with a magic link. Log in to your account and start creating AI-powered campaigns or measuring your ad spend and performance.",create_campaigns:"Create AI-generated ad campaigns in minutes",unlock_insights:"Unlock insights into your ad spend and performance",save_time:"Save time with automated campaign optimization",request_new_magic_link:"Request New Magic Link",go_to_dashboard:"Go to Dashboard",continuation_disclaimer:"By continuing, you agree to our <terms_of_service>Terms of Service</terms_of_service> and <privacy_policy>Privacy Policy</privacy_policy>."},empty_state:{analytics:{title:"You haven't connected any ad accounts yet",description:"You can connect your ad accounts in minutes and start driving more customers to your business.",button_text:"Setup analytics"}}},engage:{user:"User",user_other:"Users",automation:"Automation",automation_other:"Automations",segment:"Segment",segment_other:"Segments",one_time:"One Time",trigger_based:"Trigger Based"}},es:{common:{ad_spend:"Gasto en anuncios",date:"Fecha",close:"Cerrar",continue:"Continuar",connected:"Conectado",connecting:"Conectando...",reauthenticate:"Reautenticar",account_settings:"Configuración de cuenta",manage_account_settings:"Configuración de tu cuenta",copy:"Copiar",copied:"Copiado",error:"Se produjo un error",filter:"Filtrar",finishingUp:"Finalizando...",loading:"Cargando...",need_help:"¿Necesitas ayuda? Háznoslo saber",next:"Siguiente",next_steps:"Siguientes pasos:",number:"{{number}}",previous:"Anterior",revenue:"Ingresos",revenue_from_ads:"Ingresos de anuncios",roas:"ROAS",return_on_ad_spend:"Retorno de inversión en anuncios",select_dates:"Selecciona fechas",total_ads_spend:"Gasto total en anuncios",measure:{dashboard:{title:"Panel de ingresos de marketing",subtitle:"Rastrea y analiza cómo tus esfuerzos de marketing están generando ventas",application_status_banner_title:"Estamos experimentando algunos problemas",application_status_banner_description:"Estamos al tanto de un problema que está afectando al panel. Estamos trabajando en ello y lo resolveremos pronto.",no_metrics_banner_title:"No podemos mostrar ninguna métrica para este rango de fechas",no_metrics_banner_description:"Si has conectado tus cuentas de anuncios recientemente, tus métricas deberían comenzar a poblarse en las próximas 24 horas. Por favor, vuelve pronto.",reach_managed_campaign_banner:"Tus anuncios están siendo gestionados por Reach. Automáticamente los optimizaremos para obtener los mejores resultados."}},authentication:{required:"Se requiere autenticación",failed:"Error de autenticación",connect_account_title:"Conecta tu cuenta de {{provider}}",connect_account_description:"Para crear y gestionar campañas de anuncios, por favor conecta tu cuenta de {{provider}}",connect_account_button:"Continuar con {{provider}}",connect_account_TOS:"Al conectarte, aceptas nuestros Términos de Servicio y Política de Privacidad"},theme:{loading:"Cargando tema...",error:"Error al cargar el tema: {{message}}"},dates:{last_week:"Semana pasada",last_month:"Mes pasado",last_quarter:"Trimestre pasado",last_year:"Año pasado"},campaigns:{setup:{card_header:"Lanza anuncios pagados para obtener nuevos leads y clientes",title:"Crea tu primera campaña de anuncios AI en 4 clicks",description:"Bienvenido al futuro del marketing! Nuestro creador de campañas AI te ayuda a diseñar y gestionar anuncios que alcanzan a tu audiencia con precisión. ¡Comienza ahora para desbloquear el potencial de anuncios automatizados y basados en datos.",button:"Configura tus anuncios pagados",next_steps_description:"¿Ya tienes anuncios? Rastrea tus resultados de marketing con solo unos clicks.",link_to_analytics:"Conecta tus cuentas existentes para obtener insights instantáneos sobre tu rendimiento de marketing."},how_it_works:{dialog_title:"Cómo funciona",title:"Configura tu campaña de anuncios",step1:{title:"Configura tu presupuesto y revisa tus anuncios",description:"Define cuánto quieres gastar, revisa los diseños de anuncios y configura quién quieres llegar."},step2:{title:"Publicaremos y optimizaremos tus anuncios en Google",description:"Haremos el trabajo duro de publicar y optimizar tus anuncios en Google para asegurarnos de que obtengas el mejor retorno de inversión posible."},step3:{title:"Ver clientes y resultados",description:"Cuando un cliente compra de ti, te notificaremos y te mostraremos el total de ingresos generados para tu negocio por cada dólar invertido en anuncios."}},ads_builder:{dialog_trigger:"Nueva campaña",title:"Ads Builder",description:"Crea tu nueva campaña de anuncios",review_ad_themes:"Revisa temas de anuncios",example_ad_preview:"Ejemplo de anuncio",example_ad_preview_description:"Aquí tienes un ejemplo de cómo los clientes potenciales podrían ver tus anuncios. Automáticamente ajustaremos el texto basándonos en tus productos ofrecidos y mejoraremos el targeting basándonos en lo que resulta en más dinero para tu negocio."}},analytics:{setup_analytics:"Configura analytics",setup_analytics_description:"Vamos a empezar con analytics. Conecta tus fuentes de datos para empezar a rastrear tus clientes.",connect_data:{title:"Conecta tus datos",description:"Juntamos todos tus datos de anuncios para darte una visión clara de qué clientes están llegando de dónde."},install_pixel:{copied_to_clipboard:"Copiado al portapapeles",copied_to_clipboard_description:"El código del pixel de seguimiento ha sido copiado a tu portapapeles.",title:"Instala nuestro pixel de seguimiento",description:"Para obtener una visión completa de cómo los usuarios interactúan con tu sitio web, es importante que el código de analytics de Reach esté en cada página de tu sitio web y dentro de tantos terceros como puedas usar.",card_title:"Instala el fragmento dentro del <HEAD> de cada página",third_party_pages_your_tracking_pixel:"Tu pixel de seguimiento:",card_description:"Copia este texto y insertalo dentro de las etiquetas <HEAD> en todas las páginas.",error_generating_pixel_code:"Error generando código del pixel - por favor contacta a tu administrador",third_party_pages_question:"¿Utilizas alguna página web o landing page para promocionar tu negocio?",third_party_pages_yes:"Sí, tengo páginas web de marketing",third_party_pages_no:"No, no utilizo ninguna página web",third_party_pages_why_asking:"¿Por qué te pedimos esto?",third_party_pages_why_asking_description:"Añadir nuestro pixel de seguimiento a tu sitio web nos permite:",third_party_pages_why_asking_list_1:"Entender cómo los visitantes interactúan con tus páginas",third_party_pages_why_asking_list_2:"Medir qué anuncios están llevando visitantes a tu sitio",third_party_pages_why_asking_list_3:"Rastrear conversiones desde tus campañas",third_party_pages_enter_marketing_website:"Ingresa tu página web de marketing:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"Usaremos esto para ayudarte a instalar el pixel de seguimiento",third_party_pages_select_your_website_platform:"Selecciona tu plataforma de sitio web:"},third_party_installation_guides:{title:"Guías de instalación",description:"Estas guías te ayudarán a agregar el fragmento de analytics de Reach a tu sitio web. El proceso funciona con cualquier constructor de sitios web o plataforma y la mayoría de las herramientas de terceros.",installation_guide:"Guía de instalación de {{name}}",official_guide:"Guía oficial",shopify:{step_1:"Desde tu Shopify admin, ve a Online Store > Themes",step_2:"Encuentra el tema que quieres editar, haz click en el botón … para abrir el menú de acciones y luego haz click en Editar código",step_3:'Abre "theme.liquid"',step_4:"Encuentra la etiqueta </head>",step_5:"Pega el fragmento de código de la sección anterior justo antes de ella"},google_tag_manager:{step_1:"Ve a https://tagmanager.google.com",step_2:"Inicia sesión en tu cuenta de Google",step_3:"Haz click en la pestaña de Cuentas y selecciona Crear cuenta",step_4:"Ingresa un nombre para tu cuenta y selecciona tu ubicación",step_5:"En Container Setup, ingresa un nombre para tu contenedor (e.g., tu URL de sitio web)",step_6:'Selecciona "Web" como tipo de contenedor',step_7:"Haz click en Crear y acepta los Términos de Servicio",step_8:"Una vez creado, recibirás dos fragmentos de código para instalar:",step_9:"• Coloca el primer fragmento en la etiqueta <head> de tu página",step_10:"• Coloca el segundo fragmento justo después de la etiqueta <body>",step_11:"En la pestaña de Etiquetas, haz click en el botón + para crear una nueva etiqueta",step_12:'Selecciona "Google Analytics: Universal Analytics" como tipo de etiqueta',special_note:"Asegúrate de tener el código del contenedor de Google Tag Manager instalado en tu sitio web antes de agregar esta etiqueta."},hubspot:{step_1:"Ve a Configuración → Contenido → Páginas",step_2:'En la esquina superior izquierda, selecciona un dominio para editar sus ajustes. O selecciona "Ajustes predeterminados para todos los dominios"',step_3:'Pega el código de la sección anterior en el campo "HTML del encabezado del sitio"',step_4:'Haz click en "Guardar"'},wordpress:{step_1:"Recomendamos usar el plugin WPCode",step_2:'En el plugin, selecciona "+ Añadir fragmento"',step_3:'Cuando se te presente un menú de opciones, navega a "Añadir tu código personalizado (nuevo fragmento)" y selecciona "Usar fragmento"',step_4:"Pega el fragmento de código de la sección anterior",step_5:'Para el método de inserción, elige "Auto insertar"',step_6:'Para la ubicación, selecciona "Encabezado del sitio"',step_7:"Asegúrate de guardar tu fragmento"},squarespace:{step_1:"Ve a Configuración → Avanzado → Inyección de código",step_2:'Pega el código de la sección anterior en el campo "Encabezado"',step_3:'Haz click en "Guardar"'},wix:{step_1:"Ve a Configuración → Código personalizado",step_2:'Haz click en "+ Añadir código personalizado"',step_3:"Pega el código de la sección anterior",step_4:'Haz click en "Aplicar"',step_5:'Establece "Añadir código a páginas" a "Todas las páginas"'},webflow:{step_1:"Abre tus ajustes de proyecto",step_2:'Navega a "Código personalizado"',step_3:'Pega el código de la sección anterior en la sección "Código de encabezado"',step_4:'Haz click en "Guardar cambios"'},third_party_systems:{step_1:"Revisa si tus herramientas de terceros (formularios de leads, herramientas de programación, etc.) permiten la inyección de código personalizado",step_2:'Busca opciones etiquetadas como "Código personalizado", "Código incrustado" o "Ajustes avanzados"',step_3:"Pega el mismo código de seguimiento en estas secciones donde esté disponible",step_4:"Los lugares comunes incluyen:",step_5:"• Sección de encabezado de tu sitio web (para scripts y estilos de seguimiento)",step_6:"• Sección de pie de página de tu sitio web (para scripts y estilos de seguimiento)",special_note:"Esto asegura un seguimiento consistente en todos tus puntos de contacto con clientes, incluso cuando usas herramientas externas."},custom:{step_1:"Localiza tu plantilla HTML o archivo de diseño principal",step_2:"Encuentra la etiqueta </head> en tu HTML",step_3:"Pega el fragmento de código justo antes de la etiqueta </head>",step_4:"Guarda el archivo y desplíalo"}},success:{title:"¡Éxito!",description:"Has conectado tus fuentes de datos y instalado nuestro pixel de seguimiento.",what_next:"¿Qué pasa a continuación?",step_1:"Tus datos de anuncios comenzarán a sincronizarse automáticamente",step_2:"El pixel comenzará a rastrear conversiones en tu sitio",step_3:"Verás tus primeros informes de analytics en 24 horas"}},dashboard:{banners:{metrics_crunching:{title:"Trabajando en tus datos",description:"Has conectado tus cuentas de anuncios. Estamos ahora trabajando en tus datos. Vuelve pronto para ver tus métricas relevantes."},revoked_accounts:{title:"Tus cuentas de anuncios han sido revocadas",description:"Por favor, reconecta tus cuentas de anuncios para continuar usando el panel."}},roas_chart:{title:"Gasto en anuncios vs ingresos en el tiempo",campaign_not_available:"El gráfico no está disponible para campañas individuales todavía"},customer_acquisition:{title:"Adquisición de clientes",description:"Ver cómo adquieres nuevos clientes desde cada canal",client:"Cliente",source:"Fuente",total_spent:"Total gastado",total_revenue:"Ingresos totales",status:"Estado",no_data:"No hay datos disponibles",source_breakdown:"Desglose de fuentes",payment_status:"Estado de pago",paid:"Pagado",unpaid:"No pagado",invoice_details:"Detalles de la factura",amount:"Cantidad",service:"Servicio",invoice_date:"Fecha de la factura"},channel_performance:{title:"Rendimiento de canales",description:"Ver cómo cada canal se desempeña",channel:"Canal",spend:"Gasto",revenue:"Ingresos",roas:"ROAS",new_customers:"Nuevos clientes"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Resumen",channel_performance:"Rendimiento de canales",campaign_performance:"Rendimiento de campañas",customer_acquisition:"Adquisición de clientes",traffic_conversion:"Conversión de tráfico"},metrics:{ads_spend:"Gasto en anuncios",ads_spend_description:"El gasto en anuncios en un período determinado. Suma de todos los sub-cuentas de anuncios (e.g. insta, google). Excluyendo comisiones de agencias",direct_measured_revenue:"Ingresos medidos directamente",direct_measured_revenue_description:"La cantidad de ingresos medidos directamente desde anuncios",measured_revenue:"Ingresos medidos",measured_revenue_description:"La cantidad de ingresos medidos desde anuncios",direct_measured_conversions:"Conversiones medidas directamente",direct_measured_conversions_description:"La cantidad de conversiones medidas directamente desde anuncios",measured_conversions:"Conversiones medidas",measured_conversions_description:"La cantidad de conversiones medidas desde anuncios",roas:"ROAS",roas_description:"Este es el ratio de los ingresos a los gastos en anuncios",impressions:"Impresiones",impressions_description:"Número de veces que tus anuncios fueron mostrados a potenciales clientes",clicks:"Clicks/Acciones",clicks_description:"Total de interacciones con tus anuncios, incluyendo clicks y otras acciones",website_visitors:"Visitantes web",website_visitors_description:"Visitantes únicos a tu sitio web desde campañas de anuncios",new_leads:"Nuevos leads",new_leads_description:"Nuevos potenciales clientes que proporcionaron información de contacto",customer_ltv:"LTV de cliente",customer_ltv_description:"Valor promedio de vida de clientes adquiridos a través de anuncios",new_customers:"Nuevos clientes",new_customers_description:"Nuevos clientes que hicieron una compra o tomaron una acción",new_leads_conversion_rate:"Tasa de conversión de leads nuevos",new_leads_conversion_rate_description:"El ratio de leads nuevos al total de leads",new_customers_conversion_rate:"Tasa de conversión de nuevos clientes",new_customers_conversion_rate_description:"El ratio de nuevos clientes al total de clientes",cost_per_click:"Costo por click",cost_per_click_description:"El gasto por click en tus anuncios",click_conversion_rate:"Tasa de conversión de clicks",click_conversion_rate_description:"El ratio de clicks al total de clicks",click_through_rate:"Tasa de clics",click_through_rate_description:"El ratio de clicks al total de impresiones",conversion_rate:"Tasa de conversión",conversion_rate_description:"El ratio de conversiones al total de clicks",total_conversion:"Total de conversiones",total_conversion_description:"El número total de conversiones desde tus anuncios",cac:"CAC",cac_description:"El gasto por cliente adquirido",revenue_per_click:"Ingresos por click",revenue_per_click_description:"El ingreso generado por cada click en tus anuncios",revenue_per_new_customer:"Ingresos por nuevo cliente",revenue_per_new_customer_description:"El ingreso generado por cada nuevo cliente",reengaged_customers:"Clientes reactivados",reengaged_customers_description:"El número de clientes que han sido reactivados con tus anuncios",expected_revenue:"Ingresos esperados",expected_revenue_description:"El ingreso que esperas generar desde tus anuncios",estimated_revenue:"Ingresos estimados",estimated_revenue_description:"El ingreso que estimas generar desde tus anuncios"},title:"Panel de ingresos de marketing",settings_sheet:{setup:"Configuración",connected_accounts:"Cuentas conectadas",setup_analytics:"Configurar analytics",setup_analytics_description:"Configura tu tracking de analytics",setup_campaigns:"Configurar campañas",setup_campaigns_description:"Configura tu primera campaña",legal:"Legal",terms_of_service:"Términos de servicio",privacy_policy:"Política de privacidad"}},setup:{how_it_works:{title:"Cómo funciona",dialog_title:"Configura Marketing Insights",connect_ads_title:"Conecta tus cuentas de anuncios",connect_ads_description:"Conecta tus cuentas de anuncios de plataformas como Google y Meta para consolidar todos tus datos de campañas en un solo lugar. Esto te permite rastrear y analizar tu gasto en marketing de manera completa.",install_pixel_title:"Instala nuestro pixel de seguimiento",install_pixel_description:"Añade nuestro código de seguimiento ligero a tu sitio web para medir las interacciones y conversiones de los clientes. Esta integración simple ayuda a identificar qué anuncios están generando resultados reales para tu negocio.",see_customers_results_title:"Ver clientes y resultados",see_customers_results_description:"Obtén una visión clara de tu rendimiento en marketing con análisis detallados sobre adquisición de clientes, tasas de conversión y retorno de inversión en anuncios. Haz decisiones basadas en datos para optimizar tus campañas y crecer tu negocio.",still_have_more_questions:"¿Tienes más preguntas?",get_started:"Comenzar"},initial_setup:{wizard_title:"Conecta tus cuentas de anuncios y ver cómo tus campañas generan ingresos",title:"Desbloquea insights claros en tu rendimiento de marketing",description:"Para empezar, conecta tus cuentas de anuncios de Google y Meta. Esto te permitirá rastrear y analizar tu gasto en marketing de manera completa.",description_2:"Con un proceso de configuración simple, tendrás insights accionables a tu disposición para ayudarte a tomar mejores decisiones y crecer tu negocio.",setup_performance_analytics:"Configura analytics de rendimiento",next_steps_description:"Si no tienes anuncios aún, puedes lanzar tu primera campaña de anuncios AI en minutos.",next_steps_link:"Te pediremos que conectes tus cuentas de anuncios y configures tu primera campaña."}},oauth:{selectAccount:{title:"Cuenta de {{platform}}",description:"Elige la cuenta de {{platform}} que quieres conectar.",loading:"Cargando cuentas...",loadingPlatform:"Cargando cuentas de {{platform}}...",loadingDescription:"Por favor, espera mientras obtenemos tus cuentas disponibles...",noAccounts:"No se encontraron cuentas de {{platform}} para tu cuenta.",noAccountsDescription:"Por favor, asegúrate de tener acceso a una cuenta de {{platform}} y vuelve a intentarlo.",selectAccountPlaceholder:"Selecciona una cuenta",searchPlaceholder:"Buscar cuentas...",fetchAccounts:"Buscando cuentas...",noAccountSelected:"No hay cuenta seleccionada",enableTrackingParams:"Habilitar parámetros de seguimiento",enableTrackingParamsDescription:"Añada el parámetro de ID de campaña de alcance a la configuración de seguimiento de su plataforma publicitaria. No sobrescribiremos ningún parámetro de seguimiento existente. Necesario para un seguimiento preciso.",google:{selectAccountDescription:"Elige la cuenta de Google Ads que quieres conectar para ver tus datos. Estas serán vinculadas a nuestra MCC para un seguimiento óptimo.",mccAccounts:"Cuentas MCC",directAccounts:"Cuentas Directas"},meta:{selectAccountDescription:"Elige la cuenta de Meta Ads que quieres conectar para ver tus datos."}},success:{connection:{title:"Conectado correctamente",description:"Tu cuenta de {{provider}} ha sido conectada."},revoke:{title:"Cuenta revocada",description:"Tu cuenta de {{provider}} ha sido revocada."}},error:{title:"Error al conectar",description:"Error al conectar cuenta"},revoke:{title:"Revocar acceso",description:"¿Estás seguro? Revocar acceso eliminará la conexión que tienes y no podrás ver tus métricas de anuncios.",cancel:"Cancelar",revoke:"Revocar",error:{title:"Error",description:"Error al revocar acceso"}}},magic_link:{get_started:"Comenzar",description:"Reach estará incrustado en tu panel de control pero hasta entonces, puedes comenzar con un enlace mágico. Inicia sesión en tu cuenta y comienza a crear campañas AI o mide tu gasto en anuncios y rendimiento.",create_campaigns:"Crea campañas de anuncios AI en minutos",unlock_insights:"Desbloquea insights en tu gasto en anuncios y rendimiento",save_time:"Ahorra tiempo con optimización de campañas automatizadas",request_new_magic_link:"Solicitar nuevo enlace mágico",go_to_dashboard:"Ir al panel de control",continuation_disclaimer:"Al continuar, aceptas nuestros <terms_of_service>Términos de servicio</terms_of_service> y <privacy_policy>Política de privacidad</privacy_policy>."},empty_state:{analytics:{title:"No tienes ninguna cuenta de anuncios conectada",description:"Puedes conectar tus cuentas de anuncios en minutos y empezar a atraer más clientes a tu negocio.",button_text:"Configurar analytics"}}},engage:{user:"Usuario",user_other:"Usuarios",automation:"Automatización",automation_other:"Automatizaciones",segment:"Segmento",segment_other:"Segmentos",one_time:"Una vez",trigger_based:"Basado en un disparador"}}};ef.use(xf).use(pp).init({resources:Ef,fallbackLng:"en",debug:!1,interpolation:{escapeValue:!1},react:{useSuspense:!1},defaultNS:"common",ns:["common"],load:"languageOnly",detection:{order:["querystring","localStorage","navigator"],lookupQuerystring:"lang",lookupLocalStorage:"i18nextLng",caches:["localStorage"],convertDetectedLanguage:e=>e.split("-")[0]}});const _f={ad_spend:"Ad Spend",date:"Date",close:"Close",continue:"Continue",connected:"Connected",connecting:"Connecting...",reauthenticate:"Reauthenticate",account_settings:"Account Settings",manage_account_settings:"Manage your account settings",copy:"Copy",copied:"Copied",error:"An error occurred",filter:"Filter",finishingUp:"Finishing up...",loading:"Loading...",need_help:"Need help? let us know",next:"Next",next_steps:"Next steps:",number:"{{number}}",previous:"Previous",revenue:"Revenue",revenue_from_ads:"Revenue From Ads",roas:"ROAS",return_on_ad_spend:"Return on Ad Spend",select_dates:"Select dates",total_ads_spend:"Total Ads Spend",measure:{dashboard:{title:"Marketing ROI Dashboard",subtitle:"Track and analyze how your marketing efforts are driving sales",application_status_banner_title:"We are experiencing some issues",application_status_banner_description:"We are aware of an issue affecting the dashboard. We are working on it and will have it resolved soon.",no_metrics_banner_title:"We are unable to display any metrics for this date range",no_metrics_banner_description:"If you have just connected your ad accounts, your metrics should begin populating within the next 24 hours. Please check back soon.",reach_managed_campaign_banner:"Your ads are being managed by Reach. We’ll automatically optimize them to drive the best results."}},authentication:{required:"Authentication required",failed:"Authentication failed",connect_account_title:"Connect Your {{provider}} Account",connect_account_description:"To create and manage ad campaigns, please connect your {{provider}} account",connect_account_button:"Continue with {{provider}}",connect_account_TOS:"By connecting, you agree to our Terms of Service and Privacy Policy"},theme:{loading:"Loading theme...",error:"Error loading theme: {{message}}"},dates:{last_week:"Last week",last_month:"Last month",last_quarter:"Last quarter",last_year:"Last year"},campaigns:{setup:{card_header:"Run paid digital ads to get new leads & customers",title:"Create your first AI-driven Ad campaign in 4 simple clicks",description:"Welcome to the future of advertising! Our AI-powered campaign builder helps you effortlessly design and manage ads that reach your target audience with precision. Get started now to unlock the potential of automated, data-driven advertising.",button:"Set up paid ads",next_steps_description:"Already running ads? Track Your Marketing Results with a few clicks.",link_to_analytics:"Connect your existing accounts to get instant insights into your marketing performance."},how_it_works:{dialog_title:"How It Works",title:"Setup your ad campaign",step1:{title:"Set up budget & review your ads",description:"Define how much you want to spend, review the ad designs, and configure who you want to reach."},step2:{title:"We’ll publish & optimize your ads on Google",description:"We’ll do the hard work of publishing & continuously optimizing your ads on Google making sure you’re getting the best possible return on investment."},step3:{title:"See Customers & Results",description:"When a customer buys from you, we’ll notify you and show you the total revenue driven to your business from each dollar invested in ads. "}},ads_builder:{dialog_trigger:"New campaign",title:"Ads Wizard",description:"Create your new ad campaign",review_ad_themes:"Review Ad Themes",example_ad_preview:"Example Ad Preview",example_ad_preview_description:"Here's an example of how prospective customers might see your ads. We will automagically tweak the copy based on your products offered, and improve targeting based on what results in the most dollars to your business."}},analytics:{setup_analytics:"Setup analytics",setup_analytics_description:"Let's get you started with analytics. Connect your data sources to start tracking your customers.",connect_data:{title:"Connect Your Data",description:"We bring all of your ads data together to give you a clear view of which customers are coming in from where."},install_pixel:{copied_to_clipboard:"Copied to clipboard",copied_to_clipboard_description:"The tracking pixel code has been copied to your clipboard.",title:"Install our Tracking Pixel",description:"In order to get a complete picture of how users are interacting with your website, it’s important for the Reach analytics code to be on every page of your website and within as many third-party tools that you use as possible.",card_title:"Install the Snippet inside the <HEAD> of every page",third_party_pages_your_tracking_pixel:"Your Tracking Pixel:",card_description:"Copy this following text and insert it inside of the <HEAD> tags on all pages.",error_generating_pixel_code:"Error generating pixel code - please contact your administrator",third_party_pages_question:"Do you use any websites or landing pages for marketing your business?",third_party_pages_yes:"Yes, I have marketing websites",third_party_pages_no:"No, I don't use any websites",third_party_pages_why_asking:"Why We're Asking For This",third_party_pages_why_asking_description:"Adding our tracking pixel to your website allows us to:",third_party_pages_why_asking_list_1:"Understand how visitors interact with your pages",third_party_pages_why_asking_list_2:"Measure which ads are driving visitors to your site",third_party_pages_why_asking_list_3:"Track conversions from your campaigns",third_party_pages_enter_marketing_website:"Enter your marketing website:",third_party_pages_we_will_use_this_to_help_you_install_the_tracking_pixel:"We'll use this to help you install the tracking pixel",third_party_pages_select_your_website_platform:"Select your website platform:"},third_party_installation_guides:{title:"Installation Guides",description:"These guides will help you add the Reach analytics snippet to your website. The process works with any website builder or platform and most third-party tools.",installation_guide:"{{name}} Installation Guide",official_guide:"Official Guide",shopify:{step_1:"From your Shopify admin, go to Online Store > Themes",step_2:"Find the theme you want to edit, click the … button to open the actions menu, and then click Edit code",step_3:'Open "theme.liquid"',step_4:"Find the </head> tag",step_5:"Paste the code snippet from the section above just before it"},google_tag_manager:{step_1:"Go to https://tagmanager.google.com",step_2:"Sign in to your Google Account",step_3:"Click the Accounts tab, then select Create Account",step_4:"Enter an account name and select your country location",step_5:"In Container Setup, enter a container name (e.g., your website URL)",step_6:'Select "Web" as the container type',step_7:"Click Create and agree to the Terms of Service",step_8:"Once created, you'll receive two code snippets to install:",step_9:"• Place the first snippet in the <head> of your page",step_10:"• Place the second snippet immediately after the opening <body> tag",step_11:"In the Tags tab, click the + button to create a new tag",step_12:'Select "Google Analytics: Universal Analytics" as the tag type',special_note:"Make sure you have the Google Tag Manager container code already installed on your site before adding this tag."},hubspot:{step_1:"Go to Settings → Content → Pages",step_2:'In the upper left, select a domain to edit its settings. Or select "Default settings for all domains"',step_3:'Paste the code from the section above to the "Site Header HTML" field',step_4:'Click "Save"'},wordpress:{step_1:"We recommend using the popular WPCode Plugin",step_2:'In the plugin, select "+ Add Snippet"',step_3:'When presented with a menu of options, navigate to "Add Your Custom Code (New Snippet)" and select "Use snippet"',step_4:"Paste the code snippet from the section above",step_5:'For Insert Method, choose "Auto Insert"',step_6:'For Location, select "Site Wide Header"',step_7:"Be sure to save your snippet"},squarespace:{step_1:"Go to Settings → Advanced → Code Injection",step_2:'Paste the code from the section above into the "Header" field',step_3:'Click "Save"'},wix:{step_1:"Go to Settings → Custom Code",step_2:'Click "+ Add Custom Code"',step_3:"Paste the code from the section above",step_4:'Click "Apply"',step_5:'Set "Add Code to Pages" to "All Pages"'},webflow:{step_1:"Open your project settings",step_2:'Navigate to "Custom Code"',step_3:'Paste the code from the section above into the "Head Code" section',step_4:'Click "Save Changes"'},third_party_systems:{step_1:"Check if your third-party tools (lead forms, scheduling tools, etc.) allow custom code injection",step_2:'Look for options labeled "Custom Code", "Embed Code", or "Advanced Settings"',step_3:"Paste the same tracking code into these sections where available",step_4:"Common locations include:",step_5:"• Head section of your website (for tracking scripts and styles)",step_6:"• Footer section of your website (for tracking scripts and styles)",special_note:"This helps ensure consistent tracking across all your customer touchpoints, even when using external tools."},custom:{step_1:"Locate your website's HTML template or main layout file",step_2:"Find the </head> tag in your HTML",step_3:"Paste the code snippet just before the </head> tag",step_4:"Save the file and deploy your changes"}},success:{title:"Success!",description:"You have successfully connected your data sources and installed our tracking pixel.",what_next:"What happens next?",step_1:"Your ad data will start syncing automatically",step_2:"The pixel will begin tracking conversions on your site",step_3:"You'll see your first analytics reports within 24 hours"}},dashboard:{banners:{metrics_crunching:{title:"Crunching your data",description:"You have successfully connected your ad accounts. We're now crunching your data. Check back soon for relevant metrics."},revoked_accounts:{title:"Your ad accounts have been revoked",description:"Please reconnect your ad accounts to continue using the dashboard."}},roas_chart:{title:"Ad Spend vs Revenue Over Time",campaign_not_available:"Chart is not available for individual campaigns yet"},customer_acquisition:{title:"Client Acquisition",description:"See how many new clients you acquired from each channel",client:"Client",source:"Source",total_spent:"Total Spent",total_revenue:"Total Revenue",status:"Status",no_data:"No data available",source_breakdown:"Source",payment_status:"Payment Status",paid:"Paid",unpaid:"Unpaid",invoice_details:"Invoice Details",amount:"Amount",service:"Service",invoice_date:"Invoice Date"},channel_performance:{title:"Channel Performance",description:"See how each channel performs",channel:"Channel",spend:"Spend",revenue:"Revenue",roas:"ROAS",new_customers:"New Customers"},traffic_conversion:{title:"Traffic Conversion Funnel"},tabs:{overview:"Overview",channel_performance:"Channel Performance",campaign_performance:"Campaign Performance",customer_acquisition:"Customer Acquisition",traffic_conversion:"Traffic Conversion"},metrics:{ads_spend:"Ads Spend",ads_spend_description:"The amount spent on ads in a given period. Sum of all sub-ads accounts (e.g. insta, google). Excluding agency fees",direct_measured_revenue:"Direct Measured Revenue",direct_measured_revenue_description:"The amount of revenue directly measured from ads",measured_revenue:"Measured Revenue",measured_revenue_description:"The amount of revenue measured from ads",direct_measured_conversions:"Direct Measured Conversions",direct_measured_conversions_description:"The amount of conversions directly measured from ads",measured_conversions:"Measured Conversions",measured_conversions_description:"The amount of conversions measured from ads",roas:"ROAS",roas_description:"This is the ratio of the revenue to the ads spend",impressions:"Impressions",impressions_description:"Number of times your ads were shown to potential customers",clicks:"Clicks/Actions",clicks_description:"Total interactions with your ads, including clicks and other actions",website_visitors:"Website Visitors",website_visitors_description:"Unique visitors to your website from advertising campaigns",new_leads:"New Leads",new_leads_description:"New potential customers who provided contact information",customer_ltv:"Customer LTV",customer_ltv_description:"Average lifetime value of customers acquired through ads",new_customers:"New Customers",new_customers_description:"New customers who made a purchase or took an action",new_leads_conversion_rate:"New Leads Conversion Rate",new_leads_conversion_rate_description:"The ratio of new leads to the total number of leads",new_customers_conversion_rate:"New Customers Conversion Rate",new_customers_conversion_rate_description:"The ratio of new customers to the total number of customers",cost_per_click:"Cost Per Click",cost_per_click_description:"The amount spent per click on your ads",click_conversion_rate:"Click Conversion Rate",click_conversion_rate_description:"The ratio of clicks to the total number of clicks",click_through_rate:"Click Through Rate",click_through_rate_description:"The ratio of clicks to the total number of impressions",conversion_rate:"Conversion Rate",conversion_rate_description:"The ratio of conversions to the total number of clicks",total_conversion:"Total Conversion",total_conversion_description:"The total number of conversions from your ads",cac:"CAC",cac_description:"The amount spent per customer acquisition",revenue_per_click:"Revenue Per Click",revenue_per_click_description:"The amount of revenue generated per click on your ads",revenue_per_new_customer:"Revenue Per New Customer",revenue_per_new_customer_description:"The amount of revenue generated per new customer",reengaged_customers:"Reengaged Customers",reengaged_customers_description:"The number of customers who have been reengaged with your ads",expected_revenue:"Expected Revenue",expected_revenue_description:"The amount of revenue you expect to generate from your ads",estimated_revenue:"Estimated Revenue",estimated_revenue_description:"The amount of revenue you expect to generate from your ads"},title:"Marketing Revenue Dashboard",settings_sheet:{setup:"Setup",connected_accounts:"Connected Accounts",setup_analytics:"Setup analytics",setup_analytics_description:"Configure your analytics tracking",setup_campaigns:"Setup campaigns",setup_campaigns_description:"Set up your first campaign",legal:"Legal",terms_of_service:"Terms of Service",privacy_policy:"Privacy Policy"}},setup:{how_it_works:{title:"How It Works",dialog_title:"Setup Marketing Insights",connect_ads_title:"Connect your Ads Accounts",connect_ads_description:"Link your advertising accounts from platforms like Google and Meta to consolidate all your campaign data in one place. This enables comprehensive tracking and analysis of your marketing spend.",install_pixel_title:"Install Our Tracking Pixel",install_pixel_description:"Add our lightweight tracking code to your website to accurately measure customer interactions and conversions. This simple integration helps identify which ads are driving real results for your business.",see_customers_results_title:"See Customers & Results",see_customers_results_description:"Get clear insights into your marketing performance with detailed analytics on customer acquisition, conversion rates, and return on ad spend. Make data-driven decisions to optimize your campaigns and grow your business.",still_have_more_questions:"Still have more questions?",get_started:"Get Started"},initial_setup:{wizard_title:"Connect your ad accounts and see exactly how your campaigns drive revenue",title:"Unlock Clear Insights into Your Marketing Performance",description:"Stop guessing and start knowing. Our performance dashboard gives you a complete view of your marketing efforts, including ad spend, conversions, and return on ad spend (ROAS).",description_2:"With a simple setup process, you’ll have actionable insights at your fingertips to help you make smarter decisions and grow your business.",setup_performance_analytics:"Setup Performance Analytics",next_steps_description:"If you're not running ads yet, you can launch your first AI-powered ad campaign in minutes.",next_steps_link:"We will prompt you to connect your ad accounts and set up your first campaign."}},oauth:{selectAccount:{title:"Select {{platform}} Account",description:"Choose the {{platform}} account you want to connect.",loading:"Loading accounts...",loadingPlatform:"Loading {{platform}} accounts...",loadingDescription:"Please wait while we fetch your available accounts...",noAccounts:"No {{platform}} accounts were found for your account.",noAccountsDescription:"Please make sure you have access to a {{platform}} account and try again.",selectAccountPlaceholder:"Select an account",searchPlaceholder:"Search accounts...",fetchAccounts:"Fetching accounts...",noAccountSelected:"No account selected",enableTrackingParams:"Enable Tracking Parameters",enableTrackingParamsDescription:"Append the reach campaign id parameter to your ad platform tracking settings. We will not overwrite any existing tracking parameters. Required for accurate tracking.",google:{selectAccountDescription:"Select the Google Ads account you want to connect to view your data. These will be linked to our MCC for optimal tracking.",mccAccounts:"MCC Accounts",directAccounts:"Direct Accounts"},meta:{selectAccountDescription:"Choose the Meta Ads account you want to connect to view your data."}},success:{connection:{title:"Connected successfully",description:"Your {{provider}} account has been connected."},revoke:{title:"Account revoked",description:"Your {{provider}} account has been revoked."}},error:{title:"Connection failed",description:"Failed to connect account"},revoke:{title:"Revoke access",description:"Are you sure? Revoking access will remove the connection you have and you will be unable to view your ad metrics.",cancel:"Cancel",revoke:"Revoke",error:{title:"Error",description:"Failed to revoke access"}}},magic_link:{get_started:"Get Started",description:"Reach will be embedded within your platform dashboard but until then, you can get started with a magic link. Log in to your account and start creating AI-powered campaigns or measuring your ad spend and performance.",create_campaigns:"Create AI-generated ad campaigns in minutes",unlock_insights:"Unlock insights into your ad spend and performance",save_time:"Save time with automated campaign optimization",request_new_magic_link:"Request New Magic Link",go_to_dashboard:"Go to Dashboard",continuation_disclaimer:"By continuing, you agree to our <terms_of_service>Terms of Service</terms_of_service> and <privacy_policy>Privacy Policy</privacy_policy>."},empty_state:{analytics:{title:"You haven't connected any ad accounts yet",description:"You can connect your ad accounts in minutes and start driving more customers to your business.",button_text:"Setup analytics"}}},Sf=({children:e,language:r,initialLanguage:o})=>(n.useEffect((()=>{o&&ef.changeLanguage(o)}),[o]),n.useEffect((()=>{if(r?.overrides){const e=(e,t)=>{const n=r?.overrides?.[e]?.[t];return n?{..._f,...Object.entries(n).reduce(((e,[t,n])=>({...e,[t]:n})),{})}:_f};Object.keys(r.overrides).forEach((t=>{const n=e(t,"en"),r=e(t,"es");ef.addResourceBundle("en",t,n,!0,!0),ef.addResourceBundle("es",t,r,!0,!0)}))}}),[r?.overrides]),t.jsx(hp,{i18n:ef,children:e}));var Tf={},Cf={},Af="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},Of="1.8.0",Nf=/^(\d+)\.(\d+)\.(\d+)(-(.+))?$/;var Rf=function(e){var t=new Set([e]),n=new Set,r=e.match(Nf);if(!r)return function(){return!1};var o=+r[1],i=+r[2],a=+r[3];if(null!=r[4])return function(t){return t===e};function s(e){return n.add(e),!1}function l(e){return t.add(e),!0}return function(e){if(t.has(e))return!0;if(n.has(e))return!1;var r=e.match(Nf);if(!r)return s(e);var c=+r[2],u=+r[3];return null!=r[4]||o!==+r[1]?s(e):0===o?i===c&&a<=u?l(e):s(e):i<=c?l(e):s(e)}}(Of),Pf=Of.split(".")[0],kf=Symbol.for("opentelemetry.js.api."+Pf),Lf=Af;function Mf(e,t,n,r){var o;void 0===r&&(r=!1);var i=Lf[kf]=null!==(o=Lf[kf])&&void 0!==o?o:{version:Of};if(!r&&i[e]){var a=new Error("@opentelemetry/api: Attempted duplicate registration of API: "+e);return n.error(a.stack||a.message),!1}if(i.version!==Of){a=new Error("@opentelemetry/api: Registration of version v"+i.version+" for "+e+" does not match previously registered API v"+Of);return n.error(a.stack||a.message),!1}return i[e]=t,n.debug("@opentelemetry/api: Registered a global for "+e+" v"+Of+"."),!0}function Df(e){var t,n,r=null===(t=Lf[kf])||void 0===t?void 0:t.version;if(r&&Rf(r))return null===(n=Lf[kf])||void 0===n?void 0:n[e]}function jf(e,t){t.debug("@opentelemetry/api: Unregistering a global for "+e+" v"+Of+".");var n=Lf[kf];n&&delete n[e]}var If,Ff,Uf=function(){function e(e){this._namespace=e.namespace||"DiagComponentLogger"}return e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("debug",this._namespace,e)},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("error",this._namespace,e)},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("info",this._namespace,e)},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("warn",this._namespace,e)},e.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return $f("verbose",this._namespace,e)},e}();function $f(e,t,n){var r=Df("diag");if(r)return n.unshift(t),r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))}(Ff=If||(If={}))[Ff.NONE=0]="NONE",Ff[Ff.ERROR=30]="ERROR",Ff[Ff.WARN=50]="WARN",Ff[Ff.INFO=60]="INFO",Ff[Ff.DEBUG=70]="DEBUG",Ff[Ff.VERBOSE=80]="VERBOSE",Ff[Ff.ALL=9999]="ALL";var Bf=function(){function e(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r=Df("diag");if(r)return r[e].apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(t),!1))}}var t=this;t.setLogger=function(e,n){var r,o,i;if(void 0===n&&(n={logLevel:If.INFO}),e===t){var a=new Error("Cannot use diag as the logger for itself. Please use a DiagLogger implementation like ConsoleDiagLogger or a custom implementation");return t.error(null!==(r=a.stack)&&void 0!==r?r:a.message),!1}"number"==typeof n&&(n={logLevel:n});var s=Df("diag"),l=function(e,t){function n(n,r){var o=t[n];return"function"==typeof o&&e>=r?o.bind(t):function(){}}return e<If.NONE?e=If.NONE:e>If.ALL&&(e=If.ALL),t=t||{},{error:n("error",If.ERROR),warn:n("warn",If.WARN),info:n("info",If.INFO),debug:n("debug",If.DEBUG),verbose:n("verbose",If.VERBOSE)}}(null!==(o=n.logLevel)&&void 0!==o?o:If.INFO,e);if(s&&!n.suppressOverrideMessage){var c=null!==(i=(new Error).stack)&&void 0!==i?i:"<failed to generate stacktrace>";s.warn("Current logger will be overwritten from "+c),l.warn("Current logger will overwrite one already registered from "+c)}return Mf("diag",l,t,!0)},t.disable=function(){jf("diag",t)},t.createComponentLogger=function(e){return new Uf(e)},t.verbose=e("verbose"),t.debug=e("debug"),t.info=e("info"),t.warn=e("warn"),t.error=e("error")}return e.instance=function(){return this._instance||(this._instance=new e),this._instance},e}(),Vf=function(){function e(e){this._entries=e?new Map(e):new Map}return e.prototype.getEntry=function(e){var t=this._entries.get(e);if(t)return Object.assign({},t)},e.prototype.getAllEntries=function(){return Array.from(this._entries.entries()).map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);return[t[0],t[1]]}))},e.prototype.setEntry=function(t,n){var r=new e(this._entries);return r._entries.set(t,n),r},e.prototype.removeEntry=function(t){var n=new e(this._entries);return n._entries.delete(t),n},e.prototype.removeEntries=function(){for(var t,n,r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];var i=new e(this._entries);try{for(var a=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(r),s=a.next();!s.done;s=a.next()){i._entries.delete(s.value)}}catch(l){t={error:l}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(t)throw t.error}}return i},e.prototype.clear=function(){return new e},e}(),qf=Symbol("BaggageEntryMetadata"),zf=Bf.instance();function Hf(e){return void 0===e&&(e={}),new Vf(new Map(Object.entries(e)))}function Gf(e){return"string"!=typeof e&&(zf.error("Cannot create baggage metadata from unknown type: "+typeof e),e=""),{__TYPE__:qf,toString:function(){return e}}}function Kf(e){return Symbol.for(e)}var Wf,Yf,Xf=new(function(){return function e(t){var n=this;n._currentContext=t?new Map(t):new Map,n.getValue=function(e){return n._currentContext.get(e)},n.setValue=function(t,r){var o=new e(n._currentContext);return o._currentContext.set(t,r),o},n.deleteValue=function(t){var r=new e(n._currentContext);return r._currentContext.delete(t),r}}}()),Qf=[{n:"error",c:"error"},{n:"warn",c:"warn"},{n:"info",c:"info"},{n:"debug",c:"debug"},{n:"verbose",c:"trace"}],Zf=function(){return function(){function e(e){return function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];if(console){var r=console[e];if("function"!=typeof r&&(r=console.log),"function"==typeof r)return r.apply(console,t)}}}for(var t=0;t<Qf.length;t++)this[Qf[t].n]=e(Qf[t].c)}}(),Jf=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),eh=function(){function e(){}return e.prototype.createHistogram=function(e,t){return dh},e.prototype.createCounter=function(e,t){return uh},e.prototype.createUpDownCounter=function(e,t){return ph},e.prototype.createObservableGauge=function(e,t){return hh},e.prototype.createObservableCounter=function(e,t){return fh},e.prototype.createObservableUpDownCounter=function(e,t){return mh},e.prototype.addBatchObservableCallback=function(e,t){},e.prototype.removeBatchObservableCallback=function(e){},e}(),th=function(){return function(){}}(),nh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.add=function(e,t){},t}(th),rh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.add=function(e,t){},t}(th),oh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t.prototype.record=function(e,t){},t}(th),ih=function(){function e(){}return e.prototype.addCallback=function(e){},e.prototype.removeCallback=function(e){},e}(),ah=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),sh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),lh=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return Jf(t,e),t}(ih),ch=new eh,uh=new nh,dh=new oh,ph=new rh,fh=new ah,hh=new sh,mh=new lh;(Yf=Wf||(Wf={}))[Yf.INT=0]="INT",Yf[Yf.DOUBLE=1]="DOUBLE";var gh,yh,vh={get:function(e,t){if(null!=e)return e[t]},keys:function(e){return null==e?[]:Object.keys(e)}},bh={set:function(e,t,n){null!=e&&(e[t]=n)}},wh=function(){function e(){}return e.prototype.active=function(){return Xf},e.prototype.with=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];return t.call.apply(t,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(r),!1))},e.prototype.bind=function(e,t){return t},e.prototype.enable=function(){return this},e.prototype.disable=function(){return this},e}(),xh="context",Eh=new wh,_h=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalContextManager=function(e){return Mf(xh,e,Bf.instance())},e.prototype.active=function(){return this._getContextManager().active()},e.prototype.with=function(e,t,n){for(var r,o=[],i=3;i<arguments.length;i++)o[i-3]=arguments[i];return(r=this._getContextManager()).with.apply(r,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([e,t,n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(o),!1))},e.prototype.bind=function(e,t){return this._getContextManager().bind(e,t)},e.prototype._getContextManager=function(){return Df(xh)||Eh},e.prototype.disable=function(){this._getContextManager().disable(),jf(xh,Bf.instance())},e}();(yh=gh||(gh={}))[yh.NONE=0]="NONE",yh[yh.SAMPLED=1]="SAMPLED";var Sh="0000000000000000",Th="00000000000000000000000000000000",Ch={traceId:Th,spanId:Sh,traceFlags:gh.NONE},Ah=function(){function e(e){void 0===e&&(e=Ch),this._spanContext=e}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return this},e.prototype.setAttributes=function(e){return this},e.prototype.addEvent=function(e,t){return this},e.prototype.setStatus=function(e){return this},e.prototype.updateName=function(e){return this},e.prototype.end=function(e){},e.prototype.isRecording=function(){return!1},e.prototype.recordException=function(e,t){},e}(),Oh=Kf("OpenTelemetry Context Key SPAN");function Nh(e){return e.getValue(Oh)||void 0}function Rh(){return Nh(_h.getInstance().active())}function Ph(e,t){return e.setValue(Oh,t)}function kh(e){return e.deleteValue(Oh)}function Lh(e,t){return Ph(e,new Ah(t))}function Mh(e){var t;return null===(t=Nh(e))||void 0===t?void 0:t.spanContext()}var Dh=/^([0-9a-f]{32})$/i,jh=/^[0-9a-f]{16}$/i;function Ih(e){return Dh.test(e)&&e!==Th}function Fh(e){return jh.test(e)&&e!==Sh}function Uh(e){return Ih(e.traceId)&&Fh(e.spanId)}function $h(e){return new Ah(e)}var Bh=_h.getInstance(),Vh=function(){function e(){}return e.prototype.startSpan=function(e,t,n){if(void 0===n&&(n=Bh.active()),Boolean(null==t?void 0:t.root))return new Ah;var r,o=n&&Mh(n);return"object"==typeof(r=o)&&"string"==typeof r.spanId&&"string"==typeof r.traceId&&"number"==typeof r.traceFlags&&Uh(o)?new Ah(o):new Ah},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:Bh.active(),l=this.startSpan(e,o,s),c=Ph(s,l);return Bh.with(c,a,void 0,l)}},e}();var qh,zh,Hh,Gh,Kh,Wh,Yh=new Vh,Xh=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.startSpan=function(e,t,n){return this._getTracer().startSpan(e,t,n)},e.prototype.startActiveSpan=function(e,t,n,r){var o=this._getTracer();return Reflect.apply(o.startActiveSpan,o,arguments)},e.prototype._getTracer=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateTracer(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):Yh},e}(),Qh=new(function(){function e(){}return e.prototype.getTracer=function(e,t,n){return new Vh},e}()),Zh=function(){function e(){}return e.prototype.getTracer=function(e,t,n){var r;return null!==(r=this.getDelegateTracer(e,t,n))&&void 0!==r?r:new Xh(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:Qh},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateTracer=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getTracer(e,t,n)},e}();(zh=qh||(qh={}))[zh.NOT_RECORD=0]="NOT_RECORD",zh[zh.RECORD=1]="RECORD",zh[zh.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED",(Gh=Hh||(Hh={}))[Gh.INTERNAL=0]="INTERNAL",Gh[Gh.SERVER=1]="SERVER",Gh[Gh.CLIENT=2]="CLIENT",Gh[Gh.PRODUCER=3]="PRODUCER",Gh[Gh.CONSUMER=4]="CONSUMER",(Wh=Kh||(Kh={}))[Wh.UNSET=0]="UNSET",Wh[Wh.OK=1]="OK",Wh[Wh.ERROR=2]="ERROR";var Jh="[_0-9a-z-*/]",em=new RegExp("^(?:"+("[a-z]"+Jh+"{0,255}")+"|"+("[a-z0-9]"+Jh+"{0,240}@[a-z]"+Jh+"{0,13}")+")$"),tm=/^[ -~]{0,255}[!-~]$/,nm=/,|=/;var rm=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return em.test(e)})(o)&&function(e){return tm.test(e)&&!nm.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}();var om=_h.getInstance(),im=Bf.instance(),am=new(function(){function e(){}return e.prototype.getMeter=function(e,t,n){return ch},e}()),sm="metrics",lm=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalMeterProvider=function(e){return Mf(sm,e,Bf.instance())},e.prototype.getMeterProvider=function(){return Df(sm)||am},e.prototype.getMeter=function(e,t,n){return this.getMeterProvider().getMeter(e,t,n)},e.prototype.disable=function(){jf(sm,Bf.instance())},e}().getInstance(),cm=function(){function e(){}return e.prototype.inject=function(e,t){},e.prototype.extract=function(e,t){return e},e.prototype.fields=function(){return[]},e}(),um=Kf("OpenTelemetry Baggage Key");function dm(e){return e.getValue(um)||void 0}function pm(){return dm(_h.getInstance().active())}function fm(e,t){return e.setValue(um,t)}function hm(e){return e.deleteValue(um)}var mm="propagation",gm=new cm,ym=function(){function e(){this.createBaggage=Hf,this.getBaggage=dm,this.getActiveBaggage=pm,this.setBaggage=fm,this.deleteBaggage=hm}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalPropagator=function(e){return Mf(mm,e,Bf.instance())},e.prototype.inject=function(e,t,n){return void 0===n&&(n=bh),this._getGlobalPropagator().inject(e,t,n)},e.prototype.extract=function(e,t,n){return void 0===n&&(n=vh),this._getGlobalPropagator().extract(e,t,n)},e.prototype.fields=function(){return this._getGlobalPropagator().fields()},e.prototype.disable=function(){jf(mm,Bf.instance())},e.prototype._getGlobalPropagator=function(){return Df(mm)||gm},e}().getInstance(),vm="trace",bm=function(){function e(){this._proxyTracerProvider=new Zh,this.wrapSpanContext=$h,this.isSpanContextValid=Uh,this.deleteSpan=kh,this.getSpan=Nh,this.getActiveSpan=Rh,this.getSpanContext=Mh,this.setSpan=Ph,this.setSpanContext=Lh}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalTracerProvider=function(e){var t=Mf(vm,this._proxyTracerProvider,Bf.instance());return t&&this._proxyTracerProvider.setDelegate(e),t},e.prototype.getTracerProvider=function(){return Df(vm)||this._proxyTracerProvider},e.prototype.getTracer=function(e,t){return this.getTracerProvider().getTracer(e,t)},e.prototype.disable=function(){jf(vm,Bf.instance()),this._proxyTracerProvider=new Zh},e}().getInstance();const wm={context:om,diag:im,metrics:lm,propagation:ym,trace:bm},xm=Object.freeze(Object.defineProperty({__proto__:null,DiagConsoleLogger:Zf,get DiagLogLevel(){return If},INVALID_SPANID:Sh,INVALID_SPAN_CONTEXT:Ch,INVALID_TRACEID:Th,ProxyTracer:Xh,ProxyTracerProvider:Zh,ROOT_CONTEXT:Xf,get SamplingDecision(){return qh},get SpanKind(){return Hh},get SpanStatusCode(){return Kh},get TraceFlags(){return gh},get ValueType(){return Wf},baggageEntryMetadataFromString:Gf,context:om,createContextKey:Kf,createNoopMeter:function(){return ch},createTraceState:function(e){return new rm(e)},default:wm,defaultTextMapGetter:vh,defaultTextMapSetter:bh,diag:im,isSpanContextValid:Uh,isValidSpanId:Fh,isValidTraceId:Ih,metrics:lm,propagation:ym,trace:bm},Symbol.toStringTag,{value:"Module"}));var Em=function(){function e(){}return e.prototype.emit=function(e){},e}(),_m=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new Em},e}()),Sm="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},Tm=Symbol.for("io.opentelemetry.js.api.logs"),Cm=Sm;var Am=function(){function e(){}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return Cm[Tm]?this.getLoggerProvider():(Cm[Tm]=(t=1,n=e,r=_m,function(e){return e===t?n:r}),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=Cm[Tm])||void 0===e?void 0:e.call(Cm,1))&&void 0!==t?t:_m},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete Cm[Tm]},e}().getInstance();function Om(e){void 0===e&&(e=[]);for(var t=[],n=0,r=e.length;n<r;n++){var o=e[n];if(Array.isArray(o)){var i=Om(o);t=t.concat(i.instrumentations)}else"function"==typeof o?t.push(new o):o.instrumentationName&&t.push(o)}return{instrumentations:t}}function Nm(e){return"function"==typeof e}var Rm=function(){}.bind();function Pm(e,t,n){var r=!!e[t]&&e.propertyIsEnumerable(t);Object.defineProperty(e,t,{configurable:!0,enumerable:r,writable:!0,value:n})}function km(e){e&&e.logger&&(Nm(e.logger)?Rm=e.logger:Rm("new logger isn't a function, not replacing"))}function Lm(e,t,n){if(e&&e[t]){if(!n)return Rm("no wrapper function"),void Rm((new Error).stack);if(Nm(e[t])&&Nm(n)){var r=e[t],o=n(r,t);return Pm(o,"__original",r),Pm(o,"__unwrap",(function(){e[t]===o&&Pm(e,t,r)})),Pm(o,"__wrapped",!0),Pm(e,t,o),o}Rm("original object and wrapper must be functions")}else Rm("no original function "+t+" to wrap")}function Mm(e,t){return e&&e[t]?e[t].__unwrap?e[t].__unwrap():void Rm("no original to unwrap to -- has "+t+" already been unwrapped?"):(Rm("no function to unwrap."),void Rm((new Error).stack))}km.wrap=Lm,km.massWrap=function(e,t,n){if(!e)return Rm("must provide one or more modules to patch"),void Rm((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){Lm(e,t,n)}))})):Rm("must provide one or more functions to wrap on modules")},km.unwrap=Mm,km.massUnwrap=function(e,t){if(!e)return Rm("must provide one or more modules to patch"),void Rm((new Error).stack);Array.isArray(e)||(e=[e]),t&&Array.isArray(t)?e.forEach((function(e){t.forEach((function(t){Mm(e,t)}))})):Rm("must provide one or more functions to unwrap on modules")};var Dm=km,jm=function(){return jm=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},jm.apply(this,arguments)},Im=function(){function e(e,t,n){void 0===n&&(n={}),this.instrumentationName=e,this.instrumentationVersion=t,this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this._config=jm({enabled:!0},n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=Am.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){void 0===e&&(e={}),this._config=Object.assign({},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e}(),Fm=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Um=function(e){function t(t,n,r){void 0===r&&(r={});var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return Fm(t,e),t}(Im);var $m=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},Bm=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};const Vm=Object.freeze(Object.defineProperty({__proto__:null,InstrumentationBase:Um,InstrumentationNodeModuleDefinition:function(){return function(e,t,n,r,o){this.name=e,this.supportedVersions=t,this.patch=n,this.unpatch=r,this.files=o||[]}}(),InstrumentationNodeModuleFile:function(){return function(e,t,n,r){var o;this.supportedVersions=t,this.patch=n,this.unpatch=r,this.name=(o=e,im.warn("Path normalization is not implemented for this platform. To silence this warning, ensure no node-specific instrumentations are loaded, and node-specific types (e.g. InstrumentationNodeModuleFile), are not used in a browser context)"),o)}}(),isWrapped:function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped},registerInstrumentations:function(e){var t=Om(e.instrumentations).instrumentations,n=e.tracerProvider||bm.getTracerProvider(),r=e.meterProvider||lm.getMeterProvider(),o=e.loggerProvider||Am.getLoggerProvider();return function(e,t,n,r){for(var o=0,i=e.length;o<i;o++){var a=e[o];t&&a.setTracerProvider(t),n&&a.setMeterProvider(n),r&&a.setLoggerProvider&&a.setLoggerProvider(r),a.getConfig().enabled||a.enable()}}(t,n,r,o),function(){!function(e){e.forEach((function(e){return e.disable()}))}(t)}},safeExecuteInTheMiddle:function(e,t,n){var r,o;try{o=e()}catch(tme){r=tme}finally{if(t(r,o),r&&!n)throw r;return o}},safeExecuteInTheMiddleAsync:function(e,t,n){return $m(this,void 0,void 0,(function(){var r,o,i;return Bm(this,(function(a){switch(a.label){case 0:return a.trys.push([0,2,3,4]),[4,e()];case 1:return o=a.sent(),[3,4];case 2:return i=a.sent(),r=i,[3,4];case 3:if(t(r,o),r&&!n)throw r;return[2,o];case 4:return[2]}}))}))}},Symbol.toStringTag,{value:"Module"})),qm=za(Vm);function zm(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}var Hm="aws.lambda.invoked_arn",Gm="db.system",Km="db.connection_string",Wm="db.user",Ym="db.jdbc.driver_classname",Xm="db.name",Qm="db.statement",Zm="db.operation",Jm="db.mssql.instance_name",eg="db.cassandra.keyspace",tg="db.cassandra.page_size",ng="db.cassandra.consistency_level",rg="db.cassandra.table",og="db.cassandra.idempotence",ig="db.cassandra.speculative_execution_count",ag="db.cassandra.coordinator.id",sg="db.cassandra.coordinator.dc",lg="db.hbase.namespace",cg="db.redis.database_index",ug="db.mongodb.collection",dg="db.sql.table",pg="exception.type",fg="exception.message",hg="exception.stacktrace",mg="exception.escaped",gg="faas.trigger",yg="faas.execution",vg="faas.document.collection",bg="faas.document.operation",wg="faas.document.time",xg="faas.document.name",Eg="faas.time",_g="faas.cron",Sg="faas.coldstart",Tg="faas.invoked_name",Cg="faas.invoked_provider",Ag="faas.invoked_region",Og="net.transport",Ng="net.peer.ip",Rg="net.peer.port",Pg="net.peer.name",kg="net.host.ip",Lg="net.host.port",Mg="net.host.name",Dg="net.host.connection.type",jg="net.host.connection.subtype",Ig="net.host.carrier.name",Fg="net.host.carrier.mcc",Ug="net.host.carrier.mnc",$g="net.host.carrier.icc",Bg="peer.service",Vg="enduser.id",qg="enduser.role",zg="enduser.scope",Hg="thread.id",Gg="thread.name",Kg="code.function",Wg="code.namespace",Yg="code.filepath",Xg="code.lineno",Qg="http.method",Zg="http.url",Jg="http.target",ey="http.host",ty="http.scheme",ny="http.status_code",ry="http.flavor",oy="http.user_agent",iy="http.request_content_length",ay="http.request_content_length_uncompressed",sy="http.response_content_length",ly="http.response_content_length_uncompressed",cy="http.server_name",uy="http.route",dy="http.client_ip",py="aws.dynamodb.table_names",fy="aws.dynamodb.consumed_capacity",hy="aws.dynamodb.item_collection_metrics",my="aws.dynamodb.provisioned_read_capacity",gy="aws.dynamodb.provisioned_write_capacity",yy="aws.dynamodb.consistent_read",vy="aws.dynamodb.projection",by="aws.dynamodb.limit",wy="aws.dynamodb.attributes_to_get",xy="aws.dynamodb.index_name",Ey="aws.dynamodb.select",_y="aws.dynamodb.global_secondary_indexes",Sy="aws.dynamodb.local_secondary_indexes",Ty="aws.dynamodb.exclusive_start_table",Cy="aws.dynamodb.table_count",Ay="aws.dynamodb.scan_forward",Oy="aws.dynamodb.segment",Ny="aws.dynamodb.total_segments",Ry="aws.dynamodb.count",Py="aws.dynamodb.scanned_count",ky="aws.dynamodb.attribute_definitions",Ly="aws.dynamodb.global_secondary_index_updates",My="messaging.system",Dy="messaging.destination",jy="messaging.destination_kind",Iy="messaging.temp_destination",Fy="messaging.protocol",Uy="messaging.protocol_version",$y="messaging.url",By="messaging.message_id",Vy="messaging.conversation_id",qy="messaging.message_payload_size_bytes",zy="messaging.message_payload_compressed_size_bytes",Hy="messaging.operation",Gy="messaging.consumer_id",Ky="messaging.rabbitmq.routing_key",Wy="messaging.kafka.message_key",Yy="messaging.kafka.consumer_group",Xy="messaging.kafka.client_id",Qy="messaging.kafka.partition",Zy="messaging.kafka.tombstone",Jy="rpc.system",ev="rpc.service",tv="rpc.method",nv="rpc.grpc.status_code",rv="rpc.jsonrpc.version",ov="rpc.jsonrpc.request_id",iv="rpc.jsonrpc.error_code",av="rpc.jsonrpc.error_message",sv="message.type",lv="message.id",cv="message.compressed_size",uv="message.uncompressed_size",dv=Hm,pv=Gm,fv=Km,hv=Wm,mv=Ym,gv=Xm,yv=Qm,vv=Zm,bv=Jm,wv=eg,xv=tg,Ev=ng,_v=rg,Sv=og,Tv=ig,Cv=ag,Av=sg,Ov=lg,Nv=cg,Rv=ug,Pv=dg,kv=pg,Lv=fg,Mv=hg,Dv=mg,jv=gg,Iv=yg,Fv=vg,Uv=bg,$v=wg,Bv=xg,Vv=Eg,qv=_g,zv=Sg,Hv=Tg,Gv=Cg,Kv=Ag,Wv=Og,Yv=Ng,Xv=Rg,Qv=Pg,Zv=kg,Jv=Lg,eb=Mg,tb=Dg,nb=jg,rb=Ig,ob=Fg,ib=Ug,ab=$g,sb=Bg,lb=Vg,cb=qg,ub=zg,db=Hg,pb=Gg,fb=Kg,hb=Wg,mb=Yg,gb=Xg,yb=Qg,vb=Zg,bb=Jg,wb=ey,xb=ty,Eb=ny,_b=ry,Sb=oy,Tb=iy,Cb=ay,Ab=sy,Ob=ly,Nb=cy,Rb=uy,Pb=dy,kb=py,Lb=fy,Mb=hy,Db=my,jb=gy,Ib=yy,Fb=vy,Ub=by,$b=wy,Bb=xy,Vb=Ey,qb=_y,zb=Sy,Hb=Ty,Gb=Cy,Kb=Ay,Wb=Oy,Yb=Ny,Xb=Ry,Qb=Py,Zb=ky,Jb=Ly,ew=My,tw=Dy,nw=jy,rw=Iy,ow=Fy,iw=Uy,aw=$y,sw=By,lw=Vy,cw=qy,uw=zy,dw=Hy,pw=Gy,fw=Ky,hw=Wy,mw=Yy,gw=Xy,yw=Qy,vw=Zy,bw=Jy,ww=ev,xw=tv,Ew=nv,_w=rv,Sw=ov,Tw=iv,Cw=av,Aw=sv,Ow=lv,Nw=cv,Rw=uv,Pw=zm([Hm,Gm,Km,Wm,Ym,Xm,Qm,Zm,Jm,eg,tg,ng,rg,og,ig,ag,sg,lg,cg,ug,dg,pg,fg,hg,mg,gg,yg,vg,bg,wg,xg,Eg,_g,Sg,Tg,Cg,Ag,Og,Ng,Rg,Pg,kg,Lg,Mg,Dg,jg,Ig,Fg,Ug,$g,Bg,Vg,qg,zg,Hg,Gg,Kg,Wg,Yg,Xg,Qg,Zg,Jg,ey,ty,ny,ry,oy,iy,ay,sy,ly,cy,uy,dy,py,fy,hy,my,gy,yy,vy,by,wy,xy,Ey,_y,Sy,Ty,Cy,Ay,Oy,Ny,Ry,Py,ky,Ly,My,Dy,jy,Iy,Fy,Uy,$y,By,Vy,qy,zy,Hy,Gy,Ky,Wy,Yy,Xy,Qy,Zy,Jy,ev,tv,nv,rv,ov,iv,av,sv,lv,cv,uv]),kw="other_sql",Lw="mssql",Mw="mysql",Dw="oracle",jw="postgresql",Iw="redshift",Fw="hive",Uw="cloudscape",$w="hsqldb",Bw="progress",Vw="maxdb",qw="hanadb",zw="ingres",Hw="firstsql",Gw="cache",Kw="adabas",Ww="firebird",Yw="derby",Xw="filemaker",Qw="informix",Zw="instantdb",Jw="interbase",ex="mariadb",tx="netezza",nx="pervasive",rx="pointbase",ox="sqlite",ix="sybase",ax="teradata",sx="vertica",lx="coldfusion",cx="cassandra",ux="hbase",dx="mongodb",px="redis",fx="couchbase",hx="couchdb",mx="cosmosdb",gx="dynamodb",yx="neo4j",vx="geode",bx="elasticsearch",wx="memcached",xx="cockroachdb",Ex=kw,_x=Lw,Sx=Mw,Tx=Dw,Cx=jw,Ax=Iw,Ox=Fw,Nx=Uw,Rx=$w,Px=Bw,kx=Vw,Lx=qw,Mx=zw,Dx=Hw,jx=Gw,Ix=Kw,Fx=Ww,Ux=Yw,$x=Xw,Bx=Qw,Vx=Zw,qx=Jw,zx=ex,Hx=tx,Gx=nx,Kx=rx,Wx=ox,Yx=ix,Xx=ax,Qx=sx,Zx=lx,Jx=cx,eE=ux,tE=dx,nE=px,rE=fx,oE=hx,iE=mx,aE=gx,sE=yx,lE=vx,cE=bx,uE=wx,dE=xx,pE=zm([kw,Lw,Mw,Dw,"db2",jw,Iw,Fw,Uw,$w,Bw,Vw,qw,zw,Hw,"edb",Gw,Kw,Ww,Yw,Xw,Qw,Zw,Jw,ex,tx,nx,rx,ox,ix,ax,sx,"h2",lx,cx,ux,dx,px,fx,hx,mx,gx,yx,vx,bx,wx,xx]),fE="each_quorum",hE="quorum",mE="local_quorum",gE="three",yE="local_one",vE="serial",bE="local_serial",wE=fE,xE=hE,EE=mE,_E=gE,SE=yE,TE=vE,CE=bE,AE=zm(["all",fE,hE,mE,"one","two",gE,yE,"any",vE,bE]),OE="datasource",NE="http",RE="pubsub",PE="timer",kE="other",LE=OE,ME=NE,DE=RE,jE=PE,IE=kE,FE=zm([OE,NE,RE,PE,kE]),UE="insert",$E="edit",BE="delete",VE=UE,qE=$E,zE=BE,HE=zm([UE,$E,BE]),GE="alibaba_cloud",KE="azure",WE=GE,YE=KE,XE=zm([GE,"aws",KE,"gcp"]),QE="ip_tcp",ZE="ip_udp",JE="unix",e_="pipe",t_="inproc",n_="other",r_=QE,o_=ZE,i_=JE,a_=e_,s_=t_,l_=n_,c_=zm([QE,ZE,"ip",JE,e_,t_,n_]),u_="wifi",d_="wired",p_="cell",f_="unavailable",h_="unknown",m_=u_,g_=d_,y_=p_,v_=f_,b_=h_,w_=zm([u_,d_,p_,f_,h_]),x_="gprs",E_="edge",__="umts",S_="cdma",T_="evdo_0",C_="evdo_a",A_="cdma2000_1xrtt",O_="hsdpa",N_="hsupa",R_="hspa",P_="iden",k_="evdo_b",L_="ehrpd",M_="hspap",D_="td_scdma",j_="iwlan",I_="nrnsa",F_="lte_ca",U_=x_,$_=E_,B_=__,V_=S_,q_=T_,z_=C_,H_=A_,G_=O_,K_=N_,W_=R_,Y_=P_,X_=k_,Q_=L_,Z_=M_,J_=D_,eS=j_,tS=I_,nS=F_,rS=zm([x_,E_,__,S_,T_,C_,A_,O_,N_,R_,P_,k_,"lte",L_,M_,"gsm",D_,j_,"nr",I_,F_]),oS="SPDY",iS="QUIC",aS=oS,sS=iS,lS={HTTP_1_0:"1.0",HTTP_1_1:"1.1",HTTP_2_0:"2.0",SPDY:oS,QUIC:iS},cS="queue",uS="topic",dS=cS,pS=uS,fS=zm([cS,uS]),hS="receive",mS="process",gS=hS,yS=mS,vS=zm([hS,mS]),bS={OK:0,CANCELLED:1,UNKNOWN:2,INVALID_ARGUMENT:3,DEADLINE_EXCEEDED:4,NOT_FOUND:5,ALREADY_EXISTS:6,PERMISSION_DENIED:7,RESOURCE_EXHAUSTED:8,FAILED_PRECONDITION:9,ABORTED:10,OUT_OF_RANGE:11,UNIMPLEMENTED:12,INTERNAL:13,UNAVAILABLE:14,DATA_LOSS:15,UNAUTHENTICATED:16},wS="SENT",xS="RECEIVED",ES=wS,_S=xS,SS=zm([wS,xS]),TS="cloud.provider",CS="cloud.account.id",AS="cloud.region",OS="cloud.availability_zone",NS="cloud.platform",RS="aws.ecs.container.arn",PS="aws.ecs.cluster.arn",kS="aws.ecs.launchtype",LS="aws.ecs.task.arn",MS="aws.ecs.task.family",DS="aws.ecs.task.revision",jS="aws.eks.cluster.arn",IS="aws.log.group.names",FS="aws.log.group.arns",US="aws.log.stream.names",$S="aws.log.stream.arns",BS="container.name",VS="container.id",qS="container.runtime",zS="container.image.name",HS="container.image.tag",GS="deployment.environment",KS="device.id",WS="device.model.identifier",YS="device.model.name",XS="faas.name",QS="faas.id",ZS="faas.version",JS="faas.instance",eT="faas.max_memory",tT="host.id",nT="host.name",rT="host.type",oT="host.arch",iT="host.image.name",aT="host.image.id",sT="host.image.version",lT="k8s.cluster.name",cT="k8s.node.name",uT="k8s.node.uid",dT="k8s.namespace.name",pT="k8s.pod.uid",fT="k8s.pod.name",hT="k8s.container.name",mT="k8s.replicaset.uid",gT="k8s.replicaset.name",yT="k8s.deployment.uid",vT="k8s.deployment.name",bT="k8s.statefulset.uid",wT="k8s.statefulset.name",xT="k8s.daemonset.uid",ET="k8s.daemonset.name",_T="k8s.job.uid",ST="k8s.job.name",TT="k8s.cronjob.uid",CT="k8s.cronjob.name",AT="os.type",OT="os.description",NT="os.name",RT="os.version",PT="process.pid",kT="process.executable.name",LT="process.executable.path",MT="process.command",DT="process.command_line",jT="process.command_args",IT="process.owner",FT="process.runtime.name",UT="process.runtime.version",$T="process.runtime.description",BT="service.name",VT="service.namespace",qT="service.instance.id",zT="service.version",HT="telemetry.sdk.name",GT="telemetry.sdk.language",KT="telemetry.sdk.version",WT="telemetry.auto.version",YT="webengine.name",XT="webengine.version",QT="webengine.description",ZT=TS,JT=CS,eC=AS,tC=OS,nC=NS,rC=RS,oC=PS,iC=kS,aC=LS,sC=MS,lC=DS,cC=jS,uC=IS,dC=FS,pC=US,fC=$S,hC=BS,mC=VS,gC=qS,yC=zS,vC=HS,bC=GS,wC=KS,xC=WS,EC=YS,_C=XS,SC=QS,TC=ZS,CC=JS,AC=eT,OC=tT,NC=nT,RC=rT,PC=oT,kC=iT,LC=aT,MC=sT,DC=lT,jC=cT,IC=uT,FC=dT,UC=pT,$C=fT,BC=hT,VC=mT,qC=gT,zC=yT,HC=vT,GC=bT,KC=wT,WC=xT,YC=ET,XC=_T,QC=ST,ZC=TT,JC=CT,eA=AT,tA=OT,nA=NT,rA=RT,oA=PT,iA=kT,aA=LT,sA=MT,lA=DT,cA=jT,uA=IT,dA=FT,pA=UT,fA=$T,hA=BT,mA=VT,gA=qT,yA=zT,vA=HT,bA=GT,wA=KT,xA=WT,EA=YT,_A=XT,SA=QT,TA=zm([TS,CS,AS,OS,NS,RS,PS,kS,LS,MS,DS,jS,IS,FS,US,$S,BS,VS,qS,zS,HS,GS,KS,WS,YS,XS,QS,ZS,JS,eT,tT,nT,rT,oT,iT,aT,sT,lT,cT,uT,dT,pT,fT,hT,mT,gT,yT,vT,bT,wT,xT,ET,_T,ST,TT,CT,AT,OT,NT,RT,PT,kT,LT,MT,DT,jT,IT,FT,UT,$T,BT,VT,qT,zT,HT,GT,KT,WT,YT,XT,QT]),CA="alibaba_cloud",AA="azure",OA=CA,NA=AA,RA=zm([CA,"aws",AA,"gcp"]),PA="alibaba_cloud_ecs",kA="alibaba_cloud_fc",LA="aws_ec2",MA="aws_ecs",DA="aws_eks",jA="aws_lambda",IA="aws_elastic_beanstalk",FA="azure_vm",UA="azure_container_instances",$A="azure_aks",BA="azure_functions",VA="azure_app_service",qA="gcp_compute_engine",zA="gcp_cloud_run",HA="gcp_kubernetes_engine",GA="gcp_cloud_functions",KA="gcp_app_engine",WA=PA,YA=kA,XA=LA,QA=MA,ZA=DA,JA=jA,eO=IA,tO=FA,nO=UA,rO=$A,oO=BA,iO=VA,aO=qA,sO=zA,lO=HA,cO=GA,uO=KA,dO=zm([PA,kA,LA,MA,DA,jA,IA,FA,UA,$A,BA,VA,qA,zA,HA,GA,KA]),pO="fargate",fO=pO,hO=zm(["ec2",pO]),mO="amd64",gO="arm32",yO="arm64",vO="ia64",bO="ppc32",wO="ppc64",xO=mO,EO=gO,_O=yO,SO=vO,TO=bO,CO=wO,AO=zm([mO,gO,yO,vO,bO,wO,"x86"]),OO="windows",NO="linux",RO="darwin",PO="freebsd",kO="netbsd",LO="openbsd",MO="dragonflybsd",DO="hpux",jO="solaris",IO="z_os",FO=OO,UO=NO,$O=RO,BO=PO,VO=kO,qO=LO,zO=MO,HO=DO,GO=jO,KO=IO,WO=zm([OO,NO,RO,PO,kO,LO,MO,DO,"aix",jO,IO]),YO="dotnet",XO="erlang",QO="java",ZO="nodejs",JO="python",eN="ruby",tN="webjs",nN=YO,rN=XO,oN=QO,iN=ZO,aN=JO,sN=eN,lN=tN,cN=zm(["cpp",YO,XO,"go",QO,ZO,"php",JO,eN,tN]);const uN=Object.freeze(Object.defineProperty({__proto__:null,AWSECSLAUNCHTYPEVALUES_EC2:"ec2",AWSECSLAUNCHTYPEVALUES_FARGATE:fO,AwsEcsLaunchtypeValues:hO,CLOUDPLATFORMVALUES_ALIBABA_CLOUD_ECS:WA,CLOUDPLATFORMVALUES_ALIBABA_CLOUD_FC:YA,CLOUDPLATFORMVALUES_AWS_EC2:XA,CLOUDPLATFORMVALUES_AWS_ECS:QA,CLOUDPLATFORMVALUES_AWS_EKS:ZA,CLOUDPLATFORMVALUES_AWS_ELASTIC_BEANSTALK:eO,CLOUDPLATFORMVALUES_AWS_LAMBDA:JA,CLOUDPLATFORMVALUES_AZURE_AKS:rO,CLOUDPLATFORMVALUES_AZURE_APP_SERVICE:iO,CLOUDPLATFORMVALUES_AZURE_CONTAINER_INSTANCES:nO,CLOUDPLATFORMVALUES_AZURE_FUNCTIONS:oO,CLOUDPLATFORMVALUES_AZURE_VM:tO,CLOUDPLATFORMVALUES_GCP_APP_ENGINE:uO,CLOUDPLATFORMVALUES_GCP_CLOUD_FUNCTIONS:cO,CLOUDPLATFORMVALUES_GCP_CLOUD_RUN:sO,CLOUDPLATFORMVALUES_GCP_COMPUTE_ENGINE:aO,CLOUDPLATFORMVALUES_GCP_KUBERNETES_ENGINE:lO,CLOUDPROVIDERVALUES_ALIBABA_CLOUD:OA,CLOUDPROVIDERVALUES_AWS:"aws",CLOUDPROVIDERVALUES_AZURE:NA,CLOUDPROVIDERVALUES_GCP:"gcp",CloudPlatformValues:dO,CloudProviderValues:RA,DBCASSANDRACONSISTENCYLEVELVALUES_ALL:"all",DBCASSANDRACONSISTENCYLEVELVALUES_ANY:"any",DBCASSANDRACONSISTENCYLEVELVALUES_EACH_QUORUM:wE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_ONE:SE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_QUORUM:EE,DBCASSANDRACONSISTENCYLEVELVALUES_LOCAL_SERIAL:CE,DBCASSANDRACONSISTENCYLEVELVALUES_ONE:"one",DBCASSANDRACONSISTENCYLEVELVALUES_QUORUM:xE,DBCASSANDRACONSISTENCYLEVELVALUES_SERIAL:TE,DBCASSANDRACONSISTENCYLEVELVALUES_THREE:_E,DBCASSANDRACONSISTENCYLEVELVALUES_TWO:"two",DBSYSTEMVALUES_ADABAS:Ix,DBSYSTEMVALUES_CACHE:jx,DBSYSTEMVALUES_CASSANDRA:Jx,DBSYSTEMVALUES_CLOUDSCAPE:Nx,DBSYSTEMVALUES_COCKROACHDB:dE,DBSYSTEMVALUES_COLDFUSION:Zx,DBSYSTEMVALUES_COSMOSDB:iE,DBSYSTEMVALUES_COUCHBASE:rE,DBSYSTEMVALUES_COUCHDB:oE,DBSYSTEMVALUES_DB2:"db2",DBSYSTEMVALUES_DERBY:Ux,DBSYSTEMVALUES_DYNAMODB:aE,DBSYSTEMVALUES_EDB:"edb",DBSYSTEMVALUES_ELASTICSEARCH:cE,DBSYSTEMVALUES_FILEMAKER:$x,DBSYSTEMVALUES_FIREBIRD:Fx,DBSYSTEMVALUES_FIRSTSQL:Dx,DBSYSTEMVALUES_GEODE:lE,DBSYSTEMVALUES_H2:"h2",DBSYSTEMVALUES_HANADB:Lx,DBSYSTEMVALUES_HBASE:eE,DBSYSTEMVALUES_HIVE:Ox,DBSYSTEMVALUES_HSQLDB:Rx,DBSYSTEMVALUES_INFORMIX:Bx,DBSYSTEMVALUES_INGRES:Mx,DBSYSTEMVALUES_INSTANTDB:Vx,DBSYSTEMVALUES_INTERBASE:qx,DBSYSTEMVALUES_MARIADB:zx,DBSYSTEMVALUES_MAXDB:kx,DBSYSTEMVALUES_MEMCACHED:uE,DBSYSTEMVALUES_MONGODB:tE,DBSYSTEMVALUES_MSSQL:_x,DBSYSTEMVALUES_MYSQL:Sx,DBSYSTEMVALUES_NEO4J:sE,DBSYSTEMVALUES_NETEZZA:Hx,DBSYSTEMVALUES_ORACLE:Tx,DBSYSTEMVALUES_OTHER_SQL:Ex,DBSYSTEMVALUES_PERVASIVE:Gx,DBSYSTEMVALUES_POINTBASE:Kx,DBSYSTEMVALUES_POSTGRESQL:Cx,DBSYSTEMVALUES_PROGRESS:Px,DBSYSTEMVALUES_REDIS:nE,DBSYSTEMVALUES_REDSHIFT:Ax,DBSYSTEMVALUES_SQLITE:Wx,DBSYSTEMVALUES_SYBASE:Yx,DBSYSTEMVALUES_TERADATA:Xx,DBSYSTEMVALUES_VERTICA:Qx,DbCassandraConsistencyLevelValues:AE,DbSystemValues:pE,FAASDOCUMENTOPERATIONVALUES_DELETE:zE,FAASDOCUMENTOPERATIONVALUES_EDIT:qE,FAASDOCUMENTOPERATIONVALUES_INSERT:VE,FAASINVOKEDPROVIDERVALUES_ALIBABA_CLOUD:WE,FAASINVOKEDPROVIDERVALUES_AWS:"aws",FAASINVOKEDPROVIDERVALUES_AZURE:YE,FAASINVOKEDPROVIDERVALUES_GCP:"gcp",FAASTRIGGERVALUES_DATASOURCE:LE,FAASTRIGGERVALUES_HTTP:ME,FAASTRIGGERVALUES_OTHER:IE,FAASTRIGGERVALUES_PUBSUB:DE,FAASTRIGGERVALUES_TIMER:jE,FaasDocumentOperationValues:HE,FaasInvokedProviderValues:XE,FaasTriggerValues:FE,HOSTARCHVALUES_AMD64:xO,HOSTARCHVALUES_ARM32:EO,HOSTARCHVALUES_ARM64:_O,HOSTARCHVALUES_IA64:SO,HOSTARCHVALUES_PPC32:TO,HOSTARCHVALUES_PPC64:CO,HOSTARCHVALUES_X86:"x86",HTTPFLAVORVALUES_HTTP_1_0:"1.0",HTTPFLAVORVALUES_HTTP_1_1:"1.1",HTTPFLAVORVALUES_HTTP_2_0:"2.0",HTTPFLAVORVALUES_QUIC:sS,HTTPFLAVORVALUES_SPDY:aS,HostArchValues:AO,HttpFlavorValues:lS,MESSAGETYPEVALUES_RECEIVED:_S,MESSAGETYPEVALUES_SENT:ES,MESSAGINGDESTINATIONKINDVALUES_QUEUE:dS,MESSAGINGDESTINATIONKINDVALUES_TOPIC:pS,MESSAGINGOPERATIONVALUES_PROCESS:yS,MESSAGINGOPERATIONVALUES_RECEIVE:gS,MessageTypeValues:SS,MessagingDestinationKindValues:fS,MessagingOperationValues:vS,NETHOSTCONNECTIONSUBTYPEVALUES_CDMA:V_,NETHOSTCONNECTIONSUBTYPEVALUES_CDMA2000_1XRTT:H_,NETHOSTCONNECTIONSUBTYPEVALUES_EDGE:$_,NETHOSTCONNECTIONSUBTYPEVALUES_EHRPD:Q_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_0:q_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_A:z_,NETHOSTCONNECTIONSUBTYPEVALUES_EVDO_B:X_,NETHOSTCONNECTIONSUBTYPEVALUES_GPRS:U_,NETHOSTCONNECTIONSUBTYPEVALUES_GSM:"gsm",NETHOSTCONNECTIONSUBTYPEVALUES_HSDPA:G_,NETHOSTCONNECTIONSUBTYPEVALUES_HSPA:W_,NETHOSTCONNECTIONSUBTYPEVALUES_HSPAP:Z_,NETHOSTCONNECTIONSUBTYPEVALUES_HSUPA:K_,NETHOSTCONNECTIONSUBTYPEVALUES_IDEN:Y_,NETHOSTCONNECTIONSUBTYPEVALUES_IWLAN:eS,NETHOSTCONNECTIONSUBTYPEVALUES_LTE:"lte",NETHOSTCONNECTIONSUBTYPEVALUES_LTE_CA:nS,NETHOSTCONNECTIONSUBTYPEVALUES_NR:"nr",NETHOSTCONNECTIONSUBTYPEVALUES_NRNSA:tS,NETHOSTCONNECTIONSUBTYPEVALUES_TD_SCDMA:J_,NETHOSTCONNECTIONSUBTYPEVALUES_UMTS:B_,NETHOSTCONNECTIONTYPEVALUES_CELL:y_,NETHOSTCONNECTIONTYPEVALUES_UNAVAILABLE:v_,NETHOSTCONNECTIONTYPEVALUES_UNKNOWN:b_,NETHOSTCONNECTIONTYPEVALUES_WIFI:m_,NETHOSTCONNECTIONTYPEVALUES_WIRED:g_,NETTRANSPORTVALUES_INPROC:s_,NETTRANSPORTVALUES_IP:"ip",NETTRANSPORTVALUES_IP_TCP:r_,NETTRANSPORTVALUES_IP_UDP:o_,NETTRANSPORTVALUES_OTHER:l_,NETTRANSPORTVALUES_PIPE:a_,NETTRANSPORTVALUES_UNIX:i_,NetHostConnectionSubtypeValues:rS,NetHostConnectionTypeValues:w_,NetTransportValues:c_,OSTYPEVALUES_AIX:"aix",OSTYPEVALUES_DARWIN:$O,OSTYPEVALUES_DRAGONFLYBSD:zO,OSTYPEVALUES_FREEBSD:BO,OSTYPEVALUES_HPUX:HO,OSTYPEVALUES_LINUX:UO,OSTYPEVALUES_NETBSD:VO,OSTYPEVALUES_OPENBSD:qO,OSTYPEVALUES_SOLARIS:GO,OSTYPEVALUES_WINDOWS:FO,OSTYPEVALUES_Z_OS:KO,OsTypeValues:WO,RPCGRPCSTATUSCODEVALUES_ABORTED:10,RPCGRPCSTATUSCODEVALUES_ALREADY_EXISTS:6,RPCGRPCSTATUSCODEVALUES_CANCELLED:1,RPCGRPCSTATUSCODEVALUES_DATA_LOSS:15,RPCGRPCSTATUSCODEVALUES_DEADLINE_EXCEEDED:4,RPCGRPCSTATUSCODEVALUES_FAILED_PRECONDITION:9,RPCGRPCSTATUSCODEVALUES_INTERNAL:13,RPCGRPCSTATUSCODEVALUES_INVALID_ARGUMENT:3,RPCGRPCSTATUSCODEVALUES_NOT_FOUND:5,RPCGRPCSTATUSCODEVALUES_OK:0,RPCGRPCSTATUSCODEVALUES_OUT_OF_RANGE:11,RPCGRPCSTATUSCODEVALUES_PERMISSION_DENIED:7,RPCGRPCSTATUSCODEVALUES_RESOURCE_EXHAUSTED:8,RPCGRPCSTATUSCODEVALUES_UNAUTHENTICATED:16,RPCGRPCSTATUSCODEVALUES_UNAVAILABLE:14,RPCGRPCSTATUSCODEVALUES_UNIMPLEMENTED:12,RPCGRPCSTATUSCODEVALUES_UNKNOWN:2,RpcGrpcStatusCodeValues:bS,SEMATTRS_AWS_DYNAMODB_ATTRIBUTES_TO_GET:$b,SEMATTRS_AWS_DYNAMODB_ATTRIBUTE_DEFINITIONS:Zb,SEMATTRS_AWS_DYNAMODB_CONSISTENT_READ:Ib,SEMATTRS_AWS_DYNAMODB_CONSUMED_CAPACITY:Lb,SEMATTRS_AWS_DYNAMODB_COUNT:Xb,SEMATTRS_AWS_DYNAMODB_EXCLUSIVE_START_TABLE:Hb,SEMATTRS_AWS_DYNAMODB_GLOBAL_SECONDARY_INDEXES:qb,SEMATTRS_AWS_DYNAMODB_GLOBAL_SECONDARY_INDEX_UPDATES:Jb,SEMATTRS_AWS_DYNAMODB_INDEX_NAME:Bb,SEMATTRS_AWS_DYNAMODB_ITEM_COLLECTION_METRICS:Mb,SEMATTRS_AWS_DYNAMODB_LIMIT:Ub,SEMATTRS_AWS_DYNAMODB_LOCAL_SECONDARY_INDEXES:zb,SEMATTRS_AWS_DYNAMODB_PROJECTION:Fb,SEMATTRS_AWS_DYNAMODB_PROVISIONED_READ_CAPACITY:Db,SEMATTRS_AWS_DYNAMODB_PROVISIONED_WRITE_CAPACITY:jb,SEMATTRS_AWS_DYNAMODB_SCANNED_COUNT:Qb,SEMATTRS_AWS_DYNAMODB_SCAN_FORWARD:Kb,SEMATTRS_AWS_DYNAMODB_SEGMENT:Wb,SEMATTRS_AWS_DYNAMODB_SELECT:Vb,SEMATTRS_AWS_DYNAMODB_TABLE_COUNT:Gb,SEMATTRS_AWS_DYNAMODB_TABLE_NAMES:kb,SEMATTRS_AWS_DYNAMODB_TOTAL_SEGMENTS:Yb,SEMATTRS_AWS_LAMBDA_INVOKED_ARN:dv,SEMATTRS_CODE_FILEPATH:mb,SEMATTRS_CODE_FUNCTION:fb,SEMATTRS_CODE_LINENO:gb,SEMATTRS_CODE_NAMESPACE:hb,SEMATTRS_DB_CASSANDRA_CONSISTENCY_LEVEL:Ev,SEMATTRS_DB_CASSANDRA_COORDINATOR_DC:Av,SEMATTRS_DB_CASSANDRA_COORDINATOR_ID:Cv,SEMATTRS_DB_CASSANDRA_IDEMPOTENCE:Sv,SEMATTRS_DB_CASSANDRA_KEYSPACE:wv,SEMATTRS_DB_CASSANDRA_PAGE_SIZE:xv,SEMATTRS_DB_CASSANDRA_SPECULATIVE_EXECUTION_COUNT:Tv,SEMATTRS_DB_CASSANDRA_TABLE:_v,SEMATTRS_DB_CONNECTION_STRING:fv,SEMATTRS_DB_HBASE_NAMESPACE:Ov,SEMATTRS_DB_JDBC_DRIVER_CLASSNAME:mv,SEMATTRS_DB_MONGODB_COLLECTION:Rv,SEMATTRS_DB_MSSQL_INSTANCE_NAME:bv,SEMATTRS_DB_NAME:gv,SEMATTRS_DB_OPERATION:vv,SEMATTRS_DB_REDIS_DATABASE_INDEX:Nv,SEMATTRS_DB_SQL_TABLE:Pv,SEMATTRS_DB_STATEMENT:yv,SEMATTRS_DB_SYSTEM:pv,SEMATTRS_DB_USER:hv,SEMATTRS_ENDUSER_ID:lb,SEMATTRS_ENDUSER_ROLE:cb,SEMATTRS_ENDUSER_SCOPE:ub,SEMATTRS_EXCEPTION_ESCAPED:Dv,SEMATTRS_EXCEPTION_MESSAGE:Lv,SEMATTRS_EXCEPTION_STACKTRACE:Mv,SEMATTRS_EXCEPTION_TYPE:kv,SEMATTRS_FAAS_COLDSTART:zv,SEMATTRS_FAAS_CRON:qv,SEMATTRS_FAAS_DOCUMENT_COLLECTION:Fv,SEMATTRS_FAAS_DOCUMENT_NAME:Bv,SEMATTRS_FAAS_DOCUMENT_OPERATION:Uv,SEMATTRS_FAAS_DOCUMENT_TIME:$v,SEMATTRS_FAAS_EXECUTION:Iv,SEMATTRS_FAAS_INVOKED_NAME:Hv,SEMATTRS_FAAS_INVOKED_PROVIDER:Gv,SEMATTRS_FAAS_INVOKED_REGION:Kv,SEMATTRS_FAAS_TIME:Vv,SEMATTRS_FAAS_TRIGGER:jv,SEMATTRS_HTTP_CLIENT_IP:Pb,SEMATTRS_HTTP_FLAVOR:_b,SEMATTRS_HTTP_HOST:wb,SEMATTRS_HTTP_METHOD:yb,SEMATTRS_HTTP_REQUEST_CONTENT_LENGTH:Tb,SEMATTRS_HTTP_REQUEST_CONTENT_LENGTH_UNCOMPRESSED:Cb,SEMATTRS_HTTP_RESPONSE_CONTENT_LENGTH:Ab,SEMATTRS_HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED:Ob,SEMATTRS_HTTP_ROUTE:Rb,SEMATTRS_HTTP_SCHEME:xb,SEMATTRS_HTTP_SERVER_NAME:Nb,SEMATTRS_HTTP_STATUS_CODE:Eb,SEMATTRS_HTTP_TARGET:bb,SEMATTRS_HTTP_URL:vb,SEMATTRS_HTTP_USER_AGENT:Sb,SEMATTRS_MESSAGE_COMPRESSED_SIZE:Nw,SEMATTRS_MESSAGE_ID:Ow,SEMATTRS_MESSAGE_TYPE:Aw,SEMATTRS_MESSAGE_UNCOMPRESSED_SIZE:Rw,SEMATTRS_MESSAGING_CONSUMER_ID:pw,SEMATTRS_MESSAGING_CONVERSATION_ID:lw,SEMATTRS_MESSAGING_DESTINATION:tw,SEMATTRS_MESSAGING_DESTINATION_KIND:nw,SEMATTRS_MESSAGING_KAFKA_CLIENT_ID:gw,SEMATTRS_MESSAGING_KAFKA_CONSUMER_GROUP:mw,SEMATTRS_MESSAGING_KAFKA_MESSAGE_KEY:hw,SEMATTRS_MESSAGING_KAFKA_PARTITION:yw,SEMATTRS_MESSAGING_KAFKA_TOMBSTONE:vw,SEMATTRS_MESSAGING_MESSAGE_ID:sw,SEMATTRS_MESSAGING_MESSAGE_PAYLOAD_COMPRESSED_SIZE_BYTES:uw,SEMATTRS_MESSAGING_MESSAGE_PAYLOAD_SIZE_BYTES:cw,SEMATTRS_MESSAGING_OPERATION:dw,SEMATTRS_MESSAGING_PROTOCOL:ow,SEMATTRS_MESSAGING_PROTOCOL_VERSION:iw,SEMATTRS_MESSAGING_RABBITMQ_ROUTING_KEY:fw,SEMATTRS_MESSAGING_SYSTEM:ew,SEMATTRS_MESSAGING_TEMP_DESTINATION:rw,SEMATTRS_MESSAGING_URL:aw,SEMATTRS_NET_HOST_CARRIER_ICC:ab,SEMATTRS_NET_HOST_CARRIER_MCC:ob,SEMATTRS_NET_HOST_CARRIER_MNC:ib,SEMATTRS_NET_HOST_CARRIER_NAME:rb,SEMATTRS_NET_HOST_CONNECTION_SUBTYPE:nb,SEMATTRS_NET_HOST_CONNECTION_TYPE:tb,SEMATTRS_NET_HOST_IP:Zv,SEMATTRS_NET_HOST_NAME:eb,SEMATTRS_NET_HOST_PORT:Jv,SEMATTRS_NET_PEER_IP:Yv,SEMATTRS_NET_PEER_NAME:Qv,SEMATTRS_NET_PEER_PORT:Xv,SEMATTRS_NET_TRANSPORT:Wv,SEMATTRS_PEER_SERVICE:sb,SEMATTRS_RPC_GRPC_STATUS_CODE:Ew,SEMATTRS_RPC_JSONRPC_ERROR_CODE:Tw,SEMATTRS_RPC_JSONRPC_ERROR_MESSAGE:Cw,SEMATTRS_RPC_JSONRPC_REQUEST_ID:Sw,SEMATTRS_RPC_JSONRPC_VERSION:_w,SEMATTRS_RPC_METHOD:xw,SEMATTRS_RPC_SERVICE:ww,SEMATTRS_RPC_SYSTEM:bw,SEMATTRS_THREAD_ID:db,SEMATTRS_THREAD_NAME:pb,SEMRESATTRS_AWS_ECS_CLUSTER_ARN:oC,SEMRESATTRS_AWS_ECS_CONTAINER_ARN:rC,SEMRESATTRS_AWS_ECS_LAUNCHTYPE:iC,SEMRESATTRS_AWS_ECS_TASK_ARN:aC,SEMRESATTRS_AWS_ECS_TASK_FAMILY:sC,SEMRESATTRS_AWS_ECS_TASK_REVISION:lC,SEMRESATTRS_AWS_EKS_CLUSTER_ARN:cC,SEMRESATTRS_AWS_LOG_GROUP_ARNS:dC,SEMRESATTRS_AWS_LOG_GROUP_NAMES:uC,SEMRESATTRS_AWS_LOG_STREAM_ARNS:fC,SEMRESATTRS_AWS_LOG_STREAM_NAMES:pC,SEMRESATTRS_CLOUD_ACCOUNT_ID:JT,SEMRESATTRS_CLOUD_AVAILABILITY_ZONE:tC,SEMRESATTRS_CLOUD_PLATFORM:nC,SEMRESATTRS_CLOUD_PROVIDER:ZT,SEMRESATTRS_CLOUD_REGION:eC,SEMRESATTRS_CONTAINER_ID:mC,SEMRESATTRS_CONTAINER_IMAGE_NAME:yC,SEMRESATTRS_CONTAINER_IMAGE_TAG:vC,SEMRESATTRS_CONTAINER_NAME:hC,SEMRESATTRS_CONTAINER_RUNTIME:gC,SEMRESATTRS_DEPLOYMENT_ENVIRONMENT:bC,SEMRESATTRS_DEVICE_ID:wC,SEMRESATTRS_DEVICE_MODEL_IDENTIFIER:xC,SEMRESATTRS_DEVICE_MODEL_NAME:EC,SEMRESATTRS_FAAS_ID:SC,SEMRESATTRS_FAAS_INSTANCE:CC,SEMRESATTRS_FAAS_MAX_MEMORY:AC,SEMRESATTRS_FAAS_NAME:_C,SEMRESATTRS_FAAS_VERSION:TC,SEMRESATTRS_HOST_ARCH:PC,SEMRESATTRS_HOST_ID:OC,SEMRESATTRS_HOST_IMAGE_ID:LC,SEMRESATTRS_HOST_IMAGE_NAME:kC,SEMRESATTRS_HOST_IMAGE_VERSION:MC,SEMRESATTRS_HOST_NAME:NC,SEMRESATTRS_HOST_TYPE:RC,SEMRESATTRS_K8S_CLUSTER_NAME:DC,SEMRESATTRS_K8S_CONTAINER_NAME:BC,SEMRESATTRS_K8S_CRONJOB_NAME:JC,SEMRESATTRS_K8S_CRONJOB_UID:ZC,SEMRESATTRS_K8S_DAEMONSET_NAME:YC,SEMRESATTRS_K8S_DAEMONSET_UID:WC,SEMRESATTRS_K8S_DEPLOYMENT_NAME:HC,SEMRESATTRS_K8S_DEPLOYMENT_UID:zC,SEMRESATTRS_K8S_JOB_NAME:QC,SEMRESATTRS_K8S_JOB_UID:XC,SEMRESATTRS_K8S_NAMESPACE_NAME:FC,SEMRESATTRS_K8S_NODE_NAME:jC,SEMRESATTRS_K8S_NODE_UID:IC,SEMRESATTRS_K8S_POD_NAME:$C,SEMRESATTRS_K8S_POD_UID:UC,SEMRESATTRS_K8S_REPLICASET_NAME:qC,SEMRESATTRS_K8S_REPLICASET_UID:VC,SEMRESATTRS_K8S_STATEFULSET_NAME:KC,SEMRESATTRS_K8S_STATEFULSET_UID:GC,SEMRESATTRS_OS_DESCRIPTION:tA,SEMRESATTRS_OS_NAME:nA,SEMRESATTRS_OS_TYPE:eA,SEMRESATTRS_OS_VERSION:rA,SEMRESATTRS_PROCESS_COMMAND:sA,SEMRESATTRS_PROCESS_COMMAND_ARGS:cA,SEMRESATTRS_PROCESS_COMMAND_LINE:lA,SEMRESATTRS_PROCESS_EXECUTABLE_NAME:iA,SEMRESATTRS_PROCESS_EXECUTABLE_PATH:aA,SEMRESATTRS_PROCESS_OWNER:uA,SEMRESATTRS_PROCESS_PID:oA,SEMRESATTRS_PROCESS_RUNTIME_DESCRIPTION:fA,SEMRESATTRS_PROCESS_RUNTIME_NAME:dA,SEMRESATTRS_PROCESS_RUNTIME_VERSION:pA,SEMRESATTRS_SERVICE_INSTANCE_ID:gA,SEMRESATTRS_SERVICE_NAME:hA,SEMRESATTRS_SERVICE_NAMESPACE:mA,SEMRESATTRS_SERVICE_VERSION:yA,SEMRESATTRS_TELEMETRY_AUTO_VERSION:xA,SEMRESATTRS_TELEMETRY_SDK_LANGUAGE:bA,SEMRESATTRS_TELEMETRY_SDK_NAME:vA,SEMRESATTRS_TELEMETRY_SDK_VERSION:wA,SEMRESATTRS_WEBENGINE_DESCRIPTION:SA,SEMRESATTRS_WEBENGINE_NAME:EA,SEMRESATTRS_WEBENGINE_VERSION:_A,SemanticAttributes:Pw,SemanticResourceAttributes:TA,TELEMETRYSDKLANGUAGEVALUES_CPP:"cpp",TELEMETRYSDKLANGUAGEVALUES_DOTNET:nN,TELEMETRYSDKLANGUAGEVALUES_ERLANG:rN,TELEMETRYSDKLANGUAGEVALUES_GO:"go",TELEMETRYSDKLANGUAGEVALUES_JAVA:oN,TELEMETRYSDKLANGUAGEVALUES_NODEJS:iN,TELEMETRYSDKLANGUAGEVALUES_PHP:"php",TELEMETRYSDKLANGUAGEVALUES_PYTHON:aN,TELEMETRYSDKLANGUAGEVALUES_RUBY:sN,TELEMETRYSDKLANGUAGEVALUES_WEBJS:lN,TelemetrySdkLanguageValues:cN},Symbol.toStringTag,{value:"Module"}));var dN=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function pN(e){return e.setValue(dN,!0)}function fN(e){return!0===e.getValue(dN)}var hN=",",mN="baggage";function gN(e){return e.reduce((function(e,t){var n=""+e+(""!==e?hN:"")+t;return n.length>8192?e:n}),"")}function yN(e){return e.getAllEntries().map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),n=t[1],r=encodeURIComponent(t[0])+"="+encodeURIComponent(n.value);return void 0!==n.metadata&&(r+=";"+n.metadata.toString()),r}))}function vN(e){var t=e.split(";");if(!(t.length<=0)){var n=t.shift();if(n){var r=n.indexOf("=");if(!(r<=0)){var o,i=decodeURIComponent(n.substring(0,r).trim()),a=decodeURIComponent(n.substring(r+1).trim());return t.length>0&&(o=Gf(t.join(";"))),{key:i,value:a,metadata:o}}}}}function bN(e){return"string"!=typeof e||0===e.length?{}:e.split(hN).map((function(e){return vN(e)})).filter((function(e){return void 0!==e&&e.value.length>0})).reduce((function(e,t){return e[t.key]=t.value,e}),{})}const wN=Object.freeze(Object.defineProperty({__proto__:null,getKeyPairs:yN,parseKeyPairsIntoRecord:bN,parsePairKeyValue:vN,serializeKeyPairs:gN},Symbol.toStringTag,{value:"Module"}));var xN=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=ym.getBaggage(e);if(r&&!fN(e)){var o=gN(yN(r).filter((function(e){return e.length<=4096})).slice(0,180));o.length>0&&n.set(t,mN,o)}},e.prototype.extract=function(e,t,n){var r=n.get(t,mN),o=Array.isArray(r)?r.join(hN):r;if(!o)return e;var i={};return 0===o.length?e:(o.split(hN).forEach((function(e){var t=vN(e);if(t){var n={value:t.value};t.metadata&&(n.metadata=t.metadata),i[t.key]=n}})),0===Object.entries(i).length?e:ym.setBaggage(e,ym.createBaggage(i)))},e.prototype.fields=function(){return[mN]},e}(),EN=function(){function e(e,t){this._monotonicClock=t,this._epochMillis=e.now(),this._performanceMillis=t.now()}return e.prototype.now=function(){var e=this._monotonicClock.now()-this._performanceMillis;return this._epochMillis+e},e}(),_N=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},SN=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function TN(e){var t,n,r={};if("object"!=typeof e||null==e)return r;try{for(var o=_N(Object.entries(e)),i=o.next();!i.done;i=o.next()){var a=SN(i.value,2),s=a[0],l=a[1];CN(s)?AN(l)?r[s]=Array.isArray(l)?l.slice():l:im.warn("Invalid attribute value set for key: "+s):im.warn("Invalid attribute key: "+s)}}catch(c){t={error:c}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function CN(e){return"string"==typeof e&&e.length>0}function AN(e){return null==e||(Array.isArray(e)?function(e){var t,n,r;try{for(var o=_N(e),i=o.next();!i.done;i=o.next()){var a=i.value;if(null!=a){if(!r){if(ON(a)){r=typeof a;continue}return!1}if(typeof a!==r)return!1}}}catch(s){t={error:s}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return!0}(e):ON(e))}function ON(e){switch(typeof e){case"number":case"boolean":case"string":return!0}return!1}function NN(){return function(e){im.error(function(e){return"string"==typeof e?e:JSON.stringify(function(e){var t={},n=e;for(;null!==n;)Object.getOwnPropertyNames(n).forEach((function(e){if(!t[e]){var r=n[e];r&&(t[e]=String(r))}})),n=Object.getPrototypeOf(n);return t}(e))}(e))}}var RN,PN,kN=NN();function LN(e){try{kN(e)}catch(t){}}(PN=RN||(RN={})).AlwaysOff="always_off",PN.AlwaysOn="always_on",PN.ParentBasedAlwaysOff="parentbased_always_off",PN.ParentBasedAlwaysOn="parentbased_always_on",PN.ParentBasedTraceIdRatio="parentbased_traceidratio",PN.TraceIdRatio="traceidratio";var MN=["OTEL_SDK_DISABLED"];function DN(e){return MN.indexOf(e)>-1}var jN=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function IN(e){return jN.indexOf(e)>-1}var FN=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function UN(e){return FN.indexOf(e)>-1}var $N=1/0,BN=128,VN={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:If.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:BN,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:RN.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function qN(e,t,n){if(void 0!==n[e]){var r=String(n[e]);t[e]="true"===r.toLowerCase()}}function zN(e,t,n,r,o){if(void 0===r&&(r=-1/0),void 0===o&&(o=1/0),void 0!==n[e]){var i=Number(n[e]);isNaN(i)||(t[e]=i<r?r:i>o?o:i)}}function HN(e,t,n,r){void 0===r&&(r=",");var o=n[e];"string"==typeof o&&(t[e]=o.split(r).map((function(e){return e.trim()})))}var GN={ALL:If.ALL,VERBOSE:If.VERBOSE,DEBUG:If.DEBUG,INFO:If.INFO,WARN:If.WARN,ERROR:If.ERROR,NONE:If.NONE};function KN(e,t,n){var r=n[e];if("string"==typeof r){var o=GN[r.toUpperCase()];null!=o&&(t[e]=o)}}function WN(e){var t={};for(var n in VN){var r=n;if("OTEL_LOG_LEVEL"===r)KN(r,t,e);else if(DN(r))qN(r,t,e);else if(IN(r))zN(r,t,e);else if(UN(r))HN(r,t,e);else{var o=e[r];null!=o&&(t[r]=String(o))}}return t}var YN="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{};function XN(){var e=WN(YN);return Object.assign({},VN,e)}function QN(){return WN(YN)}function ZN(e){return e>=48&&e<=57?e-48:e>=97&&e<=102?e-87:e-55}function JN(e){for(var t=new Uint8Array(e.length/2),n=0,r=0;r<e.length;r+=2){var o=ZN(e.charCodeAt(r)),i=ZN(e.charCodeAt(r+1));t[n++]=o<<4|i}return t}var eR=function(){return function(){this.generateTraceId=nR(16),this.generateSpanId=nR(8)}}(),tR=Array(32);function nR(e){return function(){for(var t=0;t<2*e;t++)tR[t]=Math.floor(16*Math.random())+48,tR[t]>=58&&(tR[t]+=39);return String.fromCharCode.apply(null,tR.slice(0,2*e))}}var rR,oR=performance,iR="1.24.1",aR=((rR={})[TA.TELEMETRY_SDK_NAME]="opentelemetry",rR[TA.PROCESS_RUNTIME_NAME]="browser",rR[TA.TELEMETRY_SDK_LANGUAGE]=cN.WEBJS,rR[TA.TELEMETRY_SDK_VERSION]=iR,rR);function sR(e){}var lR,cR,uR=Math.pow(10,6),dR=Math.pow(10,9);function pR(e){return[Math.trunc(e/1e3),Math.round(e%1e3*uR)]}function fR(){var e=oR.timeOrigin;if("number"!=typeof e){e=oR.timing&&oR.timing.fetchStart}return e}function hR(e){return wR(pR(fR()),pR("number"==typeof e?e:oR.now()))}function mR(e,t){var n=t[0]-e[0],r=t[1]-e[1];return r<0&&(n-=1,r+=dR),[n,r]}function gR(e){return e[0]*dR+e[1]}function yR(e){return 1e6*e[0]+e[1]/1e3}function vR(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}function bR(e){return vR(e)||"number"==typeof e||e instanceof Date}function wR(e,t){var n=[e[0]+t[0],e[1]+t[1]];return n[1]>=dR&&(n[1]-=dR,n[0]+=1),n}(cR=lR||(lR={}))[cR.SUCCESS=0]="SUCCESS",cR[cR.FAILED=1]="FAILED";var xR=function(){function e(e){var t;void 0===e&&(e={}),this._propagators=null!==(t=e.propagators)&&void 0!==t?t:[],this._fields=Array.from(new Set(this._propagators.map((function(e){return"function"==typeof e.fields?e.fields():[]})).reduce((function(e,t){return e.concat(t)}),[])))}return e.prototype.inject=function(e,t,n){var r,o;try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(this._propagators),a=i.next();!a.done;a=i.next()){var s=a.value;try{s.inject(e,t,n)}catch(l){im.warn("Failed to inject with "+s.constructor.name+". Err: "+l.message)}}}catch(c){r={error:c}}finally{try{a&&!a.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}},e.prototype.extract=function(e,t,n){return this._propagators.reduce((function(e,r){try{return r.extract(e,t,n)}catch(o){im.warn("Failed to inject with "+r.constructor.name+". Err: "+o.message)}return e}),e)},e.prototype.fields=function(){return this._fields.slice()},e}(),ER="[_0-9a-z-*/]",_R=new RegExp("^(?:"+("[a-z]"+ER+"{0,255}")+"|"+("[a-z0-9]"+ER+"{0,240}@[a-z]"+ER+"{0,13}")+")$"),SR=/^[ -~]{0,255}[!-~]$/,TR=/,|=/;var CR=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return _R.test(e)})(o)&&function(e){return SR.test(e)&&!TR.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),AR="traceparent",OR="tracestate",NR=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");function RR(e){var t=NR.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}var PR,kR=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!fN(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,AR,o),r.traceState&&n.set(t,OR,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,AR);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=RR(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,OR);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new CR("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[AR,OR]},e}(),LR=Kf("OpenTelemetry SDK Context Key RPC_METADATA");(PR||(PR={})).HTTP="http";var MR,DR,jR=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:qh.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),IR=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:qh.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),FR=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(LN(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new IR),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new IR,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new jR,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new IR,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new jR}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),UR=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?qh.RECORD_AND_SAMPLED:qh.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),$R="[object Null]",BR="[object Undefined]",VR=Function.prototype.toString,qR=VR.call(Object),zR=(MR=Object.getPrototypeOf,DR=Object,function(e){return MR(DR(e))}),HR=Object.prototype,GR=HR.hasOwnProperty,KR=Symbol?Symbol.toStringTag:void 0,WR=HR.toString;function YR(e){if(!function(e){return null!=e&&"object"==typeof e}(e)||"[object Object]"!==function(e){if(null==e)return void 0===e?BR:$R;return KR&&KR in Object(e)?function(e){var t=GR.call(e,KR),n=e[KR],r=!1;try{e[KR]=void 0,r=!0}catch(tme){}var o=WR.call(e);r&&(t?e[KR]=n:delete e[KR]);return o}(e):function(e){return WR.call(e)}(e)}(e))return!1;var t=zR(e);if(null===t)return!0;var n=GR.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&VR.call(n)===qR}function XR(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e.shift(),r=new WeakMap;e.length>0;)n=ZR(n,e.shift(),0,r);return n}function QR(e){return eP(e)?e.slice():e}function ZR(e,t,n,r){var o;if(void 0===n&&(n=0),!(n>20)){if(n++,rP(e)||rP(t)||tP(t))o=QR(t);else if(eP(e)){if(o=e.slice(),eP(t))for(var i=0,a=t.length;i<a;i++)o.push(QR(t[i]));else if(nP(t))for(i=0,a=(s=Object.keys(t)).length;i<a;i++){o[l=s[i]]=QR(t[l])}}else if(nP(e))if(nP(t)){if(!function(e,t){if(!YR(e)||!YR(t))return!1;return!0}(e,t))return t;o=Object.assign({},e);var s;for(i=0,a=(s=Object.keys(t)).length;i<a;i++){var l,c=t[l=s[i]];if(rP(c))void 0===c?delete o[l]:o[l]=c;else{var u=o[l],d=c;if(JR(e,l,r)||JR(t,l,r))delete o[l];else{if(nP(u)&&nP(d)){var p=r.get(u)||[],f=r.get(d)||[];p.push({obj:e,key:l}),f.push({obj:t,key:l}),r.set(u,p),r.set(d,f)}o[l]=ZR(o[l],c,n,r)}}}}else o=t;return o}}function JR(e,t,n){for(var r=n.get(e[t])||[],o=0,i=r.length;o<i;o++){var a=r[o];if(a.key===t&&a.obj===e)return!0}return!1}function eP(e){return Array.isArray(e)}function tP(e){return"function"==typeof e}function nP(e){return!rP(e)&&!eP(e)&&!tP(e)&&"object"==typeof e}function rP(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||void 0===e||e instanceof Date||e instanceof RegExp||null===e}var oP=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),iP=function(e){function t(n){var r=e.call(this,n)||this;return Object.setPrototypeOf(r,t.prototype),r}return oP(t,e),t}(Error);function aP(e,t){return"string"==typeof t?e===t:!!e.match(t)}var sP=function(){function e(){var e=this;this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))}return Object.defineProperty(e.prototype,"promise",{get:function(){return this._promise},enumerable:!1,configurable:!0}),e.prototype.resolve=function(e){this._resolve(e)},e.prototype.reject=function(e){this._reject(e)},e}(),lP=function(){function e(e,t){this._callback=e,this._that=t,this._isCalled=!1,this._deferred=new sP}return Object.defineProperty(e.prototype,"isCalled",{get:function(){return this._isCalled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"promise",{get:function(){return this._deferred.promise},enumerable:!1,configurable:!0}),e.prototype.call=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];if(!this._isCalled){this._isCalled=!0;try{Promise.resolve((e=this._callback).call.apply(e,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([this._that],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))).then((function(e){return t._deferred.resolve(e)}),(function(e){return t._deferred.reject(e)}))}catch(o){this._deferred.reject(o)}}return this._deferred.promise},e}();var cP={_export:function(e,t){return new Promise((function(n){om.with(pN(om.active()),(function(){e.export(t,(function(e){n(e)}))}))}))}};const uP=Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:jR,AlwaysOnSampler:IR,AnchoredClock:EN,BindOnceFuture:lP,CompositePropagator:xR,DEFAULT_ATTRIBUTE_COUNT_LIMIT:BN,DEFAULT_ATTRIBUTE_VALUE_LENGTH_LIMIT:$N,DEFAULT_ENVIRONMENT:VN,DEFAULT_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,DEFAULT_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,get ExportResultCode(){return lR},ParentBasedSampler:FR,get RPCType(){return PR},RandomIdGenerator:eR,SDK_INFO:aR,TRACE_PARENT_HEADER:AR,TRACE_STATE_HEADER:OR,TimeoutError:iP,TraceIdRatioBasedSampler:UR,TraceState:CR,get TracesSamplerValues(){return RN},VERSION:iR,W3CBaggagePropagator:xN,W3CTraceContextPropagator:kR,_globalThis:YN,addHrTimes:wR,baggageUtils:wN,callWithTimeout:function(e,t){var n,r=new Promise((function(e,r){n=setTimeout((function(){r(new iP("Operation timed out."))}),t)}));return Promise.race([e,r]).then((function(e){return clearTimeout(n),e}),(function(e){throw clearTimeout(n),e}))},deleteRPCMetadata:function(e){return e.deleteValue(LR)},getEnv:XN,getEnvWithoutDefaults:QN,getRPCMetadata:function(e){return e.getValue(LR)},getTimeOrigin:fR,globalErrorHandler:LN,hexToBase64:function(e){return btoa(String.fromCharCode.apply(String,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(JN(e)),!1)))},hexToBinary:JN,hrTime:hR,hrTimeDuration:mR,hrTimeToMicroseconds:yR,hrTimeToMilliseconds:function(e){return 1e3*e[0]+e[1]/1e6},hrTimeToNanoseconds:gR,hrTimeToTimeStamp:function(e){var t=""+"0".repeat(9)+e[1]+"Z",n=t.substr(t.length-9-1);return new Date(1e3*e[0]).toISOString().replace("000Z",n)},internal:cP,isAttributeKey:CN,isAttributeValue:AN,isTimeInput:bR,isTimeInputHrTime:vR,isTracingSuppressed:fN,isUrlIgnored:function(e,t){var n,r;if(!t)return!1;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),i=o.next();!i.done;i=o.next()){if(aP(e,i.value))return!0}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return!1},isWrapped:function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped},loggingErrorHandler:NN,merge:XR,millisToHrTime:pR,otperformance:oR,parseEnvironment:WN,parseTraceParent:RR,sanitizeAttributes:TN,setGlobalErrorHandler:function(e){kN=e},setRPCMetadata:function(e,t){return e.setValue(LR,t)},suppressTracing:pN,timeInputToHrTime:function(e){if(vR(e))return e;if("number"==typeof e)return e<fR()?hR(e):pR(e);if(e instanceof Date)return pR(e.getTime());throw TypeError("Invalid input type")},unrefTimer:sR,unsuppressTracing:function(e){return e.deleteValue(dN)},urlMatches:aP},Symbol.toStringTag,{value:"Module"}));function dP(){return"unknown_service"}var pP=function(){return pP=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},pP.apply(this,arguments)},fP=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},hP=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},mP=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[hA]="unknown_service",t[bA]=aR[bA],t[vA]=aR[vA],t[wA]=aR[wA],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return fP(this,void 0,void 0,(function(){return hP(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=pP(pP({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return pP(pP(pP(pP({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),gP=new(function(){function e(){}return e.prototype.detect=function(){return new mP({})},e}()),yP=new(function(){function e(){}return e.prototype.detect=function(){return Promise.resolve(gP.detect())},e}()),vP=yP,bP=gP,wP=yP,xP=gP,EP=yP,_P=yP,SP=gP,TP=function(){return TP=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},TP.apply(this,arguments)},CP=new(function(){function e(){}return e.prototype.detect=function(e){var t,n,r,o;if(!("undefined"!=typeof navigator&&void 0===(null===(r=null===(n=global.process)||void 0===n?void 0:n.versions)||void 0===r?void 0:r.node)&&void 0===(null===(o=global.Bun)||void 0===o?void 0:o.version)))return mP.empty();var i=((t={})[TA.PROCESS_RUNTIME_NAME]="browser",t[TA.PROCESS_RUNTIME_DESCRIPTION]="Web Browser",t[TA.PROCESS_RUNTIME_VERSION]=navigator.userAgent,t);return this._getResourceAttributes(i,e)},e.prototype._getResourceAttributes=function(e,t){return""===e[TA.PROCESS_RUNTIME_VERSION]?(im.debug("BrowserDetector failed: Unable to find required browser resources. "),mP.empty()):new mP(TP({},e))},e}()),AP=new(function(){function e(){}return e.prototype.detect=function(e){return Promise.resolve(CP.detect(e))},e}()),OP=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},NP=new(function(){function e(){this._MAX_LENGTH=255,this._COMMA_SEPARATOR=",",this._LABEL_KEY_VALUE_SPLITTER="=",this._ERROR_MESSAGE_INVALID_CHARS="should be a ASCII string with a length greater than 0 and not exceed "+this._MAX_LENGTH+" characters.",this._ERROR_MESSAGE_INVALID_VALUE="should be a ASCII string with a length not exceed "+this._MAX_LENGTH+" characters."}return e.prototype.detect=function(e){var t={},n=XN(),r=n.OTEL_RESOURCE_ATTRIBUTES,o=n.OTEL_SERVICE_NAME;if(r)try{var i=this._parseResourceAttributes(r);Object.assign(t,i)}catch(tme){im.debug("EnvDetector failed: "+tme.message)}return o&&(t[hA]=o),new mP(t)},e.prototype._parseResourceAttributes=function(e){var t,n;if(!e)return{};var r={},o=e.split(this._COMMA_SEPARATOR,-1);try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(o),a=i.next();!a.done;a=i.next()){var s=a.value.split(this._LABEL_KEY_VALUE_SPLITTER,-1);if(2===s.length){var l=OP(s,2),c=l[0],u=l[1];if(c=c.trim(),u=u.trim().split(/^"|"$/).join(""),!this._isValidAndNotEmpty(c))throw new Error("Attribute key "+this._ERROR_MESSAGE_INVALID_CHARS);if(!this._isValid(u))throw new Error("Attribute value "+this._ERROR_MESSAGE_INVALID_VALUE);r[c]=decodeURIComponent(u)}}}catch(d){t={error:d}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r},e.prototype._isValid=function(e){return e.length<=this._MAX_LENGTH&&this._isBaggageOctetString(e)},e.prototype._isBaggageOctetString=function(e){for(var t=0;t<e.length;t++){var n=e.charCodeAt(t);if(n<33||44===n||59===n||92===n||n>126)return!1}return!0},e.prototype._isValidAndNotEmpty=function(e){return e.length>0&&this._isValid(e)},e}()),RP=new(function(){function e(){}return e.prototype.detect=function(e){return Promise.resolve(NP.detect(e))},e}()),PP=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},kP=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},LP=function(e){e.forEach((function(e){if(Object.keys(e.attributes).length>0){var t=JSON.stringify(e.attributes,null,4);im.verbose(t)}}))};const MP=za(Object.freeze(Object.defineProperty({__proto__:null,Resource:mP,browserDetector:AP,browserDetectorSync:CP,defaultServiceName:dP,detectResources:function(e){return void 0===e&&(e={}),PP(void 0,void 0,void 0,(function(){var t;return kP(this,(function(n){switch(n.label){case 0:return[4,Promise.all((e.detectors||[]).map((function(t){return PP(void 0,void 0,void 0,(function(){var n,r;return kP(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,t.detect(e)];case 1:return n=o.sent(),im.debug(t.constructor.name+" found resource.",n),[2,n];case 2:return r=o.sent(),im.debug(t.constructor.name+" failed: "+r.message),[2,mP.empty()];case 3:return[2]}}))}))})))];case 1:return t=n.sent(),LP(t),[2,t.reduce((function(e,t){return e.merge(t)}),mP.empty())]}}))}))},detectResourcesSync:function(e){var t;void 0===e&&(e={});var n=(null!==(t=e.detectors)&&void 0!==t?t:[]).map((function(t){try{var n,r=t.detect(e);if(null!==(o=r)&&"object"==typeof o&&"function"==typeof o.then){n=new mP({},PP(void 0,void 0,void 0,(function(){return kP(this,(function(e){switch(e.label){case 0:return[4,r];case 1:return[2,e.sent().attributes]}}))})))}else n=r;return n.waitForAsyncAttributes?n.waitForAsyncAttributes().then((function(){return im.debug(t.constructor.name+" found resource.",n)})):im.debug(t.constructor.name+" found resource.",n),n}catch(tme){return im.error(t.constructor.name+" failed: "+tme.message),mP.empty()}var o})),r=n.reduce((function(e,t){return e.merge(t)}),mP.empty());return r.waitForAsyncAttributes&&r.waitForAsyncAttributes().then((function(){LP(n)})),r},envDetector:RP,envDetectorSync:NP,hostDetector:vP,hostDetectorSync:bP,osDetector:wP,osDetectorSync:xP,processDetector:EP,processDetectorSync:_P,serviceInstanceIdDetectorSync:SP},Symbol.toStringTag,{value:"Module"})));var DP,jP=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},IP=function(){function e(e,t,n,r,o,i,a,s,l,c){void 0===a&&(a=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:Kh.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=n,this._spanContext=r,this.parentSpanId=i,this.kind=o,this.links=a;var u=Date.now();this._performanceStartTime=oR.now(),this._performanceOffset=u-(this._performanceStartTime+fR()),this._startTimeProvided=null!=s,this.startTime=this._getTime(null!=s?s:u),this.resource=e.resource,this.instrumentationLibrary=e.instrumentationLibrary,this._spanLimits=e.getSpanLimits(),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0,null!=c&&this.setAttributes(c),this._spanProcessor=e.getActiveSpanProcessor(),this._spanProcessor.onStart(this,t)}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return null==t||this._isSpanEnded()?this:0===e.length?(im.warn("Invalid attribute key: "+e),this):AN(t)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,e)?(this._droppedAttributesCount++,this):(this.attributes[e]=this._truncateToSize(t),this):(im.warn("Invalid attribute value set for key: "+e),this)},e.prototype.setAttributes=function(e){var t,n;try{for(var r=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=r.next();!o.done;o=r.next()){var i=jP(o.value,2);this.setAttribute(i[0],i[1])}}catch(a){t={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.addEvent=function(e,t,n){if(this._isSpanEnded())return this;if(0===this._spanLimits.eventCountLimit)return im.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(0===this._droppedEventsCount&&im.debug("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),bR(t)&&(bR(n)||(n=t),t=void 0);var r=TN(t);return this.events.push({name:e,attributes:r,time:this._getTime(n),droppedAttributesCount:0}),this},e.prototype.setStatus=function(e){return this._isSpanEnded()||(this.status=e),this},e.prototype.updateName=function(e){return this._isSpanEnded()||(this.name=e),this},e.prototype.end=function(e){this._isSpanEnded()?im.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once."):(this._ended=!0,this.endTime=this._getTime(e),this._duration=mR(this.startTime,this.endTime),this._duration[0]<0&&(im.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._droppedEventsCount>0&&im.warn("Dropped "+this._droppedEventsCount+" events because eventCountLimit reached"),this._spanProcessor.onEnd(this))},e.prototype._getTime=function(e){if("number"==typeof e&&e<oR.now())return hR(e+this._performanceOffset);if("number"==typeof e)return pR(e);if(e instanceof Date)return pR(e.getTime());if(vR(e))return e;if(this._startTimeProvided)return pR(Date.now());var t=oR.now()-this._performanceStartTime;return wR(this.startTime,pR(t))},e.prototype.isRecording=function(){return!1===this._ended},e.prototype.recordException=function(e,t){var n={};"string"==typeof e?n[Pw.EXCEPTION_MESSAGE]=e:e&&(e.code?n[Pw.EXCEPTION_TYPE]=e.code.toString():e.name&&(n[Pw.EXCEPTION_TYPE]=e.name),e.message&&(n[Pw.EXCEPTION_MESSAGE]=e.message),e.stack&&(n[Pw.EXCEPTION_STACKTRACE]=e.stack)),n[Pw.EXCEPTION_TYPE]||n[Pw.EXCEPTION_MESSAGE]?this.addEvent("exception",n,t):im.warn("Failed to record an exception "+e)},Object.defineProperty(e.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),e.prototype._isSpanEnded=function(){return this._ended&&im.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},e.prototype._truncateToLimitUtil=function(e,t){return e.length<=t?e:e.substr(0,t)},e.prototype._truncateToSize=function(e){var t=this,n=this._attributeValueLengthLimit;return n<=0?(im.warn("Attribute value limit must be positive, got "+n),e):"string"==typeof e?this._truncateToLimitUtil(e,n):Array.isArray(e)?e.map((function(e){return"string"==typeof e?t._truncateToLimitUtil(e,n):e})):e},e}();!function(e){e[e.NOT_RECORD=0]="NOT_RECORD",e[e.RECORD=1]="RECORD",e[e.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"}(DP||(DP={}));var FP=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:DP.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),UP=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:DP.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),$P=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(LN(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new UP),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new UP,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new FP,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new UP,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new FP}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),BP=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?DP.RECORD_AND_SAMPLED:DP.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),VP=XN(),qP=RN.AlwaysOn;function zP(){return{sampler:HP(VP),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:XN().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:XN().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:XN().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:XN().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:XN().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:XN().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:XN().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:XN().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function HP(e){switch(void 0===e&&(e=XN()),e.OTEL_TRACES_SAMPLER){case RN.AlwaysOn:return new UP;case RN.AlwaysOff:return new FP;case RN.ParentBasedAlwaysOn:return new $P({root:new UP});case RN.ParentBasedAlwaysOff:return new $P({root:new FP});case RN.TraceIdRatio:return new BP(GP(e));case RN.ParentBasedTraceIdRatio:return new $P({root:new BP(GP(e))});default:return im.error('OTEL_TRACES_SAMPLER value "'+e.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+qP+'".'),new UP}}function GP(e){if(void 0===e.OTEL_TRACES_SAMPLER_ARG||""===e.OTEL_TRACES_SAMPLER_ARG)return im.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to 1."),1;var t=Number(e.OTEL_TRACES_SAMPLER_ARG);return isNaN(t)?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to 1."),1):t<0||t>1?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to 1."),1):t}var KP=function(){function e(e,t){this._exporter=e,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var n=XN();this._maxExportBatchSize="number"==typeof(null==t?void 0:t.maxExportBatchSize)?t.maxExportBatchSize:n.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize="number"==typeof(null==t?void 0:t.maxQueueSize)?t.maxQueueSize:n.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis="number"==typeof(null==t?void 0:t.scheduledDelayMillis)?t.scheduledDelayMillis:n.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis="number"==typeof(null==t?void 0:t.exportTimeoutMillis)?t.exportTimeoutMillis:n.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new lP(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(im.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return e.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){this._shutdownOnce.isCalled||e.spanContext().traceFlags&gh.SAMPLED&&this._addToBuffer(e)},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){var e=this;return Promise.resolve().then((function(){return e.onShutdown()})).then((function(){return e._flushAll()})).then((function(){return e._exporter.shutdown()}))},e.prototype._addToBuffer=function(e){if(this._finishedSpans.length>=this._maxQueueSize)return 0===this._droppedSpansCount&&im.debug("maxQueueSize reached, dropping spans"),void this._droppedSpansCount++;this._droppedSpansCount>0&&(im.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(e),this._maybeStartTimer()},e.prototype._flushAll=function(){var e=this;return new Promise((function(t,n){for(var r=[],o=0,i=Math.ceil(e._finishedSpans.length/e._maxExportBatchSize);o<i;o++)r.push(e._flushOneBatch());Promise.all(r).then((function(){t()})).catch(n)}))},e.prototype._flushOneBatch=function(){var e=this;return this._clearTimer(),0===this._finishedSpans.length?Promise.resolve():new Promise((function(t,n){var r=setTimeout((function(){n(new Error("Timeout"))}),e._exportTimeoutMillis);om.with(pN(om.active()),(function(){var o;e._finishedSpans.length<=e._maxExportBatchSize?(o=e._finishedSpans,e._finishedSpans=[]):o=e._finishedSpans.splice(0,e._maxExportBatchSize);for(var i=function(){return e._exporter.export(o,(function(e){var o;clearTimeout(r),e.code===lR.SUCCESS?t():n(null!==(o=e.error)&&void 0!==o?o:new Error("BatchSpanProcessor: span export failed"))}))},a=null,s=0,l=o.length;s<l;s++){var c=o[s];c.resource.asyncAttributesPending&&c.resource.waitForAsyncAttributes&&(null!=a||(a=[]),a.push(c.resource.waitForAsyncAttributes()))}null===a?i():Promise.all(a).then(i,(function(e){LN(e),n(e)}))}))}))},e.prototype._maybeStartTimer=function(){var e=this;if(!this._isExporting){var t=function(){e._isExporting=!0,e._flushOneBatch().finally((function(){e._isExporting=!1,e._finishedSpans.length>0&&(e._clearTimer(),e._maybeStartTimer())})).catch((function(t){e._isExporting=!1,LN(t)}))};if(this._finishedSpans.length>=this._maxExportBatchSize)return t();void 0===this._timer&&(this._timer=setTimeout((function(){return t()}),this._scheduledDelayMillis))}},e.prototype._clearTimer=function(){void 0!==this._timer&&(clearTimeout(this._timer),this._timer=void 0)},e}(),WP=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YP=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.onInit(n),r}return WP(t,e),t.prototype.onInit=function(e){var t=this;!0!==(null==e?void 0:e.disableAutoFlushOnDocumentHide)&&"undefined"!=typeof document&&(this._visibilityChangeListener=function(){"hidden"===document.visibilityState&&t.forceFlush()},this._pageHideListener=function(){t.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},t.prototype.onShutdown=function(){"undefined"!=typeof document&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},t}(KP),XP=function(){return function(){this.generateTraceId=ZP(16),this.generateSpanId=ZP(8)}}(),QP=Array(32);function ZP(e){return function(){for(var t=0;t<2*e;t++)QP[t]=Math.floor(16*Math.random())+48,QP[t]>=58&&(QP[t]+=39);return String.fromCharCode.apply(null,QP.slice(0,2*e))}}var JP,ek,tk=function(){function e(e,t,n){this._tracerProvider=n;var r,o,i,a,s=(r=t,o={sampler:HP()},i=zP(),(a=Object.assign({},i,o,r)).generalLimits=Object.assign({},i.generalLimits,r.generalLimits||{}),a.spanLimits=Object.assign({},i.spanLimits,r.spanLimits||{}),a);this._sampler=s.sampler,this._generalLimits=s.generalLimits,this._spanLimits=s.spanLimits,this._idGenerator=t.idGenerator||new XP,this.resource=n.resource,this.instrumentationLibrary=e}return e.prototype.startSpan=function(e,t,n){var r,o,i;void 0===t&&(t={}),void 0===n&&(n=om.active()),t.root&&(n=bm.deleteSpan(n));var a=bm.getSpan(n);if(fN(n))return im.debug("Instrumentation suppressed, returning Noop Span"),bm.wrapSpanContext(Ch);var s,l,c,u=null==a?void 0:a.spanContext(),d=this._idGenerator.generateSpanId();u&&bm.isSpanContextValid(u)?(s=u.traceId,l=u.traceState,c=u.spanId):s=this._idGenerator.generateTraceId();var p=null!==(r=t.kind)&&void 0!==r?r:Hh.INTERNAL,f=(null!==(o=t.links)&&void 0!==o?o:[]).map((function(e){return{context:e.context,attributes:TN(e.attributes)}})),h=TN(t.attributes),m=this._sampler.shouldSample(n,s,e,p,h,f);l=null!==(i=m.traceState)&&void 0!==i?i:l;var g={traceId:s,spanId:d,traceFlags:m.decision===qh.RECORD_AND_SAMPLED?gh.SAMPLED:gh.NONE,traceState:l};if(m.decision===qh.NOT_RECORD)return im.debug("Recording is off, propagating context in a non-recording span"),bm.wrapSpanContext(g);var y=TN(Object.assign(h,m.attributes));return new IP(this,n,e,g,p,c,f,t.startTime,void 0,y)},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:om.active(),l=this.startSpan(e,o,s),c=bm.setSpan(s,l);return om.with(c,a,void 0,l)}},e.prototype.getGeneralLimits=function(){return this._generalLimits},e.prototype.getSpanLimits=function(){return this._spanLimits},e.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},e}(),nk=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},rk=function(){function e(e){this._spanProcessors=e}return e.prototype.forceFlush=function(){var e,t,n=[];try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.forceFlush())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e){Promise.all(n).then((function(){e()})).catch((function(t){LN(t||new Error("MultiSpanProcessor: forceFlush failed")),e()}))}))},e.prototype.onStart=function(e,t){var n,r;try{for(var o=nk(this._spanProcessors),i=o.next();!i.done;i=o.next()){i.value.onStart(e,t)}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}},e.prototype.onEnd=function(e){var t,n;try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){o.value.onEnd(e)}}catch(i){t={error:i}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.shutdown=function(){var e,t,n=[];try{for(var r=nk(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.shutdown())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e,t){Promise.all(n).then((function(){e()}),t)}))},e}(),ok=function(){function e(){}return e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){},e.prototype.shutdown=function(){return Promise.resolve()},e.prototype.forceFlush=function(){return Promise.resolve()},e}();(ek=JP||(JP={}))[ek.resolved=0]="resolved",ek[ek.timeout=1]="timeout",ek[ek.error=2]="error",ek[ek.unresolved=3]="unresolved";var ik=function(){function e(e){var t;void 0===e&&(e={}),this._registeredSpanProcessors=[],this._tracers=new Map;var n=XR({},zP(),function(e){var t,n,r,o,i,a,s,l,c,u,d,p,f=Object.assign({},e.spanLimits),h=QN();return f.attributeCountLimit=null!==(a=null!==(i=null!==(o=null!==(n=null===(t=e.spanLimits)||void 0===t?void 0:t.attributeCountLimit)&&void 0!==n?n:null===(r=e.generalLimits)||void 0===r?void 0:r.attributeCountLimit)&&void 0!==o?o:h.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)&&void 0!==i?i:h.OTEL_ATTRIBUTE_COUNT_LIMIT)&&void 0!==a?a:BN,f.attributeValueLengthLimit=null!==(p=null!==(d=null!==(u=null!==(l=null===(s=e.spanLimits)||void 0===s?void 0:s.attributeValueLengthLimit)&&void 0!==l?l:null===(c=e.generalLimits)||void 0===c?void 0:c.attributeValueLengthLimit)&&void 0!==u?u:h.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==d?d:h.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==p?p:$N,Object.assign({},e,{spanLimits:f})}(e));this.resource=null!==(t=n.resource)&&void 0!==t?t:mP.empty(),this.resource=mP.default().merge(this.resource),this._config=Object.assign({},n,{resource:this.resource});var r=this._buildExporterFromEnv();if(void 0!==r){var o=new YP(r);this.activeSpanProcessor=o}else this.activeSpanProcessor=new ok}return e.prototype.getTracer=function(e,t,n){var r=e+"@"+(t||"")+":"+((null==n?void 0:n.schemaUrl)||"");return this._tracers.has(r)||this._tracers.set(r,new tk({name:e,version:t,schemaUrl:null==n?void 0:n.schemaUrl},this._config,this)),this._tracers.get(r)},e.prototype.addSpanProcessor=function(e){0===this._registeredSpanProcessors.length&&this.activeSpanProcessor.shutdown().catch((function(e){return im.error("Error while trying to shutdown current span processor",e)})),this._registeredSpanProcessors.push(e),this.activeSpanProcessor=new rk(this._registeredSpanProcessors)},e.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},e.prototype.register=function(e){void 0===e&&(e={}),bm.setGlobalTracerProvider(this),void 0===e.propagator&&(e.propagator=this._buildPropagatorFromEnv()),e.contextManager&&om.setGlobalContextManager(e.contextManager),e.propagator&&ym.setGlobalPropagator(e.propagator)},e.prototype.forceFlush=function(){var e=this._config.forceFlushTimeoutMillis,t=this._registeredSpanProcessors.map((function(t){return new Promise((function(n){var r,o=setTimeout((function(){n(new Error("Span processor did not completed within timeout period of "+e+" ms")),r=JP.timeout}),e);t.forceFlush().then((function(){clearTimeout(o),r!==JP.timeout&&n(r=JP.resolved)})).catch((function(e){clearTimeout(o),r=JP.error,n(e)}))}))}));return new Promise((function(e,n){Promise.all(t).then((function(t){var r=t.filter((function(e){return e!==JP.resolved}));r.length>0?n(r):e()})).catch((function(e){return n([e])}))}))},e.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},e.prototype._getPropagator=function(e){var t;return null===(t=this.constructor._registeredPropagators.get(e))||void 0===t?void 0:t()},e.prototype._getSpanExporter=function(e){var t;return null===(t=this.constructor._registeredExporters.get(e))||void 0===t?void 0:t()},e.prototype._buildPropagatorFromEnv=function(){var e=this,t=Array.from(new Set(XN().OTEL_PROPAGATORS)),n=t.map((function(t){var n=e._getPropagator(t);return n||im.warn('Propagator "'+t+'" requested through environment variable is unavailable.'),n})).reduce((function(e,t){return t&&e.push(t),e}),[]);return 0===n.length?void 0:1===t.length?n[0]:new xR({propagators:n})},e.prototype._buildExporterFromEnv=function(){var e=XN().OTEL_TRACES_EXPORTER;if("none"!==e&&""!==e){var t=this._getSpanExporter(e);return t||im.error('Exporter "'+e+'" requested through environment variable is unavailable.'),t}},e._registeredPropagators=new Map([["tracecontext",function(){return new kR}],["baggage",function(){return new xN}]]),e._registeredExporters=new Map,e}(),ak=function(){function e(){}return e.prototype.export=function(e,t){return this._sendSpans(e,t)},e.prototype.shutdown=function(){return this._sendSpans([]),this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype._exportInfo=function(e){var t;return{resource:{attributes:e.resource.attributes},traceId:e.spanContext().traceId,parentId:e.parentSpanId,traceState:null===(t=e.spanContext().traceState)||void 0===t?void 0:t.serialize(),name:e.name,id:e.spanContext().spanId,kind:e.kind,timestamp:yR(e.startTime),duration:yR(e.duration),attributes:e.attributes,status:e.status,events:e.events,links:e.links}},e.prototype._sendSpans=function(e,t){var n,r;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next());}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}if(t)return t({code:lR.SUCCESS})},e}(),sk=function(){function e(){this._finishedSpans=[],this._stopped=!1}return e.prototype.export=function(e,t){var n;if(this._stopped)return t({code:lR.FAILED,error:new Error("Exporter has been stopped")});(n=this._finishedSpans).push.apply(n,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)),setTimeout((function(){return t({code:lR.SUCCESS})}),0)},e.prototype.shutdown=function(){return this._stopped=!0,this._finishedSpans=[],this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype.reset=function(){this._finishedSpans=[]},e.prototype.getFinishedSpans=function(){return this._finishedSpans},e}(),lk=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},ck=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},uk=function(){function e(e){this._exporter=e,this._shutdownOnce=new lP(this._shutdown,this),this._unresolvedExports=new Set}return e.prototype.forceFlush=function(){return lk(this,void 0,void 0,(function(){return ck(this,(function(e){switch(e.label){case 0:return[4,Promise.all(Array.from(this._unresolvedExports))];case 1:return e.sent(),this._exporter.forceFlush?[4,this._exporter.forceFlush()]:[3,3];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){var t,n,r=this;if(!this._shutdownOnce.isCalled&&e.spanContext().traceFlags&gh.SAMPLED){var o=function(){return cP._export(r._exporter,[e]).then((function(e){var t;e.code!==lR.SUCCESS&&LN(null!==(t=e.error)&&void 0!==t?t:new Error("SimpleSpanProcessor: span export failed (status "+e+")"))})).catch((function(e){LN(e)}))};if(e.resource.asyncAttributesPending){var i=null===(n=(t=e.resource).waitForAsyncAttributes)||void 0===n?void 0:n.call(t).then((function(){return null!=i&&r._unresolvedExports.delete(i),o()}),(function(e){return LN(e)}));null!=i&&this._unresolvedExports.add(i)}else o()}},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){return this._exporter.shutdown()},e}();const dk=za(Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:FP,AlwaysOnSampler:UP,BasicTracerProvider:ik,BatchSpanProcessor:YP,ConsoleSpanExporter:ak,get ForceFlushState(){return JP},InMemorySpanExporter:sk,NoopSpanProcessor:ok,ParentBasedSampler:$P,RandomIdGenerator:XP,get SamplingDecision(){return DP},SimpleSpanProcessor:uk,Span:IP,TraceIdRatioBasedSampler:BP,Tracer:tk},Symbol.toStringTag,{value:"Module"})));var pk=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");function fk(e){return e.setValue(pk,!0)}function hk(e){return!0===e.getValue(pk)}var mk="baggage";function gk(e){return e.getAllEntries().map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),n=t[1],r=encodeURIComponent(t[0])+"="+encodeURIComponent(n.value);return void 0!==n.metadata&&(r+=";"+n.metadata.toString()),r}))}var yk=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=ym.getBaggage(e);if(r&&!hk(e)){var o=function(e){return e.reduce((function(e,t){var n=e+(""!==e?",":"")+t;return n.length>8192?e:n}),"")}(gk(r).filter((function(e){return e.length<=4096})).slice(0,180));o.length>0&&n.set(t,mk,o)}},e.prototype.extract=function(e,t,n){var r=n.get(t,mk),o=Array.isArray(r)?r.join(","):r;if(!o)return e;var i={};return 0===o.length?e:(o.split(",").forEach((function(e){var t=function(e){var t=e.split(";");if(!(t.length<=0)){var n=t.shift();if(n){var r=n.indexOf("=");if(!(r<=0)){var o,i=decodeURIComponent(n.substring(0,r).trim()),a=decodeURIComponent(n.substring(r+1).trim());return t.length>0&&(o=Gf(t.join(";"))),{key:i,value:a,metadata:o}}}}}(e);if(t){var n={value:t.value};t.metadata&&(n.metadata=t.metadata),i[t.key]=n}})),0===Object.entries(i).length?e:ym.setBaggage(e,ym.createBaggage(i)))},e.prototype.fields=function(){return[mk]},e}(),vk=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},bk=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function wk(e){var t,n,r={};if("object"!=typeof e||null==e)return r;try{for(var o=vk(Object.entries(e)),i=o.next();!i.done;i=o.next()){var a=bk(i.value,2),s=a[0],l=a[1];xk(s)?Ek(l)?r[s]=Array.isArray(l)?l.slice():l:im.warn("Invalid attribute value set for key: "+s):im.warn("Invalid attribute key: "+s)}}catch(c){t={error:c}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function xk(e){return"string"==typeof e&&e.length>0}function Ek(e){return null==e||(Array.isArray(e)?function(e){var t,n,r;try{for(var o=vk(e),i=o.next();!i.done;i=o.next()){var a=i.value;if(null!=a){if(!r){if(_k(a)){r=typeof a;continue}return!1}if(typeof a!==r)return!1}}}catch(s){t={error:s}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return!0}(e):_k(e))}function _k(e){switch(typeof e){case"number":case"boolean":case"string":return!0}return!1}var Sk,Tk=function(e){im.error(function(e){return"string"==typeof e?e:JSON.stringify(function(e){for(var t={},n=e;null!==n;)Object.getOwnPropertyNames(n).forEach((function(e){if(!t[e]){var r=n[e];r&&(t[e]=String(r))}})),n=Object.getPrototypeOf(n);return t}(e))}(e))};function Ck(e){try{Tk(e)}catch(t){}}!function(e){e.AlwaysOff="always_off",e.AlwaysOn="always_on",e.ParentBasedAlwaysOff="parentbased_always_off",e.ParentBasedAlwaysOn="parentbased_always_on",e.ParentBasedTraceIdRatio="parentbased_traceidratio",e.TraceIdRatio="traceidratio"}(Sk||(Sk={}));var Ak=["OTEL_SDK_DISABLED"];function Ok(e){return Ak.indexOf(e)>-1}var Nk=["OTEL_BSP_EXPORT_TIMEOUT","OTEL_BSP_MAX_EXPORT_BATCH_SIZE","OTEL_BSP_MAX_QUEUE_SIZE","OTEL_BSP_SCHEDULE_DELAY","OTEL_BLRP_EXPORT_TIMEOUT","OTEL_BLRP_MAX_EXPORT_BATCH_SIZE","OTEL_BLRP_MAX_QUEUE_SIZE","OTEL_BLRP_SCHEDULE_DELAY","OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT","OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT","OTEL_SPAN_EVENT_COUNT_LIMIT","OTEL_SPAN_LINK_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT","OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT","OTEL_EXPORTER_OTLP_TIMEOUT","OTEL_EXPORTER_OTLP_TRACES_TIMEOUT","OTEL_EXPORTER_OTLP_METRICS_TIMEOUT","OTEL_EXPORTER_OTLP_LOGS_TIMEOUT","OTEL_EXPORTER_JAEGER_AGENT_PORT"];function Rk(e){return Nk.indexOf(e)>-1}var Pk=["OTEL_NO_PATCH_MODULES","OTEL_PROPAGATORS"];function kk(e){return Pk.indexOf(e)>-1}var Lk=1/0,Mk=128,Dk={OTEL_SDK_DISABLED:!1,CONTAINER_NAME:"",ECS_CONTAINER_METADATA_URI_V4:"",ECS_CONTAINER_METADATA_URI:"",HOSTNAME:"",KUBERNETES_SERVICE_HOST:"",NAMESPACE:"",OTEL_BSP_EXPORT_TIMEOUT:3e4,OTEL_BSP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BSP_MAX_QUEUE_SIZE:2048,OTEL_BSP_SCHEDULE_DELAY:5e3,OTEL_BLRP_EXPORT_TIMEOUT:3e4,OTEL_BLRP_MAX_EXPORT_BATCH_SIZE:512,OTEL_BLRP_MAX_QUEUE_SIZE:2048,OTEL_BLRP_SCHEDULE_DELAY:5e3,OTEL_EXPORTER_JAEGER_AGENT_HOST:"",OTEL_EXPORTER_JAEGER_AGENT_PORT:6832,OTEL_EXPORTER_JAEGER_ENDPOINT:"",OTEL_EXPORTER_JAEGER_PASSWORD:"",OTEL_EXPORTER_JAEGER_USER:"",OTEL_EXPORTER_OTLP_ENDPOINT:"",OTEL_EXPORTER_OTLP_TRACES_ENDPOINT:"",OTEL_EXPORTER_OTLP_METRICS_ENDPOINT:"",OTEL_EXPORTER_OTLP_LOGS_ENDPOINT:"",OTEL_EXPORTER_OTLP_HEADERS:"",OTEL_EXPORTER_OTLP_TRACES_HEADERS:"",OTEL_EXPORTER_OTLP_METRICS_HEADERS:"",OTEL_EXPORTER_OTLP_LOGS_HEADERS:"",OTEL_EXPORTER_OTLP_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_TRACES_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_METRICS_TIMEOUT:1e4,OTEL_EXPORTER_OTLP_LOGS_TIMEOUT:1e4,OTEL_EXPORTER_ZIPKIN_ENDPOINT:"http://localhost:9411/api/v2/spans",OTEL_LOG_LEVEL:If.INFO,OTEL_NO_PATCH_MODULES:[],OTEL_PROPAGATORS:["tracecontext","baggage"],OTEL_RESOURCE_ATTRIBUTES:"",OTEL_SERVICE_NAME:"",OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_LOGRECORD_ATTRIBUTE_VALUE_LENGTH_LIMIT:Lk,OTEL_LOGRECORD_ATTRIBUTE_COUNT_LIMIT:Mk,OTEL_SPAN_EVENT_COUNT_LIMIT:128,OTEL_SPAN_LINK_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT:128,OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT:128,OTEL_TRACES_EXPORTER:"",OTEL_TRACES_SAMPLER:Sk.ParentBasedAlwaysOn,OTEL_TRACES_SAMPLER_ARG:"",OTEL_LOGS_EXPORTER:"",OTEL_EXPORTER_OTLP_INSECURE:"",OTEL_EXPORTER_OTLP_TRACES_INSECURE:"",OTEL_EXPORTER_OTLP_METRICS_INSECURE:"",OTEL_EXPORTER_OTLP_LOGS_INSECURE:"",OTEL_EXPORTER_OTLP_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CERTIFICATE:"",OTEL_EXPORTER_OTLP_COMPRESSION:"",OTEL_EXPORTER_OTLP_TRACES_COMPRESSION:"",OTEL_EXPORTER_OTLP_METRICS_COMPRESSION:"",OTEL_EXPORTER_OTLP_LOGS_COMPRESSION:"",OTEL_EXPORTER_OTLP_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_KEY:"",OTEL_EXPORTER_OTLP_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_TRACES_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_METRICS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_LOGS_CLIENT_CERTIFICATE:"",OTEL_EXPORTER_OTLP_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_TRACES_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_LOGS_PROTOCOL:"http/protobuf",OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE:"cumulative"};function jk(e,t,n){if(void 0!==n[e]){var r=String(n[e]);t[e]="true"===r.toLowerCase()}}function Ik(e,t,n,r,o){if(void 0===r&&(r=-1/0),void 0===o&&(o=1/0),void 0!==n[e]){var i=Number(n[e]);isNaN(i)||(t[e]=i<r?r:i>o?o:i)}}function Fk(e,t,n,r){void 0===r&&(r=",");var o=n[e];"string"==typeof o&&(t[e]=o.split(r).map((function(e){return e.trim()})))}var Uk={ALL:If.ALL,VERBOSE:If.VERBOSE,DEBUG:If.DEBUG,INFO:If.INFO,WARN:If.WARN,ERROR:If.ERROR,NONE:If.NONE};function $k(e,t,n){var r=n[e];if("string"==typeof r){var o=Uk[r.toUpperCase()];null!=o&&(t[e]=o)}}function Bk(e){var t={};for(var n in Dk){var r=n;if("OTEL_LOG_LEVEL"===r)$k(r,t,e);else if(Ok(r))jk(r,t,e);else if(Rk(r))Ik(r,t,e);else if(kk(r))Fk(r,t,e);else{var o=e[r];null!=o&&(t[r]=String(o))}}return t}var Vk="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{};function qk(){var e=Bk(Vk);return Object.assign({},Dk,e)}var zk=performance;function Hk(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}var Gk,Kk=Hk(["aws.lambda.invoked_arn","db.system","db.connection_string","db.user","db.jdbc.driver_classname","db.name","db.statement","db.operation","db.mssql.instance_name","db.cassandra.keyspace","db.cassandra.page_size","db.cassandra.consistency_level","db.cassandra.table","db.cassandra.idempotence","db.cassandra.speculative_execution_count","db.cassandra.coordinator.id","db.cassandra.coordinator.dc","db.hbase.namespace","db.redis.database_index","db.mongodb.collection","db.sql.table","exception.type","exception.message","exception.stacktrace","exception.escaped","faas.trigger","faas.execution","faas.document.collection","faas.document.operation","faas.document.time","faas.document.name","faas.time","faas.cron","faas.coldstart","faas.invoked_name","faas.invoked_provider","faas.invoked_region","net.transport","net.peer.ip","net.peer.port","net.peer.name","net.host.ip","net.host.port","net.host.name","net.host.connection.type","net.host.connection.subtype","net.host.carrier.name","net.host.carrier.mcc","net.host.carrier.mnc","net.host.carrier.icc","peer.service","enduser.id","enduser.role","enduser.scope","thread.id","thread.name","code.function","code.namespace","code.filepath","code.lineno","http.method","http.url","http.target","http.host","http.scheme","http.status_code","http.flavor","http.user_agent","http.request_content_length","http.request_content_length_uncompressed","http.response_content_length","http.response_content_length_uncompressed","http.server_name","http.route","http.client_ip","aws.dynamodb.table_names","aws.dynamodb.consumed_capacity","aws.dynamodb.item_collection_metrics","aws.dynamodb.provisioned_read_capacity","aws.dynamodb.provisioned_write_capacity","aws.dynamodb.consistent_read","aws.dynamodb.projection","aws.dynamodb.limit","aws.dynamodb.attributes_to_get","aws.dynamodb.index_name","aws.dynamodb.select","aws.dynamodb.global_secondary_indexes","aws.dynamodb.local_secondary_indexes","aws.dynamodb.exclusive_start_table","aws.dynamodb.table_count","aws.dynamodb.scan_forward","aws.dynamodb.segment","aws.dynamodb.total_segments","aws.dynamodb.count","aws.dynamodb.scanned_count","aws.dynamodb.attribute_definitions","aws.dynamodb.global_secondary_index_updates","messaging.system","messaging.destination","messaging.destination_kind","messaging.temp_destination","messaging.protocol","messaging.protocol_version","messaging.url","messaging.message_id","messaging.conversation_id","messaging.message_payload_size_bytes","messaging.message_payload_compressed_size_bytes","messaging.operation","messaging.consumer_id","messaging.rabbitmq.routing_key","messaging.kafka.message_key","messaging.kafka.consumer_group","messaging.kafka.client_id","messaging.kafka.partition","messaging.kafka.tombstone","rpc.system","rpc.service","rpc.method","rpc.grpc.status_code","rpc.jsonrpc.version","rpc.jsonrpc.request_id","rpc.jsonrpc.error_code","rpc.jsonrpc.error_message","message.type","message.id","message.compressed_size","message.uncompressed_size"]),Wk="service.name",Yk="telemetry.sdk.name",Xk="telemetry.sdk.language",Qk="telemetry.sdk.version",Zk=Wk,Jk=Yk,eL=Xk,tL=Qk,nL=Hk(["cloud.provider","cloud.account.id","cloud.region","cloud.availability_zone","cloud.platform","aws.ecs.container.arn","aws.ecs.cluster.arn","aws.ecs.launchtype","aws.ecs.task.arn","aws.ecs.task.family","aws.ecs.task.revision","aws.eks.cluster.arn","aws.log.group.names","aws.log.group.arns","aws.log.stream.names","aws.log.stream.arns","container.name","container.id","container.runtime","container.image.name","container.image.tag","deployment.environment","device.id","device.model.identifier","device.model.name","faas.name","faas.id","faas.version","faas.instance","faas.max_memory","host.id","host.name","host.type","host.arch","host.image.name","host.image.id","host.image.version","k8s.cluster.name","k8s.node.name","k8s.node.uid","k8s.namespace.name","k8s.pod.uid","k8s.pod.name","k8s.container.name","k8s.replicaset.uid","k8s.replicaset.name","k8s.deployment.uid","k8s.deployment.name","k8s.statefulset.uid","k8s.statefulset.name","k8s.daemonset.uid","k8s.daemonset.name","k8s.job.uid","k8s.job.name","k8s.cronjob.uid","k8s.cronjob.name","os.type","os.description","os.name","os.version","process.pid","process.executable.name","process.executable.path","process.command","process.command_line","process.command_args","process.owner","process.runtime.name","process.runtime.version","process.runtime.description",Wk,"service.namespace","service.instance.id","service.version",Yk,Xk,Qk,"telemetry.auto.version","webengine.name","webengine.version","webengine.description"]),rL=Hk(["cpp","dotnet","erlang","go","java","nodejs","php","python","ruby","webjs"]),oL=((Gk={})[nL.TELEMETRY_SDK_NAME]="opentelemetry",Gk[nL.PROCESS_RUNTIME_NAME]="browser",Gk[nL.TELEMETRY_SDK_LANGUAGE]=rL.WEBJS,Gk[nL.TELEMETRY_SDK_VERSION]="1.24.1",Gk);var iL,aL=Math.pow(10,6),sL=Math.pow(10,9);function lL(e){return[Math.trunc(e/1e3),Math.round(e%1e3*aL)]}function cL(){var e=zk.timeOrigin;if("number"!=typeof e){e=zk.timing&&zk.timing.fetchStart}return e}function uL(e){return gL(lL(cL()),lL("number"==typeof e?e:zk.now()))}function dL(e){if(hL(e))return e;if("number"==typeof e)return e<cL()?uL(e):lL(e);if(e instanceof Date)return lL(e.getTime());throw TypeError("Invalid input type")}function pL(e){return e[0]*sL+e[1]}function fL(e){return 1e6*e[0]+e[1]/1e3}function hL(e){return Array.isArray(e)&&2===e.length&&"number"==typeof e[0]&&"number"==typeof e[1]}function mL(e){return hL(e)||"number"==typeof e||e instanceof Date}function gL(e,t){var n=[e[0]+t[0],e[1]+t[1]];return n[1]>=sL&&(n[1]-=sL,n[0]+=1),n}!function(e){e[e.SUCCESS=0]="SUCCESS",e[e.FAILED=1]="FAILED"}(iL||(iL={}));var yL=function(){function e(e){var t;void 0===e&&(e={}),this._propagators=null!==(t=e.propagators)&&void 0!==t?t:[],this._fields=Array.from(new Set(this._propagators.map((function(e){return"function"==typeof e.fields?e.fields():[]})).reduce((function(e,t){return e.concat(t)}),[])))}return e.prototype.inject=function(e,t,n){var r,o;try{for(var i=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(this._propagators),a=i.next();!a.done;a=i.next()){var s=a.value;try{s.inject(e,t,n)}catch(l){im.warn("Failed to inject with "+s.constructor.name+". Err: "+l.message)}}}catch(c){r={error:c}}finally{try{a&&!a.done&&(o=i.return)&&o.call(i)}finally{if(r)throw r.error}}},e.prototype.extract=function(e,t,n){return this._propagators.reduce((function(e,r){try{return r.extract(e,t,n)}catch(o){im.warn("Failed to inject with "+r.constructor.name+". Err: "+o.message)}return e}),e)},e.prototype.fields=function(){return this._fields.slice()},e}(),vL="[_0-9a-z-*/]",bL=new RegExp("^(?:"+("[a-z]"+vL+"{0,255}")+"|"+("[a-z0-9]"+vL+"{0,240}@[a-z]"+vL+"{0,13}")+")$"),wL=/^[ -~]{0,255}[!-~]$/,xL=/,|=/;var EL=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return bL.test(e)})(o)&&function(e){return wL.test(e)&&!xL.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),_L="traceparent",SL="tracestate",TL=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");var CL=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!hk(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,_L,o),r.traceState&&n.set(t,SL,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,_L);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=function(e){var t=TL.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,SL);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new EL("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[_L,SL]},e}(),AL="[object Null]",OL="[object Undefined]",NL=Function.prototype.toString,RL=NL.call(Object),PL=function(e,t){return function(n){return e(t(n))}}(Object.getPrototypeOf,Object),kL=Object.prototype,LL=kL.hasOwnProperty,ML=Symbol?Symbol.toStringTag:void 0,DL=kL.toString;function jL(e){if(!function(e){return null!=e&&"object"==typeof e}(e)||"[object Object]"!==function(e){if(null==e)return void 0===e?OL:AL;return ML&&ML in Object(e)?function(e){var t=LL.call(e,ML),n=e[ML],r=!1;try{e[ML]=void 0,r=!0}catch(tme){}var o=DL.call(e);r&&(t?e[ML]=n:delete e[ML]);return o}(e):function(e){return DL.call(e)}(e)}(e))return!1;var t=PL(e);if(null===t)return!0;var n=LL.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&NL.call(n)===RL}function IL(e){return $L(e)?e.slice():e}function FL(e,t,n,r){var o;if(void 0===n&&(n=0),!(n>20)){if(n++,qL(e)||qL(t)||BL(t))o=IL(t);else if($L(e)){if(o=e.slice(),$L(t))for(var i=0,a=t.length;i<a;i++)o.push(IL(t[i]));else if(VL(t))for(i=0,a=(s=Object.keys(t)).length;i<a;i++){o[l=s[i]]=IL(t[l])}}else if(VL(e))if(VL(t)){if(!function(e,t){if(!jL(e)||!jL(t))return!1;return!0}(e,t))return t;o=Object.assign({},e);var s;for(i=0,a=(s=Object.keys(t)).length;i<a;i++){var l,c=t[l=s[i]];if(qL(c))void 0===c?delete o[l]:o[l]=c;else{var u=o[l],d=c;if(UL(e,l,r)||UL(t,l,r))delete o[l];else{if(VL(u)&&VL(d)){var p=r.get(u)||[],f=r.get(d)||[];p.push({obj:e,key:l}),f.push({obj:t,key:l}),r.set(u,p),r.set(d,f)}o[l]=FL(o[l],c,n,r)}}}}else o=t;return o}}function UL(e,t,n){for(var r=n.get(e[t])||[],o=0,i=r.length;o<i;o++){var a=r[o];if(a.key===t&&a.obj===e)return!0}return!1}function $L(e){return Array.isArray(e)}function BL(e){return"function"==typeof e}function VL(e){return!qL(e)&&!$L(e)&&!BL(e)&&"object"==typeof e}function qL(e){return"string"==typeof e||"number"==typeof e||"boolean"==typeof e||void 0===e||e instanceof Date||e instanceof RegExp||null===e}var zL=function(){function e(){var e=this;this._promise=new Promise((function(t,n){e._resolve=t,e._reject=n}))}return Object.defineProperty(e.prototype,"promise",{get:function(){return this._promise},enumerable:!1,configurable:!0}),e.prototype.resolve=function(e){this._resolve(e)},e.prototype.reject=function(e){this._reject(e)},e}(),HL=function(){function e(e,t){this._callback=e,this._that=t,this._isCalled=!1,this._deferred=new zL}return Object.defineProperty(e.prototype,"isCalled",{get:function(){return this._isCalled},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"promise",{get:function(){return this._deferred.promise},enumerable:!1,configurable:!0}),e.prototype.call=function(){for(var e,t=this,n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];if(!this._isCalled){this._isCalled=!0;try{Promise.resolve((e=this._callback).call.apply(e,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([this._that],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(n),!1))).then((function(e){return t._deferred.resolve(e)}),(function(e){return t._deferred.reject(e)}))}catch(o){this._deferred.reject(o)}}return this._deferred.promise},e}();var GL,KL={_export:function(e,t){return new Promise((function(n){om.with(fk(om.active()),(function(){e.export(t,(function(e){n(e)}))}))}))}},WL=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},YL=function(){function e(e,t,n,r,o,i,a,s,l,c){void 0===a&&(a=[]),this.attributes={},this.links=[],this.events=[],this._droppedAttributesCount=0,this._droppedEventsCount=0,this._droppedLinksCount=0,this.status={code:Kh.UNSET},this.endTime=[0,0],this._ended=!1,this._duration=[-1,-1],this.name=n,this._spanContext=r,this.parentSpanId=i,this.kind=o,this.links=a;var u=Date.now();this._performanceStartTime=zk.now(),this._performanceOffset=u-(this._performanceStartTime+cL()),this._startTimeProvided=null!=s,this.startTime=this._getTime(null!=s?s:u),this.resource=e.resource,this.instrumentationLibrary=e.instrumentationLibrary,this._spanLimits=e.getSpanLimits(),this._attributeValueLengthLimit=this._spanLimits.attributeValueLengthLimit||0,null!=c&&this.setAttributes(c),this._spanProcessor=e.getActiveSpanProcessor(),this._spanProcessor.onStart(this,t)}return e.prototype.spanContext=function(){return this._spanContext},e.prototype.setAttribute=function(e,t){return null==t||this._isSpanEnded()?this:0===e.length?(im.warn("Invalid attribute key: "+e),this):Ek(t)?Object.keys(this.attributes).length>=this._spanLimits.attributeCountLimit&&!Object.prototype.hasOwnProperty.call(this.attributes,e)?(this._droppedAttributesCount++,this):(this.attributes[e]=this._truncateToSize(t),this):(im.warn("Invalid attribute value set for key: "+e),this)},e.prototype.setAttributes=function(e){var t,n;try{for(var r=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(Object.entries(e)),o=r.next();!o.done;o=r.next()){var i=WL(o.value,2);this.setAttribute(i[0],i[1])}}catch(a){t={error:a}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}return this},e.prototype.addEvent=function(e,t,n){if(this._isSpanEnded())return this;if(0===this._spanLimits.eventCountLimit)return im.warn("No events allowed."),this._droppedEventsCount++,this;this.events.length>=this._spanLimits.eventCountLimit&&(0===this._droppedEventsCount&&im.debug("Dropping extra events."),this.events.shift(),this._droppedEventsCount++),mL(t)&&(mL(n)||(n=t),t=void 0);var r=wk(t);return this.events.push({name:e,attributes:r,time:this._getTime(n),droppedAttributesCount:0}),this},e.prototype.setStatus=function(e){return this._isSpanEnded()||(this.status=e),this},e.prototype.updateName=function(e){return this._isSpanEnded()||(this.name=e),this},e.prototype.end=function(e){this._isSpanEnded()?im.error(this.name+" "+this._spanContext.traceId+"-"+this._spanContext.spanId+" - You can only call end() on a span once."):(this._ended=!0,this.endTime=this._getTime(e),this._duration=function(e,t){var n=t[0]-e[0],r=t[1]-e[1];return r<0&&(n-=1,r+=sL),[n,r]}(this.startTime,this.endTime),this._duration[0]<0&&(im.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.",this.startTime,this.endTime),this.endTime=this.startTime.slice(),this._duration=[0,0]),this._droppedEventsCount>0&&im.warn("Dropped "+this._droppedEventsCount+" events because eventCountLimit reached"),this._spanProcessor.onEnd(this))},e.prototype._getTime=function(e){if("number"==typeof e&&e<zk.now())return uL(e+this._performanceOffset);if("number"==typeof e)return lL(e);if(e instanceof Date)return lL(e.getTime());if(hL(e))return e;if(this._startTimeProvided)return lL(Date.now());var t=zk.now()-this._performanceStartTime;return gL(this.startTime,lL(t))},e.prototype.isRecording=function(){return!1===this._ended},e.prototype.recordException=function(e,t){var n={};"string"==typeof e?n[Kk.EXCEPTION_MESSAGE]=e:e&&(e.code?n[Kk.EXCEPTION_TYPE]=e.code.toString():e.name&&(n[Kk.EXCEPTION_TYPE]=e.name),e.message&&(n[Kk.EXCEPTION_MESSAGE]=e.message),e.stack&&(n[Kk.EXCEPTION_STACKTRACE]=e.stack)),n[Kk.EXCEPTION_TYPE]||n[Kk.EXCEPTION_MESSAGE]?this.addEvent("exception",n,t):im.warn("Failed to record an exception "+e)},Object.defineProperty(e.prototype,"duration",{get:function(){return this._duration},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ended",{get:function(){return this._ended},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedAttributesCount",{get:function(){return this._droppedAttributesCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedEventsCount",{get:function(){return this._droppedEventsCount},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"droppedLinksCount",{get:function(){return this._droppedLinksCount},enumerable:!1,configurable:!0}),e.prototype._isSpanEnded=function(){return this._ended&&im.warn("Can not execute the operation on ended Span {traceId: "+this._spanContext.traceId+", spanId: "+this._spanContext.spanId+"}"),this._ended},e.prototype._truncateToLimitUtil=function(e,t){return e.length<=t?e:e.substr(0,t)},e.prototype._truncateToSize=function(e){var t=this,n=this._attributeValueLengthLimit;return n<=0?(im.warn("Attribute value limit must be positive, got "+n),e):"string"==typeof e?this._truncateToLimitUtil(e,n):Array.isArray(e)?e.map((function(e){return"string"==typeof e?t._truncateToLimitUtil(e,n):e})):e},e}();!function(e){e[e.NOT_RECORD=0]="NOT_RECORD",e[e.RECORD=1]="RECORD",e[e.RECORD_AND_SAMPLED=2]="RECORD_AND_SAMPLED"}(GL||(GL={}));var XL=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:GL.NOT_RECORD}},e.prototype.toString=function(){return"AlwaysOffSampler"},e}(),QL=function(){function e(){}return e.prototype.shouldSample=function(){return{decision:GL.RECORD_AND_SAMPLED}},e.prototype.toString=function(){return"AlwaysOnSampler"},e}(),ZL=function(){function e(e){var t,n,r,o;this._root=e.root,this._root||(Ck(new Error("ParentBasedSampler must have a root sampler configured")),this._root=new QL),this._remoteParentSampled=null!==(t=e.remoteParentSampled)&&void 0!==t?t:new QL,this._remoteParentNotSampled=null!==(n=e.remoteParentNotSampled)&&void 0!==n?n:new XL,this._localParentSampled=null!==(r=e.localParentSampled)&&void 0!==r?r:new QL,this._localParentNotSampled=null!==(o=e.localParentNotSampled)&&void 0!==o?o:new XL}return e.prototype.shouldSample=function(e,t,n,r,o,i){var a=bm.getSpanContext(e);return a&&Uh(a)?a.isRemote?a.traceFlags&gh.SAMPLED?this._remoteParentSampled.shouldSample(e,t,n,r,o,i):this._remoteParentNotSampled.shouldSample(e,t,n,r,o,i):a.traceFlags&gh.SAMPLED?this._localParentSampled.shouldSample(e,t,n,r,o,i):this._localParentNotSampled.shouldSample(e,t,n,r,o,i):this._root.shouldSample(e,t,n,r,o,i)},e.prototype.toString=function(){return"ParentBased{root="+this._root.toString()+", remoteParentSampled="+this._remoteParentSampled.toString()+", remoteParentNotSampled="+this._remoteParentNotSampled.toString()+", localParentSampled="+this._localParentSampled.toString()+", localParentNotSampled="+this._localParentNotSampled.toString()+"}"},e}(),JL=function(){function e(e){void 0===e&&(e=0),this._ratio=e,this._ratio=this._normalize(e),this._upperBound=Math.floor(4294967295*this._ratio)}return e.prototype.shouldSample=function(e,t){return{decision:Ih(t)&&this._accumulate(t)<this._upperBound?GL.RECORD_AND_SAMPLED:GL.NOT_RECORD}},e.prototype.toString=function(){return"TraceIdRatioBased{"+this._ratio+"}"},e.prototype._normalize=function(e){return"number"!=typeof e||isNaN(e)?0:e>=1?1:e<=0?0:e},e.prototype._accumulate=function(e){for(var t=0,n=0;n<e.length/8;n++){var r=8*n;t=(t^parseInt(e.slice(r,r+8),16))>>>0}return t},e}(),eM=qk(),tM=Sk.AlwaysOn;function nM(){return{sampler:rM(eM),forceFlushTimeoutMillis:3e4,generalLimits:{attributeValueLengthLimit:qk().OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:qk().OTEL_ATTRIBUTE_COUNT_LIMIT},spanLimits:{attributeValueLengthLimit:qk().OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT,attributeCountLimit:qk().OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT,linkCountLimit:qk().OTEL_SPAN_LINK_COUNT_LIMIT,eventCountLimit:qk().OTEL_SPAN_EVENT_COUNT_LIMIT,attributePerEventCountLimit:qk().OTEL_SPAN_ATTRIBUTE_PER_EVENT_COUNT_LIMIT,attributePerLinkCountLimit:qk().OTEL_SPAN_ATTRIBUTE_PER_LINK_COUNT_LIMIT}}}function rM(e){switch(void 0===e&&(e=qk()),e.OTEL_TRACES_SAMPLER){case Sk.AlwaysOn:return new QL;case Sk.AlwaysOff:return new XL;case Sk.ParentBasedAlwaysOn:return new ZL({root:new QL});case Sk.ParentBasedAlwaysOff:return new ZL({root:new XL});case Sk.TraceIdRatio:return new JL(oM(e));case Sk.ParentBasedTraceIdRatio:return new ZL({root:new JL(oM(e))});default:return im.error('OTEL_TRACES_SAMPLER value "'+e.OTEL_TRACES_SAMPLER+" invalid, defaulting to "+tM+'".'),new QL}}function oM(e){if(void 0===e.OTEL_TRACES_SAMPLER_ARG||""===e.OTEL_TRACES_SAMPLER_ARG)return im.error("OTEL_TRACES_SAMPLER_ARG is blank, defaulting to 1."),1;var t=Number(e.OTEL_TRACES_SAMPLER_ARG);return isNaN(t)?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is invalid, defaulting to 1."),1):t<0||t>1?(im.error("OTEL_TRACES_SAMPLER_ARG="+e.OTEL_TRACES_SAMPLER_ARG+" was given, but it is out of range ([0..1]), defaulting to 1."),1):t}function iM(e){var t,n,r,o,i,a,s,l,c,u,d,p,f=Object.assign({},e.spanLimits),h=Bk(Vk);return f.attributeCountLimit=null!==(a=null!==(i=null!==(o=null!==(n=null===(t=e.spanLimits)||void 0===t?void 0:t.attributeCountLimit)&&void 0!==n?n:null===(r=e.generalLimits)||void 0===r?void 0:r.attributeCountLimit)&&void 0!==o?o:h.OTEL_SPAN_ATTRIBUTE_COUNT_LIMIT)&&void 0!==i?i:h.OTEL_ATTRIBUTE_COUNT_LIMIT)&&void 0!==a?a:Mk,f.attributeValueLengthLimit=null!==(p=null!==(d=null!==(u=null!==(l=null===(s=e.spanLimits)||void 0===s?void 0:s.attributeValueLengthLimit)&&void 0!==l?l:null===(c=e.generalLimits)||void 0===c?void 0:c.attributeValueLengthLimit)&&void 0!==u?u:h.OTEL_SPAN_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==d?d:h.OTEL_ATTRIBUTE_VALUE_LENGTH_LIMIT)&&void 0!==p?p:Lk,Object.assign({},e,{spanLimits:f})}var aM=function(){function e(e,t){this._exporter=e,this._isExporting=!1,this._finishedSpans=[],this._droppedSpansCount=0;var n=qk();this._maxExportBatchSize="number"==typeof(null==t?void 0:t.maxExportBatchSize)?t.maxExportBatchSize:n.OTEL_BSP_MAX_EXPORT_BATCH_SIZE,this._maxQueueSize="number"==typeof(null==t?void 0:t.maxQueueSize)?t.maxQueueSize:n.OTEL_BSP_MAX_QUEUE_SIZE,this._scheduledDelayMillis="number"==typeof(null==t?void 0:t.scheduledDelayMillis)?t.scheduledDelayMillis:n.OTEL_BSP_SCHEDULE_DELAY,this._exportTimeoutMillis="number"==typeof(null==t?void 0:t.exportTimeoutMillis)?t.exportTimeoutMillis:n.OTEL_BSP_EXPORT_TIMEOUT,this._shutdownOnce=new HL(this._shutdown,this),this._maxExportBatchSize>this._maxQueueSize&&(im.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"),this._maxExportBatchSize=this._maxQueueSize)}return e.prototype.forceFlush=function(){return this._shutdownOnce.isCalled?this._shutdownOnce.promise:this._flushAll()},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){this._shutdownOnce.isCalled||e.spanContext().traceFlags&gh.SAMPLED&&this._addToBuffer(e)},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){var e=this;return Promise.resolve().then((function(){return e.onShutdown()})).then((function(){return e._flushAll()})).then((function(){return e._exporter.shutdown()}))},e.prototype._addToBuffer=function(e){if(this._finishedSpans.length>=this._maxQueueSize)return 0===this._droppedSpansCount&&im.debug("maxQueueSize reached, dropping spans"),void this._droppedSpansCount++;this._droppedSpansCount>0&&(im.warn("Dropped "+this._droppedSpansCount+" spans because maxQueueSize reached"),this._droppedSpansCount=0),this._finishedSpans.push(e),this._maybeStartTimer()},e.prototype._flushAll=function(){var e=this;return new Promise((function(t,n){for(var r=[],o=0,i=Math.ceil(e._finishedSpans.length/e._maxExportBatchSize);o<i;o++)r.push(e._flushOneBatch());Promise.all(r).then((function(){t()})).catch(n)}))},e.prototype._flushOneBatch=function(){var e=this;return this._clearTimer(),0===this._finishedSpans.length?Promise.resolve():new Promise((function(t,n){var r=setTimeout((function(){n(new Error("Timeout"))}),e._exportTimeoutMillis);om.with(fk(om.active()),(function(){var o;e._finishedSpans.length<=e._maxExportBatchSize?(o=e._finishedSpans,e._finishedSpans=[]):o=e._finishedSpans.splice(0,e._maxExportBatchSize);for(var i=function(){return e._exporter.export(o,(function(e){var o;clearTimeout(r),e.code===iL.SUCCESS?t():n(null!==(o=e.error)&&void 0!==o?o:new Error("BatchSpanProcessor: span export failed"))}))},a=null,s=0,l=o.length;s<l;s++){var c=o[s];c.resource.asyncAttributesPending&&c.resource.waitForAsyncAttributes&&(null!=a||(a=[]),a.push(c.resource.waitForAsyncAttributes()))}null===a?i():Promise.all(a).then(i,(function(e){Ck(e),n(e)}))}))}))},e.prototype._maybeStartTimer=function(){var e=this;if(!this._isExporting){var t=function(){e._isExporting=!0,e._flushOneBatch().finally((function(){e._isExporting=!1,e._finishedSpans.length>0&&(e._clearTimer(),e._maybeStartTimer())})).catch((function(t){e._isExporting=!1,Ck(t)}))};if(this._finishedSpans.length>=this._maxExportBatchSize)return t();void 0===this._timer&&(this._timer=setTimeout((function(){return t()}),this._scheduledDelayMillis))}},e.prototype._clearTimer=function(){void 0!==this._timer&&(clearTimeout(this._timer),this._timer=void 0)},e}(),sM=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),lM=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.onInit(n),r}return sM(t,e),t.prototype.onInit=function(e){var t=this;!0!==(null==e?void 0:e.disableAutoFlushOnDocumentHide)&&"undefined"!=typeof document&&(this._visibilityChangeListener=function(){"hidden"===document.visibilityState&&t.forceFlush()},this._pageHideListener=function(){t.forceFlush()},document.addEventListener("visibilitychange",this._visibilityChangeListener),document.addEventListener("pagehide",this._pageHideListener))},t.prototype.onShutdown=function(){"undefined"!=typeof document&&(this._visibilityChangeListener&&document.removeEventListener("visibilitychange",this._visibilityChangeListener),this._pageHideListener&&document.removeEventListener("pagehide",this._pageHideListener))},t}(aM),cM=function(){return function(){this.generateTraceId=dM(16),this.generateSpanId=dM(8)}}(),uM=Array(32);function dM(e){return function(){for(var t=0;t<2*e;t++)uM[t]=Math.floor(16*Math.random())+48,uM[t]>=58&&(uM[t]+=39);return String.fromCharCode.apply(null,uM.slice(0,2*e))}}var pM=function(){function e(e,t,n){this._tracerProvider=n;var r,o,i,a,s=(r=t,o={sampler:rM()},i=nM(),(a=Object.assign({},i,o,r)).generalLimits=Object.assign({},i.generalLimits,r.generalLimits||{}),a.spanLimits=Object.assign({},i.spanLimits,r.spanLimits||{}),a);this._sampler=s.sampler,this._generalLimits=s.generalLimits,this._spanLimits=s.spanLimits,this._idGenerator=t.idGenerator||new cM,this.resource=n.resource,this.instrumentationLibrary=e}return e.prototype.startSpan=function(e,t,n){var r,o,i;void 0===t&&(t={}),void 0===n&&(n=om.active()),t.root&&(n=bm.deleteSpan(n));var a=bm.getSpan(n);if(hk(n))return im.debug("Instrumentation suppressed, returning Noop Span"),bm.wrapSpanContext(Ch);var s,l,c,u=null==a?void 0:a.spanContext(),d=this._idGenerator.generateSpanId();u&&bm.isSpanContextValid(u)?(s=u.traceId,l=u.traceState,c=u.spanId):s=this._idGenerator.generateTraceId();var p=null!==(r=t.kind)&&void 0!==r?r:Hh.INTERNAL,f=(null!==(o=t.links)&&void 0!==o?o:[]).map((function(e){return{context:e.context,attributes:wk(e.attributes)}})),h=wk(t.attributes),m=this._sampler.shouldSample(n,s,e,p,h,f);l=null!==(i=m.traceState)&&void 0!==i?i:l;var g={traceId:s,spanId:d,traceFlags:m.decision===qh.RECORD_AND_SAMPLED?gh.SAMPLED:gh.NONE,traceState:l};if(m.decision===qh.NOT_RECORD)return im.debug("Recording is off, propagating context in a non-recording span"),bm.wrapSpanContext(g);var y=wk(Object.assign(h,m.attributes));return new YL(this,n,e,g,p,c,f,t.startTime,void 0,y)},e.prototype.startActiveSpan=function(e,t,n,r){var o,i,a;if(!(arguments.length<2)){2===arguments.length?a=t:3===arguments.length?(o=t,a=n):(o=t,i=n,a=r);var s=null!=i?i:om.active(),l=this.startSpan(e,o,s),c=bm.setSpan(s,l);return om.with(c,a,void 0,l)}},e.prototype.getGeneralLimits=function(){return this._generalLimits},e.prototype.getSpanLimits=function(){return this._spanLimits},e.prototype.getActiveSpanProcessor=function(){return this._tracerProvider.getActiveSpanProcessor()},e}();var fM,hM=function(){return hM=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},hM.apply(this,arguments)},mM=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},gM=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},yM=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[Zk]="unknown_service",t[eL]=oL[eL],t[Jk]=oL[Jk],t[tL]=oL[tL],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return mM(this,void 0,void 0,(function(){return gM(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=hM(hM({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return hM(hM(hM(hM({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),vM=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},bM=function(){function e(e){this._spanProcessors=e}return e.prototype.forceFlush=function(){var e,t,n=[];try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.forceFlush())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e){Promise.all(n).then((function(){e()})).catch((function(t){Ck(t||new Error("MultiSpanProcessor: forceFlush failed")),e()}))}))},e.prototype.onStart=function(e,t){var n,r;try{for(var o=vM(this._spanProcessors),i=o.next();!i.done;i=o.next()){i.value.onStart(e,t)}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}},e.prototype.onEnd=function(e){var t,n;try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){o.value.onEnd(e)}}catch(i){t={error:i}}finally{try{o&&!o.done&&(n=r.return)&&n.call(r)}finally{if(t)throw t.error}}},e.prototype.shutdown=function(){var e,t,n=[];try{for(var r=vM(this._spanProcessors),o=r.next();!o.done;o=r.next()){n.push(o.value.shutdown())}}catch(i){e={error:i}}finally{try{o&&!o.done&&(t=r.return)&&t.call(r)}finally{if(e)throw e.error}}return new Promise((function(e,t){Promise.all(n).then((function(){e()}),t)}))},e}(),wM=function(){function e(){}return e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){},e.prototype.shutdown=function(){return Promise.resolve()},e.prototype.forceFlush=function(){return Promise.resolve()},e}();!function(e){e[e.resolved=0]="resolved",e[e.timeout=1]="timeout",e[e.error=2]="error",e[e.unresolved=3]="unresolved"}(fM||(fM={}));var xM,EM,_M,SM=function(){function e(e){var t;void 0===e&&(e={}),this._registeredSpanProcessors=[],this._tracers=new Map;var n=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=e.shift(),r=new WeakMap;e.length>0;)n=FL(n,e.shift(),0,r);return n}({},nM(),iM(e));this.resource=null!==(t=n.resource)&&void 0!==t?t:yM.empty(),this.resource=yM.default().merge(this.resource),this._config=Object.assign({},n,{resource:this.resource});var r=this._buildExporterFromEnv();if(void 0!==r){var o=new lM(r);this.activeSpanProcessor=o}else this.activeSpanProcessor=new wM}return e.prototype.getTracer=function(e,t,n){var r=e+"@"+(t||"")+":"+((null==n?void 0:n.schemaUrl)||"");return this._tracers.has(r)||this._tracers.set(r,new pM({name:e,version:t,schemaUrl:null==n?void 0:n.schemaUrl},this._config,this)),this._tracers.get(r)},e.prototype.addSpanProcessor=function(e){0===this._registeredSpanProcessors.length&&this.activeSpanProcessor.shutdown().catch((function(e){return im.error("Error while trying to shutdown current span processor",e)})),this._registeredSpanProcessors.push(e),this.activeSpanProcessor=new bM(this._registeredSpanProcessors)},e.prototype.getActiveSpanProcessor=function(){return this.activeSpanProcessor},e.prototype.register=function(e){void 0===e&&(e={}),bm.setGlobalTracerProvider(this),void 0===e.propagator&&(e.propagator=this._buildPropagatorFromEnv()),e.contextManager&&om.setGlobalContextManager(e.contextManager),e.propagator&&ym.setGlobalPropagator(e.propagator)},e.prototype.forceFlush=function(){var e=this._config.forceFlushTimeoutMillis,t=this._registeredSpanProcessors.map((function(t){return new Promise((function(n){var r,o=setTimeout((function(){n(new Error("Span processor did not completed within timeout period of "+e+" ms")),r=fM.timeout}),e);t.forceFlush().then((function(){clearTimeout(o),r!==fM.timeout&&n(r=fM.resolved)})).catch((function(e){clearTimeout(o),r=fM.error,n(e)}))}))}));return new Promise((function(e,n){Promise.all(t).then((function(t){var r=t.filter((function(e){return e!==fM.resolved}));r.length>0?n(r):e()})).catch((function(e){return n([e])}))}))},e.prototype.shutdown=function(){return this.activeSpanProcessor.shutdown()},e.prototype._getPropagator=function(e){var t;return null===(t=this.constructor._registeredPropagators.get(e))||void 0===t?void 0:t()},e.prototype._getSpanExporter=function(e){var t;return null===(t=this.constructor._registeredExporters.get(e))||void 0===t?void 0:t()},e.prototype._buildPropagatorFromEnv=function(){var e=this,t=Array.from(new Set(qk().OTEL_PROPAGATORS)),n=t.map((function(t){var n=e._getPropagator(t);return n||im.warn('Propagator "'+t+'" requested through environment variable is unavailable.'),n})).reduce((function(e,t){return t&&e.push(t),e}),[]);return 0===n.length?void 0:1===t.length?n[0]:new yL({propagators:n})},e.prototype._buildExporterFromEnv=function(){var e=qk().OTEL_TRACES_EXPORTER;if("none"!==e&&""!==e){var t=this._getSpanExporter(e);return t||im.error('Exporter "'+e+'" requested through environment variable is unavailable.'),t}},e._registeredPropagators=new Map([["tracecontext",function(){return new CL}],["baggage",function(){return new yk}]]),e._registeredExporters=new Map,e}(),TM=function(){function e(){}return e.prototype.export=function(e,t){return this._sendSpans(e,t)},e.prototype.shutdown=function(){return this._sendSpans([]),this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype._exportInfo=function(e){var t;return{resource:{attributes:e.resource.attributes},traceId:e.spanContext().traceId,parentId:e.parentSpanId,traceState:null===(t=e.spanContext().traceState)||void 0===t?void 0:t.serialize(),name:e.name,id:e.spanContext().spanId,kind:e.kind,timestamp:fL(e.startTime),duration:fL(e.duration),attributes:e.attributes,status:e.status,events:e.events,links:e.links}},e.prototype._sendSpans=function(e,t){var n,r;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next());}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}if(t)return t({code:iL.SUCCESS})},e}(),CM=function(){function e(){this._finishedSpans=[],this._stopped=!1}return e.prototype.export=function(e,t){var n;if(this._stopped)return t({code:iL.FAILED,error:new Error("Exporter has been stopped")});(n=this._finishedSpans).push.apply(n,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)),setTimeout((function(){return t({code:iL.SUCCESS})}),0)},e.prototype.shutdown=function(){return this._stopped=!0,this._finishedSpans=[],this.forceFlush()},e.prototype.forceFlush=function(){return Promise.resolve()},e.prototype.reset=function(){this._finishedSpans=[]},e.prototype.getFinishedSpans=function(){return this._finishedSpans},e}(),AM=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},OM=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},NM=function(){function e(e){this._exporter=e,this._shutdownOnce=new HL(this._shutdown,this),this._unresolvedExports=new Set}return e.prototype.forceFlush=function(){return AM(this,void 0,void 0,(function(){return OM(this,(function(e){switch(e.label){case 0:return[4,Promise.all(Array.from(this._unresolvedExports))];case 1:return e.sent(),this._exporter.forceFlush?[4,this._exporter.forceFlush()]:[3,3];case 2:e.sent(),e.label=3;case 3:return[2]}}))}))},e.prototype.onStart=function(e,t){},e.prototype.onEnd=function(e){var t,n,r=this;if(!this._shutdownOnce.isCalled&&e.spanContext().traceFlags&gh.SAMPLED){var o=function(){return KL._export(r._exporter,[e]).then((function(e){var t;e.code!==iL.SUCCESS&&Ck(null!==(t=e.error)&&void 0!==t?t:new Error("SimpleSpanProcessor: span export failed (status "+e+")"))})).catch((function(e){Ck(e)}))};if(e.resource.asyncAttributesPending){var i=null===(n=(t=e.resource).waitForAsyncAttributes)||void 0===n?void 0:n.call(t).then((function(){return null!=i&&r._unresolvedExports.delete(i),o()}),(function(e){return Ck(e)}));null!=i&&this._unresolvedExports.add(i)}else o()}},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype._shutdown=function(){return this._exporter.shutdown()},e}(),RM=function(){function e(){this._enabled=!1,this._currentContext=Xf}return e.prototype._bindFunction=function(e,t){void 0===e&&(e=Xf);var n=this,r=function(){for(var r=this,o=[],i=0;i<arguments.length;i++)o[i]=arguments[i];return n.with(e,(function(){return t.apply(r,o)}))};return Object.defineProperty(r,"length",{enumerable:!1,configurable:!0,writable:!1,value:t.length}),r},e.prototype.active=function(){return this._currentContext},e.prototype.bind=function(e,t){return void 0===e&&(e=this.active()),"function"==typeof t?this._bindFunction(e,t):t},e.prototype.disable=function(){return this._currentContext=Xf,this._enabled=!1,this},e.prototype.enable=function(){return this._enabled||(this._enabled=!0,this._currentContext=Xf),this},e.prototype.with=function(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];var i=this._currentContext;this._currentContext=e||Xf;try{return t.call.apply(t,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([n],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(r),!1))}finally{this._currentContext=i}},e}(),PM=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),kM=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;if(t.contextManager)throw"contextManager should be defined in register method not in constructor";if(t.propagator)throw"propagator should be defined in register method not in constructor";return n}return PM(t,e),t.prototype.register=function(t){void 0===t&&(t={}),void 0===t.contextManager&&(t.contextManager=new RM),t.contextManager&&t.contextManager.enable(),e.prototype.register.call(this,t)},t}(SM);function LM(e,t){return t in e}function MM(e,t,n,r){var o=void 0,i=void 0;LM(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=r||xM.FETCH_START;if(LM(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function DM(e,t){MM(e,xM.FETCH_START,t),MM(e,xM.DOMAIN_LOOKUP_START,t),MM(e,xM.DOMAIN_LOOKUP_END,t),MM(e,xM.CONNECT_START,t),LM(t,"name")&&t.name.startsWith("https:")&&MM(e,xM.SECURE_CONNECTION_START,t),MM(e,xM.CONNECT_END,t),MM(e,xM.REQUEST_START,t),MM(e,xM.RESPONSE_START,t),MM(e,xM.RESPONSE_END,t);var n=t[xM.ENCODED_BODY_SIZE];void 0!==n&&e.setAttribute(Kk.HTTP_RESPONSE_CONTENT_LENGTH,n);var r=t[xM.DECODED_BODY_SIZE];void 0!==r&&n!==r&&e.setAttribute(Kk.HTTP_RESPONSE_CONTENT_LENGTH_UNCOMPRESSED,r)}function jM(e){return e.slice().sort((function(e,t){var n=e[xM.FETCH_START],r=t[xM.FETCH_START];return n>r?1:n<r?-1:0}))}function IM(){return"undefined"!=typeof location?location.origin:void 0}function FM(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(_M||(_M=document.createElement("a")),_M);return t.href=e,t}function UM(e,t){if(e.nodeType===Node.DOCUMENT_NODE)return"/";var n=function(e,t){var n=e.nodeType,r=function(e){if(!e.parentNode)return 0;var t=[e.nodeType];e.nodeType===Node.CDATA_SECTION_NODE&&t.push(Node.TEXT_NODE);var n=Array.from(e.parentNode.childNodes);if(n=n.filter((function(n){var r=n.localName;return t.indexOf(n.nodeType)>=0&&r===e.localName})),n.length>=1)return n.indexOf(e)+1;return 0}(e),o="";if(n===Node.ELEMENT_NODE){var i=e.getAttribute("id");if(t&&i)return'//*[@id="'+i+'"]';o=e.localName}else if(n===Node.TEXT_NODE||n===Node.CDATA_SECTION_NODE)o="text()";else{if(n!==Node.COMMENT_NODE)return"";o="comment()"}if(o&&r>1)return"/"+o+"["+r+"]";return"/"+o}(e,t);if(t&&n.indexOf("@id")>0)return n;var r="";return e.parentNode&&(r+=UM(e.parentNode,!1)),r+=n}(EM=xM||(xM={})).CONNECT_END="connectEnd",EM.CONNECT_START="connectStart",EM.DECODED_BODY_SIZE="decodedBodySize",EM.DOM_COMPLETE="domComplete",EM.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",EM.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",EM.DOM_INTERACTIVE="domInteractive",EM.DOMAIN_LOOKUP_END="domainLookupEnd",EM.DOMAIN_LOOKUP_START="domainLookupStart",EM.ENCODED_BODY_SIZE="encodedBodySize",EM.FETCH_START="fetchStart",EM.LOAD_EVENT_END="loadEventEnd",EM.LOAD_EVENT_START="loadEventStart",EM.NAVIGATION_START="navigationStart",EM.REDIRECT_END="redirectEnd",EM.REDIRECT_START="redirectStart",EM.REQUEST_START="requestStart",EM.RESPONSE_END="responseEnd",EM.RESPONSE_START="responseStart",EM.SECURE_CONNECTION_START="secureConnectionStart",EM.UNLOAD_EVENT_END="unloadEventEnd",EM.UNLOAD_EVENT_START="unloadEventStart";const $M=za(Object.freeze(Object.defineProperty({__proto__:null,AlwaysOffSampler:XL,AlwaysOnSampler:QL,BasicTracerProvider:SM,BatchSpanProcessor:lM,ConsoleSpanExporter:TM,get ForceFlushState(){return fM},InMemorySpanExporter:CM,NoopSpanProcessor:wM,ParentBasedSampler:ZL,get PerformanceTimingNames(){return xM},RandomIdGenerator:cM,get SamplingDecision(){return GL},SimpleSpanProcessor:NM,Span:YL,StackContextManager:RM,TraceIdRatioBasedSampler:JL,Tracer:pM,WebTracerProvider:kM,addSpanNetworkEvent:MM,addSpanNetworkEvents:DM,getElementXPath:UM,getResource:function(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=FM(e),s=function(e,t,n,r,o,i){var a=pL(t),s=pL(n),l=r.filter((function(t){var n=pL(dL(t[xM.FETCH_START])),r=pL(dL(t[xM.RESPONSE_END]));return t.initiatorType.toLowerCase()===(i||"xmlhttprequest")&&t.name===e&&n>=a&&r<=s}));l.length>0&&(l=l.filter((function(e){return!o.has(e)})));return l}(e=a.toString(),t,n,r,o,i);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=jM(s);if(a.origin!==IM()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=pL(n),i=pL(dL(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=pL(dL(c[xM.FETCH_START])),d=o-pL(dL(c[xM.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[xM.RESPONSE_END],n);return u[xM.FETCH_START]<c[xM.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}},hasKey:LM,normalizeUrl:function(e){return FM(e).href},parseUrl:FM,shouldPropagateTraceHeaders:function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),FM(e).origin===IM()||n.some((function(t){return n=e,"string"==typeof(r=t)?n===r:!!n.match(r);var n,r}))},sortResources:jM},Symbol.toStringTag,{value:"Module"}))),BM=za(uN);var VM={};Object.defineProperty(VM,"__esModule",{value:!0}),VM.SessionIdSpanProcessor=void 0;const qM=Array(32);function zM(e){for(var t={},n=e.length,r=0;r<n;r++){var o=e[r];o&&(t[String(o).toUpperCase().replace(/[-.]/g,"_")]=o)}return t}VM.SessionIdSpanProcessor=class{constructor(){var e;this._idGenerator=(e=16,function(){for(let t=0;t<2*e;t++)qM[t]=Math.floor(16*Math.random())+48,qM[t]>=58&&(qM[t]+=39);return String.fromCharCode.apply(null,qM.slice(0,2*e))}),this._sessionId=this._idGenerator()}onStart(e){e.setAttribute("session.id",this._sessionId)}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var HM,GM="service.name",KM="telemetry.sdk.name",WM="telemetry.sdk.language",YM="telemetry.sdk.version",XM=GM,QM=KM,ZM=WM,JM=YM,eD=zM(["cloud.provider","cloud.account.id","cloud.region","cloud.availability_zone","cloud.platform","aws.ecs.container.arn","aws.ecs.cluster.arn","aws.ecs.launchtype","aws.ecs.task.arn","aws.ecs.task.family","aws.ecs.task.revision","aws.eks.cluster.arn","aws.log.group.names","aws.log.group.arns","aws.log.stream.names","aws.log.stream.arns","container.name","container.id","container.runtime","container.image.name","container.image.tag","deployment.environment","device.id","device.model.identifier","device.model.name","faas.name","faas.id","faas.version","faas.instance","faas.max_memory","host.id","host.name","host.type","host.arch","host.image.name","host.image.id","host.image.version","k8s.cluster.name","k8s.node.name","k8s.node.uid","k8s.namespace.name","k8s.pod.uid","k8s.pod.name","k8s.container.name","k8s.replicaset.uid","k8s.replicaset.name","k8s.deployment.uid","k8s.deployment.name","k8s.statefulset.uid","k8s.statefulset.name","k8s.daemonset.uid","k8s.daemonset.name","k8s.job.uid","k8s.job.name","k8s.cronjob.uid","k8s.cronjob.name","os.type","os.description","os.name","os.version","process.pid","process.executable.name","process.executable.path","process.command","process.command_line","process.command_args","process.owner","process.runtime.name","process.runtime.version","process.runtime.description",GM,"service.namespace","service.instance.id","service.version",KM,WM,YM,"telemetry.auto.version","webengine.name","webengine.version","webengine.description"]),tD=zM(["cpp","dotnet","erlang","go","java","nodejs","php","python","ruby","webjs"]),nD=((HM={})[eD.TELEMETRY_SDK_NAME]="opentelemetry",HM[eD.PROCESS_RUNTIME_NAME]="browser",HM[eD.TELEMETRY_SDK_LANGUAGE]=tD.WEBJS,HM[eD.TELEMETRY_SDK_VERSION]="1.24.1",HM);var rD=function(){return rD=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},rD.apply(this,arguments)},oD=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},iD=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},aD=function(){function e(e,t){var n,r=this;this._attributes=e,this.asyncAttributesPending=null!=t,this._syncAttributes=null!==(n=this._attributes)&&void 0!==n?n:{},this._asyncAttributesPromise=null==t?void 0:t.then((function(e){return r._attributes=Object.assign({},r._attributes,e),r.asyncAttributesPending=!1,e}),(function(e){return im.debug("a resource's async attributes promise rejected: %s",e),r.asyncAttributesPending=!1,{}}))}return e.empty=function(){return e.EMPTY},e.default=function(){var t;return new e(((t={})[XM]="unknown_service",t[ZM]=nD[ZM],t[QM]=nD[QM],t[JM]=nD[JM],t))},Object.defineProperty(e.prototype,"attributes",{get:function(){var e;return this.asyncAttributesPending&&im.error("Accessing resource attributes before async attributes settled"),null!==(e=this._attributes)&&void 0!==e?e:{}},enumerable:!1,configurable:!0}),e.prototype.waitForAsyncAttributes=function(){return oD(this,void 0,void 0,(function(){return iD(this,(function(e){switch(e.label){case 0:return this.asyncAttributesPending?[4,this._asyncAttributesPromise]:[3,2];case 1:e.sent(),e.label=2;case 2:return[2]}}))}))},e.prototype.merge=function(t){var n,r=this;if(!t)return this;var o=rD(rD({},this._syncAttributes),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes);return this._asyncAttributesPromise||t._asyncAttributesPromise?new e(o,Promise.all([this._asyncAttributesPromise,t._asyncAttributesPromise]).then((function(e){var n,o=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),i=o[0],a=o[1];return rD(rD(rD(rD({},r._syncAttributes),i),null!==(n=t._syncAttributes)&&void 0!==n?n:t.attributes),a)}))):new e(o)},e.EMPTY=new e({}),e}(),sD="browser.platform",lD="browser.brands",cD="browser.mobile",uD="browser.language",dD="browser.user_agent",pD=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},fD=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}};var hD=new(function(){function e(){}return e.prototype.detect=function(e){return pD(this,void 0,void 0,(function(){var t;return fD(this,(function(n){return"undefined"!=typeof navigator?(t=function(){var e={},t=navigator.userAgentData;t?(e[sD]=t.platform,e[lD]=t.brands.map((function(e){return e.brand+" "+e.version})),e[cD]=t.mobile):e[dD]=navigator.userAgent;return e[uD]=navigator.language,e}(),[2,this._getResourceAttributes(t,e)]):[2,aD.empty()]}))}))},e.prototype._getResourceAttributes=function(e,t){return e[dD]||e[sD]?new aD(e):(im.debug("BrowserDetector failed: Unable to find required browser resources. "),aD.empty())},e}());const mD=za(Object.freeze(Object.defineProperty({__proto__:null,browserDetector:hD},Symbol.toStringTag,{value:"Module"})));Object.defineProperty(Cf,"__esModule",{value:!0}),Cf.WebSDK=void 0;const gD=qm,yD=MP,vD=dk,bD=$M,wD=BM,xD=VM,ED=mD;Cf.WebSDK=class{constructor(e={}){var t,n,r,o;if(this._resource=null!==(t=e.resource)&&void 0!==t?t:new yD.Resource({}),this._resourceDetectors=null!==(n=e.resourceDetectors)&&void 0!==n?n:[ED.browserDetector],this._serviceName=e.serviceName,this._autoDetectResources=null===(r=e.autoDetectResources)||void 0===r||r,e.spanProcessor||e.traceExporter){const t={};e.sampler&&(t.sampler=e.sampler),e.spanLimits&&(t.spanLimits=e.spanLimits),e.idGenerator&&(t.idGenerator=e.idGenerator);const n=null!==(o=e.spanProcessor)&&void 0!==o?o:new vD.BatchSpanProcessor(e.traceExporter);this._tracerProviderConfig={tracerConfig:t,spanProcessor:n,contextManager:e.contextManager,textMapPropagator:e.textMapPropagator}}let i=[];e.instrumentations&&(i=e.instrumentations),this._instrumentations=i}start(){var e,t,n;if(this._disabled)return;if((0,gD.registerInstrumentations)({instrumentations:this._instrumentations}),this._autoDetectResources){this._resource=this._resource.merge((0,yD.detectResourcesSync)({detectors:this._resourceDetectors}))}this._resource=void 0===this._serviceName?this._resource:this._resource.merge(new yD.Resource({[wD.SEMRESATTRS_SERVICE_NAME]:this._serviceName}));const r=new bD.WebTracerProvider(Object.assign(Object.assign({},null===(e=this._tracerProviderConfig)||void 0===e?void 0:e.tracerConfig),{resource:this._resource}));this._tracerProvider=r,this._tracerProviderConfig&&r.addSpanProcessor(this._tracerProviderConfig.spanProcessor),r.register({contextManager:null===(t=this._tracerProviderConfig)||void 0===t?void 0:t.contextManager,propagator:null===(n=this._tracerProviderConfig)||void 0===n?void 0:n.textMapPropagator}),r.addSpanProcessor(new xD.SessionIdSpanProcessor)}getResourceAttributes(){return this._resource.attributes}shutdown(){const e=[];return this._tracerProvider&&e.push(this._tracerProvider.shutdown()),Promise.all(e).then((()=>{}))}};var _D={},SD={},TD={};Object.defineProperty(TD,"__esModule",{value:!0}),TD.VERSION=void 0,TD.VERSION="0.3.0",Object.defineProperty(SD,"__esModule",{value:!0}),SD.configureHoneycombResource=void 0;const CD=MP,AD=TD;SD.configureHoneycombResource=function(){return new CD.Resource({"honeycomb.distro.version":AD.VERSION,"honeycomb.distro.runtime_version":"browser"})};var OD={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.configureEntryPageResource=e.defaultConfig=void 0;const t=MP;function n(e,t){if(e)return t}e.defaultConfig={path:!0,hash:!0,hostname:!0,referrer:!0,url:!1,search:!1},e.configureEntryPageResource=function(r){if(!1===r||!(null===window||void 0===window?void 0:window.location))return new t.Resource({});const o=function(t){if(!t)return e.defaultConfig;return Object.assign(Object.assign({},e.defaultConfig),t)}(r),{href:i,pathname:a,search:s,hash:l,hostname:c}=window.location,u={"entry_page.url":n(o.url,i),"entry_page.path":n(o.path,a),"entry_page.search":n(o.search,s),"entry_page.hash":n(o.hash,l),"entry_page.hostname":n(o.hostname,c),"entry_page.referrer":n(o.referrer,document.referrer)};return new t.Resource(u)}}(OD);var ND,RD,PD={},kD={exports:{}};ND=kD,RD=kD.exports,function(e,t){var n="function",r="undefined",o="object",i="string",a="major",s="model",l="name",c="type",u="vendor",d="version",p="architecture",f="console",h="mobile",m="tablet",g="smarttv",y="wearable",v="embedded",b="Amazon",w="Apple",x="ASUS",E="BlackBerry",_="Browser",S="Chrome",T="Firefox",C="Google",A="Huawei",O="LG",N="Microsoft",R="Motorola",P="Opera",k="Samsung",L="Sharp",M="Sony",D="Xiaomi",j="Zebra",I="Facebook",F="Chromium OS",U="Mac OS",$=" Browser",B=function(e){for(var t={},n=0;n<e.length;n++)t[e[n].toUpperCase()]=e[n];return t},V=function(e,t){return typeof e===i&&-1!==q(t).indexOf(q(e))},q=function(e){return e.toLowerCase()},z=function(e,t){if(typeof e===i)return e=e.replace(/^\s\s*/,""),typeof t===r?e:e.substring(0,500)},H=function(e,r){for(var i,a,s,l,c,u,d=0;d<r.length&&!c;){var p=r[d],f=r[d+1];for(i=a=0;i<p.length&&!c&&p[i];)if(c=p[i++].exec(e))for(s=0;s<f.length;s++)u=c[++a],typeof(l=f[s])===o&&l.length>0?2===l.length?this[l[0]]=typeof l[1]==n?l[1].call(this,u):l[1]:3===l.length?this[l[0]]=typeof l[1]!==n||l[1].exec&&l[1].test?u?u.replace(l[1],l[2]):t:u?l[1].call(this,u,l[2]):t:4===l.length&&(this[l[0]]=u?l[3].call(this,u.replace(l[1],l[2])):t):this[l]=u||t;d+=2}},G=function(e,n){for(var r in n)if(typeof n[r]===o&&n[r].length>0){for(var i=0;i<n[r].length;i++)if(V(n[r][i],e))return"?"===r?t:r}else if(V(n[r],e))return"?"===r?t:r;return n.hasOwnProperty("*")?n["*"]:e},K={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},W={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[d,[l,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[d,[l,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[l,d],[/opios[\/ ]+([\w\.]+)/i],[d,[l,P+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[d,[l,P+" GX"]],[/\bopr\/([\w\.]+)/i],[d,[l,P]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[d,[l,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[d,[l,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|ovibrowser|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon)\/([-\w\.]+)/i,/(heytap|ovi|115)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[l,d],[/quark(?:pc)?\/([-\w\.]+)/i],[d,[l,"Quark"]],[/\bddg\/([\w\.]+)/i],[d,[l,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[d,[l,"UC"+_]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[d,[l,"WeChat"]],[/konqueror\/([\w\.]+)/i],[d,[l,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[d,[l,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[d,[l,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[d,[l,"Smart Lenovo "+_]],[/(avast|avg)\/([\w\.]+)/i],[[l,/(.+)/,"$1 Secure "+_],d],[/\bfocus\/([\w\.]+)/i],[d,[l,T+" Focus"]],[/\bopt\/([\w\.]+)/i],[d,[l,P+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[d,[l,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[d,[l,"Dolphin"]],[/coast\/([\w\.]+)/i],[d,[l,P+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[d,[l,"MIUI"+$]],[/fxios\/([\w\.-]+)/i],[d,[l,T]],[/\bqihoobrowser\/?([\w\.]*)/i],[d,[l,"360"]],[/\b(qq)\/([\w\.]+)/i],[[l,/(.+)/,"$1Browser"],d],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[l,/(.+)/,"$1"+$],d],[/samsungbrowser\/([\w\.]+)/i],[d,[l,k+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[d,[l,"Sogou Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[l,"Sogou Mobile"],d],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[l,d],[/(lbbrowser|rekonq)/i,/\[(linkedin)app\]/i],[l],[/ome\/([\w\.]+) \w* ?(iron) saf/i,/ome\/([\w\.]+).+qihu (360)[es]e/i],[d,l],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[l,I],d],[/(Klarna)\/([\w\.]+)/i,/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[l,d],[/\bgsa\/([\w\.]+) .*safari\//i],[d,[l,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[d,[l,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[d,[l,S+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[l,S+" WebView"],d],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[d,[l,"Android "+_]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[l,d],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[d,[l,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[d,l],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[l,[d,G,{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[l,d],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[l,"Netscape"],d],[/(wolvic|librewolf)\/([\w\.]+)/i],[l,d],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[d,[l,T+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i],[l,[d,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[l,[d,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[p,"amd64"]],[/(ia32(?=;))/i],[[p,q]],[/((?:i[346]|x)86)[;\)]/i],[[p,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[p,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[p,"armhf"]],[/windows (ce|mobile); ppc;/i],[[p,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[p,/ower/,"",q]],[/(sun4\w)[;\)]/i],[[p,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[p,q]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[s,[u,k],[c,m]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr])[-\w]+)/i,/sec-(sgh\w+)/i],[s,[u,k],[c,h]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[s,[u,w],[c,h]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[s,[u,w],[c,m]],[/(macintosh);/i],[s,[u,w]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[s,[u,L],[c,h]],[/(?:honor)([-\w ]+)[;\)]/i],[s,[u,"Honor"],[c,h]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[s,[u,A],[c,m]],[/(?:huawei)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[s,[u,A],[c,h]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/oid[^\)]+; (m?[12][0-389][01]\w{3,6}[c-y])( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite|pro)?)(?: bui|\))/i],[[s,/_/g," "],[u,D],[c,h]],[/oid[^\)]+; (2\d{4}(283|rpbf)[cgl])( bui|\))/i,/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[s,/_/g," "],[u,D],[c,m]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[s,[u,"OPPO"],[c,h]],[/\b(opd2\d{3}a?) bui/i],[s,[u,"OPPO"],[c,m]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[s,[u,"Vivo"],[c,h]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[s,[u,"Realme"],[c,h]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[s,[u,R],[c,h]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[s,[u,R],[c,m]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[s,[u,O],[c,m]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[s,[u,O],[c,h]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[s,[u,"Lenovo"],[c,m]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[s,/_/g," "],[u,"Nokia"],[c,h]],[/(pixel c)\b/i],[s,[u,C],[c,m]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[s,[u,C],[c,h]],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[s,[u,M],[c,h]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[s,"Xperia Tablet"],[u,M],[c,m]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[s,[u,"OnePlus"],[c,h]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[s,[u,b],[c,m]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[s,/(.+)/g,"Fire Phone $1"],[u,b],[c,h]],[/(playbook);[-\w\),; ]+(rim)/i],[s,u,[c,m]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[s,[u,E],[c,h]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[s,[u,x],[c,m]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[s,[u,x],[c,h]],[/(nexus 9)/i],[s,[u,"HTC"],[c,m]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[u,[s,/_/g," "],[c,h]],[/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])\w*(\)| bui)/i],[s,[u,"TCL"],[c,m]],[/(itel) ((\w+))/i],[[u,q],s,[c,G,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[s,[u,"Acer"],[c,m]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[s,[u,"Meizu"],[c,h]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[s,[u,"Ulefone"],[c,h]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[s,[u,"Energizer"],[c,h]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[s,[u,"Cat"],[c,h]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[s,[u,"Smartfren"],[c,h]],[/droid.+; (a(?:015|06[35]|142p?))/i],[s,[u,"Nothing"],[c,h]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (imo) ((?!tab)[\w ]+?)(?: bui|\))/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[u,s,[c,h]],[/(imo) (tab \w+)/i,/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[u,s,[c,m]],[/(surface duo)/i],[s,[u,N],[c,m]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[s,[u,"Fairphone"],[c,h]],[/(u304aa)/i],[s,[u,"AT&T"],[c,h]],[/\bsie-(\w*)/i],[s,[u,"Siemens"],[c,h]],[/\b(rct\w+) b/i],[s,[u,"RCA"],[c,m]],[/\b(venue[\d ]{2,7}) b/i],[s,[u,"Dell"],[c,m]],[/\b(q(?:mv|ta)\w+) b/i],[s,[u,"Verizon"],[c,m]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[s,[u,"Barnes & Noble"],[c,m]],[/\b(tm\d{3}\w+) b/i],[s,[u,"NuVision"],[c,m]],[/\b(k88) b/i],[s,[u,"ZTE"],[c,m]],[/\b(nx\d{3}j) b/i],[s,[u,"ZTE"],[c,h]],[/\b(gen\d{3}) b.+49h/i],[s,[u,"Swiss"],[c,h]],[/\b(zur\d{3}) b/i],[s,[u,"Swiss"],[c,m]],[/\b((zeki)?tb.*\b) b/i],[s,[u,"Zeki"],[c,m]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[u,"Dragon Touch"],s,[c,m]],[/\b(ns-?\w{0,9}) b/i],[s,[u,"Insignia"],[c,m]],[/\b((nxa|next)-?\w{0,9}) b/i],[s,[u,"NextBook"],[c,m]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[u,"Voice"],s,[c,h]],[/\b(lvtel\-)?(v1[12]) b/i],[[u,"LvTel"],s,[c,h]],[/\b(ph-1) /i],[s,[u,"Essential"],[c,h]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[s,[u,"Envizen"],[c,m]],[/\b(trio[-\w\. ]+) b/i],[s,[u,"MachSpeed"],[c,m]],[/\btu_(1491) b/i],[s,[u,"Rotor"],[c,m]],[/(shield[\w ]+) b/i],[s,[u,"Nvidia"],[c,m]],[/(sprint) (\w+)/i],[u,s,[c,h]],[/(kin\.[onetw]{3})/i],[[s,/\./g," "],[u,N],[c,h]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[s,[u,j],[c,m]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[s,[u,j],[c,h]],[/smart-tv.+(samsung)/i],[u,[c,g]],[/hbbtv.+maple;(\d+)/i],[[s,/^/,"SmartTV"],[u,k],[c,g]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[u,O],[c,g]],[/(apple) ?tv/i],[u,[s,w+" TV"],[c,g]],[/crkey/i],[[s,S+"cast"],[u,C],[c,g]],[/droid.+aft(\w+)( bui|\))/i],[s,[u,b],[c,g]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[s,[u,L],[c,g]],[/(bravia[\w ]+)( bui|\))/i],[s,[u,M],[c,g]],[/(mitv-\w{5}) bui/i],[s,[u,D],[c,g]],[/Hbbtv.*(technisat) (.*);/i],[u,s,[c,g]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[u,z],[s,z],[c,g]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[c,g]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[u,s,[c,f]],[/droid.+; (shield) bui/i],[s,[u,"Nvidia"],[c,f]],[/(playstation [345portablevi]+)/i],[s,[u,M],[c,f]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[s,[u,N],[c,f]],[/\b(sm-[lr]\d\d[05][fnuw]?s?)\b/i],[s,[u,k],[c,y]],[/((pebble))app/i],[u,s,[c,y]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[s,[u,w],[c,y]],[/droid.+; (glass) \d/i],[s,[u,C],[c,y]],[/droid.+; (wt63?0{2,3})\)/i],[s,[u,j],[c,y]],[/droid.+; (glass) \d/i],[s,[u,C],[c,y]],[/(pico) (4|neo3(?: link|pro)?)/i],[u,s,[c,y]],[/; (quest( \d| pro)?)/i],[s,[u,I],[c,y]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[u,[c,v]],[/(aeobc)\b/i],[s,[u,b],[c,v]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew).+? mobile safari/i],[s,[c,h]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[s,[c,m]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[c,m]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[c,h]],[/(android[-\w\. ]{0,9});.+buil/i],[s,[u,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[d,[l,"EdgeHTML"]],[/(arkweb)\/([\w\.]+)/i],[l,d],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[d,[l,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[l,d],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[d,l]],os:[[/microsoft (windows) (vista|xp)/i],[l,d],[/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i],[l,[d,G,K]],[/windows nt 6\.2; (arm)/i,/windows[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i,/(?:win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[d,G,K],[l,"Windows"]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[d,/_/g,"."],[l,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[l,U],[d,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[d,l],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish|openharmony)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[l,d],[/\(bb(10);/i],[d,[l,E]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[d,[l,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[d,[l,T+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[d,[l,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[d,[l,"watchOS"]],[/crkey\/([\d\.]+)/i],[d,[l,S+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[l,F],d],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[l,d],[/(sunos) ?([\w\.\d]*)/i],[[l,"Solaris"],d],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[l,d]]},Y=function(f,g){if(typeof f===o&&(g=f,f=t),!(this instanceof Y))return new Y(f,g).getResult();var y=typeof e!==r&&e.navigator?e.navigator:t,v=f||(y&&y.userAgent?y.userAgent:""),b=y&&y.userAgentData?y.userAgentData:t,w=g?function(e,t){var n={};for(var r in e)n[r]=t[r]&&t[r].length%2==0?t[r].concat(e[r]):e[r];return n}(W,g):W,x=y&&y.userAgent==v;return this.getBrowser=function(){var e,r={};return r[l]=t,r[d]=t,H.call(r,v,w.browser),r[a]=typeof(e=r[d])===i?e.replace(/[^\d\.]/g,"").split(".")[0]:t,x&&y&&y.brave&&typeof y.brave.isBrave==n&&(r[l]="Brave"),r},this.getCPU=function(){var e={};return e[p]=t,H.call(e,v,w.cpu),e},this.getDevice=function(){var e={};return e[u]=t,e[s]=t,e[c]=t,H.call(e,v,w.device),x&&!e[c]&&b&&b.mobile&&(e[c]=h),x&&"Macintosh"==e[s]&&y&&typeof y.standalone!==r&&y.maxTouchPoints&&y.maxTouchPoints>2&&(e[s]="iPad",e[c]=m),e},this.getEngine=function(){var e={};return e[l]=t,e[d]=t,H.call(e,v,w.engine),e},this.getOS=function(){var e={};return e[l]=t,e[d]=t,H.call(e,v,w.os),x&&!e[l]&&b&&b.platform&&"Unknown"!=b.platform&&(e[l]=b.platform.replace(/chrome os/i,F).replace(/macos/i,U)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return v},this.setUA=function(e){return v=typeof e===i&&e.length>500?z(e,500):e,this},this.setUA(v),this};Y.VERSION="1.0.40",Y.BROWSER=B([l,d,a]),Y.CPU=B([p]),Y.DEVICE=B([s,u,c,f,h,g,m,y,v]),Y.ENGINE=Y.OS=B([l,d]),ND.exports&&(RD=ND.exports=Y),RD.UAParser=Y;var X=typeof e!==r&&(e.jQuery||e.Zepto);if(X&&!X.ua){var Q=new Y;X.ua=Q.getResult(),X.ua.get=function(){return Q.getUA()},X.ua.set=function(e){Q.setUA(e);var t=Q.getResult();for(var n in t)X.ua[n]=t[n]}}}("object"==typeof window?window:Va);var LD=kD.exports;!function(e){var t=Va&&Va.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.configureBrowserAttributesResource=e.computeDeviceProperties=e.computeNetworkType=e.computeScreenSize=void 0;const n=MP,r=t(LD);e.computeScreenSize=e=>e<=768?"small":e>768&&e<=1024?"medium":e>1024?"large":"unknown";e.computeNetworkType=e=>{var t;return null!==(t=null==e?void 0:e.effectiveType)&&void 0!==t?t:"unknown"};e.computeDeviceProperties=e=>{const t=new r.default(e),{name:n,version:o}=t.getBrowser();return{browserName:null!=n?n:"unknown",browserVersion:null!=o?o:"unknown",deviceType:(i=t.getDevice().type,a=n,i||a?i||"desktop":"unknown")};var i,a},e.configureBrowserAttributesResource=function(){const{browserName:t,browserVersion:r,deviceType:o}=(0,e.computeDeviceProperties)(navigator.userAgent);return new n.Resource({"user_agent.original":navigator.userAgent,"browser.mobile":navigator.userAgent.includes("Mobi"),"browser.touch_screen_enabled":navigator.maxTouchPoints>0,"browser.language":navigator.language,"browser.name":t,"browser.version":r,"device.type":o,"network.effectiveType":(0,e.computeNetworkType)(navigator.connection),"screen.width":window.screen.width,"screen.height":window.screen.height,"screen.size":(0,e.computeScreenSize)(window.screen.width)})}}(PD);var MD={};Object.defineProperty(MD,"__esModule",{value:!0}),MD.mergeResources=void 0;const DD=MP;function jD(e){return e instanceof DD.Resource?e:new DD.Resource(e||{})}MD.mergeResources=function(e){let t=jD(e[0]);for(let n=1;n<e.length;n++){if(!e[n])continue;const r=jD(e[n]);t=t.merge(r)}return t};var ID={};const FD=za(xm);var UD={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getSampleRate=e.getTracesApiKey=e.getTracesEndpoint=e.maybeAppendTracesPath=e.isClassic=e.createHoneycombSDKLogMessage=e.defaultOptions=e.DEFAULT_SAMPLE_RATE=e.DEFAULT_SERVICE_NAME=e.DEFAULT_TRACES_ENDPOINT=e.TRACES_PATH=e.DEFAULT_API_ENDPOINT=void 0,e.DEFAULT_API_ENDPOINT="https://api.honeycomb.io",e.TRACES_PATH="v1/traces",e.DEFAULT_TRACES_ENDPOINT=`${e.DEFAULT_API_ENDPOINT}/${e.TRACES_PATH}`,e.DEFAULT_SERVICE_NAME="unknown_service",e.DEFAULT_SAMPLE_RATE=1,e.defaultOptions={apiKey:"",tracesApiKey:"",endpoint:e.DEFAULT_TRACES_ENDPOINT,tracesEndpoint:e.DEFAULT_TRACES_ENDPOINT,serviceName:e.DEFAULT_SERVICE_NAME,debug:!1,sampleRate:1,skipOptionsValidation:!1,localVisualizations:!1,webVitalsInstrumentationConfig:{enabled:!0}};e.createHoneycombSDKLogMessage=e=>`@honeycombio/opentelemetry-web: ${e}`;const t=/^[a-f0-9]*$/,n=/^hc[a-z]ic_[a-z0-9]*$/;function r(t){return t.endsWith(e.TRACES_PATH)||t.endsWith(`${e.TRACES_PATH}/`)?t:t.endsWith("/")?t+e.TRACES_PATH:t+"/"+e.TRACES_PATH}e.isClassic=function(e){return null!=e&&0!==e.length&&(32===e.length?t.test(e):64===e.length&&n.test(e))},e.maybeAppendTracesPath=r;e.getTracesEndpoint=t=>(null==t?void 0:t.tracesEndpoint)?t.tracesEndpoint:(null==t?void 0:t.endpoint)?r(t.endpoint):e.DEFAULT_TRACES_ENDPOINT;e.getTracesApiKey=e=>(null==e?void 0:e.tracesApiKey)||(null==e?void 0:e.apiKey);e.getSampleRate=t=>"number"==typeof(null==t?void 0:t.sampleRate)&&Number.isSafeInteger(null==t?void 0:t.sampleRate)&&(null==t?void 0:t.sampleRate)>=0?null==t?void 0:t.sampleRate:e.DEFAULT_SAMPLE_RATE}(UD);var $D={};!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateOptionsWarnings=e.FAILED_AUTH_FOR_LOCAL_VISUALIZATIONS=e.MISSING_FIELDS_FOR_LOCAL_VISUALIZATIONS=e.SAMPLER_OVERRIDE_WARNING=e.SKIPPING_OPTIONS_VALIDATION_MSG=e.MISSING_DATASET_ERROR=e.IGNORED_DATASET_ERROR=e.MISSING_SERVICE_NAME_ERROR=e.MISSING_API_KEY_ERROR=void 0;const t=UD;e.MISSING_API_KEY_ERROR=(0,t.createHoneycombSDKLogMessage)("❌ Missing API Key. Set `apiKey` in HoneycombOptions. Telemetry will not be exported."),e.MISSING_SERVICE_NAME_ERROR=(0,t.createHoneycombSDKLogMessage)(`❌ Missing Service Name. Set \`serviceName\` in HoneycombOptions. Defaulting to '${t.defaultOptions.serviceName}'`),e.IGNORED_DATASET_ERROR=(0,t.createHoneycombSDKLogMessage)("🔕 Dataset is ignored in favor of service name."),e.MISSING_DATASET_ERROR=(0,t.createHoneycombSDKLogMessage)("❌ Missing dataset. Specify either HONEYCOMB_DATASET environment variable or dataset in the options parameter."),e.SKIPPING_OPTIONS_VALIDATION_MSG=(0,t.createHoneycombSDKLogMessage)("⏭️ Skipping options validation. To re-enable, set skipOptionsValidation option or HONEYCOMB_SKIP_OPTIONS_VALIDATION to false."),e.SAMPLER_OVERRIDE_WARNING=(0,t.createHoneycombSDKLogMessage)("🔨 Default deterministic sampler has been overridden. Honeycomb requires a resource attribute called SampleRate to properly show weighted values. Non-deterministic sampleRate could lead to missing spans in Honeycomb. See our docs for more details. https://docs.honeycomb.io/getting-data-in/opentelemetry/node-distro/#sampling-without-the-honeycomb-sdk"),e.MISSING_FIELDS_FOR_LOCAL_VISUALIZATIONS=(0,t.createHoneycombSDKLogMessage)("🔕 Disabling local visualizations - must have both service name and API key configured."),e.FAILED_AUTH_FOR_LOCAL_VISUALIZATIONS=(0,t.createHoneycombSDKLogMessage)("🔕 Failed to get proper auth response from Honeycomb. No local visualization available.");e.validateOptionsWarnings=e=>{if(!(null==e?void 0:e.skipOptionsValidation))return(null==e?void 0:e.apiKey)&&(0,t.isClassic)(null==e?void 0:e.apiKey),(null==e?void 0:e.apiKey)&&(0,t.isClassic)(null==e?void 0:e.apiKey),e}}($D),Object.defineProperty(ID,"__esModule",{value:!0}),ID.configureDebug=void 0;const BD=FD,VD=UD,qD=$D;ID.configureDebug=function(e){if(!(null==e?void 0:e.debug))return;BD.diag.setLogger(new BD.DiagConsoleLogger,BD.DiagLogLevel.DEBUG),BD.diag.debug((0,VD.createHoneycombSDKLogMessage)("🐝 Honeycomb Web SDK Debug Mode Enabled 🐝"));const t=(0,VD.getTracesEndpoint)(e),n=Object.assign(Object.assign(Object.assign({},VD.defaultOptions),e),{tracesEndpoint:t});!function(e){const t=(0,VD.getTracesApiKey)(e)||"";if(!t)return void BD.diag.debug(qD.MISSING_API_KEY_ERROR);BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`API Key configured for traces: '${t}'`))}(n),function(e){const t=e.serviceName||VD.defaultOptions.serviceName;if(t===VD.defaultOptions.serviceName)return void BD.diag.debug(qD.MISSING_SERVICE_NAME_ERROR);BD.diag.debug(`@honeycombio/opentelemetry-web: Service Name configured for traces: '${t}'`)}(n),function(e){const t=(0,VD.getTracesEndpoint)(e);if(!t)return void BD.diag.debug((0,VD.createHoneycombSDKLogMessage)("No endpoint configured for traces"));BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`Endpoint configured for traces: '${t}'`))}(n),function(e){const t=(0,VD.getSampleRate)(e);if(!t)return void BD.diag.debug("No sampler configured for traces");BD.diag.debug((0,VD.createHoneycombSDKLogMessage)(`Sample Rate configured for traces: '${t}'`))}(n)};var zD={},HD={};Object.defineProperty(HD,"__esModule",{value:!0}),HD.BaggageSpanProcessor=void 0;const GD=FD;HD.BaggageSpanProcessor=class{constructor(){}onStart(e,t){var n,r;(null!==(r=null===(n=GD.propagation.getBaggage(t))||void 0===n?void 0:n.getAllEntries())&&void 0!==r?r:[]).forEach((t=>{e.setAttribute(t[0],t[1].value),GD.diag.debug(`@honeycombio/opentelemetry-web: 🚨 Baggage in all outgoing headers: ${t[0]}=${t[1].value} `)}))}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var KD={};Object.defineProperty(KD,"__esModule",{value:!0}),KD.BrowserAttributesSpanProcessor=void 0;KD.BrowserAttributesSpanProcessor=class{constructor(){}onStart(e){const{href:t,pathname:n,search:r,hash:o,hostname:i}=window.location;e.setAttributes({"browser.width":window.innerWidth,"browser.height":window.innerHeight,"page.hash":o,"page.url":t,"page.route":n,"page.hostname":i,"page.search":r})}onEnd(){}forceFlush(){return Promise.resolve()}shutdown(){return Promise.resolve()}};var WD={},YD=1e4;function XD(e){void 0===e&&(e={});var t={};return Object.entries(e).forEach((function(e){var n=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2),r=n[0],o=n[1];void 0!==o?t[r]=String(o):im.warn('Header "'+r+'" has invalid value ('+o+") and will be ignored")})),t}function QD(e){return"number"==typeof e?e<=0?ZD(e,1e4):e:(n=Number(null!==(t=XN().OTEL_EXPORTER_OTLP_TRACES_TIMEOUT)&&void 0!==t?t:XN().OTEL_EXPORTER_OTLP_TIMEOUT))<=0?ZD(n,YD):n;var t,n}function ZD(e,t){return im.warn("Timeout must be greater than 0",e),t}var JD=function(){function e(e){void 0===e&&(e={}),this._sendingPromises=[],this.url=this.getDefaultUrl(e),"string"==typeof e.hostname&&(this.hostname=e.hostname),this.shutdown=this.shutdown.bind(this),this._shutdownOnce=new lP(this._shutdown,this),this._concurrencyLimit="number"==typeof e.concurrencyLimit?e.concurrencyLimit:30,this.timeoutMillis=QD(e.timeoutMillis),this.onInit(e)}return e.prototype.export=function(e,t){this._shutdownOnce.isCalled?t({code:lR.FAILED,error:new Error("Exporter has been shutdown")}):this._sendingPromises.length>=this._concurrencyLimit?t({code:lR.FAILED,error:new Error("Concurrent export limit reached")}):this._export(e).then((function(){t({code:lR.SUCCESS})})).catch((function(e){t({code:lR.FAILED,error:e})}))},e.prototype._export=function(e){var t=this;return new Promise((function(n,r){try{im.debug("items to be sent",e),t.send(e,n,r)}catch(tme){r(tme)}}))},e.prototype.shutdown=function(){return this._shutdownOnce.call()},e.prototype.forceFlush=function(){return Promise.all(this._sendingPromises).then((function(){}))},e.prototype._shutdown=function(){return im.debug("shutdown started"),this.onShutdown(),this.forceFlush()},e}(),ej=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),tj=function(e){function t(t,n,r){var o=e.call(this,t)||this;return o.name="OTLPExporterError",o.data=r,o.code=n,o}return ej(t,e),t}(Error),nj=function(){return nj=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},nj.apply(this,arguments)};function rj(e,t,n,r,o,i){var a,s,l=!1,c=setTimeout((function(){if(clearTimeout(a),l=!0,s.readyState===XMLHttpRequest.DONE){var e=new tj("Request Timeout");i(e)}else s.abort()}),r),u=function(r,d){void 0===r&&(r=5),void 0===d&&(d=1e3),(s=new XMLHttpRequest).open("POST",t);Object.entries(nj(nj({},{Accept:"application/json","Content-Type":"application/json"}),n)).forEach((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);s.setRequestHeader(t[0],t[1])})),s.send(e),s.onreadystatechange=function(){if(s.readyState===XMLHttpRequest.DONE&&!1===l)if(s.status>=200&&s.status<=299)im.debug("xhr success",e),o(),clearTimeout(c),clearTimeout(a);else if(s.status&&[429,502,503,504].includes(s.status)&&r>0){var t=void 0;d*=1.5,t=s.getResponseHeader("Retry-After")?function(e){if(null==e)return-1;var t=Number.parseInt(e,10);if(Number.isInteger(t))return t>0?1e3*t:-1;var n=new Date(e).getTime()-Date.now();return n>=0?n:0}(s.getResponseHeader("Retry-After")):Math.round(Math.random()*(5e3-d)+d),a=setTimeout((function(){u(r-1,d)}),t)}else{var n=new tj("Failed to export with XHR (status: "+s.status+")",s.status);i(n),clearTimeout(c),clearTimeout(a)}},s.onabort=function(){if(l){var e=new tj("Request Timeout");i(e)}clearTimeout(c),clearTimeout(a)},s.onerror=function(){if(l){var e=new tj("Request Timeout");i(e)}clearTimeout(c),clearTimeout(a)}};u()}var oj=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),ij=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;return n._useXHR=!1,n._useXHR=!!t.headers||"function"!=typeof navigator.sendBeacon,n._headers=n._useXHR?Object.assign({},XD(t.headers),bN(XN().OTEL_EXPORTER_OTLP_HEADERS)):{},n}return oj(t,e),t.prototype.onInit=function(){},t.prototype.onShutdown=function(){},t.prototype.send=function(e,t,n){var r=this;if(this._shutdownOnce.isCalled)im.debug("Shutdown already started. Cannot send objects");else{var o=this.convert(e),i=JSON.stringify(o),a=new Promise((function(e,t){r._useXHR?rj(i,r.url,r._headers,r.timeoutMillis,e,t):function(e,t,n,r,o){navigator.sendBeacon(t,new Blob([e],n))?(im.debug("sendBeacon - can send",e),r()):o(new tj("sendBeacon - cannot send "+e))}(i,r.url,{type:"application/json"},e,t)})).then(t,n);this._sendingPromises.push(a);var s=function(){var e=r._sendingPromises.indexOf(a);r._sendingPromises.splice(e,1)};a.then(s,s)}},t}(JD);function aj(e){var t=BigInt(1e9);return BigInt(e[0])*t+BigInt(e[1])}function sj(e){var t,n=aj(e);return t=n,{low:Number(BigInt.asUintN(32,t)),high:Number(BigInt.asUintN(32,t>>BigInt(32)))}}var lj="undefined"!=typeof BigInt?function(e){return aj(e).toString()}:gR;function cj(e){return e}function uj(e){if(void 0!==e)return JN(e)}var dj={encodeHrTime:sj,encodeSpanContext:JN,encodeOptionalSpanContext:uj};function pj(e){return Object.keys(e).map((function(t){return fj(t,e[t])}))}function fj(e,t){return{key:e,value:hj(t)}}function hj(e){var t=typeof e;return"string"===t?{stringValue:e}:"number"===t?Number.isInteger(e)?{intValue:e}:{doubleValue:e}:"boolean"===t?{boolValue:e}:e instanceof Uint8Array?{bytesValue:e}:Array.isArray(e)?{arrayValue:{values:e.map(hj)}}:"object"===t&&null!=e?{kvlistValue:{values:Object.entries(e).map((function(e){var t=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e,2);return fj(t[0],t[1])}))}}:{}}function mj(e,t){var n,r=e.spanContext(),o=e.status;return{traceId:t.encodeSpanContext(r.traceId),spanId:t.encodeSpanContext(r.spanId),parentSpanId:t.encodeOptionalSpanContext(e.parentSpanId),traceState:null===(n=r.traceState)||void 0===n?void 0:n.serialize(),name:e.name,kind:null==e.kind?0:e.kind+1,startTimeUnixNano:t.encodeHrTime(e.startTime),endTimeUnixNano:t.encodeHrTime(e.endTime),attributes:pj(e.attributes),droppedAttributesCount:e.droppedAttributesCount,events:e.events.map((function(e){return function(e,t){return{attributes:e.attributes?pj(e.attributes):[],name:e.name,timeUnixNano:t.encodeHrTime(e.time),droppedAttributesCount:e.droppedAttributesCount||0}}(e,t)})),droppedEventsCount:e.droppedEventsCount,status:{code:o.code,message:o.message},links:e.links.map((function(e){return function(e,t){var n;return{attributes:e.attributes?pj(e.attributes):[],spanId:t.encodeSpanContext(e.context.spanId),traceId:t.encodeSpanContext(e.context.traceId),traceState:null===(n=e.context.traceState)||void 0===n?void 0:n.serialize(),droppedAttributesCount:e.droppedAttributesCount||0}}(e,t)})),droppedLinksCount:e.droppedLinksCount}}function gj(e){return{attributes:pj(e.attributes),droppedAttributesCount:0}}var yj=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a};function vj(e,t){var n=function(e){var t,n;if(void 0===e)return dj;var r=null===(t=e.useLongBits)||void 0===t||t,o=null!==(n=e.useHex)&&void 0!==n&&n;return{encodeHrTime:r?sj:lj,encodeSpanContext:o?cj:JN,encodeOptionalSpanContext:o?cj:uj}}(t);return{resourceSpans:wj(e,n)}}function bj(e){var t,n,r=new Map;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e),i=o.next();!i.done;i=o.next()){var a=i.value,s=r.get(a.resource);s||r.set(a.resource,s=new Map);var l=a.instrumentationLibrary.name+"@"+(a.instrumentationLibrary.version||"")+":"+(a.instrumentationLibrary.schemaUrl||""),c=s.get(l);c||s.set(l,c=[]),c.push(a)}}catch(u){t={error:u}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}function wj(e,t){for(var n,r=[],o=bj(e).entries(),i=o.next();!i.done;){for(var a=yj(i.value,2),s=a[0],l=[],c=a[1].values(),u=c.next();!u.done;){var d=u.value;if(d.length>0){var p=d.map((function(e){return mj(e,t)}));l.push({scope:(n=d[0].instrumentationLibrary,{name:n.name,version:n.version}),spans:p,schemaUrl:d[0].instrumentationLibrary.schemaUrl})}u=c.next()}var f={resource:gj(s),scopeSpans:l,schemaUrl:void 0};r.push(f),i=o.next()}return r}var xj=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),Ej="v1/traces",_j="http://localhost:4318/"+Ej,Sj=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,t)||this;return n._headers=Object.assign(n._headers,bN(XN().OTEL_EXPORTER_OTLP_TRACES_HEADERS)),n}return xj(t,e),t.prototype.convert=function(e){return vj(e,{useHex:!0,useLongBits:!1})},t.prototype.getDefaultUrl=function(e){return"string"==typeof e.url?e.url:XN().OTEL_EXPORTER_OTLP_TRACES_ENDPOINT.length>0?function(e){try{var t=new URL(e);return""===t.pathname&&(t.pathname=t.pathname+"/"),t.toString()}catch(n){return im.warn("Could not parse export URL: '"+e+"'"),e}}(XN().OTEL_EXPORTER_OTLP_TRACES_ENDPOINT):XN().OTEL_EXPORTER_OTLP_ENDPOINT.length>0?(t=XN().OTEL_EXPORTER_OTLP_ENDPOINT,n=Ej,t.endsWith("/")||(t+="/"),t+n):_j;var t,n},t}(ij);const Tj=za(Object.freeze(Object.defineProperty({__proto__:null,OTLPTraceExporter:Sj},Symbol.toStringTag,{value:"Module"})));!function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.configureHoneycombHttpJsonTraceExporter=e.DATASET_HEADER_KEY=e.TEAM_HEADER_KEY=void 0;const t=Tj,n=UD;e.TEAM_HEADER_KEY="x-honeycomb-team",e.DATASET_HEADER_KEY="x-honeycomb-dataset",e.configureHoneycombHttpJsonTraceExporter=function(r){const o=(0,n.getTracesApiKey)(r);return new t.OTLPTraceExporter({url:(0,n.getTracesEndpoint)(r),headers:Object.assign({[e.TEAM_HEADER_KEY]:o,[e.DATASET_HEADER_KEY]:(0,n.isClassic)(o)?null==r?void 0:r.dataset:void 0},null==r?void 0:r.headers)})}}(WD);var Cj={};const Aj=za(uP);var Oj=Va&&Va.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))};Object.defineProperty(Cj,"__esModule",{value:!0}),Cj.configureCompositeExporter=void 0;const Nj=Aj;Cj.configureCompositeExporter=function(e){return new Rj(e)};class Rj{constructor(e){this._exporters=e}export(e,t){this._exporters.forEach((n=>n.export(e,t))),t({code:Nj.ExportResultCode.SUCCESS})}shutdown(){return Oj(this,void 0,void 0,(function*(){const e=[];this._exporters.forEach((t=>e.push(t.shutdown()))),yield Promise.all(e)}))}}var Pj={};Object.defineProperty(Pj,"__esModule",{value:!0}),Pj.buildTraceUrl=Pj.configureConsoleTraceLinkExporter=void 0;const kj=Aj,Lj=UD;Pj.configureConsoleTraceLinkExporter=function(e){const t=(0,Lj.getTracesApiKey)(e);return new Mj(null==e?void 0:e.serviceName,t)};class Mj{constructor(e,t){if(this._traceUrl="",!e||!t)return;fetch("https://api.honeycomb.io/1/auth",{headers:{"x-honeycomb-team":t}}).then((e=>{if(e.ok)return e.json();throw new Error})).then((n=>{var r,o,i;const a=n;if(!(null===(r=a.team)||void 0===r?void 0:r.slug))throw new Error;this._traceUrl=Dj(t,e,null===(o=a.team)||void 0===o?void 0:o.slug,null===(i=a.environment)||void 0===i?void 0:i.slug)})).catch((()=>{}))}export(e,t){this._traceUrl&&e.forEach((e=>{})),t({code:kj.ExportResultCode.SUCCESS})}shutdown(){return Promise.resolve()}}function Dj(e,t,n,r){let o=`https://ui.honeycomb.io/${n}`;return!(0,Lj.isClassic)(e)&&r&&(o+=`/environments/${r}`),o+=`/datasets/${t}/trace?trace_id`,o}Pj.buildTraceUrl=Dj,Object.defineProperty(zD,"__esModule",{value:!0}),zD.CompositeSpanProcessor=zD.configureSpanProcessors=void 0;const jj=HD,Ij=KD,Fj=dk,Uj=WD,$j=Cj,Bj=Pj;zD.configureSpanProcessors=e=>{const t=new Vj,n=[];return(null==e?void 0:e.localVisualizations)&&n.push((0,Bj.configureConsoleTraceLinkExporter)(e)),(null==e?void 0:e.traceExporter)&&n.push(null==e?void 0:e.traceExporter),t.addProcessor(new Fj.BatchSpanProcessor((0,$j.configureCompositeExporter)([(0,Uj.configureHoneycombHttpJsonTraceExporter)(e),...n]))),t.addProcessor(new jj.BaggageSpanProcessor),t.addProcessor(new Ij.BrowserAttributesSpanProcessor),(null==e?void 0:e.spanProcessor)&&t.addProcessor(null==e?void 0:e.spanProcessor),t};class Vj{constructor(){this.spanProcessors=[]}addProcessor(e){this.spanProcessors.push(e)}getSpanProcessors(){return this.spanProcessors}onStart(e,t){this.spanProcessors.forEach((n=>{n.onStart(e,t)}))}onEnd(e){this.spanProcessors.forEach((t=>{t.onEnd(e)}))}forceFlush(){return Promise.all(this.spanProcessors.map((e=>e.forceFlush()))).then((()=>{}))}shutdown(){return Promise.all(this.spanProcessors.map((e=>e.forceFlush()))).then((()=>{}))}}zD.CompositeSpanProcessor=Vj;var qj={};Object.defineProperty(qj,"__esModule",{value:!0}),qj.DeterministicSampler=qj.configureDeterministicSampler=void 0;const zj=dk,Hj=UD;qj.configureDeterministicSampler=e=>{const t=(0,Hj.getSampleRate)(e);return new Gj(t)};class Gj{constructor(e){switch(this._sampleRate=e,e){case 0:this._sampler=new zj.AlwaysOffSampler;break;case 1:this._sampler=new zj.AlwaysOnSampler;break;default:this._sampler=new zj.TraceIdRatioBasedSampler(1/e);break}}shouldSample(e,t,n,r,o,i){const a=this._sampler.shouldSample(e,t,n,r,o,i);return Object.assign(Object.assign({},a),{attributes:Object.assign(Object.assign({},a.attributes),{SampleRate:this._sampleRate})})}toString(){return`DeterministicSampler(${this._sampler.toString()})`}}qj.DeterministicSampler=Gj;var Kj={},Wj={exports:{}};!function(e,t){!function(e){var t,n,r=function(){var e=self.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0];if(e&&e.responseStart>0&&e.responseStart<performance.now())return e},o=function(e){if("loading"===document.readyState)return"loading";var t=r();if(t){if(e<t.domInteractive)return"loading";if(0===t.domContentLoadedEventStart||e<t.domContentLoadedEventStart)return"dom-interactive";if(0===t.domComplete||e<t.domComplete)return"dom-content-loaded"}return"complete"},i=function(e){var t=e.nodeName;return 1===e.nodeType?t.toLowerCase():t.toUpperCase().replace(/^#/,"")},a=function(e,t){var n="";try{for(;e&&9!==e.nodeType;){var r=e,o=r.id?"#"+r.id:i(r)+(r.classList&&r.classList.value&&r.classList.value.trim()&&r.classList.value.trim().length?"."+r.classList.value.trim().replace(/\s+/g,"."):"");if(n.length+o.length>(t||100)-1)return n||o;if(n=n?o+">"+n:o,r.id)break;e=r.parentNode}}catch(a){}return n},s=-1,l=function(){return s},c=function(e){addEventListener("pageshow",(function(t){t.persisted&&(s=t.timeStamp,e(t))}),!0)},u=function(){var e=r();return e&&e.activationStart||0},d=function(e,t){var n=r(),o="navigate";return l()>=0?o="back-forward-cache":n&&(document.prerendering||u()>0?o="prerender":document.wasDiscarded?o="restore":n.type&&(o=n.type.replace(/_/g,"-"))),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:"v4-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:o}},p=function(e,t,n){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var r=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(o){}},f=function(e,t,n,r){var o,i;return function(a){var s,l;t.value>=0&&(a||r)&&((i=t.value-(o||0))||void 0===o)&&(o=t.value,t.delta=i,t.rating=(s=t.value)>(l=n)[1]?"poor":s>l[0]?"needs-improvement":"good",e(t))}},h=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},m=function(e){document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&e()}))},g=function(e){var t=!1;return function(){t||(e(),t=!0)}},y=-1,v=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},b=function(e){"hidden"===document.visibilityState&&y>-1&&(y="visibilitychange"===e.type?e.timeStamp:0,x())},w=function(){addEventListener("visibilitychange",b,!0),addEventListener("prerenderingchange",b,!0)},x=function(){removeEventListener("visibilitychange",b,!0),removeEventListener("prerenderingchange",b,!0)},E=function(){return y<0&&(y=v(),w(),c((function(){setTimeout((function(){y=v(),w()}),0)}))),{get firstHiddenTime(){return y}}},_=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},S=[1800,3e3],T=function(e,t){t=t||{},_((function(){var n,r=E(),o=d("FCP"),i=p("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(i.disconnect(),e.startTime<r.firstHiddenTime&&(o.value=Math.max(e.startTime-u(),0),o.entries.push(e),n(!0)))}))}));i&&(n=f(e,o,S,t.reportAllChanges),c((function(r){o=d("FCP"),n=f(e,o,S,t.reportAllChanges),h((function(){o.value=performance.now()-r.timeStamp,n(!0)}))})))}))},C=[.1,.25],A=0,O=1/0,N=0,R=function(e){e.forEach((function(e){e.interactionId&&(O=Math.min(O,e.interactionId),N=Math.max(N,e.interactionId),A=N?(N-O)/7+1:0)}))},P=function(){return t?A:performance.interactionCount||0},k=function(){"interactionCount"in performance||t||(t=p("event",R,{type:"event",buffered:!0,durationThreshold:0}))},L=[],M=new Map,D=0,j=function(){var e=Math.min(L.length-1,Math.floor((P()-D)/50));return L[e]},I=[],F=function(e){if(I.forEach((function(t){return t(e)})),e.interactionId||"first-input"===e.entryType){var t=L[L.length-1],n=M.get(e.interactionId);if(n||L.length<10||e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===n.entries[0].startTime&&n.entries.push(e);else{var r={id:e.interactionId,latency:e.duration,entries:[e]};M.set(r.id,r),L.push(r)}L.sort((function(e,t){return t.latency-e.latency})),L.length>10&&L.splice(10).forEach((function(e){return M.delete(e.id)}))}}},U=function(e){var t=self.requestIdleCallback||self.setTimeout,n=-1;return e=g(e),"hidden"===document.visibilityState?e():(n=t(e),m(e)),n},$=[200,500],B=function(e,t){"PerformanceEventTiming"in self&&"interactionId"in PerformanceEventTiming.prototype&&(t=t||{},_((function(){var n;k();var r,o=d("INP"),i=function(e){U((function(){e.forEach(F);var t=j();t&&t.latency!==o.value&&(o.value=t.latency,o.entries=t.entries,r())}))},a=p("event",i,{durationThreshold:null!==(n=t.durationThreshold)&&void 0!==n?n:40});r=f(e,o,$,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),m((function(){i(a.takeRecords()),r(!0)})),c((function(){D=P(),L.length=0,M.clear(),o=d("INP"),r=f(e,o,$,t.reportAllChanges)})))})))},V=[],q=[],z=0,H=new WeakMap,G=new Map,K=-1,W=function(e){V=V.concat(e),Y()},Y=function(){K<0&&(K=U(X))},X=function(){G.size>10&&G.forEach((function(e,t){M.has(t)||G.delete(t)}));var e=L.map((function(e){return H.get(e.entries[0])})),t=q.length-50;q=q.filter((function(n,r){return r>=t||e.includes(n)}));for(var n=new Set,r=0;r<q.length;r++){var o=q[r];te(o.startTime,o.processingEnd).forEach((function(e){n.add(e)}))}var i=V.length-1-50;V=V.filter((function(e,t){return e.startTime>z&&t>i||n.has(e)})),K=-1};I.push((function(e){e.interactionId&&e.target&&!G.has(e.interactionId)&&G.set(e.interactionId,e.target)}),(function(e){var t,n=e.startTime+e.duration;z=Math.max(z,e.processingEnd);for(var r=q.length-1;r>=0;r--){var o=q[r];if(Math.abs(n-o.renderTime)<=8){(t=o).startTime=Math.min(e.startTime,t.startTime),t.processingStart=Math.min(e.processingStart,t.processingStart),t.processingEnd=Math.max(e.processingEnd,t.processingEnd),t.entries.push(e);break}}t||q.push(t={startTime:e.startTime,processingStart:e.processingStart,processingEnd:e.processingEnd,renderTime:n,entries:[e]}),(e.interactionId||"first-input"===e.entryType)&&H.set(e,t),Y()}));var Q,Z,J,ee,te=function(e,t){for(var n,r=[],o=0;n=V[o];o++)if(!(n.startTime+n.duration<e)){if(n.startTime>t)break;r.push(n)}return r},ne=[2500,4e3],re={},oe=[800,1800],ie=function e(t){document.prerendering?_((function(){return e(t)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(t)}),!0):setTimeout(t,0)},ae=function(e,t){t=t||{};var n=d("TTFB"),o=f(e,n,oe,t.reportAllChanges);ie((function(){var i=r();i&&(n.value=Math.max(i.responseStart-u(),0),n.entries=[i],o(!0),c((function(){n=d("TTFB",0),(o=f(e,n,oe,t.reportAllChanges))(!0)})))}))},se={passive:!0,capture:!0},le=new Date,ce=function(e,t){Q||(Q=t,Z=e,J=new Date,pe(removeEventListener),ue())},ue=function(){if(Z>=0&&Z<J-le){var e={entryType:"first-input",name:Q.type,target:Q.target,cancelable:Q.cancelable,startTime:Q.timeStamp,processingStart:Q.timeStamp+Z};ee.forEach((function(t){t(e)})),ee=[]}},de=function(e){if(e.cancelable){var t=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?(n=t,r=e,o=function(){ce(n,r),a()},i=function(){a()},a=function(){removeEventListener("pointerup",o,se),removeEventListener("pointercancel",i,se)},addEventListener("pointerup",o,se),addEventListener("pointercancel",i,se)):ce(t,e)}var n,r,o,i,a},pe=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(t){return e(t,de,se)}))},fe=[100,300],he=function(e,t){t=t||{},_((function(){var n,r=E(),o=d("FID"),i=function(e){e.startTime<r.firstHiddenTime&&(o.value=e.processingStart-e.startTime,o.entries.push(e),n(!0))},a=function(e){e.forEach(i)},s=p("first-input",a);n=f(e,o,fe,t.reportAllChanges),s&&(m(g((function(){a(s.takeRecords()),s.disconnect()}))),c((function(){o=d("FID"),n=f(e,o,fe,t.reportAllChanges),ee=[],Z=-1,Q=null,pe(addEventListener),ee.push(i),ue()})))}))};e.CLSThresholds=C,e.FCPThresholds=S,e.FIDThresholds=fe,e.INPThresholds=$,e.LCPThresholds=ne,e.TTFBThresholds=oe,e.onCLS=function(e,t){var n,r;n=function(t){var n=function(e){var t,n={};if(e.entries.length){var r=e.entries.reduce((function(e,t){return e&&e.value>t.value?e:t}));if(r&&r.sources&&r.sources.length){var i=(t=r.sources).find((function(e){return e.node&&1===e.node.nodeType}))||t[0];i&&(n={largestShiftTarget:a(i.node),largestShiftTime:r.startTime,largestShiftValue:r.value,largestShiftSource:i,largestShiftEntry:r,loadState:o(r.startTime)})}}return Object.assign(e,{attribution:n})}(t);e(n)},r=(r=t)||{},T(g((function(){var e,t=d("CLS",0),o=0,i=[],a=function(n){n.forEach((function(e){e.hadRecentInput||(o&&e.startTime-i[i.length-1].startTime<1e3&&e.startTime-i[0].startTime<5e3?(o+=e.value,i.push(e)):(o=e.value,i=[e]))})),o>t.value&&(t.value=o,t.entries=i,e())},s=p("layout-shift",a);s&&(e=f(n,t,C,r.reportAllChanges),m((function(){a(s.takeRecords()),e(!0)})),c((function(){o=0,t=d("CLS",0),e=f(n,t,C,r.reportAllChanges),h((function(){return e()}))})),setTimeout(e,0))})))},e.onFCP=function(e,t){T((function(t){var n=function(e){var t={timeToFirstByte:0,firstByteToFCP:e.value,loadState:o(l())};if(e.entries.length){var n=r(),i=e.entries[e.entries.length-1];if(n){var a=Math.max(0,n.responseStart-(n.activationStart||0));t={timeToFirstByte:a,firstByteToFCP:e.value-a,loadState:o(e.entries[0].startTime),navigationEntry:n,fcpEntry:i}}}return Object.assign(e,{attribution:t})}(t);e(n)}),t)},e.onFID=function(e,t){he((function(t){var n,r,i,s=(i={eventTarget:a((r=(n=t).entries[0]).target),eventType:r.name,eventTime:r.startTime,eventEntry:r,loadState:o(r.startTime)},Object.assign(n,{attribution:i}));e(s)}),t)},e.onINP=function(e,t){n||(n=p("long-animation-frame",W)),B((function(t){var n,r,i,s,l,c,u,d,p,f,h,m,g=(i=H.get(r=(n=t).entries[0]),s=r.processingStart,l=i.processingEnd,c=i.entries.sort((function(e,t){return e.processingStart-t.processingStart})),u=te(r.startTime,l),d=n.entries.find((function(e){return e.target})),p=d&&d.target||G.get(r.interactionId),f=[r.startTime+r.duration,l].concat(u.map((function(e){return e.startTime+e.duration}))),h=Math.max.apply(Math,f),m={interactionTarget:a(p),interactionTargetElement:p,interactionType:r.name.startsWith("key")?"keyboard":"pointer",interactionTime:r.startTime,nextPaintTime:h,processedEventEntries:c,longAnimationFrameEntries:u,inputDelay:s-r.startTime,processingDuration:l-s,presentationDelay:Math.max(h-l,0),loadState:o(r.startTime)},Object.assign(n,{attribution:m}));e(g)}),t)},e.onLCP=function(e,t){var n,o;n=function(t){var n=function(e){var t={timeToFirstByte:0,resourceLoadDelay:0,resourceLoadDuration:0,elementRenderDelay:e.value};if(e.entries.length){var n=r();if(n){var o=n.activationStart||0,i=e.entries[e.entries.length-1],s=i.url&&performance.getEntriesByType("resource").filter((function(e){return e.name===i.url}))[0],l=Math.max(0,n.responseStart-o),c=Math.max(l,s?(s.requestStart||s.startTime)-o:0),u=Math.max(c,s?s.responseEnd-o:0),d=Math.max(u,i.startTime-o);t={element:a(i.element),timeToFirstByte:l,resourceLoadDelay:c-l,resourceLoadDuration:u-c,elementRenderDelay:d-u,navigationEntry:n,lcpEntry:i},i.url&&(t.url=i.url),s&&(t.lcpResourceEntry=s)}}return Object.assign(e,{attribution:t})}(t);e(n)},o=(o=t)||{},_((function(){var e,t=E(),r=d("LCP"),i=function(n){o.reportAllChanges||(n=n.slice(-1)),n.forEach((function(n){n.startTime<t.firstHiddenTime&&(r.value=Math.max(n.startTime-u(),0),r.entries=[n],e())}))},a=p("largest-contentful-paint",i);if(a){e=f(n,r,ne,o.reportAllChanges);var s=g((function(){re[r.id]||(i(a.takeRecords()),a.disconnect(),re[r.id]=!0,e(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return U(s)}),{once:!0,capture:!0})})),m(s),c((function(t){r=d("LCP"),e=f(n,r,ne,o.reportAllChanges),h((function(){r.value=performance.now()-t.timeStamp,re[r.id]=!0,e(!0)}))}))}}))},e.onTTFB=function(e,t){ae((function(t){var n=function(e){var t={waitingDuration:0,cacheDuration:0,dnsDuration:0,connectionDuration:0,requestDuration:0};if(e.entries.length){var n=e.entries[0],r=n.activationStart||0,o=Math.max((n.workerStart||n.fetchStart)-r,0),i=Math.max(n.domainLookupStart-r,0),a=Math.max(n.connectStart-r,0),s=Math.max(n.connectEnd-r,0);t={waitingDuration:o,cacheDuration:i-o,dnsDuration:a-i,connectionDuration:s-a,requestDuration:e.value-s,navigationEntry:n}}return Object.assign(e,{attribution:t})}(t);e(n)}),t)}}(t)}(0,Wj.exports);var Yj=Wj.exports,Xj=Va&&Va.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),Qj=Va&&Va.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t}),Zj=Va&&Va.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)"default"!==n&&Object.prototype.hasOwnProperty.call(e,n)&&Xj(t,e,n);return Qj(t,e),t};Object.defineProperty(Kj,"__esModule",{value:!0}),Kj.WebVitalsInstrumentation=Kj.InstrumentationAbstract=void 0;const Jj=Yj,eI=TD,tI=FD,nI=Zj(Dm);let rI=class{constructor(e,t,n={}){this.instrumentationName=e,this.instrumentationVersion=t,this._wrap=nI.wrap,this._unwrap=nI.unwrap,this._massWrap=nI.massWrap,this._massUnwrap=nI.massUnwrap,this._config=Object.assign({enabled:!0},n),this._diag=tI.diag.createComponentLogger({namespace:e}),this._tracer=tI.trace.getTracer(e,t),this._meter=tI.metrics.getMeter(e,t),this._updateMetricInstruments()}get meter(){return this._meter}setMeterProvider(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()}_updateMetricInstruments(){}getConfig(){return this._config}setConfig(e={}){this._config=Object.assign({},e)}setTracerProvider(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)}get tracer(){return this._tracer}};Kj.InstrumentationAbstract=rI;Kj.WebVitalsInstrumentation=class extends rI{constructor({enabled:e=!0,vitalsToTrack:t=["CLS","LCP","INP"],lcp:n,cls:r,inp:o,fid:i,fcp:a,ttfb:s}={}){super("@honeycombio/instrumentation-web-vitals",eI.VERSION,{enabled:e,vitalsToTrack:t,lcp:n,cls:r,inp:o,fid:i,fcp:a,ttfb:s}),this.onReportCLS=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{largestShiftTarget:o,largestShiftTime:i,largestShiftValue:a,loadState:s,largestShiftEntry:l}=r,c=this.getAttrPrefix(n),u=this.tracer.startSpan(n);u.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${c}.largest_shift_target`]:o,[`${c}.element`]:o,[`${c}.largest_shift_time`]:i,[`${c}.largest_shift_value`]:a,[`${c}.load_state`]:s,[`${c}.had_recent_input`]:null==l?void 0:l.hadRecentInput})),t&&t(e,u),u.end()},this.onReportLCP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{element:o,url:i,timeToFirstByte:a,resourceLoadDelay:s,resourceLoadDuration:l,elementRenderDelay:c}=r,u=this.getAttrPrefix(n),d=this.tracer.startSpan(n);d.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${u}.element`]:o,[`${u}.url`]:i,[`${u}.time_to_first_byte`]:a,[`${u}.resource_load_delay`]:s,[`${u}.resource_load_duration`]:l,[`${u}.element_render_delay`]:c,[`${u}.resource_load_time`]:l})),t&&t(e,d),d.end()},this.onReportINP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{inputDelay:o,interactionTarget:i,interactionTime:a,interactionType:s,loadState:l,nextPaintTime:c,presentationDelay:u,processingDuration:d}=r,p=this.getAttrPrefix(n),f=this.tracer.startSpan(n);f.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${p}.input_delay`]:o,[`${p}.interaction_target`]:i,[`${p}.interaction_time`]:a,[`${p}.interaction_type`]:s,[`${p}.load_state`]:l,[`${p}.next_paint_time`]:c,[`${p}.presentation_delay`]:u,[`${p}.processing_duration`]:d,[`${p}.element`]:i,[`${p}.event_type`]:s})),t&&t(e,f),f.end()},this.onReportFCP=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{timeToFirstByte:o,firstByteToFCP:i,loadState:a}=r,s=this.getAttrPrefix(n),l=this.tracer.startSpan(n);l.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${s}.time_to_first_byte`]:o,[`${s}.time_since_first_byte`]:i,[`${s}.load_state`]:a})),t&&t(e,l),l.end()},this.onReportFID=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{eventTarget:o,eventType:i,loadState:a}=r,s=this.getAttrPrefix(n),l=this.tracer.startSpan(n);l.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${s}.element`]:o,[`${s}.event_type`]:i,[`${s}.load_state`]:a})),t&&t(e,l),l.end()},this.onReportTTFB=(e,t)=>{if(!this.isEnabled())return;const{name:n,attribution:r}=e,{cacheDuration:o,connectionDuration:i,dnsDuration:a,requestDuration:s,waitingDuration:l}=r,c=this.getAttrPrefix(n),u=this.tracer.startSpan(n);u.setAttributes(Object.assign(Object.assign({},this.getSharedAttributes(e)),{[`${c}.waiting_duration`]:l,[`${c}.dns_duration`]:a,[`${c}.connection_duration`]:i,[`${c}.request_duration`]:s,[`${c}.cache_duration`]:o,[`${c}.waiting_time`]:l,[`${c}.dns_time`]:a,[`${c}.connection_time`]:i,[`${c}.request_time`]:s})),t&&t(e,u),u.end()},this.vitalsToTrack=[...t],this.lcpOpts=n,this.clsOpts=r,this.inpOpts=o,this.fidOpts=i,this.fcpOpts=a,this.ttfbOpts=s,this._isEnabled=e,this._setupWebVitalsCallbacks()}init(){}_setupWebVitalsCallbacks(){this.vitalsToTrack.includes("CLS")&&(0,Jj.onCLS)((e=>{var t;this.onReportCLS(e,null===(t=this.clsOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.clsOpts),this.vitalsToTrack.includes("LCP")&&(0,Jj.onLCP)((e=>{var t;this.onReportLCP(e,null===(t=this.lcpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.lcpOpts),this.vitalsToTrack.includes("INP")&&(0,Jj.onINP)((e=>{var t;this.onReportINP(e,null===(t=this.inpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.inpOpts),this.vitalsToTrack.includes("FID")&&(0,Jj.onFID)((e=>{var t;this.onReportFID(e,null===(t=this.fidOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.fidOpts),this.vitalsToTrack.includes("TTFB")&&(0,Jj.onTTFB)((e=>{var t;this.onReportTTFB(e,null===(t=this.ttfbOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.ttfbOpts),this.vitalsToTrack.includes("FCP")&&(0,Jj.onFCP)((e=>{var t;this.onReportFCP(e,null===(t=this.fcpOpts)||void 0===t?void 0:t.applyCustomAttributes)}),this.fcpOpts)}getAttrPrefix(e){return e.toLowerCase()}getSharedAttributes(e){const{name:t,id:n,delta:r,rating:o,value:i,navigationType:a}=e,s=this.getAttrPrefix(t);return{[`${s}.id`]:n,[`${s}.delta`]:r,[`${s}.value`]:i,[`${s}.rating`]:o,[`${s}.navigation_type`]:a}}disable(){this.isEnabled()?(this._isEnabled=!1,this._diag.debug("Instrumentation disabled")):this._diag.debug("Instrumentation already disabled")}enable(){this.isEnabled()?this._diag.debug("Instrumentation already enabled"):(this._isEnabled=!0,this._diag.debug("Instrumentation enabled"),this._diag.debug(`Sending spans for ${this.vitalsToTrack.join(",")}`))}isEnabled(){return this._isEnabled}},Object.defineProperty(_D,"__esModule",{value:!0}),_D.HoneycombWebSDK=void 0;const oI=Cf,iI=SD,aI=OD,sI=PD,lI=MD,cI=ID,uI=zD,dI=qj,pI=$D,fI=Kj;_D.HoneycombWebSDK=class extends oI.WebSDK{constructor(e){var t;const n=[...(null==e?void 0:e.instrumentations)||[]];!1!==(null===(t=null==e?void 0:e.webVitalsInstrumentationConfig)||void 0===t?void 0:t.enabled)&&n.push(new fI.WebVitalsInstrumentation(null==e?void 0:e.webVitalsInstrumentationConfig)),super(Object.assign(Object.assign({},e),{instrumentations:n,resource:(0,lI.mergeResources)([(0,sI.configureBrowserAttributesResource)(),(0,aI.configureEntryPageResource)(null==e?void 0:e.entryPageAttributes),null==e?void 0:e.resource,null==e?void 0:e.resourceAttributes,(0,iI.configureHoneycombResource)()]),sampler:(0,dI.configureDeterministicSampler)(e),spanProcessor:(0,uI.configureSpanProcessors)(e)})),(0,pI.validateOptionsWarnings)(e),(null==e?void 0:e.debug)&&(0,cI.configureDebug)(e)}},function(e){var t=Va&&Va.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n);var o=Object.getOwnPropertyDescriptor(t,n);o&&!("get"in o?!t.__esModule:o.writable||o.configurable)||(o={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,o)}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),n=Va&&Va.__exportStar||function(e,n){for(var r in e)"default"===r||Object.prototype.hasOwnProperty.call(n,r)||t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(Cf,e),n(_D,e),n(Kj,e)}(Tf);var hI=Kf("OpenTelemetry SDK Context Key SUPPRESS_TRACING");var mI="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},gI=performance,yI="http.method",vI="http.url",bI="http.host",wI="http.scheme",xI="http.status_code",EI="http.user_agent",_I="http.request_content_length_uncompressed",SI="http.response_content_length",TI="http.response_content_length_uncompressed",CI=Math.pow(10,6),AI=Math.pow(10,9);function OI(e){return[Math.trunc(e/1e3),Math.round(e%1e3*CI)]}function NI(){var e=gI.timeOrigin;if("number"!=typeof e){e=gI.timing&&gI.timing.fetchStart}return e}function RI(e){return function(e,t){var n=[e[0]+t[0],e[1]+t[1]];n[1]>=AI&&(n[1]-=AI,n[0]+=1);return n}(OI(NI()),OI("number"==typeof e?e:gI.now()))}function PI(e){if(t=e,Array.isArray(t)&&2===t.length&&"number"==typeof t[0]&&"number"==typeof t[1])return e;if("number"==typeof e)return e<NI()?RI(e):OI(e);if(e instanceof Date)return OI(e.getTime());throw TypeError("Invalid input type");var t}function kI(e){return e[0]*AI+e[1]}var LI="[_0-9a-z-*/]",MI=new RegExp("^(?:"+("[a-z]"+LI+"{0,255}")+"|"+("[a-z0-9]"+LI+"{0,240}@[a-z]"+LI+"{0,13}")+")$"),DI=/^[ -~]{0,255}[!-~]$/,jI=/,|=/;var II=function(){function e(e){this._internalState=new Map,e&&this._parse(e)}return e.prototype.set=function(e,t){var n=this._clone();return n._internalState.has(e)&&n._internalState.delete(e),n._internalState.set(e,t),n},e.prototype.unset=function(e){var t=this._clone();return t._internalState.delete(e),t},e.prototype.get=function(e){return this._internalState.get(e)},e.prototype.serialize=function(){var e=this;return this._keys().reduce((function(t,n){return t.push(n+"="+e.get(n)),t}),[]).join(",")},e.prototype._parse=function(e){e.length>512||(this._internalState=e.split(",").reverse().reduce((function(e,t){var n=t.trim(),r=n.indexOf("=");if(-1!==r){var o=n.slice(0,r),i=n.slice(r+1,t.length);(function(e){return MI.test(e)})(o)&&function(e){return DI.test(e)&&!jI.test(e)}(i)&&e.set(o,i)}return e}),new Map),this._internalState.size>32&&(this._internalState=new Map(Array.from(this._internalState.entries()).reverse().slice(0,32))))},e.prototype._keys=function(){return Array.from(this._internalState.keys()).reverse()},e.prototype._clone=function(){var t=new e;return t._internalState=new Map(this._internalState),t},e}(),FI="traceparent",UI="tracestate",$I=new RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");var BI=function(){function e(){}return e.prototype.inject=function(e,t,n){var r=bm.getSpanContext(e);if(r&&!function(e){return!0===e.getValue(hI)}(e)&&Uh(r)){var o="00-"+r.traceId+"-"+r.spanId+"-0"+Number(r.traceFlags||gh.NONE).toString(16);n.set(t,FI,o),r.traceState&&n.set(t,UI,r.traceState.serialize())}},e.prototype.extract=function(e,t,n){var r=n.get(t,FI);if(!r)return e;var o=Array.isArray(r)?r[0]:r;if("string"!=typeof o)return e;var i=function(e){var t=$I.exec(e);return t?"00"===t[1]&&t[5]?null:{traceId:t[2],spanId:t[3],traceFlags:parseInt(t[4],16)}:null}(o);if(!i)return e;i.isRemote=!0;var a=n.get(t,UI);if(a){var s=Array.isArray(a)?a.join(","):a;i.traceState=new II("string"==typeof s?s:void 0)}return bm.setSpanContext(e,i)},e.prototype.fields=function(){return[FI,UI]},e}();function VI(e,t){return"string"==typeof t?e===t:!!e.match(t)}function qI(e,t){var n,r;if(!t)return!1;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),i=o.next();!i.done;i=o.next()){if(VI(e,i.value))return!0}}catch(a){n={error:a}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}return!1}var zI=function(){function e(){}return e.prototype.emit=function(e){},e}(),HI=new zI,GI=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new zI},e}()),KI=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):HI},e}(),WI=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new KI(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:GI},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),YI="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},XI=Symbol.for("io.opentelemetry.js.api.logs"),QI=YI;var ZI,JI,eF=function(){function e(){this._proxyLoggerProvider=new WI}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return QI[XI]?this.getLoggerProvider():(QI[XI]=(t=1,n=e,r=GI,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=QI[XI])||void 0===e?void 0:e.call(QI,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete QI[XI],this._proxyLoggerProvider=new WI},e}().getInstance(),tF=function(){return tF=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},tF.apply(this,arguments)},nF=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=eF.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=tF({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),rF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),oF=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return rF(t,e),t}(nF);function iF(e,t,n){var r,o;try{o=e()}catch(tme){r=tme}finally{return t(r,o),o}}function aF(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}(JI=ZI||(ZI={})).DOCUMENT_LOAD="documentLoad",JI.DOCUMENT_FETCH="documentFetch",JI.RESOURCE_FETCH="resourceFetch";var sF,lF;(lF=sF||(sF={})).FIRST_PAINT="firstPaint",lF.FIRST_CONTENTFUL_PAINT="firstContentfulPaint";var cF={"first-paint":sF.FIRST_PAINT,"first-contentful-paint":sF.FIRST_CONTENTFUL_PAINT},uF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),dF=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-document-load","0.44.1",t)||this;return n.component="document-load",n.version="1",n.moduleName=n.component,n}return uF(t,e),t.prototype.init=function(){},t.prototype._onDocumentLoaded=function(){var e=this;window.setTimeout((function(){e._collectPerformance()}))},t.prototype._addResourcesSpans=function(e){var t,n,r=this,o=null===(n=(t=gI).getEntriesByType)||void 0===n?void 0:n.call(t,"resource");o&&o.forEach((function(t){r._initResourceSpan(t,e)}))},t.prototype._collectPerformance=function(){var e=this,t=Array.from(document.getElementsByTagName("meta")).find((function(e){return e.getAttribute("name")===FI})),n=function(){var e,t,n={},r=null===(t=(e=gI).getEntriesByType)||void 0===t?void 0:t.call(e,"navigation")[0];if(r)Object.values(xM).forEach((function(e){if(LM(r,e)){var t=r[e];"number"==typeof t&&(n[e]=t)}}));else{var o=gI.timing;o&&Object.values(xM).forEach((function(e){if(LM(o,e)){var t=o[e];"number"==typeof t&&(n[e]=t)}}))}return n}();om.with(ym.extract(Xf,{traceparent:t&&t.content||""}),(function(){var t,r=e._startSpan(ZI.DOCUMENT_LOAD,xM.FETCH_START,n);r&&(om.with(bm.setSpan(om.active(),r),(function(){var t=e._startSpan(ZI.DOCUMENT_FETCH,xM.FETCH_START,n);t&&(t.setAttribute(vI,location.href),om.with(bm.setSpan(om.active(),t),(function(){var r;e.getConfig().ignoreNetworkEvents||DM(t,n),e._addCustomAttributesOnSpan(t,null===(r=e.getConfig().applyCustomAttributesOnSpan)||void 0===r?void 0:r.documentFetch),e._endSpan(t,xM.RESPONSE_END,n)})))})),r.setAttribute(vI,location.href),r.setAttribute(EI,navigator.userAgent),e._addResourcesSpans(r),e.getConfig().ignoreNetworkEvents||(MM(r,xM.FETCH_START,n),MM(r,xM.UNLOAD_EVENT_START,n),MM(r,xM.UNLOAD_EVENT_END,n),MM(r,xM.DOM_INTERACTIVE,n),MM(r,xM.DOM_CONTENT_LOADED_EVENT_START,n),MM(r,xM.DOM_CONTENT_LOADED_EVENT_END,n),MM(r,xM.DOM_COMPLETE,n),MM(r,xM.LOAD_EVENT_START,n),MM(r,xM.LOAD_EVENT_END,n)),e.getConfig().ignorePerformancePaintEvents||function(e){var t,n,r=null===(n=(t=gI).getEntriesByType)||void 0===n?void 0:n.call(t,"paint");r&&r.forEach((function(t){var n=t.name,r=t.startTime;LM(cF,n)&&e.addEvent(cF[n],r)}))}(r),e._addCustomAttributesOnSpan(r,null===(t=e.getConfig().applyCustomAttributesOnSpan)||void 0===t?void 0:t.documentLoad),e._endSpan(r,xM.LOAD_EVENT_END,n))}))},t.prototype._endSpan=function(e,t,n){e&&(LM(n,t)?e.end(n[t]):e.end())},t.prototype._initResourceSpan=function(e,t){var n,r=this._startSpan(ZI.RESOURCE_FETCH,xM.FETCH_START,e,t);r&&(r.setAttribute(vI,e.name),this.getConfig().ignoreNetworkEvents||DM(r,e),this._addCustomAttributesOnResourceSpan(r,e,null===(n=this.getConfig().applyCustomAttributesOnSpan)||void 0===n?void 0:n.resourceFetch),this._endSpan(r,xM.RESPONSE_END,e))},t.prototype._startSpan=function(e,t,n,r){if(LM(n,t)&&"number"==typeof n[t])return this.tracer.startSpan(e,{startTime:n[t]},r?bm.setSpan(om.active(),r):void 0)},t.prototype._waitForPageLoad=function(){"complete"===window.document.readyState?this._onDocumentLoaded():(this._onDocumentLoaded=this._onDocumentLoaded.bind(this),window.addEventListener("load",this._onDocumentLoaded))},t.prototype._addCustomAttributesOnSpan=function(e,t){var n=this;t&&iF((function(){return t(e)}),(function(e){e&&n._diag.error("addCustomAttributesOnSpan",e)}))},t.prototype._addCustomAttributesOnResourceSpan=function(e,t,n){var r=this;n&&iF((function(){return n(e,t)}),(function(e){e&&r._diag.error("addCustomAttributesOnResourceSpan",e)}))},t.prototype.enable=function(){window.removeEventListener("load",this._onDocumentLoaded),this._waitForPageLoad()},t.prototype.disable=function(){window.removeEventListener("load",this._onDocumentLoaded)},t}(oF),pF=function(){function e(){}return e.prototype.emit=function(e){},e}(),fF=new pF,hF=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new pF},e}()),mF=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):fF},e}(),gF=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new mF(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:hF},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),yF="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},vF=Symbol.for("io.opentelemetry.js.api.logs"),bF=yF;var wF,xF,EF,_F=function(){function e(){this._proxyLoggerProvider=new gF}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return bF[vF]?this.getLoggerProvider():(bF[vF]=(t=1,n=e,r=hF,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=bF[vF])||void 0===e?void 0:e.call(bF,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete bF[vF],this._proxyLoggerProvider=new gF},e}().getInstance(),SF=function(){return SF=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},SF.apply(this,arguments)},TF=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=_F.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=SF({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),CF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),AF=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return CF(t,e),t}(TF);function OF(e,t){return t in e}function NF(e,t,n,r){var o=void 0,i=void 0;OF(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=wF.FETCH_START;if(OF(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function RF(e,t,n){void 0===n&&(n=!1),n||(NF(e,wF.FETCH_START,t),NF(e,wF.DOMAIN_LOOKUP_START,t),NF(e,wF.DOMAIN_LOOKUP_END,t),NF(e,wF.CONNECT_START,t),OF(t,"name")&&t.name.startsWith("https:")&&NF(e,wF.SECURE_CONNECTION_START,t),NF(e,wF.CONNECT_END,t),NF(e,wF.REQUEST_START,t),NF(e,wF.RESPONSE_START,t),NF(e,wF.RESPONSE_END,t));var r=t[wF.ENCODED_BODY_SIZE];void 0!==r&&e.setAttribute(SI,r);var o=t[wF.DECODED_BODY_SIZE];void 0!==o&&r!==o&&e.setAttribute(TI,o)}function PF(){return"undefined"!=typeof location?location.origin:void 0}function kF(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=LF(e),s=function(e,t,n,r,o,i){var a=kI(t),s=kI(n),l=r.filter((function(t){var n=kI(PI(t[wF.FETCH_START])),r=kI(PI(t[wF.RESPONSE_END]));return t.initiatorType.toLowerCase()===i&&t.name===e&&n>=a&&r<=s}));l.length>0&&(l=l.filter((function(e){return!o.has(e)})));return l}(e=a.toString(),t,n,r,o,i);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=function(e){return e.slice().sort((function(e,t){var n=e[wF.FETCH_START],r=t[wF.FETCH_START];return n>r?1:n<r?-1:0}))}(s);if(a.origin!==PF()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=kI(n),i=kI(PI(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=kI(PI(c[wF.FETCH_START])),d=o-kI(PI(c[wF.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[wF.RESPONSE_END],n);return u[wF.FETCH_START]<c[wF.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}}function LF(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(xF||(xF=document.createElement("a")),xF);return t.href=e,t}!function(e){e.CONNECT_END="connectEnd",e.CONNECT_START="connectStart",e.DECODED_BODY_SIZE="decodedBodySize",e.DOM_COMPLETE="domComplete",e.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",e.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",e.DOM_INTERACTIVE="domInteractive",e.DOMAIN_LOOKUP_END="domainLookupEnd",e.DOMAIN_LOOKUP_START="domainLookupStart",e.ENCODED_BODY_SIZE="encodedBodySize",e.FETCH_START="fetchStart",e.LOAD_EVENT_END="loadEventEnd",e.LOAD_EVENT_START="loadEventStart",e.NAVIGATION_START="navigationStart",e.REDIRECT_END="redirectEnd",e.REDIRECT_START="redirectStart",e.REQUEST_START="requestStart",e.RESPONSE_END="responseEnd",e.RESPONSE_START="responseStart",e.SECURE_CONNECTION_START="secureConnectionStart",e.UNLOAD_EVENT_END="unloadEventEnd",e.UNLOAD_EVENT_START="unloadEventStart"}(wF||(wF={})),function(e){e.COMPONENT="component",e.HTTP_ERROR_NAME="http.error_name",e.HTTP_STATUS_TEXT="http.status_text"}(EF||(EF={}));var MF=function(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{l(r.next(e))}catch(tme){i(tme)}}function s(e){try{l(r.throw(e))}catch(tme){i(tme)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,s)}l((r=r.apply(e,t||[])).next())}))},DF=function(e,t){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(i){return function(s){return function(i){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&i[0]?r.return:i[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,i[1])).done)return o;switch(r=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,r=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(tme){i=[6,tme],r=0}finally{n=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,s])}}},jF=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},IF=im.createComponentLogger({namespace:"@opentelemetry/opentelemetry-instrumentation-fetch/utils"});function FF(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(e[0]instanceof URL||"string"==typeof e[0]){var n=e[1];if(!(null==n?void 0:n.body))return Promise.resolve();if(n.body instanceof ReadableStream){var r=function(e){if(!e.pipeThrough)return IF.warn("Platform has ReadableStream but not pipeThrough!"),{body:e,length:Promise.resolve(void 0)};var t,n=0,r=new Promise((function(e){t=e})),o=new TransformStream({start:function(){},transform:function(e,t){return MF(this,void 0,void 0,(function(){var r;return DF(this,(function(o){switch(o.label){case 0:return[4,e];case 1:return r=o.sent(),n+=r.byteLength,t.enqueue(e),[2]}}))}))},flush:function(){t(n)}});return{body:e.pipeThrough(o),length:r}}(n.body),o=r.length;return n.body=r.body,o}return Promise.resolve(function(e){if("undefined"!=typeof Document&&e instanceof Document)return(new XMLSerializer).serializeToString(document).length;if(e instanceof Blob)return e.size;if(void 0!==e.byteLength)return e.byteLength;if(e instanceof FormData)return function(e){var t,n,r=0;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e.entries()),i=o.next();!i.done;i=o.next()){var a=jF(i.value,2),s=a[1];r+=a[0].length,s instanceof Blob?r+=s.size:r+=s.length}}catch(l){t={error:l}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}(e);if(e instanceof URLSearchParams)return $F(e.toString());if("string"==typeof e)return $F(e);return void IF.warn("unknown body type")}(n.body))}var i=e[0];return(null==i?void 0:i.body)?i.clone().text().then((function(e){return $F(e)})):Promise.resolve()}var UF=new TextEncoder;function $F(e){return UF.encode(e).byteLength}var BF,VF,qF="0.57.2",zF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),HF="object"==typeof process&&"node"===(null===(BF=process.release)||void 0===BF?void 0:BF.name),GF=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-fetch",qF,t)||this;return n.component="fetch",n.version=qF,n.moduleName=n.component,n._usedResources=new WeakSet,n._tasksCount=0,n}return zF(t,e),t.prototype.init=function(){},t.prototype._addChildSpan=function(e,t){var n=this.tracer.startSpan("CORS Preflight",{startTime:t[wF.FETCH_START]},bm.setSpan(om.active(),e));RF(n,t,this.getConfig().ignoreNetworkEvents),n.end(t[wF.RESPONSE_END])},t.prototype._addFinalSpanAttributes=function(e,t){var n=LF(t.url);e.setAttribute(xI,t.status),null!=t.statusText&&e.setAttribute(EF.HTTP_STATUS_TEXT,t.statusText),e.setAttribute(bI,n.host),e.setAttribute(wI,n.protocol.replace(":","")),"undefined"!=typeof navigator&&e.setAttribute(EI,navigator.userAgent)},t.prototype._addHeaders=function(e,t){if(!function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),LF(e).origin===PF()||n.some((function(t){return VI(e,t)}))}(t,this.getConfig().propagateTraceHeaderCorsUrls)){var n={};return ym.inject(om.active(),n),void(Object.keys(n).length>0&&this._diag.debug("headers inject skipped due to CORS policy"))}if(e instanceof Request)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else if(e.headers instanceof Headers)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else if(e.headers instanceof Map)ym.inject(om.active(),e.headers,{set:function(e,t,n){return e.set(t,"string"==typeof n?n:String(n))}});else{n={};ym.inject(om.active(),n),e.headers=Object.assign({},n,e.headers||{})}},t.prototype._clearResources=function(){0===this._tasksCount&&this.getConfig().clearTimingResources&&(performance.clearResourceTimings(),this._usedResources=new WeakSet)},t.prototype._createSpan=function(e,t){var n;if(void 0===t&&(t={}),!qI(e,this.getConfig().ignoreUrls)){var r=(t.method||"GET").toUpperCase();return this.tracer.startSpan("HTTP "+r,{kind:Hh.CLIENT,attributes:(n={},n[EF.COMPONENT]=this.moduleName,n[yI]=r,n[vI]=e,n)})}this._diag.debug("ignoring span as url matches ignored url")},t.prototype._findResourceAndAddNetworkEvents=function(e,t,n){var r=t.entries;if(!r.length){if(!performance.getEntriesByType)return;r=performance.getEntriesByType("resource")}var o=kF(t.spanUrl,t.startTime,n,r,this._usedResources,"fetch");if(o.mainRequest){var i=o.mainRequest;this._markResourceAsUsed(i);var a=o.corsPreFlightRequest;a&&(this._addChildSpan(e,a),this._markResourceAsUsed(a)),RF(e,i,this.getConfig().ignoreNetworkEvents)}},t.prototype._markResourceAsUsed=function(e){this._usedResources.add(e)},t.prototype._endSpan=function(e,t,n){var r=this,o=OI(Date.now()),i=RI();this._addFinalSpanAttributes(e,n),setTimeout((function(){var n;null===(n=t.observer)||void 0===n||n.disconnect(),r._findResourceAndAddNetworkEvents(e,t,i),r._tasksCount--,r._clearResources(),e.end(o)}),300)},t.prototype._patchConstructor=function(){var e=this;return function(t){var n=e;return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];var o=this,i=LF(e[0]instanceof Request?e[0].url:String(e[0])).href,a=e[0]instanceof Request?e[0]:e[1]||{},s=n._createSpan(i,a);if(!s)return t.apply(this,e);var l=n._prepareSpanData(i);function c(e,t){n._applyAttributesAfterFetch(e,a,t),n._endSpan(e,l,{status:t.status||0,statusText:t.message,url:i})}function u(e,t){n._applyAttributesAfterFetch(e,a,t),n._endSpan(e,l,t.status>=200&&t.status<400?t:{status:t.status,statusText:t.statusText,url:i})}function d(e,t,n){try{var r=n.clone(),o=n.clone(),i=r.body;if(i){var a=i.getReader(),s=function(){a.read().then((function(t){t.done?u(e,o):s()}),(function(t){c(e,t)}))};s()}else u(e,n)}finally{t(n)}}function p(e,t,n){try{c(e,n)}finally{t(n)}}return n.getConfig().measureRequestSize&&FF.apply(void 0,function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}(e),!1)).then((function(e){e&&s.setAttribute(_I,e)})).catch((function(e){n._diag.warn("getFetchBodyLength",e)})),new Promise((function(e,r){return om.with(bm.setSpan(om.active(),s),(function(){return n._addHeaders(a,i),n._tasksCount++,t.apply(o,a instanceof Request?[a]:[i,a]).then(d.bind(o,s,e),p.bind(o,s,r))}))}))}}},t.prototype._applyAttributesAfterFetch=function(e,t,n){var r=this,o=this.getConfig().applyCustomAttributesOnSpan;o&&function(e,t){var n,r;try{r=e()}catch(tme){n=tme}finally{return t(n,r),r}}((function(){return o(e,t,n)}),(function(e){e&&r._diag.error("applyCustomAttributesOnSpan",e)}))},t.prototype._prepareSpanData=function(e){var t=RI(),n=[];if("function"!=typeof PerformanceObserver)return{entries:n,startTime:t,spanUrl:e};var r=new PerformanceObserver((function(t){t.getEntries().forEach((function(t){"fetch"===t.initiatorType&&t.name===e&&n.push(t)}))}));return r.observe({entryTypes:["resource"]}),{entries:n,observer:r,startTime:t,spanUrl:e}},t.prototype.enable=function(){HF?this._diag.warn("this instrumentation is intended for web usage only, it does not instrument Node.js's fetch()"):(function(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}(fetch)&&(this._unwrap(mI,"fetch"),this._diag.debug("removing previous patch for constructor")),this._wrap(mI,"fetch",this._patchConstructor()))},t.prototype.disable=function(){HF||(this._unwrap(mI,"fetch"),this._usedResources=new WeakSet)},t}(AF);!function(e){e.EVENT_TYPE="event_type",e.TARGET_ELEMENT="target_element",e.TARGET_XPATH="target_xpath",e.HTTP_URL="http.url"}(VF||(VF={}));var KF="0.44.1",WF=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),YF=["click"];function XF(){return!1}var QF=function(e){function t(t){var n;void 0===t&&(t={});var r=e.call(this,"@opentelemetry/instrumentation-user-interaction",KF,t)||this;return r.version=KF,r.moduleName="user-interaction",r._spansData=new WeakMap,r._wrappedListeners=new WeakMap,r._eventsSpanMap=new WeakMap,r._eventNames=new Set(null!==(n=null==t?void 0:t.eventNames)&&void 0!==n?n:YF),r._shouldPreventSpanCreation="function"==typeof(null==t?void 0:t.shouldPreventSpanCreation)?t.shouldPreventSpanCreation:XF,r}return WF(t,e),t.prototype.init=function(){},t.prototype._checkForTimeout=function(e,t){var n=this._spansData.get(t);n&&("setTimeout"===e.source?n.hrTimeLastTimeout=RI():"Promise.then"!==e.source&&"setTimeout"!==e.source&&(n.hrTimeLastTimeout=void 0))},t.prototype._allowEventName=function(e){return this._eventNames.has(e)},t.prototype._createSpan=function(e,t,n){var r;if(e instanceof HTMLElement&&e.getAttribute&&!e.hasAttribute("disabled")&&this._allowEventName(t)){var o=UM(e,!0);try{var i=this.tracer.startSpan(t,{attributes:(r={},r[VF.EVENT_TYPE]=t,r[VF.TARGET_ELEMENT]=e.tagName,r[VF.TARGET_XPATH]=o,r[VF.HTTP_URL]=window.location.href,r)},n?bm.setSpan(om.active(),n):void 0);if(!0===this._shouldPreventSpanCreation(t,e,i))return;return this._spansData.set(i,{taskCount:0}),i}catch(tme){this._diag.error("failed to start create new user interaction span",tme)}}},t.prototype._decrementTask=function(e){var t=this._spansData.get(e);t&&(t.taskCount--,0===t.taskCount&&this._tryToEndSpan(e,t.hrTimeLastTimeout))},t.prototype._getCurrentSpan=function(e){var t=e.get("OT_ZONE_CONTEXT");return t?bm.getSpan(t):t},t.prototype._incrementTask=function(e){var t=this._spansData.get(e);t&&t.taskCount++},t.prototype.addPatchedListener=function(e,t,n,r){var o=this._wrappedListeners.get(n);o||this._wrappedListeners.set(n,o=new Map);var i=o.get(t);return i||o.set(t,i=new Map),!i.has(e)&&(i.set(e,r),!0)},t.prototype.removePatchedListener=function(e,t,n){var r=this._wrappedListeners.get(n);if(r){var o=r.get(t);if(o){var i=o.get(e);return i&&(o.delete(e),0===o.size&&(r.delete(t),0===r.size&&this._wrappedListeners.delete(n))),i}}},t.prototype._invokeListener=function(e,t,n){return"function"==typeof e?e.apply(t,n):e.handleEvent(n[0])},t.prototype._patchAddEventListener=function(){var e=this;return function(t){return function(n,r,o){if(!r)return t.call(this,n,r,o);var i=o&&"object"==typeof o&&o.once,a=function(){for(var t,o=this,a=[],s=0;s<arguments.length;s++)a[s]=arguments[s];var l=a[0],c=null==l?void 0:l.target;l&&(t=e._eventsSpanMap.get(l)),i&&e.removePatchedListener(this,n,r);var u=e._createSpan(c,n,t);return u?(l&&e._eventsSpanMap.set(l,u),om.with(bm.setSpan(om.active(),u),(function(){var t=e._invokeListener(r,o,a);return u.end(),t}))):e._invokeListener(r,this,a)};return e.addPatchedListener(this,n,r,a)?t.call(this,n,a,o):void 0}}},t.prototype._patchRemoveEventListener=function(){var e=this;return function(t){return function(n,r,o){var i=e.removePatchedListener(this,n,r);return t.call(this,n,i||r,o)}}},t.prototype._getPatchableEventTargets=function(){return window.EventTarget?[EventTarget.prototype]:[Node.prototype,Window.prototype]},t.prototype._patchHistoryApi=function(){this._unpatchHistoryApi(),this._wrap(history,"replaceState",this._patchHistoryMethod()),this._wrap(history,"pushState",this._patchHistoryMethod()),this._wrap(history,"back",this._patchHistoryMethod()),this._wrap(history,"forward",this._patchHistoryMethod()),this._wrap(history,"go",this._patchHistoryMethod())},t.prototype._patchHistoryMethod=function(){var e=this;return function(t){return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var o=""+location.pathname+location.hash+location.search,i=t.apply(this,n),a=""+location.pathname+location.hash+location.search;return o!==a&&e._updateInteractionName(a),i}}},t.prototype._unpatchHistoryApi=function(){aF(history.replaceState)&&this._unwrap(history,"replaceState"),aF(history.pushState)&&this._unwrap(history,"pushState"),aF(history.back)&&this._unwrap(history,"back"),aF(history.forward)&&this._unwrap(history,"forward"),aF(history.go)&&this._unwrap(history,"go")},t.prototype._updateInteractionName=function(e){var t=bm.getSpan(om.active());t&&"function"==typeof t.updateName&&t.updateName("Navigation: "+e)},t.prototype._patchZoneCancelTask=function(){var e=this;return function(t){return function(n){var r=Zone.current,o=e._getCurrentSpan(r);return o&&e._shouldCountTask(n,r)&&e._decrementTask(o),t.call(this,n)}}},t.prototype._patchZoneScheduleTask=function(){var e=this;return function(t){return function(n){var r=Zone.current,o=e._getCurrentSpan(r);return o&&e._shouldCountTask(n,r)&&(e._incrementTask(o),e._checkForTimeout(n,o)),t.call(this,n)}}},t.prototype._patchZoneRunTask=function(){var e=this;return function(t){return function(n,r,o){var i,a=Array.isArray(o)&&o[0]instanceof Event?o[0]:void 0,s=null==a?void 0:a.target,l=this;if(s){if(i=e._createSpan(s,n.eventName))return e._incrementTask(i),l.run((function(){try{return om.with(bm.setSpan(om.active(),i),(function(){var e=Zone.current;return n._zone=e,t.call(e,n,r,o)}))}finally{e._decrementTask(i)}}))}else i=e._getCurrentSpan(l);try{return t.call(l,n,r,o)}finally{i&&e._shouldCountTask(n,l)&&e._decrementTask(i)}}}},t.prototype._shouldCountTask=function(e,t){if(e._zone&&(t=e._zone),!t||!e.data||e.data.isPeriodic)return!1;var n=this._getCurrentSpan(t);return!!n&&(!!this._spansData.get(n)&&("macroTask"===e.type||"microTask"===e.type))},t.prototype._tryToEndSpan=function(e,t){e&&(this._spansData.get(e)&&(e.end(t),this._spansData.delete(e)))},t.prototype.enable=function(){var e=this,t=this._getZoneWithPrototype();(this._diag.debug("applying patch to",this.moduleName,this.version,"zone:",!!t),t)?(aF(t.prototype.runTask)&&(this._unwrap(t.prototype,"runTask"),this._diag.debug("removing previous patch from method runTask")),aF(t.prototype.scheduleTask)&&(this._unwrap(t.prototype,"scheduleTask"),this._diag.debug("removing previous patch from method scheduleTask")),aF(t.prototype.cancelTask)&&(this._unwrap(t.prototype,"cancelTask"),this._diag.debug("removing previous patch from method cancelTask")),this._zonePatched=!0,this._wrap(t.prototype,"runTask",this._patchZoneRunTask()),this._wrap(t.prototype,"scheduleTask",this._patchZoneScheduleTask()),this._wrap(t.prototype,"cancelTask",this._patchZoneCancelTask())):(this._zonePatched=!1,this._getPatchableEventTargets().forEach((function(t){aF(t.addEventListener)&&(e._unwrap(t,"addEventListener"),e._diag.debug("removing previous patch from method addEventListener")),aF(t.removeEventListener)&&(e._unwrap(t,"removeEventListener"),e._diag.debug("removing previous patch from method removeEventListener")),e._wrap(t,"addEventListener",e._patchAddEventListener()),e._wrap(t,"removeEventListener",e._patchRemoveEventListener())})));this._patchHistoryApi()},t.prototype.disable=function(){var e=this,t=this._getZoneWithPrototype();(this._diag.debug("removing patch from",this.moduleName,this.version,"zone:",!!t),t&&this._zonePatched)?(aF(t.prototype.runTask)&&this._unwrap(t.prototype,"runTask"),aF(t.prototype.scheduleTask)&&this._unwrap(t.prototype,"scheduleTask"),aF(t.prototype.cancelTask)&&this._unwrap(t.prototype,"cancelTask")):this._getPatchableEventTargets().forEach((function(t){aF(t.addEventListener)&&e._unwrap(t,"addEventListener"),aF(t.removeEventListener)&&e._unwrap(t,"removeEventListener")}));this._unpatchHistoryApi()},t.prototype._getZoneWithPrototype=function(){return window.Zone},t}(oF),ZF=function(){function e(){}return e.prototype.emit=function(e){},e}(),JF=new ZF,eU=new(function(){function e(){}return e.prototype.getLogger=function(e,t,n){return new ZF},e}()),tU=function(){function e(e,t,n,r){this._provider=e,this.name=t,this.version=n,this.options=r}return e.prototype.emit=function(e){this._getLogger().emit(e)},e.prototype._getLogger=function(){if(this._delegate)return this._delegate;var e=this._provider.getDelegateLogger(this.name,this.version,this.options);return e?(this._delegate=e,this._delegate):JF},e}(),nU=function(){function e(){}return e.prototype.getLogger=function(e,t,n){var r;return null!==(r=this.getDelegateLogger(e,t,n))&&void 0!==r?r:new tU(this,e,t,n)},e.prototype.getDelegate=function(){var e;return null!==(e=this._delegate)&&void 0!==e?e:eU},e.prototype.setDelegate=function(e){this._delegate=e},e.prototype.getDelegateLogger=function(e,t,n){var r;return null===(r=this._delegate)||void 0===r?void 0:r.getLogger(e,t,n)},e}(),rU="object"==typeof globalThis?globalThis:"object"==typeof self?self:"object"==typeof window?window:"object"==typeof global?global:{},oU=Symbol.for("io.opentelemetry.js.api.logs"),iU=rU;var aU,sU,lU,cU=function(){function e(){this._proxyLoggerProvider=new nU}return e.getInstance=function(){return this._instance||(this._instance=new e),this._instance},e.prototype.setGlobalLoggerProvider=function(e){return iU[oU]?this.getLoggerProvider():(iU[oU]=(t=1,n=e,r=eU,function(e){return e===t?n:r}),this._proxyLoggerProvider.setDelegate(e),e);var t,n,r},e.prototype.getLoggerProvider=function(){var e,t;return null!==(t=null===(e=iU[oU])||void 0===e?void 0:e.call(iU,1))&&void 0!==t?t:this._proxyLoggerProvider},e.prototype.getLogger=function(e,t,n){return this.getLoggerProvider().getLogger(e,t,n)},e.prototype.disable=function(){delete iU[oU],this._proxyLoggerProvider=new nU},e}().getInstance(),uU=function(){return uU=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},uU.apply(this,arguments)},dU=function(){function e(e,t,n){this.instrumentationName=e,this.instrumentationVersion=t,this._config={},this._wrap=Dm.wrap,this._unwrap=Dm.unwrap,this._massWrap=Dm.massWrap,this._massUnwrap=Dm.massUnwrap,this.setConfig(n),this._diag=im.createComponentLogger({namespace:e}),this._tracer=bm.getTracer(e,t),this._meter=lm.getMeter(e,t),this._logger=cU.getLogger(e,t),this._updateMetricInstruments()}return Object.defineProperty(e.prototype,"meter",{get:function(){return this._meter},enumerable:!1,configurable:!0}),e.prototype.setMeterProvider=function(e){this._meter=e.getMeter(this.instrumentationName,this.instrumentationVersion),this._updateMetricInstruments()},Object.defineProperty(e.prototype,"logger",{get:function(){return this._logger},enumerable:!1,configurable:!0}),e.prototype.setLoggerProvider=function(e){this._logger=e.getLogger(this.instrumentationName,this.instrumentationVersion)},e.prototype.getModuleDefinitions=function(){var e,t=null!==(e=this.init())&&void 0!==e?e:[];return Array.isArray(t)?t:[t]},e.prototype._updateMetricInstruments=function(){},e.prototype.getConfig=function(){return this._config},e.prototype.setConfig=function(e){this._config=uU({enabled:!0},e)},e.prototype.setTracerProvider=function(e){this._tracer=e.getTracer(this.instrumentationName,this.instrumentationVersion)},Object.defineProperty(e.prototype,"tracer",{get:function(){return this._tracer},enumerable:!1,configurable:!0}),e.prototype._runSpanCustomizationHook=function(e,t,n,r){if(e)try{e(n,r)}catch(tme){this._diag.error("Error running span customization hook due to exception in handler",{triggerName:t},tme)}},e}(),pU=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),fU=function(e){function t(t,n,r){var o=e.call(this,t,n,r)||this;return o._config.enabled&&o.enable(),o}return pU(t,e),t}(dU);function hU(e){return"function"==typeof e&&"function"==typeof e.__original&&"function"==typeof e.__unwrap&&!0===e.__wrapped}function mU(e,t){return t in e}function gU(e,t,n,r){var o=void 0,i=void 0;mU(n,t)&&"number"==typeof n[t]&&(o=n[t]);var a=aU.FETCH_START;if(mU(n,a)&&"number"==typeof n[a]&&(i=n[a]),void 0!==o&&void 0!==i&&o>=i)return e.addEvent(t,o),e}function yU(e,t,n){void 0===n&&(n=!1),n||(gU(e,aU.FETCH_START,t),gU(e,aU.DOMAIN_LOOKUP_START,t),gU(e,aU.DOMAIN_LOOKUP_END,t),gU(e,aU.CONNECT_START,t),mU(t,"name")&&t.name.startsWith("https:")&&gU(e,aU.SECURE_CONNECTION_START,t),gU(e,aU.CONNECT_END,t),gU(e,aU.REQUEST_START,t),gU(e,aU.RESPONSE_START,t),gU(e,aU.RESPONSE_END,t));var r=t[aU.ENCODED_BODY_SIZE];void 0!==r&&e.setAttribute(SI,r);var o=t[aU.DECODED_BODY_SIZE];void 0!==o&&r!==o&&e.setAttribute(TI,o)}function vU(){return"undefined"!=typeof location?location.origin:void 0}function bU(e,t,n,r,o,i){void 0===o&&(o=new WeakSet);var a=wU(e),s=function(e,t,n,r,o){var i=kI(t),a=kI(n),s=r.filter((function(t){var n=kI(PI(t[aU.FETCH_START])),r=kI(PI(t[aU.RESPONSE_END]));return"xmlhttprequest"===t.initiatorType.toLowerCase()&&t.name===e&&n>=i&&r<=a}));s.length>0&&(s=s.filter((function(e){return!o.has(e)})));return s}(e=a.toString(),t,n,r,o);if(0===s.length)return{mainRequest:void 0};if(1===s.length)return{mainRequest:s[0]};var l=function(e){return e.slice().sort((function(e,t){var n=e[aU.FETCH_START],r=t[aU.FETCH_START];return n>r?1:n<r?-1:0}))}(s);if(a.origin!==vU()&&l.length>1){var c=l[0],u=function(e,t,n){for(var r,o=kI(n),i=kI(PI(t)),a=e[1],s=e.length,l=1;l<s;l++){var c=e[l],u=kI(PI(c[aU.FETCH_START])),d=o-kI(PI(c[aU.RESPONSE_END]));u>=i&&(!r||d<r)&&(r=d,a=c)}return a}(l,c[aU.RESPONSE_END],n);return u[aU.FETCH_START]<c[aU.RESPONSE_END]&&(u=c,c=void 0),{corsPreFlightRequest:c,mainRequest:u}}return{mainRequest:s[0]}}function wU(e){if("function"==typeof URL)return new URL(e,"undefined"!=typeof document?document.baseURI:"undefined"!=typeof location?location.href:void 0);var t=(sU||(sU=document.createElement("a")),sU);return t.href=e,t}!function(e){e.CONNECT_END="connectEnd",e.CONNECT_START="connectStart",e.DECODED_BODY_SIZE="decodedBodySize",e.DOM_COMPLETE="domComplete",e.DOM_CONTENT_LOADED_EVENT_END="domContentLoadedEventEnd",e.DOM_CONTENT_LOADED_EVENT_START="domContentLoadedEventStart",e.DOM_INTERACTIVE="domInteractive",e.DOMAIN_LOOKUP_END="domainLookupEnd",e.DOMAIN_LOOKUP_START="domainLookupStart",e.ENCODED_BODY_SIZE="encodedBodySize",e.FETCH_START="fetchStart",e.LOAD_EVENT_END="loadEventEnd",e.LOAD_EVENT_START="loadEventStart",e.NAVIGATION_START="navigationStart",e.REDIRECT_END="redirectEnd",e.REDIRECT_START="redirectStart",e.REQUEST_START="requestStart",e.RESPONSE_END="responseEnd",e.RESPONSE_START="responseStart",e.SECURE_CONNECTION_START="secureConnectionStart",e.UNLOAD_EVENT_END="unloadEventEnd",e.UNLOAD_EVENT_START="unloadEventStart"}(aU||(aU={})),function(e){e.METHOD_OPEN="open",e.METHOD_SEND="send",e.EVENT_ABORT="abort",e.EVENT_ERROR="error",e.EVENT_LOAD="loaded",e.EVENT_TIMEOUT="timeout"}(lU||(lU={}));var xU=function(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(s){o={error:s}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a},EU=im.createComponentLogger({namespace:"@opentelemetry/opentelemetry-instrumentation-xml-http-request/utils"});function _U(e){return"undefined"!=typeof Document&&e instanceof Document?(new XMLSerializer).serializeToString(document).length:e instanceof Blob?e.size:void 0!==e.byteLength?e.byteLength:e instanceof FormData?function(e){var t,n,r=0;try{for(var o=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(e.entries()),i=o.next();!i.done;i=o.next()){var a=xU(i.value,2),s=a[1];r+=a[0].length,s instanceof Blob?r+=s.size:r+=s.length}}catch(l){t={error:l}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}return r}(e):e instanceof URLSearchParams?TU(e.toString()):"string"==typeof e?TU(e):void EU.warn("unknown body type")}var SU=new TextEncoder;function TU(e){return SU.encode(e).byteLength}var CU,AU="0.57.2";!function(e){e.HTTP_STATUS_TEXT="http.status_text"}(CU||(CU={}));var OU=function(){var e=function(t,n){return(e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function r(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(r.prototype=n.prototype,new r)}}(),NU=function(e){function t(t){void 0===t&&(t={});var n=e.call(this,"@opentelemetry/instrumentation-xml-http-request",AU,t)||this;return n.component="xml-http-request",n.version=AU,n.moduleName=n.component,n._tasksCount=0,n._xhrMem=new WeakMap,n._usedResources=new WeakSet,n}return OU(t,e),t.prototype.init=function(){},t.prototype._addHeaders=function(e,t){if(!function(e,t){var n=t||[];return("string"==typeof n||n instanceof RegExp)&&(n=[n]),wU(e).origin===vU()||n.some((function(t){return VI(e,t)}))}(wU(t).href,this.getConfig().propagateTraceHeaderCorsUrls)){var n={};return ym.inject(om.active(),n),void(Object.keys(n).length>0&&this._diag.debug("headers inject skipped due to CORS policy"))}var r={};ym.inject(om.active(),r),Object.keys(r).forEach((function(t){e.setRequestHeader(t,String(r[t]))}))},t.prototype._addChildSpan=function(e,t){var n=this;om.with(bm.setSpan(om.active(),e),(function(){var e=n.tracer.startSpan("CORS Preflight",{startTime:t[aU.FETCH_START]});yU(e,t,n.getConfig().ignoreNetworkEvents),e.end(t[aU.RESPONSE_END])}))},t.prototype._addFinalSpanAttributes=function(e,t,n){if("string"==typeof n){var r=wU(n);void 0!==t.status&&e.setAttribute(xI,t.status),void 0!==t.statusText&&e.setAttribute(CU.HTTP_STATUS_TEXT,t.statusText),e.setAttribute(bI,r.host),e.setAttribute(wI,r.protocol.replace(":","")),e.setAttribute(EI,navigator.userAgent)}},t.prototype._applyAttributesAfterXHR=function(e,t){var n=this,r=this.getConfig().applyCustomAttributesOnSpan;"function"==typeof r&&function(e,t){var n,r;try{r=e()}catch(tme){n=tme}finally{return t(n,r),r}}((function(){return r(e,t)}),(function(e){e&&n._diag.error("applyCustomAttributesOnSpan",e)}))},t.prototype._addResourceObserver=function(e,t){var n=this._xhrMem.get(e);n&&"function"==typeof PerformanceObserver&&"function"==typeof PerformanceResourceTiming&&(n.createdResources={observer:new PerformanceObserver((function(e){var r=e.getEntries(),o=wU(t);r.forEach((function(e){"xmlhttprequest"===e.initiatorType&&e.name===o.href&&n.createdResources&&n.createdResources.entries.push(e)}))})),entries:[]},n.createdResources.observer.observe({entryTypes:["resource"]}))},t.prototype._clearResources=function(){0===this._tasksCount&&this.getConfig().clearTimingResources&&(gI.clearResourceTimings(),this._xhrMem=new WeakMap,this._usedResources=new WeakSet)},t.prototype._findResourceAndAddNetworkEvents=function(e,t,n,r,o){if(n&&r&&o&&e.createdResources){var i=e.createdResources.entries;i&&i.length||(i=gI.getEntriesByType("resource"));var a=bU(wU(n).href,r,o,i,this._usedResources);if(a.mainRequest){var s=a.mainRequest;this._markResourceAsUsed(s);var l=a.corsPreFlightRequest;l&&(this._addChildSpan(t,l),this._markResourceAsUsed(l)),yU(t,s,this.getConfig().ignoreNetworkEvents)}}},t.prototype._cleanPreviousSpanInformation=function(e){var t=this._xhrMem.get(e);if(t){var n=t.callbackToRemoveEvents;n&&n(),this._xhrMem.delete(e)}},t.prototype._createSpan=function(e,t,n){var r;if(!qI(t,this.getConfig().ignoreUrls)){var o=n.toUpperCase(),i=this.tracer.startSpan(o,{kind:Hh.CLIENT,attributes:(r={},r[yI]=n,r[vI]=wU(t).toString(),r)});return i.addEvent(lU.METHOD_OPEN),this._cleanPreviousSpanInformation(e),this._xhrMem.set(e,{span:i,spanUrl:t}),i}this._diag.debug("ignoring span as url matches ignored url")},t.prototype._markResourceAsUsed=function(e){this._usedResources.add(e)},t.prototype._patchOpen=function(){var e=this;return function(t){var n=e;return function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return n._createSpan(this,e[1],e[0]),t.apply(this,e)}}},t.prototype._patchSend=function(){var e=this;function t(t,n){var r=e._xhrMem.get(n);if(r){r.status=n.status,r.statusText=n.statusText,e._xhrMem.delete(n),r.span&&e._applyAttributesAfterXHR(r.span,n);var o=RI(),i=Date.now();setTimeout((function(){!function(t,n,r,o){var i=n.callbackToRemoveEvents;"function"==typeof i&&i();var a=n.span,s=n.spanUrl;a&&(e._findResourceAndAddNetworkEvents(n,a,s,n.sendStartTime,r),a.addEvent(t,o),e._addFinalSpanAttributes(a,n,s),a.end(o),e._tasksCount--),e._clearResources()}(t,r,o,i)}),300)}}function n(){t(lU.EVENT_ERROR,this)}function r(){t(lU.EVENT_ABORT,this)}function o(){t(lU.EVENT_TIMEOUT,this)}function i(){t(this.status<299?lU.EVENT_LOAD:lU.EVENT_ERROR,this)}return function(t){return function(){for(var a=this,s=[],l=0;l<arguments.length;l++)s[l]=arguments[l];var c=e._xhrMem.get(this);if(!c)return t.apply(this,s);var u=c.span,d=c.spanUrl;if(u&&d){if(e.getConfig().measureRequestSize&&(null==s?void 0:s[0])){var p=_U(s[0]);void 0!==p&&u.setAttribute(_I,p)}om.with(bm.setSpan(om.active(),u),(function(){e._tasksCount++,c.sendStartTime=RI(),u.addEvent(lU.METHOD_SEND),a.addEventListener("abort",r),a.addEventListener("error",n),a.addEventListener("load",i),a.addEventListener("timeout",o),c.callbackToRemoveEvents=function(){!function(t){t.removeEventListener("abort",r),t.removeEventListener("error",n),t.removeEventListener("load",i),t.removeEventListener("timeout",o);var a=e._xhrMem.get(t);a&&(a.callbackToRemoveEvents=void 0)}(a),c.createdResources&&c.createdResources.observer.disconnect()},e._addHeaders(a,d),e._addResourceObserver(a,d)}))}return t.apply(this,s)}}},t.prototype.enable=function(){this._diag.debug("applying patch to",this.moduleName,this.version),hU(XMLHttpRequest.prototype.open)&&(this._unwrap(XMLHttpRequest.prototype,"open"),this._diag.debug("removing previous patch from method open")),hU(XMLHttpRequest.prototype.send)&&(this._unwrap(XMLHttpRequest.prototype,"send"),this._diag.debug("removing previous patch from method send")),this._wrap(XMLHttpRequest.prototype,"open",this._patchOpen()),this._wrap(XMLHttpRequest.prototype,"send",this._patchSend())},t.prototype.disable=function(){this._diag.debug("removing patch from",this.moduleName,this.version),this._unwrap(XMLHttpRequest.prototype,"open"),this._unwrap(XMLHttpRequest.prototype,"send"),this._tasksCount=0,this._xhrMem=new WeakMap,this._usedResources=new WeakSet},t}(fU),RU={"@opentelemetry/instrumentation-document-load":dF,"@opentelemetry/instrumentation-fetch":GF,"@opentelemetry/instrumentation-user-interaction":QF,"@opentelemetry/instrumentation-xml-http-request":NU};function PU(e){var t;void 0===e&&(e={});for(var n=0,r=Object.keys(e);n<r.length;n++){var o=r[n];Object.prototype.hasOwnProperty.call(RU,o)||im.error('Provided instrumentation name "'+o+'" not found')}for(var i=[],a=0,s=Object.keys(RU);a<s.length;a++){var l=s[a],c=RU[l],u=null!==(t=e[l])&&void 0!==t?t:{};if(!1!==u.enabled)try{im.debug("Loading instrumentation for "+l),i.push(new c(u))}catch(tme){im.error(tme)}else im.debug("Disabling instrumentation for "+l)}return i}let kU=!1;const LU=[/.*launchdarkly\.com.*/i,/.*\/api\/telemetry.*/i,new RegExp(`^(?!${Ee.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}/).*`)],MU={ignoreNetworkEvents:!0,propagateTraceHeaderCorsUrls:[new RegExp(Ee)],ignoreUrls:LU},DU=({tenantExternalId:e,partnerId:t,debug:r})=>{const o=(()=>{const{ldClient:e}=n.useContext(nl.reactContext);return e})(),i=o?.variation("show-fe-honeycomb-logs",!1);if(kU||!i)return null;try{ym.setGlobalPropagator(new BI);const n=new Tf.HoneycombWebSDK({tracesEndpoint:`${Ee}/telemetry`,serviceName:"sdk-client",debug:r,skipOptionsValidation:!0,instrumentations:[PU({"@opentelemetry/instrumentation-xml-http-request":{...MU,ignoreUrls:LU},"@opentelemetry/instrumentation-fetch":{...MU,ignoreUrls:LU},"@opentelemetry/instrumentation-document-load":{enabled:!1},"@opentelemetry/instrumentation-user-interaction":{enabled:!1}})],resourceAttributes:{"tenant.externalId":e,"partner.id":t}});n.start(),kU=!0,window.addEventListener("beforeunload",(()=>{n.shutdown().catch((e=>{}))}))}catch(tme){return null}return null};function jU(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function IU(...e){return t=>{let n=!1;const r=e.map((e=>{const r=jU(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():jU(e[t],null)}}}}function FU(...e){return i.useCallback(IU(...e),e)}var UU=i.forwardRef(((e,n)=>{const{children:r,...o}=e,a=i.Children.toArray(r),s=a.find(VU);if(s){const e=s.props.children,r=a.map((t=>t===s?i.Children.count(e)>1?i.Children.only(null):i.isValidElement(e)?e.props.children:null:t));return t.jsx($U,{...o,ref:n,children:i.isValidElement(e)?i.cloneElement(e,void 0,r):null})}return t.jsx($U,{...o,ref:n,children:r})}));UU.displayName="Slot";var $U=i.forwardRef(((e,t)=>{const{children:n,...r}=e;if(i.isValidElement(n)){const e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(n),o=function(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==i.Fragment&&(o.ref=t?IU(t,e):e),i.cloneElement(n,o)}return i.Children.count(n)>1?i.Children.only(null):null}));$U.displayName="SlotClone";var BU=({children:e})=>t.jsx(t.Fragment,{children:e});function VU(e){return i.isValidElement(e)&&e.type===BU}var qU=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,n)=>{const r=i.forwardRef(((e,r)=>{const{asChild:o,...i}=e,a=o?UU:n;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),t.jsx(a,{...i,ref:r})}));return r.displayName=`Primitive.${n}`,{...e,[n]:r}}),{}),zU=i.forwardRef(((e,n)=>t.jsx(qU.span,{...e,ref:n,style:{position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal",...e.style}})));function HU(e,t,{checkForDefaultPrevented:n=!0}={}){return function(r){if(e?.(r),!1===n||!r.defaultPrevented)return t?.(r)}}function GU(e,t){if("function"==typeof e)return e(t);null!=e&&(e.current=t)}function KU(...e){return t=>{let n=!1;const r=e.map((e=>{const r=GU(e,t);return n||"function"!=typeof r||(n=!0),r}));if(n)return()=>{for(let t=0;t<r.length;t++){const n=r[t];"function"==typeof n?n():GU(e[t],null)}}}}function WU(...e){return i.useCallback(KU(...e),e)}function YU(...e){const t=e[0];if(1===e.length)return t;const n=()=>{const n=e.map((e=>({useScope:e(),scopeName:e.scopeName})));return function(e){const r=n.reduce(((t,{useScope:n,scopeName:r})=>({...t,...n(e)[`__scope${r}`]})),{});return i.useMemo((()=>({[`__scope${t.scopeName}`]:r})),[r])}};return n.scopeName=t.scopeName,n}zU.displayName="VisuallyHidden";var XU=globalThis?.document?i.useLayoutEffect:()=>{},QU=i[" useId ".trim().toString()]||(()=>{}),ZU=0;function JU(e){const[t,n]=i.useState(QU());return XU((()=>{n((e=>e??String(ZU++)))}),[e]),e||(t?`radix-${t}`:"")}function e$(e){const t=i.useRef(e);return i.useEffect((()=>{t.current=e})),i.useMemo((()=>(...e)=>t.current?.(...e)),[])}function t$({prop:e,defaultProp:t,onChange:n=()=>{}}){const[r,o]=function({defaultProp:e,onChange:t}){const n=i.useState(e),[r]=n,o=i.useRef(r),a=e$(t);return i.useEffect((()=>{o.current!==r&&(a(r),o.current=r)}),[r,o,a]),n}({defaultProp:t,onChange:n}),a=void 0!==e,s=a?e:r,l=e$(n);return[s,i.useCallback((t=>{if(a){const n="function"==typeof t?t(e):t;n!==e&&l(n)}else o(t)}),[a,e,o,l])]}function n$(e){const n=r$(e),r=i.forwardRef(((e,r)=>{const{children:o,...a}=e,s=i.Children.toArray(o),l=s.find(i$);if(l){const e=l.props.children,o=s.map((t=>t===l?i.Children.count(e)>1?i.Children.only(null):i.isValidElement(e)?e.props.children:null:t));return t.jsx(n,{...a,ref:r,children:i.isValidElement(e)?i.cloneElement(e,void 0,o):null})}return t.jsx(n,{...a,ref:r,children:o})}));return r.displayName=`${e}.Slot`,r}function r$(e){const t=i.forwardRef(((e,t)=>{const{children:n,...r}=e;if(i.isValidElement(n)){const e=function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(n),o=function(e,t){const n={...t};for(const r in t){const o=e[r],i=t[r];/^on[A-Z]/.test(r)?o&&i?n[r]=(...e)=>{i(...e),o(...e)}:o&&(n[r]=o):"style"===r?n[r]={...o,...i}:"className"===r&&(n[r]=[o,i].filter(Boolean).join(" "))}return{...e,...n}}(r,n.props);return n.type!==i.Fragment&&(o.ref=t?KU(t,e):e),i.cloneElement(n,o)}return i.Children.count(n)>1?i.Children.only(null):null}));return t.displayName=`${e}.SlotClone`,t}var o$=Symbol("radix.slottable");function i$(e){return i.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===o$}var a$=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"].reduce(((e,n)=>{const r=n$(`Primitive.${n}`),o=i.forwardRef(((e,o)=>{const{asChild:i,...a}=e,s=i?r:n;return"undefined"!=typeof window&&(window[Symbol.for("radix-ui")]=!0),t.jsx(s,{...a,ref:o})}));return o.displayName=`Primitive.${n}`,{...e,[n]:o}}),{});var s$,l$="dismissableLayer.update",c$="dismissableLayer.pointerDownOutside",u$="dismissableLayer.focusOutside",d$=i.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),p$=i.forwardRef(((e,n)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:l,onDismiss:c,...u}=e,d=i.useContext(d$),[p,f]=i.useState(null),h=p?.ownerDocument??globalThis?.document,[,m]=i.useState({}),g=WU(n,(e=>f(e))),y=Array.from(d.layers),[v]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),b=y.indexOf(v),w=p?y.indexOf(p):-1,x=d.layersWithOutsidePointerEventsDisabled.size>0,E=w>=b,_=function(e,t=globalThis?.document){const n=e$(e),r=i.useRef(!1),o=i.useRef((()=>{}));return i.useEffect((()=>{const e=e=>{if(e.target&&!r.current){let r=function(){h$(c$,n,i,{discrete:!0})};const i={originalEvent:e};"touch"===e.pointerType?(t.removeEventListener("click",o.current),o.current=r,t.addEventListener("click",o.current,{once:!0})):r()}else t.removeEventListener("click",o.current);r.current=!1},i=window.setTimeout((()=>{t.addEventListener("pointerdown",e)}),0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",e),t.removeEventListener("click",o.current)}}),[t,n]),{onPointerDownCapture:()=>r.current=!0}}((e=>{const t=e.target,n=[...d.branches].some((e=>e.contains(t)));E&&!n&&(a?.(e),l?.(e),e.defaultPrevented||c?.())}),h),S=function(e,t=globalThis?.document){const n=e$(e),r=i.useRef(!1);return i.useEffect((()=>{const e=e=>{if(e.target&&!r.current){h$(u$,n,{originalEvent:e},{discrete:!1})}};return t.addEventListener("focusin",e),()=>t.removeEventListener("focusin",e)}),[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}((e=>{const t=e.target;[...d.branches].some((e=>e.contains(t)))||(s?.(e),l?.(e),e.defaultPrevented||c?.())}),h);return function(e,t=globalThis?.document){const n=e$(e);i.useEffect((()=>{const e=e=>{"Escape"===e.key&&n(e)};return t.addEventListener("keydown",e,{capture:!0}),()=>t.removeEventListener("keydown",e,{capture:!0})}),[n,t])}((e=>{w===d.layers.size-1&&(o?.(e),!e.defaultPrevented&&c&&(e.preventDefault(),c()))}),h),i.useEffect((()=>{if(p)return r&&(0===d.layersWithOutsidePointerEventsDisabled.size&&(s$=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(p)),d.layers.add(p),f$(),()=>{r&&1===d.layersWithOutsidePointerEventsDisabled.size&&(h.body.style.pointerEvents=s$)}}),[p,h,r,d]),i.useEffect((()=>()=>{p&&(d.layers.delete(p),d.layersWithOutsidePointerEventsDisabled.delete(p),f$())}),[p,d]),i.useEffect((()=>{const e=()=>m({});return document.addEventListener(l$,e),()=>document.removeEventListener(l$,e)}),[]),t.jsx(a$.div,{...u,ref:g,style:{pointerEvents:x?E?"auto":"none":void 0,...e.style},onFocusCapture:HU(e.onFocusCapture,S.onFocusCapture),onBlurCapture:HU(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:HU(e.onPointerDownCapture,_.onPointerDownCapture)})}));p$.displayName="DismissableLayer";function f$(){const e=new CustomEvent(l$);document.dispatchEvent(e)}function h$(e,t,n,{discrete:r}){const o=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&o.addEventListener(e,t,{once:!0}),r?function(e,t){e&&a.flushSync((()=>e.dispatchEvent(t)))}(o,i):o.dispatchEvent(i)}i.forwardRef(((e,n)=>{const r=i.useContext(d$),o=i.useRef(null),a=WU(n,o);return i.useEffect((()=>{const e=o.current;if(e)return r.branches.add(e),()=>{r.branches.delete(e)}}),[r.branches]),t.jsx(a$.div,{...e,ref:a})})).displayName="DismissableLayerBranch";var m$="focusScope.autoFocusOnMount",g$="focusScope.autoFocusOnUnmount",y$={bubbles:!1,cancelable:!0},v$=i.forwardRef(((e,n)=>{const{loop:r=!1,trapped:o=!1,onMountAutoFocus:a,onUnmountAutoFocus:s,...l}=e,[c,u]=i.useState(null),d=e$(a),p=e$(s),f=i.useRef(null),h=WU(n,(e=>u(e))),m=i.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;i.useEffect((()=>{if(o){let e=function(e){if(m.paused||!c)return;const t=e.target;c.contains(t)?f.current=t:E$(f.current,{select:!0})},t=function(e){if(m.paused||!c)return;const t=e.relatedTarget;null!==t&&(c.contains(t)||E$(f.current,{select:!0}))},n=function(e){if(document.activeElement===document.body)for(const t of e)t.removedNodes.length>0&&E$(c)};document.addEventListener("focusin",e),document.addEventListener("focusout",t);const r=new MutationObserver(n);return c&&r.observe(c,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",e),document.removeEventListener("focusout",t),r.disconnect()}}}),[o,c,m.paused]),i.useEffect((()=>{if(c){_$.add(m);const t=document.activeElement;if(!c.contains(t)){const n=new CustomEvent(m$,y$);c.addEventListener(m$,d),c.dispatchEvent(n),n.defaultPrevented||(!function(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(E$(r,{select:t}),document.activeElement!==n)return}((e=b$(c),e.filter((e=>"A"!==e.tagName))),{select:!0}),document.activeElement===t&&E$(c))}return()=>{c.removeEventListener(m$,d),setTimeout((()=>{const e=new CustomEvent(g$,y$);c.addEventListener(g$,p),c.dispatchEvent(e),e.defaultPrevented||E$(t??document.body,{select:!0}),c.removeEventListener(g$,p),_$.remove(m)}),0)}}var e}),[c,d,p,m]);const g=i.useCallback((e=>{if(!r&&!o)return;if(m.paused)return;const t=document.activeElement;if("Tab"===e.key&&!e.altKey&&!e.ctrlKey&&!e.metaKey&&t){const n=e.currentTarget,[o,i]=function(e){const t=b$(e),n=w$(t,e),r=w$(t.reverse(),e);return[n,r]}(n);o&&i?e.shiftKey||t!==i?e.shiftKey&&t===o&&(e.preventDefault(),r&&E$(i,{select:!0})):(e.preventDefault(),r&&E$(o,{select:!0})):t===n&&e.preventDefault()}}),[r,o,m.paused]);return t.jsx(a$.div,{tabIndex:-1,...l,ref:h,onKeyDown:g})}));function b$(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:e=>e.disabled||e.hidden||"INPUT"===e.tagName&&"hidden"===e.type?NodeFilter.FILTER_SKIP:e.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});for(;n.nextNode();)t.push(n.currentNode);return t}function w$(e,t){for(const n of e)if(!x$(n,{upTo:t}))return n}function x$(e,{upTo:t}){if("hidden"===getComputedStyle(e).visibility)return!0;for(;e;){if(void 0!==t&&e===t)return!1;if("none"===getComputedStyle(e).display)return!0;e=e.parentElement}return!1}function E$(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&function(e){return e instanceof HTMLInputElement&&"select"in e}(e)&&t&&e.select()}}v$.displayName="FocusScope";var _$=function(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=S$(e,t),e.unshift(t)},remove(t){e=S$(e,t),e[0]?.resume()}}}();function S$(e,t){const n=[...e],r=n.indexOf(t);return-1!==r&&n.splice(r,1),n}var T$=i.forwardRef(((e,n)=>{const{container:o,...a}=e,[s,l]=i.useState(!1);XU((()=>l(!0)),[]);const c=o||s&&globalThis?.document?.body;return c?r.createPortal(t.jsx(a$.div,{...a,ref:n}),c):null}));T$.displayName="Portal";var C$=e=>{const{present:t,children:n}=e,r=function(e){const[t,n]=i.useState(),r=i.useRef({}),o=i.useRef(e),a=i.useRef("none"),s=e?"mounted":"unmounted",[l,c]=function(e,t){return i.useReducer(((e,n)=>t[e][n]??e),e)}(s,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return i.useEffect((()=>{const e=A$(r.current);a.current="mounted"===l?e:"none"}),[l]),XU((()=>{const t=r.current,n=o.current;if(n!==e){const r=a.current,i=A$(t);if(e)c("MOUNT");else if("none"===i||"none"===t?.display)c("UNMOUNT");else{c(n&&r!==i?"ANIMATION_OUT":"UNMOUNT")}o.current=e}}),[e,c]),XU((()=>{if(t){let e;const n=t.ownerDocument.defaultView??window,i=i=>{const a=A$(r.current).includes(i.animationName);if(i.target===t&&a&&(c("ANIMATION_END"),!o.current)){const r=t.style.animationFillMode;t.style.animationFillMode="forwards",e=n.setTimeout((()=>{"forwards"===t.style.animationFillMode&&(t.style.animationFillMode=r)}))}},s=e=>{e.target===t&&(a.current=A$(r.current))};return t.addEventListener("animationstart",s),t.addEventListener("animationcancel",i),t.addEventListener("animationend",i),()=>{n.clearTimeout(e),t.removeEventListener("animationstart",s),t.removeEventListener("animationcancel",i),t.removeEventListener("animationend",i)}}c("ANIMATION_END")}),[t,c]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:i.useCallback((e=>{e&&(r.current=getComputedStyle(e)),n(e)}),[])}}(t),o="function"==typeof n?n({present:r.isPresent}):i.Children.only(n),a=WU(r.ref,function(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;if(n)return e.ref;if(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n)return e.props.ref;return e.props.ref||e.ref}(o));return"function"==typeof n||r.isPresent?i.cloneElement(o,{ref:a}):null};function A$(e){return e?.animationName||"none"}C$.displayName="Presence";var O$=0;function N$(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var R$=function(){return R$=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},R$.apply(this,arguments)};function P$(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}"function"==typeof SuppressedError&&SuppressedError;var k$="right-scroll-bar-position",L$="width-before-scroll-bar";function M$(e,t){return"function"==typeof e?e(t):e&&(e.current=t),e}var D$="undefined"!=typeof window?i.useLayoutEffect:i.useEffect,j$=new WeakMap;function I$(e,t){var r=function(e,t){var r=n.useState((function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(e){var t=r.value;t!==e&&(r.value=e,r.callback(e,t))}}}}))[0];return r.callback=t,r.facade}(null,(function(t){return e.forEach((function(e){return M$(e,t)}))}));return D$((function(){var t=j$.get(r);if(t){var n=new Set(t),o=new Set(e),i=r.current;n.forEach((function(e){o.has(e)||M$(e,null)})),o.forEach((function(e){n.has(e)||M$(e,i)}))}j$.set(r,e)}),[e]),r}function F$(e){return e}var U$=function(e){var t=e.sideCar,n=P$(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return i.createElement(r,R$({},n))};U$.isSideCarExport=!0;var $$=function(e){void 0===e&&(e={});var t=function(e,t){void 0===t&&(t=F$);var n=[],r=!1;return{read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(e){var o=t(e,r);return n.push(o),function(){n=n.filter((function(e){return e!==o}))}},assignSyncMedium:function(e){for(r=!0;n.length;){var t=n;n=[],t.forEach(e)}n={push:function(t){return e(t)},filter:function(){return n}}},assignMedium:function(e){r=!0;var t=[];if(n.length){var o=n;n=[],o.forEach(e),t=n}var i=function(){var n=t;t=[],n.forEach(e)},a=function(){return Promise.resolve().then(i)};a(),n={push:function(e){t.push(e),a()},filter:function(e){return t=t.filter(e),n}}}}}(null);return t.options=R$({async:!0,ssr:!1},e),t}(),B$=function(){},V$=i.forwardRef((function(e,t){var n=i.useRef(null),r=i.useState({onScrollCapture:B$,onWheelCapture:B$,onTouchMoveCapture:B$}),o=r[0],a=r[1],s=e.forwardProps,l=e.children,c=e.className,u=e.removeScrollBar,d=e.enabled,p=e.shards,f=e.sideCar,h=e.noIsolation,m=e.inert,g=e.allowPinchZoom,y=e.as,v=void 0===y?"div":y,b=e.gapMode,w=P$(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=f,E=I$([n,t]),_=R$(R$({},w),o);return i.createElement(i.Fragment,null,d&&i.createElement(x,{sideCar:$$,removeScrollBar:u,shards:p,noIsolation:h,inert:m,setCallbacks:a,allowPinchZoom:!!g,lockRef:n,gapMode:b}),s?i.cloneElement(i.Children.only(l),R$(R$({},_),{ref:E})):i.createElement(v,R$({},_,{className:c,ref:E}),l))}));V$.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1},V$.classNames={fullWidth:L$,zeroRight:k$};function q$(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=function(){if("undefined"!=typeof __webpack_nonce__)return __webpack_nonce__}();return t&&e.setAttribute("nonce",t),e}var z$=function(){var e=0,t=null;return{add:function(n){var r,o;0==e&&(t=q$())&&(o=n,(r=t).styleSheet?r.styleSheet.cssText=o:r.appendChild(document.createTextNode(o)),function(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}(t)),e++},remove:function(){! --e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},H$=function(){var e,t=(e=z$(),function(t,n){i.useEffect((function(){return e.add(t),function(){e.remove()}}),[t&&n])});return function(e){return t(e.styles,e.dynamic),null}},G$={left:0,top:0,right:0,gap:0},K$=function(e){return parseInt(e||"",10)||0},W$=function(e){if(void 0===e&&(e="margin"),"undefined"==typeof window)return G$;var t=function(e){var t=window.getComputedStyle(document.body),n=t["padding"===e?"paddingTop":"marginTop"],r=t["padding"===e?"paddingRight":"marginRight"];return[K$(t["padding"===e?"paddingLeft":"marginLeft"]),K$(n),K$(r)]}(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},Y$=H$(),X$="data-scroll-locked",Q$=function(e,t,n,r){var o=e.left,i=e.top,a=e.right,s=e.gap;return void 0===n&&(n="margin"),"\n .".concat("with-scroll-bars-hidden"," {\n overflow: hidden ").concat(r,";\n padding-right: ").concat(s,"px ").concat(r,";\n }\n body[").concat(X$,"] {\n overflow: hidden ").concat(r,";\n overscroll-behavior: contain;\n ").concat([t&&"position: relative ".concat(r,";"),"margin"===n&&"\n padding-left: ".concat(o,"px;\n padding-top: ").concat(i,"px;\n padding-right: ").concat(a,"px;\n margin-left:0;\n margin-top:0;\n margin-right: ").concat(s,"px ").concat(r,";\n "),"padding"===n&&"padding-right: ".concat(s,"px ").concat(r,";")].filter(Boolean).join(""),"\n }\n \n .").concat(k$," {\n right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(L$," {\n margin-right: ").concat(s,"px ").concat(r,";\n }\n \n .").concat(k$," .").concat(k$," {\n right: 0 ").concat(r,";\n }\n \n .").concat(L$," .").concat(L$," {\n margin-right: 0 ").concat(r,";\n }\n \n body[").concat(X$,"] {\n ").concat("--removed-body-scroll-bar-size",": ").concat(s,"px;\n }\n")},Z$=function(){var e=parseInt(document.body.getAttribute(X$)||"0",10);return isFinite(e)?e:0},J$=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,o=void 0===r?"margin":r;i.useEffect((function(){return document.body.setAttribute(X$,(Z$()+1).toString()),function(){var e=Z$()-1;e<=0?document.body.removeAttribute(X$):document.body.setAttribute(X$,e.toString())}}),[]);var a=i.useMemo((function(){return W$(o)}),[o]);return i.createElement(Y$,{styles:Q$(a,!t,o,n?"":"!important")})},eB=!1;if("undefined"!=typeof window)try{var tB=Object.defineProperty({},"passive",{get:function(){return eB=!0,!0}});window.addEventListener("test",tB,tB),window.removeEventListener("test",tB,tB)}catch(nme){eB=!1}var nB=!!eB&&{passive:!1},rB=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return"hidden"!==n[t]&&!(n.overflowY===n.overflowX&&!function(e){return"TEXTAREA"===e.tagName}(e)&&"visible"===n[t])},oB=function(e,t){var n=t.ownerDocument,r=t;do{if("undefined"!=typeof ShadowRoot&&r instanceof ShadowRoot&&(r=r.host),iB(e,r)){var o=aB(e,r);if(o[1]>o[2])return!0}r=r.parentNode}while(r&&r!==n.body);return!1},iB=function(e,t){return"v"===e?function(e){return rB(e,"overflowY")}(t):function(e){return rB(e,"overflowX")}(t)},aB=function(e,t){return"v"===e?[(n=t).scrollTop,n.scrollHeight,n.clientHeight]:function(e){return[e.scrollLeft,e.scrollWidth,e.clientWidth]}(t);var n},sB=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},lB=function(e){return[e.deltaX,e.deltaY]},cB=function(e){return e&&"current"in e?e.current:e},uB=function(e){return"\n .block-interactivity-".concat(e," {pointer-events: none;}\n .allow-interactivity-").concat(e," {pointer-events: all;}\n")},dB=0,pB=[];function fB(e){for(var t=null;null!==e;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const hB=(mB=function(e){var t=i.useRef([]),n=i.useRef([0,0]),r=i.useRef(),o=i.useState(dB++)[0],a=i.useState(H$)[0],s=i.useRef(e);i.useEffect((function(){s.current=e}),[e]),i.useEffect((function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(o));var t=function(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([e.lockRef.current],(e.shards||[]).map(cB),!0).filter(Boolean);return t.forEach((function(e){return e.classList.add("allow-interactivity-".concat(o))})),function(){document.body.classList.remove("block-interactivity-".concat(o)),t.forEach((function(e){return e.classList.remove("allow-interactivity-".concat(o))}))}}}),[e.inert,e.lockRef.current,e.shards]);var l=i.useCallback((function(e,t){if("touches"in e&&2===e.touches.length||"wheel"===e.type&&e.ctrlKey)return!s.current.allowPinchZoom;var o,i=sB(e),a=n.current,l="deltaX"in e?e.deltaX:a[0]-i[0],c="deltaY"in e?e.deltaY:a[1]-i[1],u=e.target,d=Math.abs(l)>Math.abs(c)?"h":"v";if("touches"in e&&"h"===d&&"range"===u.type)return!1;var p=oB(d,u);if(!p)return!0;if(p?o=d:(o="v"===d?"h":"v",p=oB(d,u)),!p)return!1;if(!r.current&&"changedTouches"in e&&(l||c)&&(r.current=o),!o)return!0;var f=r.current||o;return function(e,t,n,r){var o=function(e,t){return"h"===e&&"rtl"===t?-1:1}(e,window.getComputedStyle(t).direction),i=o*r,a=n.target,s=t.contains(a),l=!1,c=i>0,u=0,d=0;do{var p=aB(e,a),f=p[0],h=p[1]-p[2]-o*f;(f||h)&&iB(e,a)&&(u+=h,d+=f),a=a instanceof ShadowRoot?a.host:a.parentNode}while(!s&&a!==document.body||s&&(t.contains(a)||t===a));return(c&&Math.abs(u)<1||!c&&Math.abs(d)<1)&&(l=!0),l}(f,t,e,"h"===f?l:c)}),[]),c=i.useCallback((function(e){var n=e;if(pB.length&&pB[pB.length-1]===a){var r="deltaY"in n?lB(n):sB(n),o=t.current.filter((function(e){return e.name===n.type&&(e.target===n.target||n.target===e.shadowParent)&&(t=e.delta)[0]===(o=r)[0]&&t[1]===o[1];var t,o}))[0];if(o&&o.should)n.cancelable&&n.preventDefault();else if(!o){var i=(s.current.shards||[]).map(cB).filter(Boolean).filter((function(e){return e.contains(n.target)}));(i.length>0?l(n,i[0]):!s.current.noIsolation)&&n.cancelable&&n.preventDefault()}}}),[]),u=i.useCallback((function(e,n,r,o){var i={name:e,delta:n,target:r,should:o,shadowParent:fB(r)};t.current.push(i),setTimeout((function(){t.current=t.current.filter((function(e){return e!==i}))}),1)}),[]),d=i.useCallback((function(e){n.current=sB(e),r.current=void 0}),[]),p=i.useCallback((function(t){u(t.type,lB(t),t.target,l(t,e.lockRef.current))}),[]),f=i.useCallback((function(t){u(t.type,sB(t),t.target,l(t,e.lockRef.current))}),[]);i.useEffect((function(){return pB.push(a),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:f}),document.addEventListener("wheel",c,nB),document.addEventListener("touchmove",c,nB),document.addEventListener("touchstart",d,nB),function(){pB=pB.filter((function(e){return e!==a})),document.removeEventListener("wheel",c,nB),document.removeEventListener("touchmove",c,nB),document.removeEventListener("touchstart",d,nB)}}),[]);var h=e.removeScrollBar;return i.createElement(i.Fragment,null,e.inert?i.createElement(a,{styles:uB(o)}):null,h?i.createElement(J$,{gapMode:e.gapMode}):null)},$$.useMedium(mB),U$);var mB,gB=i.forwardRef((function(e,t){return i.createElement(V$,R$({},e,{ref:t,sideCar:hB}))}));gB.classNames=V$.classNames;var yB=new WeakMap,vB=new WeakMap,bB={},wB=0,xB=function(e){return e&&(e.host||xB(e.parentNode))},EB=function(e,t,n,r){var o=function(e,t){return t.map((function(t){if(e.contains(t))return t;var n=xB(t);return n&&e.contains(n)?n:null})).filter((function(e){return Boolean(e)}))}(t,Array.isArray(e)?e:[e]);bB[n]||(bB[n]=new WeakMap);var i=bB[n],a=[],s=new Set,l=new Set(o),c=function(e){e&&!s.has(e)&&(s.add(e),c(e.parentNode))};o.forEach(c);var u=function(e){e&&!l.has(e)&&Array.prototype.forEach.call(e.children,(function(e){if(s.has(e))u(e);else try{var t=e.getAttribute(r),o=null!==t&&"false"!==t,l=(yB.get(e)||0)+1,c=(i.get(e)||0)+1;yB.set(e,l),i.set(e,c),a.push(e),1===l&&o&&vB.set(e,!0),1===c&&e.setAttribute(n,"true"),o||e.setAttribute(r,"true")}catch(tme){}}))};return u(t),s.clear(),wB++,function(){a.forEach((function(e){var t=yB.get(e)-1,o=i.get(e)-1;yB.set(e,t),i.set(e,o),t||(vB.has(e)||e.removeAttribute(r),vB.delete(e)),o||e.removeAttribute(n)})),--wB||(yB=new WeakMap,yB=new WeakMap,vB=new WeakMap,bB={})}},_B=function(e,t,n){void 0===n&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),o=function(e){return"undefined"==typeof document?null:(Array.isArray(e)?e[0]:e).ownerDocument.body}(e);return o?(r.push.apply(r,Array.from(o.querySelectorAll("[aria-live]"))),EB(r,o,n,"aria-hidden")):function(){return null}},SB="Dialog",[TB,CB]=function(e,n=[]){let r=[];const o=()=>{const t=r.map((e=>i.createContext(e)));return function(n){const r=n?.[e]||t;return i.useMemo((()=>({[`__scope${e}`]:{...n,[e]:r}})),[n,r])}};return o.scopeName=e,[function(n,o){const a=i.createContext(o),s=r.length;r=[...r,o];const l=n=>{const{scope:r,children:o,...l}=n,c=r?.[e]?.[s]||a,u=i.useMemo((()=>l),Object.values(l));return t.jsx(c.Provider,{value:u,children:o})};return l.displayName=n+"Provider",[l,function(t,r){const l=i.useContext(r?.[e]?.[s]||a);if(l)return l;if(void 0!==o)return o;throw new Error(`\`${t}\` must be used within \`${n}\``)}]},YU(o,...n)]}(SB),[AB,OB]=TB(SB),NB=e=>{const{__scopeDialog:n,children:r,open:o,defaultOpen:a,onOpenChange:s,modal:l=!0}=e,c=i.useRef(null),u=i.useRef(null),[d=!1,p]=t$({prop:o,defaultProp:a,onChange:s});return t.jsx(AB,{scope:n,triggerRef:c,contentRef:u,contentId:JU(),titleId:JU(),descriptionId:JU(),open:d,onOpenChange:p,onOpenToggle:i.useCallback((()=>p((e=>!e))),[p]),modal:l,children:r})};NB.displayName=SB;var RB="DialogTrigger";i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(RB,r),a=WU(n,i.triggerRef);return t.jsx(a$.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":XB(i.open),...o,ref:a,onClick:HU(e.onClick,i.onOpenToggle)})})).displayName=RB;var PB="DialogPortal",[kB,LB]=TB(PB,{forceMount:void 0}),MB=e=>{const{__scopeDialog:n,forceMount:r,children:o,container:a}=e,s=OB(PB,n);return t.jsx(kB,{scope:n,forceMount:r,children:i.Children.map(o,(e=>t.jsx(C$,{present:r||s.open,children:t.jsx(T$,{asChild:!0,container:a,children:e})})))})};MB.displayName=PB;var DB="DialogOverlay",jB=i.forwardRef(((e,n)=>{const r=LB(DB,e.__scopeDialog),{forceMount:o=r.forceMount,...i}=e,a=OB(DB,e.__scopeDialog);return a.modal?t.jsx(C$,{present:o||a.open,children:t.jsx(FB,{...i,ref:n})}):null}));jB.displayName=DB;var IB=n$("DialogOverlay.RemoveScroll"),FB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(DB,r);return t.jsx(gB,{as:IB,allowPinchZoom:!0,shards:[i.contentRef],children:t.jsx(a$.div,{"data-state":XB(i.open),...o,ref:n,style:{pointerEvents:"auto",...o.style}})})})),UB="DialogContent",$B=i.forwardRef(((e,n)=>{const r=LB(UB,e.__scopeDialog),{forceMount:o=r.forceMount,...i}=e,a=OB(UB,e.__scopeDialog);return t.jsx(C$,{present:o||a.open,children:t.jsx(a.modal?BB:VB,{...i,ref:n})})}));$B.displayName=UB;var BB=i.forwardRef(((e,n)=>{const r=OB(UB,e.__scopeDialog),o=i.useRef(null),a=WU(n,r.contentRef,o);return i.useEffect((()=>{const e=o.current;if(e)return _B(e)}),[]),t.jsx(qB,{...e,ref:a,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:HU(e.onCloseAutoFocus,(e=>{e.preventDefault(),r.triggerRef.current?.focus()})),onPointerDownOutside:HU(e.onPointerDownOutside,(e=>{const t=e.detail.originalEvent;(2===t.button||0===t.button&&!0===t.ctrlKey)&&e.preventDefault()})),onFocusOutside:HU(e.onFocusOutside,(e=>e.preventDefault()))})})),VB=i.forwardRef(((e,n)=>{const r=OB(UB,e.__scopeDialog),o=i.useRef(!1),a=i.useRef(!1);return t.jsx(qB,{...e,ref:n,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(o.current||r.triggerRef.current?.focus(),t.preventDefault()),o.current=!1,a.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(o.current=!0,"pointerdown"===t.detail.originalEvent.type&&(a.current=!0));const n=t.target,i=r.triggerRef.current?.contains(n);i&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&a.current&&t.preventDefault()}})})),qB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,trapFocus:o,onOpenAutoFocus:a,onCloseAutoFocus:s,...l}=e,c=OB(UB,r),u=i.useRef(null),d=WU(n,u);return i.useEffect((()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??N$()),document.body.insertAdjacentElement("beforeend",e[1]??N$()),O$++,()=>{1===O$&&document.querySelectorAll("[data-radix-focus-guard]").forEach((e=>e.remove())),O$--}}),[]),t.jsxs(t.Fragment,{children:[t.jsx(v$,{asChild:!0,loop:!0,trapped:o,onMountAutoFocus:a,onUnmountAutoFocus:s,children:t.jsx(p$,{role:"dialog",id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":XB(c.open),...l,ref:d,onDismiss:()=>c.onOpenChange(!1)})}),t.jsxs(t.Fragment,{children:[t.jsx(eV,{titleId:c.titleId}),t.jsx(tV,{contentRef:u,descriptionId:c.descriptionId})]})]})})),zB="DialogTitle",HB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(zB,r);return t.jsx(a$.h2,{id:i.titleId,...o,ref:n})}));HB.displayName=zB;var GB="DialogDescription",KB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(GB,r);return t.jsx(a$.p,{id:i.descriptionId,...o,ref:n})}));KB.displayName=GB;var WB="DialogClose",YB=i.forwardRef(((e,n)=>{const{__scopeDialog:r,...o}=e,i=OB(WB,r);return t.jsx(a$.button,{type:"button",...o,ref:n,onClick:HU(e.onClick,(()=>i.onOpenChange(!1)))})}));function XB(e){return e?"open":"closed"}YB.displayName=WB;var QB="DialogTitleWarning",[ZB,JB]=function(e,n){const r=i.createContext(n),o=e=>{const{children:n,...o}=e,a=i.useMemo((()=>o),Object.values(o));return t.jsx(r.Provider,{value:a,children:n})};return o.displayName=e+"Provider",[o,function(t){const o=i.useContext(r);if(o)return o;if(void 0!==n)return n;throw new Error(`\`${t}\` must be used within \`${e}\``)}]}(QB,{contentName:UB,titleName:zB,docsSlug:"dialog"}),eV=({titleId:e})=>{const t=JB(QB);return i.useEffect((()=>{if(e){document.getElementById(e)}}),[`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.\n\nIf you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.\n\nFor more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`,e]),null},tV=({contentRef:e,descriptionId:t})=>{const n=JB("DialogDescriptionWarning");return i.useEffect((()=>{const n=e.current?.getAttribute("aria-describedby");if(t&&n){document.getElementById(t)}}),[`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${n.contentName}}.`,e,t]),null},nV=NB,rV=MB,oV=jB,iV=$B,aV=HB,sV=KB,lV=YB;function cV(...e){return Vd(Xc(e))}const uV=nV,dV=({...e})=>t.jsx(rV,{children:t.jsx("div",{"data-reach-root":!0,children:e.children})}),pV=i.forwardRef((({className:e,...n},r)=>t.jsx(oV,{ref:r,className:cV("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n})));pV.displayName=oV.displayName;const fV=i.forwardRef((({className:e,children:n,hideCloseButton:r=!1,...o},i)=>t.jsxs(dV,{children:[t.jsx(pV,{}),t.jsxs(iV,{ref:i,className:cV("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),onInteractOutside:e=>{e.composedPath().some((e=>"classList"in e&&Array.from(e.classList).includes("pac-item")))&&e.preventDefault()},...o,children:[n,!r&&t.jsxs(lV,{className:"absolute right-6 top-6 rounded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:[t.jsx(Yu,{className:"h-6 w-6"}),t.jsx("span",{className:"sr-only",children:"Close"})]})]})]})));fV.displayName=iV.displayName;const hV=({className:e,...n})=>t.jsx("div",{className:cV("flex flex-col space-y-1.5 text-center sm:text-left",e),...n});hV.displayName="DialogHeader";const mV=i.forwardRef((({className:e,...n},r)=>t.jsx(aV,{ref:r,className:cV("text-lg font-semibold leading-none tracking-tight text-foreground",e),...n})));mV.displayName=aV.displayName;const gV=i.forwardRef((({className:e,...n},r)=>t.jsx(sV,{ref:r,className:cV("text-sm text-muted-foreground",e),...n})));gV.displayName=sV.displayName;i.forwardRef((({className:e,children:n,...r},o)=>t.jsx(zU,{ref:o,className:cV(e),...r,children:n}))).displayName="DialogVisuallyHidden";const yV=n.createContext({});function vV(e){const t=n.useRef(null);return null===t.current&&(t.current=e()),t.current}const bV=n.createContext(null),wV=n.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});class xV extends i.Component{getSnapshotBeforeUpdate(e){const t=this.props.childRef.current;if(t&&e.isPresent&&!this.props.isPresent){const e=t.offsetParent,n=e instanceof HTMLElement&&e.offsetWidth||0,r=this.props.sizeRef.current;r.height=t.offsetHeight||0,r.width=t.offsetWidth||0,r.top=t.offsetTop,r.left=t.offsetLeft,r.right=n-r.width-r.left}return null}componentDidUpdate(){}render(){return this.props.children}}function EV({children:e,isPresent:r,anchorX:o}){const a=n.useId(),s=n.useRef(null),l=n.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:c}=n.useContext(wV);return n.useInsertionEffect((()=>{const{width:e,height:t,top:n,left:i,right:u}=l.current;if(r||!s.current||!e||!t)return;const d="left"===o?`left: ${i}`:`right: ${u}`;s.current.dataset.motionPopId=a;const p=document.createElement("style");return c&&(p.nonce=c),document.head.appendChild(p),p.sheet&&p.sheet.insertRule(`\n [data-motion-pop-id="${a}"] {\n position: absolute !important;\n width: ${e}px !important;\n height: ${t}px !important;\n ${d}px !important;\n top: ${n}px !important;\n }\n `),()=>{document.head.removeChild(p)}}),[r]),t.jsx(xV,{isPresent:r,childRef:s,sizeRef:l,children:i.cloneElement(e,{ref:s})})}const _V=({children:e,initial:r,isPresent:o,onExitComplete:a,custom:s,presenceAffectsLayout:l,mode:c,anchorX:u})=>{const d=vV(SV),p=n.useId(),f=n.useCallback((e=>{d.set(e,!0);for(const t of d.values())if(!t)return;a&&a()}),[d,a]),h=n.useMemo((()=>({id:p,initial:r,isPresent:o,custom:s,onExitComplete:f,register:e=>(d.set(e,!1),()=>d.delete(e))})),l?[Math.random(),f]:[o,f]);return n.useMemo((()=>{d.forEach(((e,t)=>d.set(t,!1)))}),[o]),i.useEffect((()=>{!o&&!d.size&&a&&a()}),[o]),"popLayout"===c&&(e=t.jsx(EV,{isPresent:o,anchorX:u,children:e})),t.jsx(bV.Provider,{value:h,children:e})};function SV(){return new Map}function TV(e=!0){const t=n.useContext(bV);if(null===t)return[!0,null];const{isPresent:r,onExitComplete:o,register:i}=t,a=n.useId();n.useEffect((()=>{e&&i(a)}),[e]);const s=n.useCallback((()=>e&&o&&o(a)),[a,o,e]);return!r&&o?[!1,s]:[!0]}const CV=e=>e.key||"";function AV(e){const t=[];return n.Children.forEach(e,(e=>{n.isValidElement(e)&&t.push(e)})),t}const OV="undefined"!=typeof window,NV=OV?n.useLayoutEffect:n.useEffect,RV=({children:e,custom:r,initial:o=!0,onExitComplete:i,presenceAffectsLayout:a=!0,mode:s="sync",propagate:l=!1,anchorX:c="left"})=>{const[u,d]=TV(l),p=n.useMemo((()=>AV(e)),[e]),f=l&&!u?[]:p.map(CV),h=n.useRef(!0),m=n.useRef(p),g=vV((()=>new Map)),[y,v]=n.useState(p),[b,w]=n.useState(p);NV((()=>{h.current=!1,m.current=p;for(let e=0;e<b.length;e++){const t=CV(b[e]);f.includes(t)?g.delete(t):!0!==g.get(t)&&g.set(t,!1)}}),[b,f.length,f.join("-")]);const x=[];if(p!==y){let e=[...p];for(let t=0;t<b.length;t++){const n=b[t],r=CV(n);f.includes(r)||(e.splice(t,0,n),x.push(n))}return"wait"===s&&x.length&&(e=x),w(AV(e)),v(p),null}process;const{forceRender:E}=n.useContext(yV);return t.jsx(t.Fragment,{children:b.map((e=>{const n=CV(e),y=!(l&&!u)&&(p===b||f.includes(n));return t.jsx(_V,{isPresent:y,initial:!(h.current&&!o)&&void 0,custom:r,presenceAffectsLayout:a,mode:s,onExitComplete:y?void 0:()=>{if(!g.has(n))return;g.set(n,!0);let e=!0;g.forEach((t=>{t||(e=!1)})),e&&(null==E||E(),w(m.current),l&&(null==d||d()),i&&i())},anchorX:c,children:e},n)}))})},PV=e=>e;let kV=PV,LV=PV;function MV(e){let t;return()=>(void 0===t&&(t=e()),t)}"production"!==process.env.NODE_ENV&&(kV=(e,t)=>{},LV=(e,t)=>{if(!e)throw new Error(t)});const DV=(e,t,n)=>{const r=t-e;return 0===r?1:(n-e)/r},jV=e=>1e3*e,IV=e=>e/1e3,FV=!1,UV=["read","resolveKeyframes","update","preRender","render","postRender"],$V={value:null};function BV(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,a=UV.reduce(((e,n)=>(e[n]=function(e,t){let n=new Set,r=new Set,o=!1,i=!1;const a=new WeakSet;let s={delta:0,timestamp:0,isProcessing:!1},l=0;function c(t){a.has(t)&&(u.schedule(t),e()),l++,t(s)}const u={schedule:(e,t=!1,i=!1)=>{const s=i&&o?n:r;return t&&a.add(e),s.has(e)||s.add(e),e},cancel:e=>{r.delete(e),a.delete(e)},process:e=>{s=e,o?i=!0:(o=!0,[n,r]=[r,n],n.forEach(c),t&&$V.value&&$V.value.frameloop[t].push(l),l=0,n.clear(),o=!1,i&&(i=!1,u.process(e)))}};return u}(i,t?n:void 0),e)),{}),{read:s,resolveKeyframes:l,update:c,preRender:u,render:d,postRender:p}=a,f=()=>{const i=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(i-o.timestamp,40),1),o.timestamp=i,o.isProcessing=!0,s.process(o),l.process(o),c.process(o),u.process(o),d.process(o),p.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(f))};return{schedule:UV.reduce(((t,i)=>{const s=a[i];return t[i]=(t,i=!1,a=!1)=>(n||(n=!0,r=!0,o.isProcessing||e(f)),s.schedule(t,i,a)),t}),{}),cancel:e=>{for(let t=0;t<UV.length;t++)a[UV[t]].cancel(e)},state:o,steps:a}}const{schedule:VV,cancel:qV,state:zV,steps:HV}=BV("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:PV,!0),GV=n.createContext({strict:!1}),KV={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},WV={};for(const ome in KV)WV[ome]={isEnabled:e=>KV[ome].some((t=>!!e[t]))};const YV=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function XV(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||YV.has(e)}let QV=e=>!XV(e);try{(ZV=require("@emotion/is-prop-valid").default)&&(QV=e=>e.startsWith("on")?!XV(e):ZV(e))}catch(rme){}var ZV;const JV=new Set;function eq(e,t,n){e||JV.has(t)||JV.add(t)}function tq(e){if("undefined"==typeof Proxy)return e;const t=new Map;return new Proxy(((...t)=>("production"!==process.env.NODE_ENV&&eq(!1,"motion() is deprecated. Use motion.create() instead."),e(...t))),{get:(n,r)=>"create"===r?e:(t.has(r)||t.set(r,e(r)),t.get(r))})}const nq=n.createContext({});function rq(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}function oq(e){return"string"==typeof e||Array.isArray(e)}const iq=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],aq=["initial",...iq];function sq(e){return rq(e.animate)||aq.some((t=>oq(e[t])))}function lq(e){return Boolean(sq(e)||e.variants)}function cq(e){const{initial:t,animate:r}=function(e,t){if(sq(e)){const{initial:t,animate:n}=e;return{initial:!1===t||oq(t)?t:void 0,animate:oq(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,n.useContext(nq));return n.useMemo((()=>({initial:t,animate:r})),[uq(t),uq(r)])}function uq(e){return Array.isArray(e)?e.join(" "):e}const dq=Symbol.for("motionComponentSymbol");function pq(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function fq(e,t,r){return n.useCallback((n=>{n&&e.onMount&&e.onMount(n),t&&(n?t.mount(n):t.unmount()),r&&("function"==typeof r?r(n):pq(r)&&(r.current=n))}),[t])}const hq=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),mq="data-"+hq("framerAppearId"),{schedule:gq}=BV(queueMicrotask,!1),yq=n.createContext({});function vq(e,t,r,o,i){var a,s;const{visualElement:l}=n.useContext(nq),c=n.useContext(GV),u=n.useContext(bV),d=n.useContext(wV).reducedMotion,p=n.useRef(null);o=o||c.renderer,!p.current&&o&&(p.current=o(e,{visualState:t,parent:l,props:r,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:d}));const f=p.current,h=n.useContext(yq);!f||f.projection||!i||"html"!==f.type&&"svg"!==f.type||function(e,t,n,r){const{layoutId:o,layout:i,drag:a,dragConstraints:s,layoutScroll:l,layoutRoot:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:bq(e.parent)),e.projection.setOptions({layoutId:o,layout:i,alwaysMeasureLayout:Boolean(a)||s&&pq(s),visualElement:e,animationType:"string"==typeof i?i:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:c})}(p.current,r,i,h);const m=n.useRef(!1);n.useInsertionEffect((()=>{f&&m.current&&f.update(r,u)}));const g=r[mq],y=n.useRef(Boolean(g)&&!(null===(a=window.MotionHandoffIsComplete)||void 0===a?void 0:a.call(window,g))&&(null===(s=window.MotionHasOptimisedAnimation)||void 0===s?void 0:s.call(window,g)));return NV((()=>{f&&(m.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),gq.render(f.render),y.current&&f.animationState&&f.animationState.animateChanges())})),n.useEffect((()=>{f&&(!y.current&&f.animationState&&f.animationState.animateChanges(),y.current&&(queueMicrotask((()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)})),y.current=!1))})),f}function bq(e){if(e)return!1!==e.options.allowProjection?e.projection:bq(e.parent)}function wq({preloadedFeatures:e,createVisualElement:r,useRender:o,useVisualState:i,Component:a}){var s,l;function c(s,l){let c;const u={...n.useContext(wV),...s,layoutId:xq(s)},{isStatic:d}=u,p=cq(s),f=i(s,d);if(!d&&OV){!function(e,t){const r=n.useContext(GV).strict;if("production"!==process.env.NODE_ENV&&t&&r){const t="You have rendered a `motion` component within a `LazyMotion` component. This will break tree shaking. Import and render a `m` component instead.";e.ignoreStrict?kV(!1,t):LV(!1,t)}}(u,e);const t=function(e){const{drag:t,layout:n}=WV;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(u);c=t.MeasureLayout,p.visualElement=vq(a,f,u,r,t.ProjectionNode)}return t.jsxs(nq.Provider,{value:p,children:[c&&p.visualElement?t.jsx(c,{visualElement:p.visualElement,...u}):null,o(a,s,fq(f,p.visualElement,l),f,d,p.visualElement)]})}e&&function(e){for(const t in e)WV[t]={...WV[t],...e[t]}}(e),c.displayName=`motion.${"string"==typeof a?a:`create(${null!==(l=null!==(s=a.displayName)&&void 0!==s?s:a.name)&&void 0!==l?l:""})`}`;const u=n.forwardRef(c);return u[dq]=a,u}function xq({layoutId:e}){const t=n.useContext(yV).id;return t&&void 0!==e?t+"-"+e:e}const Eq=e=>t=>"string"==typeof t&&t.startsWith(e),_q=Eq("--"),Sq=Eq("var(--"),Tq=e=>!!Sq(e)&&Cq.test(e.split("/*")[0].trim()),Cq=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Aq={};const Oq=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Nq=new Set(Oq);function Rq(e,{layout:t,layoutId:n}){return Nq.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!Aq[e]||"opacity"===e)}const Pq=e=>Boolean(e&&e.getVelocity),kq=(e,t)=>t&&"number"==typeof e?t.transform(e):e,Lq=(e,t,n)=>n>t?t:n<e?e:n,Mq={test:e=>"number"==typeof e,parse:parseFloat,transform:e=>e},Dq={...Mq,transform:e=>Lq(0,1,e)},jq={...Mq,default:1},Iq=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),Fq=Iq("deg"),Uq=Iq("%"),$q=Iq("px"),Bq=Iq("vh"),Vq=Iq("vw"),qq={...Uq,parse:e=>Uq.parse(e)/100,transform:e=>Uq.transform(100*e)},zq={borderWidth:$q,borderTopWidth:$q,borderRightWidth:$q,borderBottomWidth:$q,borderLeftWidth:$q,borderRadius:$q,radius:$q,borderTopLeftRadius:$q,borderTopRightRadius:$q,borderBottomRightRadius:$q,borderBottomLeftRadius:$q,width:$q,maxWidth:$q,height:$q,maxHeight:$q,top:$q,right:$q,bottom:$q,left:$q,padding:$q,paddingTop:$q,paddingRight:$q,paddingBottom:$q,paddingLeft:$q,margin:$q,marginTop:$q,marginRight:$q,marginBottom:$q,marginLeft:$q,backgroundPositionX:$q,backgroundPositionY:$q},Hq={rotate:Fq,rotateX:Fq,rotateY:Fq,rotateZ:Fq,scale:jq,scaleX:jq,scaleY:jq,scaleZ:jq,skew:Fq,skewX:Fq,skewY:Fq,distance:$q,translateX:$q,translateY:$q,translateZ:$q,x:$q,y:$q,z:$q,perspective:$q,transformPerspective:$q,opacity:Dq,originX:qq,originY:qq,originZ:$q},Gq={...Mq,transform:Math.round},Kq={...zq,...Hq,zIndex:Gq,size:$q,fillOpacity:Dq,strokeOpacity:Dq,numOctaves:Gq},Wq={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Yq=Oq.length;function Xq(e,t,n){const{style:r,vars:o,transformOrigin:i}=e;let a=!1,s=!1;for(const l in t){const e=t[l];if(Nq.has(l))a=!0;else if(_q(l))o[l]=e;else{const t=kq(e,Kq[l]);l.startsWith("origin")?(s=!0,i[l]=t):r[l]=t}}if(t.transform||(a||n?r.transform=function(e,t,n){let r="",o=!0;for(let i=0;i<Yq;i++){const a=Oq[i],s=e[a];if(void 0===s)continue;let l=!0;if(l="number"==typeof s?s===(a.startsWith("scale")?1:0):0===parseFloat(s),!l||n){const e=kq(s,Kq[a]);l||(o=!1,r+=`${Wq[a]||a}(${e}) `),n&&(t[a]=e)}}return r=r.trim(),n?r=n(t,o?"":r):o&&(r="none"),r}(t,e.transform,n):r.transform&&(r.transform="none")),s){const{originX:e="50%",originY:t="50%",originZ:n=0}=i;r.transformOrigin=`${e} ${t} ${n}`}}const Qq=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function Zq(e,t,n){for(const r in t)Pq(t[r])||Rq(r,n)||(e[r]=t[r])}function Jq(e,t){const r={};return Zq(r,e.style||{},e),Object.assign(r,function({transformTemplate:e},t){return n.useMemo((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{}};return Xq(n,t,e),Object.assign({},n.vars,n.style)}),[t])}(e,t)),r}function ez(e,t){const n={},r=Jq(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const tz=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function nz(e){return"string"==typeof e&&!e.includes("-")&&!!(tz.indexOf(e)>-1||/[A-Z]/u.test(e))}const rz={offset:"stroke-dashoffset",array:"stroke-dasharray"},oz={offset:"strokeDashoffset",array:"strokeDasharray"};function iz(e,t,n){return"string"==typeof e?e:$q.transform(t+n*e)}function az(e,{attrX:t,attrY:n,attrScale:r,originX:o,originY:i,pathLength:a,pathSpacing:s=1,pathOffset:l=0,...c},u,d){if(Xq(e,c,d),u)return void(e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox));e.attrs=e.style,e.style={};const{attrs:p,style:f,dimensions:h}=e;p.transform&&(h&&(f.transform=p.transform),delete p.transform),h&&(void 0!==o||void 0!==i||f.transform)&&(f.transformOrigin=function(e,t,n){return`${iz(t,e.x,e.width)} ${iz(n,e.y,e.height)}`}(h,void 0!==o?o:.5,void 0!==i?i:.5)),void 0!==t&&(p.x=t),void 0!==n&&(p.y=n),void 0!==r&&(p.scale=r),void 0!==a&&function(e,t,n=1,r=0,o=!0){e.pathLength=1;const i=o?rz:oz;e[i.offset]=$q.transform(-r);const a=$q.transform(t),s=$q.transform(n);e[i.array]=`${a} ${s}`}(p,a,s,l,!1)}const sz=()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}}),lz=e=>"string"==typeof e&&"svg"===e.toLowerCase();function cz(e,t,r,o){const i=n.useMemo((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return az(n,t,lz(o),e.transformTemplate),{...n.attrs,style:{...n.style}}}),[t]);if(e.style){const t={};Zq(t,e.style,e),i.style={...t,...i.style}}return i}function uz(e=!1){return(t,r,o,{latestValues:i},a)=>{const s=(nz(t)?cz:ez)(r,i,a,t),l=function(e,t,n){const r={};for(const o in e)"values"===o&&"object"==typeof e.values||(QV(o)||!0===n&&XV(o)||!t&&!XV(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}(r,"string"==typeof t,e),c=t!==n.Fragment?{...l,...s,ref:o}:{},{children:u}=r,d=n.useMemo((()=>Pq(u)?u.get():u),[u]);return n.createElement(t,{...c,children:d})}}function dz(e){const t=[{},{}];return null==e||e.values.forEach(((e,n)=>{t[0][n]=e.get(),t[1][n]=e.getVelocity()})),t}function pz(e,t,n,r){if("function"==typeof t){const[o,i]=dz(r);t=t(void 0!==n?n:e.custom,o,i)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){const[o,i]=dz(r);t=t(void 0!==n?n:e.custom,o,i)}return t}const fz=e=>Array.isArray(e);function hz(e){const t=Pq(e)?e.get():e;return n=t,Boolean(n&&"object"==typeof n&&n.mix&&n.toValue)?t.toValue():t;var n}const mz=e=>(t,r)=>{const o=n.useContext(nq),i=n.useContext(bV),a=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},r,o,i){const a={latestValues:gz(r,o,i,e),renderState:t()};return n&&(a.onMount=e=>n({props:r,current:e,...a}),a.onUpdate=e=>n(e)),a}(e,t,o,i);return r?a():vV(a)};function gz(e,t,n,r){const o={},i=r(e,{});for(const p in i)o[p]=hz(i[p]);let{initial:a,animate:s}=e;const l=sq(e),c=lq(e);t&&c&&!l&&!1!==e.inherit&&(void 0===a&&(a=t.initial),void 0===s&&(s=t.animate));let u=!!n&&!1===n.initial;u=u||!1===a;const d=u?s:a;if(d&&"boolean"!=typeof d&&!rq(d)){const t=Array.isArray(d)?d:[d];for(let n=0;n<t.length;n++){const r=pz(e,t[n]);if(r){const{transitionEnd:e,transition:t,...n}=r;for(const r in n){let e=n[r];if(Array.isArray(e)){e=e[u?e.length-1:0]}null!==e&&(o[r]=e)}for(const r in e)o[r]=e[r]}}}return o}function yz(e,t,n){var r;const{style:o}=e,i={};for(const a in o)(Pq(o[a])||t.style&&Pq(t.style[a])||Rq(a,e)||void 0!==(null===(r=null==n?void 0:n.getValue(a))||void 0===r?void 0:r.liveStyle))&&(i[a]=o[a]);return i}const vz={useVisualState:mz({scrapeMotionValuesFromProps:yz,createRenderState:Qq})};function bz(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(tme){t.dimensions={x:0,y:0,width:0,height:0}}}function wz(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const i in n)e.style.setProperty(i,n[i])}const xz=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function Ez(e,t,n,r){wz(e,t,void 0,r);for(const o in t.attrs)e.setAttribute(xz.has(o)?o:hq(o),t.attrs[o])}function _z(e,t,n){const r=yz(e,t,n);for(const o in e)if(Pq(e[o])||Pq(t[o])){r[-1!==Oq.indexOf(o)?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o]=e[o]}return r}const Sz=["x","y","width","height","cx","cy","r"],Tz={useVisualState:mz({scrapeMotionValuesFromProps:_z,createRenderState:sz,onUpdate:({props:e,prevProps:t,current:n,renderState:r,latestValues:o})=>{if(!n)return;let i=!!e.drag;if(!i)for(const s in o)if(Nq.has(s)){i=!0;break}if(!i)return;let a=!t;if(t)for(let s=0;s<Sz.length;s++){const n=Sz[s];e[n]!==t[n]&&(a=!0)}a&&VV.read((()=>{bz(n,r),VV.render((()=>{az(r,o,lz(n.tagName),e.transformTemplate),Ez(n,r)}))}))}})};function Cz(e,t){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return wq({...nz(n)?Tz:vz,preloadedFeatures:e,useRender:uz(r),createVisualElement:t,Component:n})}}function Az(e,t,n){const r=e.getProps();return pz(r,t,void 0!==n?n:r.custom,e)}const Oz=MV((()=>void 0!==window.ScrollTimeline));class Nz{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map((e=>"finished"in e?e.finished:e)))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;n<this.animations.length;n++)this.animations[n][e]=t}attachTimeline(e,t){const n=this.animations.map((n=>Oz()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0));return()=>{n.forEach(((e,t)=>{e&&e(),this.animations[t].stop()}))}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;t<this.animations.length;t++)e=Math.max(e,this.animations[t].duration);return e}runAll(e){this.animations.forEach((t=>t[e]()))}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class Rz extends Nz{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}function Pz(e,t){return e?e[t]||e.default||e:void 0}const kz=2e4;function Lz(e){let t=0;let n=e.next(t);for(;!n.done&&t<kz;)t+=50,n=e.next(t);return t>=kz?1/0:t}function Mz(e){return"function"==typeof e}function Dz(e,t){e.timeline=t,e.onfinish=null}const jz=e=>Array.isArray(e)&&"number"==typeof e[0],Iz={linearEasing:void 0};function Fz(e,t){const n=MV(e);return()=>{var e;return null!==(e=Iz[t])&&void 0!==e?e:n()}}const Uz=Fz((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(tme){return!1}return!0}),"linearEasing"),$z=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let i=0;i<o;i++)r+=e(DV(0,o-1,i))+", ";return`linear(${r.substring(0,r.length-2)})`};function Bz(e){return Boolean("function"==typeof e&&Uz()||!e||"string"==typeof e&&(e in qz||Uz())||jz(e)||Array.isArray(e)&&e.every(Bz))}const Vz=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,qz={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Vz([0,.65,.55,1]),circOut:Vz([.55,0,1,.45]),backIn:Vz([.31,.01,.66,-.59]),backOut:Vz([.33,1.53,.69,.99])};function zz(e,t){return e?"function"==typeof e&&Uz()?$z(e,t):jz(e)?Vz(e):Array.isArray(e)?e.map((e=>zz(e,t)||qz.easeOut)):qz[e]:void 0}const Hz={x:!1,y:!1};function Gz(){return Hz.x||Hz.y}function Kz(e,t){const n=function(e){if(e instanceof Element)return[e];if("string"==typeof e){const t=document.querySelectorAll(e);return t?Array.from(t):[]}return Array.from(e)}(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function Wz(e){return!("touch"===e.pointerType||Gz())}const Yz=(e,t)=>!!t&&(e===t||Yz(e,t.parentElement)),Xz=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary,Qz=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);const Zz=new WeakSet;function Jz(e){return t=>{"Enter"===t.key&&e(t)}}function eH(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function tH(e){return Xz(e)&&!Gz()}function nH(e,t,n={}){const[r,o,i]=Kz(e,n),a=e=>{const r=e.currentTarget;if(!tH(e)||Zz.has(r))return;Zz.add(r);const i=t(r,e),a=(e,t)=>{window.removeEventListener("pointerup",s),window.removeEventListener("pointercancel",l),tH(e)&&Zz.has(r)&&(Zz.delete(r),"function"==typeof i&&i(e,{success:t}))},s=e=>{a(e,n.useGlobalTarget||Yz(r,e.target))},l=e=>{a(e,!1)};window.addEventListener("pointerup",s,o),window.addEventListener("pointercancel",l,o)};return r.forEach((e=>{(function(e){return Qz.has(e.tagName)||-1!==e.tabIndex})(e)||null!==e.getAttribute("tabindex")||(e.tabIndex=0);(n.useGlobalTarget?window:e).addEventListener("pointerdown",a,o),e.addEventListener("focus",(e=>((e,t)=>{const n=e.currentTarget;if(!n)return;const r=Jz((()=>{if(Zz.has(n))return;eH(n,"down");const e=Jz((()=>{eH(n,"up")}));n.addEventListener("keyup",e,t),n.addEventListener("blur",(()=>eH(n,"cancel")),t)}));n.addEventListener("keydown",r,t),n.addEventListener("blur",(()=>n.removeEventListener("keydown",r)),t)})(e,o)),o)})),i}const rH=new Set(["width","height","top","left","right","bottom",...Oq]);let oH;function iH(){oH=void 0}const aH={now:()=>(void 0===oH&&aH.set(zV.isProcessing||FV?zV.timestamp:performance.now()),oH),set:e=>{oH=e,queueMicrotask(iH)}};function sH(e,t){-1===e.indexOf(t)&&e.push(t)}function lH(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class cH{constructor(){this.subscriptions=[]}add(e){return sH(this.subscriptions,e),()=>lH(this.subscriptions,e)}notify(e,t,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(let o=0;o<r;o++){const r=this.subscriptions[o];r&&r(e,t,n)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}function uH(e,t){return t?e*(1e3/t):0}class dH{constructor(e,t={}){this.version="12.4.0",this.canTrackVelocity=null,this.events={},this.updateAndNotify=(e,t=!0)=>{const n=aH.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){this.current=e,this.updatedAt=aH.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=!isNaN(parseFloat(this.current)))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return"production"!==process.env.NODE_ENV&&eq(!1,'value.onChange(callback) is deprecated. Switch to value.on("change", callback).'),this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new cH);const n=this.events[e].add(t);return"change"===e?()=>{n(),VV.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=aH.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;const t=Math.min(this.updatedAt-this.prevUpdatedAt,30);return uH(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function pH(e,t){return new dH(e,t)}function fH(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,pH(n))}function hH(e,t){const n=e.getValue("willChange");if(r=n,Boolean(Pq(r)&&r.add))return n.add(t);var r}function mH(e){return e.props[mq]}const gH=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function yH(e,t,n,r){if(e===t&&n===r)return PV;const o=t=>function(e,t,n,r,o){let i,a,s=0;do{a=t+(n-t)/2,i=gH(a,r,o)-e,i>0?n=a:t=a}while(Math.abs(i)>1e-7&&++s<12);return a}(t,0,1,e,n);return e=>0===e||1===e?e:gH(o(e),t,r)}const vH=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,bH=e=>t=>1-e(1-t),wH=yH(.33,1.53,.69,.99),xH=bH(wH),EH=vH(xH),_H=e=>(e*=2)<1?.5*xH(e):.5*(2-Math.pow(2,-10*(e-1))),SH=e=>1-Math.sin(Math.acos(e)),TH=bH(SH),CH=vH(SH),AH=e=>/^0[^.\s]+$/u.test(e);const OH=e=>Math.round(1e5*e)/1e5,NH=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const RH=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,PH=(e,t)=>n=>Boolean("string"==typeof n&&RH.test(n)&&n.startsWith(e)||t&&!function(e){return null==e}(n)&&Object.prototype.hasOwnProperty.call(n,t)),kH=(e,t,n)=>r=>{if("string"!=typeof r)return r;const[o,i,a,s]=r.match(NH);return{[e]:parseFloat(o),[t]:parseFloat(i),[n]:parseFloat(a),alpha:void 0!==s?parseFloat(s):1}},LH={...Mq,transform:e=>Math.round((e=>Lq(0,255,e))(e))},MH={test:PH("rgb","red"),parse:kH("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+LH.transform(e)+", "+LH.transform(t)+", "+LH.transform(n)+", "+OH(Dq.transform(r))+")"};const DH={test:PH("#"),parse:function(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}},transform:MH.transform},jH={test:PH("hsl","hue"),parse:kH("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Uq.transform(OH(t))+", "+Uq.transform(OH(n))+", "+OH(Dq.transform(r))+")"},IH={test:e=>MH.test(e)||DH.test(e)||jH.test(e),parse:e=>MH.test(e)?MH.parse(e):jH.test(e)?jH.parse(e):DH.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?MH.transform(e):jH.transform(e)},FH=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;const UH="number",$H="color",BH=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function VH(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let i=0;const a=t.replace(BH,(e=>(IH.test(e)?(r.color.push(i),o.push($H),n.push(IH.parse(e))):e.startsWith("var(")?(r.var.push(i),o.push("var"),n.push(e)):(r.number.push(i),o.push(UH),n.push(parseFloat(e))),++i,"${}"))).split("${}");return{values:n,split:a,indexes:r,types:o}}function qH(e){return VH(e).values}function zH(e){const{split:t,types:n}=VH(e),r=t.length;return e=>{let o="";for(let i=0;i<r;i++)if(o+=t[i],void 0!==e[i]){const t=n[i];o+=t===UH?OH(e[i]):t===$H?IH.transform(e[i]):e[i]}return o}}const HH=e=>"number"==typeof e?0:e;const GH={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(NH))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(FH))||void 0===n?void 0:n.length)||0)>0},parse:qH,createTransformer:zH,getAnimatableNone:function(e){const t=qH(e);return zH(e)(t.map(HH))}},KH=new Set(["brightness","contrast","saturate","opacity"]);function WH(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[r]=n.match(NH)||[];if(!r)return e;const o=n.replace(r,"");let i=KH.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+o+")"}const YH=/\b([a-z-]*)\(.*?\)/gu,XH={...GH,getAnimatableNone:e=>{const t=e.match(YH);return t?t.map(WH).join(" "):e}},QH={...Kq,color:IH,backgroundColor:IH,outlineColor:IH,fill:IH,stroke:IH,borderColor:IH,borderTopColor:IH,borderRightColor:IH,borderBottomColor:IH,borderLeftColor:IH,filter:XH,WebkitFilter:XH},ZH=e=>QH[e];function JH(e,t){let n=ZH(e);return n!==XH&&(n=GH),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const eG=new Set(["auto","none","0"]);const tG=e=>e===Mq||e===$q,nG=(e,t)=>parseFloat(e.split(", ")[t]),rG=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/u);if(o)return nG(o[1],t);{const t=r.match(/^matrix\((.+)\)$/u);return t?nG(t[1],e):0}},oG=new Set(["x","y","z"]),iG=Oq.filter((e=>!oG.has(e)));const aG={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:rG(4,13),y:rG(5,14)};aG.translateX=aG.x,aG.translateY=aG.y;const sG=new Set;let lG=!1,cG=!1;function uG(){if(cG){const e=Array.from(sG).filter((e=>e.needsMeasurement)),t=new Set(e.map((e=>e.element))),n=new Map;t.forEach((e=>{const t=function(e){const t=[];return iG.forEach((n=>{const r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),t}(e);t.length&&(n.set(e,t),e.render())})),e.forEach((e=>e.measureInitialState())),t.forEach((e=>{e.render();const t=n.get(e);t&&t.forEach((([t,n])=>{var r;null===(r=e.getValue(t))||void 0===r||r.set(n)}))})),e.forEach((e=>e.measureEndState())),e.forEach((e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)}))}cG=!1,lG=!1,sG.forEach((e=>e.complete())),sG.clear()}function dG(){sG.forEach((e=>{e.readKeyframes(),e.needsMeasurement&&(cG=!0)}))}class pG{constructor(e,t,n,r,o,i=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=o,this.isAsync=i}scheduleResolve(){this.isScheduled=!0,this.isAsync?(sG.add(this),lG||(lG=!0,VV.read(dG),VV.resolveKeyframes(uG))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;for(let o=0;o<e.length;o++)if(null===e[o])if(0===o){const o=null==r?void 0:r.get(),i=e[e.length-1];if(void 0!==o)e[0]=o;else if(n&&t){const r=n.readValue(t,i);null!=r&&(e[0]=r)}void 0===e[0]&&(e[0]=i),r&&void 0===o&&r.set(e[0])}else e[o]=e[o-1]}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(){this.isComplete=!0,this.onComplete(this.unresolvedKeyframes,this.finalKeyframe),sG.delete(this)}cancel(){this.isComplete||(this.isScheduled=!1,sG.delete(this))}resume(){this.isComplete||this.scheduleResolve()}}const fG=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),hG=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function mG(e,t,n=1){LV(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=function(e){const t=hG.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${null!=n?n:r}`,o]}(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const e=i.trim();return fG(e)?parseFloat(e):e}return Tq(o)?mG(o,t,n+1):o}const gG=e=>t=>t.test(e),yG=[Mq,$q,Uq,Fq,Vq,Bq,{test:e=>"auto"===e,parse:e=>e}],vG=e=>yG.find(gG(e));class bG extends pG{constructor(e,t,n,r,o){super(e,t,n,r,o,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let s=0;s<e.length;s++){let n=e[s];if("string"==typeof n&&(n=n.trim(),Tq(n))){const r=mG(n,t.current);void 0!==r&&(e[s]=r),s===e.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!rH.has(n)||2!==e.length)return;const[r,o]=e,i=vG(r),a=vG(o);if(i!==a)if(tG(i)&&tG(a))for(let s=0;s<e.length;s++){const t=e[s];"string"==typeof t&&(e[s]=parseFloat(t))}else this.needsMeasurement=!0}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:t}=this,n=[];for(let o=0;o<e.length;o++)("number"==typeof(r=e[o])?0===r:null===r||"none"===r||"0"===r||AH(r))&&n.push(o);var r;n.length&&function(e,t,n){let r,o=0;for(;o<e.length&&!r;){const t=e[o];"string"==typeof t&&!eG.has(t)&&VH(t).values.length&&(r=e[o]),o++}if(r&&n)for(const i of t)e[i]=JH(n,r)}(e,n,t)}measureInitialState(){const{element:e,unresolvedKeyframes:t,name:n}=this;if(!e||!e.current)return;"height"===n&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=aG[n](e.measureViewportBox(),window.getComputedStyle(e.current)),t[0]=this.measuredOrigin;const r=t[t.length-1];void 0!==r&&e.getValue(n,r).jump(r,!1)}measureEndState(){var e;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const o=t.getValue(n);o&&o.jump(this.measuredOrigin,!1);const i=r.length-1,a=r[i];r[i]=aG[n](t.measureViewportBox(),window.getComputedStyle(t.current)),null!==a&&void 0===this.finalKeyframe&&(this.finalKeyframe=a),(null===(e=this.removedTransforms)||void 0===e?void 0:e.length)&&this.removedTransforms.forEach((([e,n])=>{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}const wG=(e,t)=>"zIndex"!==t&&(!("number"!=typeof e&&!Array.isArray(e))||!("string"!=typeof e||!GH.test(e)&&"0"!==e||e.startsWith("url(")));const xG=e=>null!==e;function EG(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter(xG),i=t&&"loop"!==n&&t%2==1?0:o.length-1;return i&&void 0!==r?r:o[i]}class _G{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:i="loop",...a}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=aH.now(),this.options={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:o,repeatType:i,...a},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(dG(),uG()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=aH.now(),this.hasAttemptedResolve=!0;const{name:n,type:r,velocity:o,delay:i,onComplete:a,onUpdate:s,isGenerator:l}=this.options;if(!l&&!function(e,t,n,r){const o=e[0];if(null===o)return!1;if("display"===t||"visibility"===t)return!0;const i=e[e.length-1],a=wG(o,t),s=wG(i,t);return kV(a===s,`You are trying to animate ${t} from "${o}" to "${i}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${i} via the \`style\` property.`),!(!a||!s)&&(function(e){const t=e[0];if(1===e.length)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}(e)||("spring"===n||Mz(n))&&r)}(e,n,r,o)){if(!i)return s&&s(EG(e,this.options,t)),a&&a(),void this.resolveFinishedPromise();this.options.duration=0}const c=this.initPlayback(e,t);!1!==c&&(this._resolved={keyframes:e,finalKeyframe:t,...c},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise((e=>{this.resolveFinishedPromise=e}))}}const SG=(e,t,n)=>e+(t-e)*n;function TG(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function CG(e,t){return n=>n>0?t:e}const AG=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},OG=[DH,MH,jH];function NG(e){const t=(n=e,OG.find((e=>e.test(n))));var n;if(kV(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`),!Boolean(t))return!1;let r=t.parse(e);return t===jH&&(r=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let o=0,i=0,a=0;if(t/=100){const r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;o=TG(s,r,e+1/3),i=TG(s,r,e),a=TG(s,r,e-1/3)}else o=i=a=n;return{red:Math.round(255*o),green:Math.round(255*i),blue:Math.round(255*a),alpha:r}}(r)),r}const RG=(e,t)=>{const n=NG(e),r=NG(t);if(!n||!r)return CG(e,t);const o={...n};return e=>(o.red=AG(n.red,r.red,e),o.green=AG(n.green,r.green,e),o.blue=AG(n.blue,r.blue,e),o.alpha=SG(n.alpha,r.alpha,e),MH.transform(o))},PG=(e,t)=>n=>t(e(n)),kG=(...e)=>e.reduce(PG),LG=new Set(["none","hidden"]);function MG(e,t){return n=>SG(e,t,n)}function DG(e){return"number"==typeof e?MG:"string"==typeof e?Tq(e)?CG:IH.test(e)?RG:FG:Array.isArray(e)?jG:"object"==typeof e?IH.test(e)?RG:IG:CG}function jG(e,t){const n=[...e],r=n.length,o=e.map(((e,n)=>DG(e)(e,t[n])));return e=>{for(let t=0;t<r;t++)n[t]=o[t](e);return n}}function IG(e,t){const n={...e,...t},r={};for(const o in n)void 0!==e[o]&&void 0!==t[o]&&(r[o]=DG(e[o])(e[o],t[o]));return e=>{for(const t in r)n[t]=r[t](e);return n}}const FG=(e,t)=>{const n=GH.createTransformer(t),r=VH(e),o=VH(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?LG.has(e)&&!o.values.length||LG.has(t)&&!r.values.length?function(e,t){return LG.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):kG(jG(function(e,t){var n;const r=[],o={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const a=t.types[i],s=null!==(n=e.values[e.indexes[a][o[a]]])&&void 0!==n?n:0;r[i]=s,o[a]++}return r}(r,o),o.values),n):(kV(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`),CG(e,t))};function UG(e,t,n){if("number"==typeof e&&"number"==typeof t&&"number"==typeof n)return SG(e,t,n);return DG(e)(e,t)}function $G(e,t,n){const r=Math.max(t-5,0);return uH(n-e(r),t-r)}const BG=100,VG=10,qG=1,zG=0,HG=800,GG=.3,KG=.3,WG={granular:.01,default:2},YG={granular:.005,default:.5},XG=.01,QG=10,ZG=.05,JG=1;function eK({duration:e=HG,bounce:t=GG,velocity:n=zG,mass:r=qG}){let o,i;kV(e<=jV(QG),"Spring duration must be 10 seconds or less");let a=1-t;a=Lq(ZG,JG,a),e=Lq(XG,QG,IV(e)),a<1?(o=t=>{const r=t*a,o=r*e;return.001-(r-n)/nK(t,a)*Math.exp(-o)},i=t=>{const r=t*a*e,i=r*n+n,s=Math.pow(a,2)*Math.pow(t,2)*e,l=Math.exp(-r),c=nK(Math.pow(t,2),a);return(.001-o(t)>0?-1:1)*((i-s)*l)/c}):(o=t=>Math.exp(-t*e)*((t-n)*e+1)-.001,i=t=>Math.exp(-t*e)*(e*e*(n-t)));const s=function(e,t,n){let r=n;for(let o=1;o<tK;o++)r-=e(r)/t(r);return r}(o,i,5/e);if(e=jV(e),isNaN(s))return{stiffness:BG,damping:VG,duration:e};{const t=Math.pow(s,2)*r;return{stiffness:t,damping:2*a*Math.sqrt(r*t),duration:e}}}const tK=12;function nK(e,t){return e*Math.sqrt(1-t*t)}const rK=["duration","bounce"],oK=["stiffness","damping","mass"];function iK(e,t){return t.some((t=>void 0!==e[t]))}function aK(e=KG,t=GG){const n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const i=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],s={done:!1,value:i},{stiffness:l,damping:c,mass:u,duration:d,velocity:p,isResolvedFromDuration:f}=function(e){let t={velocity:zG,stiffness:BG,damping:VG,mass:qG,isResolvedFromDuration:!1,...e};if(!iK(e,oK)&&iK(e,rK))if(e.visualDuration){const n=2*Math.PI/(1.2*e.visualDuration),r=n*n,o=2*Lq(.05,1,1-(e.bounce||0))*Math.sqrt(r);t={...t,mass:qG,stiffness:r,damping:o}}else{const n=eK(e);t={...t,...n,mass:qG},t.isResolvedFromDuration=!0}return t}({...n,velocity:-IV(n.velocity||0)}),h=p||0,m=c/(2*Math.sqrt(l*u)),g=a-i,y=IV(Math.sqrt(l/u)),v=Math.abs(g)<5;let b;if(r||(r=v?WG.granular:WG.default),o||(o=v?YG.granular:YG.default),m<1){const e=nK(y,m);b=t=>{const n=Math.exp(-m*y*t);return a-n*((h+m*y*g)/e*Math.sin(e*t)+g*Math.cos(e*t))}}else if(1===m)b=e=>a-Math.exp(-y*e)*(g+(h+y*g)*e);else{const e=y*Math.sqrt(m*m-1);b=t=>{const n=Math.exp(-m*y*t),r=Math.min(e*t,300);return a-n*((h+m*y*g)*Math.sinh(r)+e*g*Math.cosh(r))/e}}const w={calculatedDuration:f&&d||null,next:e=>{const t=b(e);if(f)s.done=e>=d;else{let n=0;m<1&&(n=0===e?jV(h):$G(b,e,t));const i=Math.abs(n)<=r,l=Math.abs(a-t)<=o;s.done=i&&l}return s.value=s.done?a:t,s},toString:()=>{const e=Math.min(Lz(w),kz),t=$z((t=>w.next(e*t).value),e,30);return e+"ms "+t}};return w}function sK({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:i=500,modifyTarget:a,min:s,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],p={done:!1,value:d},f=e=>void 0===s?l:void 0===l||Math.abs(s-e)<Math.abs(l-e)?s:l;let h=n*t;const m=d+h,g=void 0===a?m:a(m);g!==m&&(h=g-d);const y=e=>-h*Math.exp(-e/r),v=e=>g+y(e),b=e=>{const t=y(e),n=v(e);p.done=Math.abs(t)<=c,p.value=p.done?g:n};let w,x;const E=e=>{var t;(t=p.value,void 0!==s&&t<s||void 0!==l&&t>l)&&(w=e,x=aK({keyframes:[p.value,f(p.value)],velocity:$G(v,e,p.value),damping:o,stiffness:i,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:e=>{let t=!1;return x||void 0!==w||(t=!0,b(e),E(e)),void 0!==w&&e>=w?x.next(e-w):(!t&&b(e),p)}}}const lK=yH(.42,0,1,1),cK=yH(0,0,.58,1),uK=yH(.42,0,.58,1),dK={linear:PV,easeIn:lK,easeInOut:uK,easeOut:cK,circIn:SH,circInOut:CH,circOut:TH,backIn:xH,backInOut:EH,backOut:wH,anticipate:_H},pK=e=>{if(jz(e)){LV(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return yH(t,n,r,o)}return"string"==typeof e?(LV(void 0!==dK[e],`Invalid easing type '${e}'`),dK[e]):e};function fK(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const i=e.length;if(LV(i===t.length,"Both input and output ranges must be the same length"),1===i)return()=>t[0];if(2===i&&t[0]===t[1])return()=>t[1];const a=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=function(e,t,n){const r=[],o=n||UG,i=e.length-1;for(let a=0;a<i;a++){let n=o(e[a],e[a+1]);if(t){const e=Array.isArray(t)?t[a]||PV:t;n=kG(e,n)}r.push(n)}return r}(t,r,o),l=s.length,c=n=>{if(a&&n<e[0])return t[0];let r=0;if(l>1)for(;r<e.length-2&&!(n<e[r+1]);r++);return s[r](DV(e[r],e[r+1],n))};return n?t=>c(Lq(e[0],e[i-1],t)):c}function hK(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++)e.push(SG(n,1,DV(0,t,r)))}(t,e.length-1),t}function mK({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=(e=>Array.isArray(e)&&"number"!=typeof e[0])(r)?r.map(pK):pK(r),i={done:!1,value:t[0]},a=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:hK(t),e),s=fK(a,t,{ease:Array.isArray(o)?o:(l=t,c=o,l.map((()=>c||uK)).splice(0,l.length-1))});var l,c;return{calculatedDuration:e,next:t=>(i.value=s(t),i.done=t>=e,i)}}const gK=e=>{const t=({timestamp:t})=>e(t);return{start:()=>VV.update(t,!0),stop:()=>qV(t),now:()=>zV.isProcessing?zV.timestamp:aH.now()}},yK={decay:sK,inertia:sK,tween:mK,keyframes:mK,spring:aK},vK=e=>e/100;class bK extends _G{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:e}=this.options;e&&e()};const{name:t,motionValue:n,element:r,keyframes:o}=this.options;this.resolver=new((null==r?void 0:r.KeyframeResolver)||pG)(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){const{type:t="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:o,velocity:i=0}=this.options,a=Mz(t)?t:yK[t]||mK;let s,l;a!==mK&&"number"!=typeof e[0]&&("production"!==process.env.NODE_ENV&&LV(2===e.length,`Only two keyframes currently supported with spring and inertia animations. Trying to animate ${e}`),s=kG(vK,UG(e[0],e[1])),e=[0,100]);const c=a({...this.options,keyframes:e});"mirror"===o&&(l=a({...this.options,keyframes:[...e].reverse(),velocity:-i})),null===c.calculatedDuration&&(c.calculatedDuration=Lz(c));const{calculatedDuration:u}=c,d=u+r;return{generator:c,mirroredGenerator:l,mapPercentToKeyframes:s,calculatedDuration:u,resolvedDuration:d,totalDuration:d*(n+1)-r}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){const{resolved:n}=this;if(!n){const{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}const{finalKeyframe:r,generator:o,mirroredGenerator:i,mapPercentToKeyframes:a,keyframes:s,calculatedDuration:l,totalDuration:c,resolvedDuration:u}=n;if(null===this.startTime)return o.next(0);const{delay:d,repeat:p,repeatType:f,repeatDelay:h,onUpdate:m}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),this.currentTime=t?e:null!==this.holdTime?this.holdTime:Math.round(e-this.startTime)*this.speed;const g=this.currentTime-d*(this.speed>=0?1:-1),y=this.speed>=0?g<0:g>c;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=c);let v=this.currentTime,b=o;if(p){const e=Math.min(this.currentTime,c)/u;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,p+1);Boolean(t%2)&&("reverse"===f?(n=1-n,h&&(n-=h/u)):"mirror"===f&&(b=i)),v=Lq(0,1,n)*u}const w=y?{done:!1,value:s[0]}:b.next(v);a&&(w.value=a(w.value));let{done:x}=w;y||null===l||(x=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const E=null===this.holdTime&&("finished"===this.state||"running"===this.state&&x);return E&&void 0!==r&&(w.value=EG(s,this.options,r)),m&&m(w.value),E&&this.finish(),w}get duration(){const{resolved:e}=this;return e?IV(e.calculatedDuration):0}get time(){return IV(this.currentTime)}set time(e){this.currentTime=e=jV(e),null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=IV(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:e=gK,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e((e=>this.tick(e)))),t&&t();const r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;this._resolved?(this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const wK=new Set(["opacity","clipPath","filter","transform"]);function xK(e,t,n,{delay:r=0,duration:o=300,repeat:i=0,repeatType:a="loop",ease:s="easeInOut",times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=zz(s,o);Array.isArray(u)&&(c.easing=u);return e.animate(c,{delay:r,duration:o,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:i+1,direction:"reverse"===a?"alternate":"normal"})}const EK=MV((()=>Object.hasOwnProperty.call(Element.prototype,"animate")));const _K={anticipate:_H,backInOut:EH,circInOut:CH};class SK extends _G{constructor(e){super(e);const{name:t,motionValue:n,element:r,keyframes:o}=this.options;this.resolver=new bG(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}initPlayback(e,t){let{duration:n=300,times:r,ease:o,type:i,motionValue:a,name:s,startTime:l}=this.options;if(!a.owner||!a.owner.current)return!1;var c;if("string"==typeof o&&Uz()&&o in _K&&(o=_K[o]),Mz((c=this.options).type)||"spring"===c.type||!Bz(c.ease)){const{onComplete:t,onUpdate:a,motionValue:s,element:l,...c}=this.options,u=function(e,t){const n=new bK({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:e[0]};const o=[];let i=0;for(;!r.done&&i<2e4;)r=n.sample(i),o.push(r.value),i+=10;return{times:void 0,keyframes:o,duration:i-10,ease:"linear"}}(e,c);1===(e=u.keyframes).length&&(e[1]=e[0]),n=u.duration,r=u.times,o=u.ease,i="keyframes"}const u=xK(a.owner.current,s,e,{...this.options,duration:n,times:r,ease:o});return u.startTime=null!=l?l:this.calcStartTime(),this.pendingTimeline?(Dz(u,this.pendingTimeline),this.pendingTimeline=void 0):u.onfinish=()=>{const{onComplete:n}=this.options;a.set(EG(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:u,duration:n,times:r,type:i,ease:o,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:t}=e;return IV(t)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:t}=e;return IV(t.currentTime||0)}set time(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.currentTime=jV(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:t}=e;return t.playbackRate}set speed(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:t}=e;return t.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){const{resolved:t}=this;if(!t)return PV;const{animation:n}=t;Dz(n,e)}else this.pendingTimeline=e;return PV}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:t,keyframes:n,duration:r,type:o,ease:i,times:a}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){const{motionValue:e,onUpdate:t,onComplete:s,element:l,...c}=this.options,u=new bK({...c,keyframes:n,duration:r,type:o,ease:i,times:a,isGenerator:!0}),d=jV(this.time);e.setWithVelocity(u.sample(d-10).value,u.sample(d).value,10)}const{onStop:s}=this.options;s&&s(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:i,type:a}=e;if(!(t&&t.owner&&t.owner.current instanceof HTMLElement))return!1;const{onUpdate:s,transformTemplate:l}=t.owner.getProps();return EK()&&n&&wK.has(n)&&!s&&!l&&!r&&"mirror"!==o&&0!==i&&"inertia"!==a}}const TK={type:"spring",stiffness:500,damping:25,restSpeed:10},CK={type:"keyframes",duration:.8},AK={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},OK=(e,{keyframes:t})=>t.length>2?CK:Nq.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:TK:AK;const NK=(e,t,n,r={},o,i)=>a=>{const s=Pz(r,e)||{},l=s.delay||r.delay||0;let{elapsed:c=0}=r;c-=jV(l);let u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...s,delay:-c,onUpdate:e=>{t.set(e),s.onUpdate&&s.onUpdate(e)},onComplete:()=>{a(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:i?void 0:o};(function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:i,repeatType:a,repeatDelay:s,from:l,elapsed:c,...u}){return!!Object.keys(u).length})(s)||(u={...u,...OK(e,u)}),u.duration&&(u.duration=jV(u.duration)),u.repeatDelay&&(u.repeatDelay=jV(u.repeatDelay)),void 0!==u.from&&(u.keyframes[0]=u.from);let d=!1;if((!1===u.type||0===u.duration&&!u.repeatDelay)&&(u.duration=0,0===u.delay&&(d=!0)),d&&!i&&void 0!==t.get()){const e=EG(u.keyframes,s);if(void 0!==e)return VV.update((()=>{u.onUpdate(e),u.onComplete()})),new Rz([])}return!i&&SK.supports(u)?new SK(u):new bK(u)};function RK({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}function PK(e,t,{delay:n=0,transitionOverride:r,type:o}={}){var i;let{transition:a=e.getDefaultTransition(),transitionEnd:s,...l}=t;r&&(a=r);const c=[],u=o&&e.animationState&&e.animationState.getState()[o];for(const d in l){const t=e.getValue(d,null!==(i=e.latestValues[d])&&void 0!==i?i:null),r=l[d];if(void 0===r||u&&RK(u,d))continue;const o={delay:n,...Pz(a||{},d)};let s=!1;if(window.MotionHandoffAnimation){const t=mH(e);if(t){const e=window.MotionHandoffAnimation(t,d,VV);null!==e&&(o.startTime=e,s=!0)}}hH(e,d),t.start(NK(d,t,r,e.shouldReduceMotion&&rH.has(d)?{type:!1}:o,e,s));const p=t.animation;p&&c.push(p)}return s&&Promise.all(c).then((()=>{VV.update((()=>{s&&function(e,t){const n=Az(e,t);let{transitionEnd:r={},transition:o={},...i}=n||{};i={...i,...r};for(const s in i)fH(e,s,fz(a=i[s])?a[a.length-1]||0:a);var a}(e,s)}))})),c}function kK(e,t,n={}){var r;const o=Az(e,t,"exit"===n.type?null===(r=e.presenceContext)||void 0===r?void 0:r.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(i=n.transitionOverride);const a=o?()=>Promise.all(PK(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(r=0)=>{const{delayChildren:o=0,staggerChildren:a,staggerDirection:s}=i;return function(e,t,n=0,r=0,o=1,i){const a=[],s=(e.variantChildren.size-1)*r,l=1===o?(e=0)=>e*r:(e=0)=>s-e*r;return Array.from(e.variantChildren).sort(LK).forEach(((e,r)=>{e.notify("AnimationStart",t),a.push(kK(e,t,{...i,delay:n+l(r)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(a)}(e,t,o+r,a,s,n)}:()=>Promise.resolve(),{when:l}=i;if(l){const[e,t]="beforeChildren"===l?[a,s]:[s,a];return e().then((()=>t()))}return Promise.all([a(),s(n.delay)])}function LK(e,t){return e.sortNodePosition(t)}function MK(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const DK=aq.length;function jK(e){if(!e)return;if(!e.isControllingVariants){const t=e.parent&&jK(e.parent)||{};return void 0!==e.props.initial&&(t.initial=e.props.initial),t}const t={};for(let n=0;n<DK;n++){const r=aq[n],o=e.props[r];(oq(o)||!1===o)&&(t[r]=o)}return t}const IK=[...iq].reverse(),FK=iq.length;function UK(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t)){const o=t.map((t=>kK(e,t,n)));r=Promise.all(o)}else if("string"==typeof t)r=kK(e,t,n);else{const o="function"==typeof t?Az(e,t,n.custom):t;r=Promise.all(PK(e,o,n))}return r.then((()=>{e.notify("AnimationComplete",t)}))}(e,t,n))))}function $K(e){let t=UK(e),n=qK(),r=!0;const o=t=>(n,r)=>{var o;const i=Az(e,r,"exit"===t?null===(o=e.presenceContext)||void 0===o?void 0:o.custom:void 0);if(i){const{transition:e,transitionEnd:t,...r}=i;n={...n,...r,...t}}return n};function i(i){const{props:a}=e,s=jK(e.parent)||{},l=[],c=new Set;let u={},d=1/0;for(let t=0;t<FK;t++){const p=IK[t],f=n[p],h=void 0!==a[p]?a[p]:s[p],m=oq(h),g=p===i?f.isActive:null;!1===g&&(d=t);let y=h===s[p]&&h!==a[p]&&m;if(y&&r&&e.manuallyAnimateOnMount&&(y=!1),f.protectedKeys={...u},!f.isActive&&null===g||!h&&!f.prevProp||rq(h)||"boolean"==typeof h)continue;const v=BK(f.prevProp,h);let b=v||p===i&&f.isActive&&!y&&m||t>d&&m,w=!1;const x=Array.isArray(h)?h:[h];let E=x.reduce(o(p),{});!1===g&&(E={});const{prevResolvedValues:_={}}=f,S={..._,...E},T=t=>{b=!0,c.has(t)&&(w=!0,c.delete(t)),f.needsAnimating[t]=!0;const n=e.getValue(t);n&&(n.liveStyle=!1)};for(const e in S){const t=E[e],n=_[e];if(u.hasOwnProperty(e))continue;let r=!1;r=fz(t)&&fz(n)?!MK(t,n):t!==n,r?null!=t?T(e):c.add(e):void 0!==t&&c.has(e)?T(e):f.protectedKeys[e]=!0}f.prevProp=h,f.prevResolvedValues=E,f.isActive&&(u={...u,...E}),r&&e.blockInitialAnimation&&(b=!1);b&&(!(y&&v)||w)&&l.push(...x.map((e=>({animation:e,options:{type:p}}))))}if(c.size){const t={};c.forEach((n=>{const r=e.getBaseTarget(n),o=e.getValue(n);o&&(o.liveStyle=!0),t[n]=null!=r?r:null})),l.push({animation:t})}let p=Boolean(l.length);return!r||!1!==a.initial&&a.initial!==a.animate||e.manuallyAnimateOnMount||(p=!1),r=!1,p?t(l):Promise.resolve()}return{animateChanges:i,setActive:function(t,r){var o;if(n[t].isActive===r)return Promise.resolve();null===(o=e.variantChildren)||void 0===o||o.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,r)})),n[t].isActive=r;const a=i(t);for(const e in n)n[e].protectedKeys={};return a},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=qK(),r=!0}}}function BK(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!MK(t,e)}function VK(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function qK(){return{animate:VK(!0),whileInView:VK(),whileHover:VK(),whileTap:VK(),whileDrag:VK(),whileFocus:VK(),exit:VK()}}class zK{constructor(e){this.isMounted=!1,this.node=e}update(){}}let HK=0;const GK={animation:{Feature:class extends zK{constructor(e){super(e),e.animationState||(e.animationState=$K(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();rq(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}},exit:{Feature:class extends zK{constructor(){super(...arguments),this.id=HK++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;const r=this.node.animationState.setActive("exit",!e);t&&!e&&r.then((()=>{t(this.id)}))}mount(){const{register:e,onExitComplete:t}=this.node.presenceContext||{};t&&t(this.id),e&&(this.unmount=e(this.id))}unmount(){}}}};function KK(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function WK(e){return{point:{x:e.pageX,y:e.pageY}}}function YK(e,t,n,r){return KK(e,t,(e=>t=>Xz(t)&&e(t,WK(t)))(n),r)}const XK=(e,t)=>Math.abs(e-t);class QK{constructor(e,t,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:o=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=eW(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=XK(e.x,t.x),r=XK(e.y,t.y);return Math.sqrt(n**2+r**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:r}=e,{timestamp:o}=zV;this.history.push({...r,timestamp:o});const{onStart:i,onMove:a}=this.handlers;t||(i&&i(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),a&&a(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=ZK(t,this.transformPagePoint),VV.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();const{onEnd:n,onSessionEnd:r,resumeAnimation:o}=this.handlers;if(this.dragSnapToOrigin&&o&&o(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const i=eW("pointercancel"===e.type?this.lastMoveEventInfo:ZK(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,i),r&&r(e,i)},!Xz(e))return;this.dragSnapToOrigin=o,this.handlers=t,this.transformPagePoint=n,this.contextWindow=r||window;const i=ZK(WK(e),this.transformPagePoint),{point:a}=i,{timestamp:s}=zV;this.history=[{...a,timestamp:s}];const{onSessionStart:l}=t;l&&l(e,eW(i,this.history)),this.removeListeners=kG(YK(this.contextWindow,"pointermove",this.handlePointerMove),YK(this.contextWindow,"pointerup",this.handlePointerUp),YK(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),qV(this.updatePoint)}}function ZK(e,t){return t?{point:t(e.point)}:e}function JK(e,t){return{x:e.x-t.x,y:e.y-t.y}}function eW({point:e},t){return{point:e,delta:JK(e,nW(t)),offset:JK(e,tW(t)),velocity:rW(t,.1)}}function tW(e){return e[0]}function nW(e){return e[e.length-1]}function rW(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=nW(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>jV(t)));)n--;if(!r)return{x:0,y:0};const i=IV(o.timestamp-r.timestamp);if(0===i)return{x:0,y:0};const a={x:(o.x-r.x)/i,y:(o.y-r.y)/i};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function oW(e){return e.max-e.min}function iW(e,t,n,r=.5){e.origin=r,e.originPoint=SG(t.min,t.max,e.origin),e.scale=oW(n)/oW(t),e.translate=SG(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function aW(e,t,n,r){iW(e.x,t.x,n.x,r?r.originX:void 0),iW(e.y,t.y,n.y,r?r.originY:void 0)}function sW(e,t,n){e.min=n.min+t.min,e.max=e.min+oW(t)}function lW(e,t,n){e.min=t.min-n.min,e.max=e.min+oW(t)}function cW(e,t,n){lW(e.x,t.x,n.x),lW(e.y,t.y,n.y)}function uW(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function dW(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}const pW=.35;function fW(e,t,n){return{min:hW(e,t),max:hW(e,n)}}function hW(e,t){return"number"==typeof e?e:e[t]||0}const mW=()=>({x:{min:0,max:0},y:{min:0,max:0}});function gW(e){return[e("x"),e("y")]}function yW({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function vW(e){return void 0===e||1===e}function bW({scale:e,scaleX:t,scaleY:n}){return!vW(e)||!vW(t)||!vW(n)}function wW(e){return bW(e)||xW(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function xW(e){return EW(e.x)||EW(e.y)}function EW(e){return e&&"0%"!==e}function _W(e,t,n){return n+t*(e-n)}function SW(e,t,n,r,o){return void 0!==o&&(e=_W(e,o,r)),_W(e,n,r)+t}function TW(e,t=0,n=1,r,o){e.min=SW(e.min,t,n,r,o),e.max=SW(e.max,t,n,r,o)}function CW(e,{x:t,y:n}){TW(e.x,t.translate,t.scale,t.originPoint),TW(e.y,n.translate,n.scale,n.originPoint)}const AW=.999999999999,OW=1.0000000000001;function NW(e,t){e.min=e.min+t,e.max=e.max+t}function RW(e,t,n,r,o=.5){TW(e,t,n,SG(e.min,e.max,o),r)}function PW(e,t){RW(e.x,t.x,t.scaleX,t.scale,t.originX),RW(e.y,t.y,t.scaleY,t.scale,t.originY)}function kW(e,t){return yW(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}const LW=({current:e})=>e?e.ownerDocument.defaultView:null,MW=new WeakMap;class DW{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic={x:{min:0,max:0},y:{min:0,max:0}},this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:r}=this.getProps();this.panSession=new QK(e,{onSessionStart:e=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(WK(e).point)},onStart:(e,t)=>{const{drag:n,dragPropagation:r,onDragStart:o}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===(i=n)||"y"===i?Hz[i]?null:(Hz[i]=!0,()=>{Hz[i]=!1}):Hz.x||Hz.y?null:(Hz.x=Hz.y=!0,()=>{Hz.x=Hz.y=!1}),!this.openDragLock))return;var i;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),gW((e=>{let t=this.getAxisMotionValue(e).get()||0;if(Uq.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[e];if(r){t=oW(r)*(parseFloat(t)/100)}}}this.originPoint[e]=t})),o&&VV.postRender((()=>o(e,t))),hH(this.visualElement,"transform");const{animationState:a}=this.visualElement;a&&a.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:o,onDrag:i}=this.getProps();if(!n&&!this.openDragLock)return;const{offset:a}=t;if(r&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(a),void(null!==this.currentDirection&&o&&o(this.currentDirection));this.updateAxis("x",t.point,a),this.updateAxis("y",t.point,a),this.visualElement.render(),i&&i(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>gW((e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:LW(this.visualElement)})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:r}=t;this.startAnimation(r);const{onDragEnd:o}=this.getProps();o&&VV.postRender((()=>o(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:r}=this.getProps();if(!n||!jW(e,r,this.currentDirection))return;const o=this.getAxisMotionValue(e);let i=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(i=function(e,{min:t,max:n},r){return void 0!==t&&e<t?e=r?SG(t,e,r.min):Math.max(e,t):void 0!==n&&e>n&&(e=r?SG(n,e,r.max):Math.min(e,n)),e}(i,this.constraints[e],this.elastic[e])),o.set(i)}resolveConstraints(){var e;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,o=this.constraints;t&&pq(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!t||!r)&&function(e,{top:t,left:n,bottom:r,right:o}){return{x:uW(e.x,n,o),y:uW(e.y,t,r)}}(r.layoutBox,t),this.elastic=function(e=pW){return!1===e?e=0:!0===e&&(e=pW),{x:fW(e,"left","right"),y:fW(e,"top","bottom")}}(n),o!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&gW((e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(r.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!pq(e))return!1;const n=e.current;LV(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const o=function(e,t,n){const r=kW(e,n),{scroll:o}=t;return o&&(NW(r.x,o.offset.x),NW(r.y,o.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let i=function(e,t){return{x:dW(e.x,t.x),y:dW(e.y,t.y)}}(r.layout.layoutBox,o);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(i));this.hasMutatedConstraints=!!e,e&&(i=yW(e))}return i}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:r,dragTransition:o,dragSnapToOrigin:i,onDragTransitionEnd:a}=this.getProps(),s=this.constraints||{},l=gW((a=>{if(!jW(a,t,this.currentDirection))return;let l=s&&s[a]||{};i&&(l={min:0,max:0});const c={type:"inertia",velocity:n?e[a]:0,bounceStiffness:r?200:1e6,bounceDamping:r?40:1e7,timeConstant:750,restDelta:1,restSpeed:10,...o,...l};return this.startAxisValueAnimation(a,c)}));return Promise.all(l).then(a)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return hH(this.visualElement,e),n.start(NK(e,n,0,t,this.visualElement,!1))}stopAnimation(){gW((e=>this.getAxisMotionValue(e).stop()))}pauseAnimation(){gW((e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()}))}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){const t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps(),r=n[t];return r||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){gW((t=>{const{drag:n}=this.getProps();if(!jW(t,n,this.currentDirection))return;const{projection:r}=this.visualElement,o=this.getAxisMotionValue(t);if(r&&r.layout){const{min:n,max:i}=r.layout.layoutBox[t];o.set(e[t]-SG(n,i,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!pq(t)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};gW((e=>{const t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){const n=t.get();r[e]=function(e,t){let n=.5;const r=oW(e),o=oW(t);return o>r?n=DV(t.min,t.max-r,e.min):r>o&&(n=DV(e.min,e.max-o,t.min)),Lq(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),gW((t=>{if(!jW(t,e,null))return;const n=this.getAxisMotionValue(t),{min:o,max:i}=this.constraints[t];n.set(SG(o,i,r[t]))}))}addListeners(){if(!this.visualElement.current)return;MW.set(this.visualElement,this);const e=YK(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();pq(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),VV.read(t);const o=KK(window,"resize",(()=>this.scalePositionWithinConstraints())),i=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(gW((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{o(),e(),r(),i&&i()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:o=!1,dragElastic:i=pW,dragMomentum:a=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:o,dragElastic:i,dragMomentum:a}}}function jW(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const IW=e=>(t,n)=>{e&&VV.postRender((()=>e(t,n)))};const FW={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function UW(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const $W={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!$q.test(e))return e;e=parseFloat(e)}return`${UW(e,t.target.x)}% ${UW(e,t.target.y)}%`}},BW={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=GH.parse(e);if(o.length>5)return r;const i=GH.createTransformer(e),a="number"!=typeof o[0]?1:0,s=n.x.scale*t.x,l=n.y.scale*t.y;o[0+a]/=s,o[1+a]/=l;const c=SG(s,l,.5);return"number"==typeof o[2+a]&&(o[2+a]/=c),"number"==typeof o[3+a]&&(o[3+a]/=c),i(o)}};class VW extends n.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:o}=e;!function(e){for(const t in e)Aq[t]=e[t],_q(t)&&(Aq[t].isCSSVariable=!0)}(zW),o&&(t.group&&t.group.add(o),n&&n.register&&r&&n.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",(()=>{this.safeToRemove()})),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),FW.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:r,isPresent:o}=this.props,i=n.projection;return i?(i.isPresent=o,r||e.layoutDependency!==t||void 0===t?i.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?i.promote():i.relegate()||VV.postRender((()=>{const e=i.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),gq.postRender((()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function qW(e){const[r,o]=TV(),i=n.useContext(yV);return t.jsx(VW,{...e,layoutGroup:i,switchLayoutGroup:n.useContext(yq),isPresent:r,safeToRemove:o})}const zW={borderRadius:{...$W,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:$W,borderTopRightRadius:$W,borderBottomLeftRadius:$W,borderBottomRightRadius:$W,boxShadow:BW};const HW=(e,t)=>e.depth-t.depth;class GW{constructor(){this.children=[],this.isDirty=!1}add(e){sH(this.children,e),this.isDirty=!0}remove(e){lH(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(HW),this.isDirty=!1,this.children.forEach(e)}}const KW=["TopLeft","TopRight","BottomLeft","BottomRight"],WW=KW.length,YW=e=>"string"==typeof e?parseFloat(e):e,XW=e=>"number"==typeof e||$q.test(e);function QW(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const ZW=eY(0,.5,TH),JW=eY(.5,.95,PV);function eY(e,t,n){return r=>r<e?0:r>t?1:n(DV(e,t,r))}function tY(e,t){e.min=t.min,e.max=t.max}function nY(e,t){tY(e.x,t.x),tY(e.y,t.y)}function rY(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function oY(e,t,n,r,o){return e=_W(e-=t,1/n,r),void 0!==o&&(e=_W(e,1/o,r)),e}function iY(e,t,[n,r,o],i,a){!function(e,t=0,n=1,r=.5,o,i=e,a=e){Uq.test(t)&&(t=parseFloat(t),t=SG(a.min,a.max,t/100)-a.min);if("number"!=typeof t)return;let s=SG(i.min,i.max,r);e===i&&(s-=t),e.min=oY(e.min,t,n,s,o),e.max=oY(e.max,t,n,s,o)}(e,t[n],t[r],t[o],t.scale,i,a)}const aY=["x","scaleX","originX"],sY=["y","scaleY","originY"];function lY(e,t,n,r){iY(e.x,t,aY,n?n.x:void 0,r?r.x:void 0),iY(e.y,t,sY,n?n.y:void 0,r?r.y:void 0)}function cY(e){return 0===e.translate&&1===e.scale}function uY(e){return cY(e.x)&&cY(e.y)}function dY(e,t){return e.min===t.min&&e.max===t.max}function pY(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function fY(e,t){return pY(e.x,t.x)&&pY(e.y,t.y)}function hY(e){return oW(e.x)/oW(e.y)}function mY(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class gY{constructor(){this.members=[]}add(e){sH(this.members,e),e.scheduleRender()}remove(e){if(lH(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let r=t;r>=0;r--){const e=this.members[r];if(!1!==e.isPresent){n=e;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const yY=["","X","Y","Z"],vY={visibility:"hidden"};let bY=0;function wY(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function xY(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=mH(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",VV,!(t||r))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&xY(r)}function EY({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(e={},n=(null==t?void 0:t())){this.id=bY++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(TY),this.nodes.forEach(kY),this.nodes.forEach(LY),this.nodes.forEach(CY)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let t=0;t<this.path.length;t++)this.path[t].shouldResetTransform=!0;this.root===this&&(this.nodes=new GW)}addEventListener(e,t){return this.eventHandlers.has(e)||this.eventHandlers.set(e,new cH),this.eventHandlers.get(e).add(t)}notifyListeners(e,...t){const n=this.eventHandlers.get(e);n&&n.notify(...t)}hasListeners(e){return this.eventHandlers.has(e)}mount(t,n=this.root.hasTreeAnimated){if(this.instance)return;var r;this.isSVG=(r=t)instanceof SVGElement&&"svg"!==r.tagName,this.instance=t;const{layoutId:o,layout:i,visualElement:a}=this.options;if(a&&!a.current&&a.mount(t),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),n&&(i||o)&&(this.isLayoutDirty=!0),e){let n;const r=()=>this.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=aH.now(),r=({timestamp:o})=>{const i=o-n;i>=t&&(qV(r),e(i-t))};return VV.read(r,!0),()=>qV(r)}(r,250),FW.hasAnimatedSinceResize&&(FW.hasAnimatedSinceResize=!1,this.nodes.forEach(PY))}))}o&&this.root.registerSharedNode(o,this),!1!==this.options.animate&&a&&(o||i)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeLayoutChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const o=this.options.transition||a.getDefaultTransition()||UY,{onLayoutAnimationStart:i,onLayoutAnimationComplete:s}=a.getProps(),l=!this.targetLayout||!fY(this.targetLayout,r),c=!t&&n;if(this.options.layoutRoot||this.resumeFrom||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...Pz(o,"layout"),onPlay:i,onComplete:s};(a.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||PY(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,qV(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(MY),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&xY(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let o=0;o<this.path.length;o++){const e=this.path[o];e.shouldResetTransform=!0,e.updateScroll("snapshot"),e.options.layoutRoot&&e.willUpdate(!1)}const{layoutId:t,layout:n}=this.options;if(void 0===t&&!n)return;const r=this.getTransformTemplate();this.prevTransformTemplateValue=r?r(this.latestValues,""):void 0,this.updateSnapshot(),e&&this.notifyListeners("willUpdate")}update(){this.updateScheduled=!1;if(this.isUpdateBlocked())return this.unblockUpdate(),this.clearAllSnapshots(),void this.nodes.forEach(OY);this.isUpdating||this.nodes.forEach(NY),this.isUpdating=!1,this.nodes.forEach(RY),this.nodes.forEach(_Y),this.nodes.forEach(SY),this.clearAllSnapshots();const e=aH.now();zV.delta=Lq(0,1e3/60,e-zV.timestamp),zV.timestamp=e,zV.isProcessing=!0,HV.update.process(zV),HV.preRender.process(zV),HV.render.process(zV),zV.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,gq.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(AY),this.sharedNodes.forEach(DY)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,VV.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){VV.postRender((()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure(),!this.snapshot||oW(this.snapshot.measuredBox.x)||oW(this.snapshot.measuredBox.y)||(this.snapshot=void 0))}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let n=0;n<this.path.length;n++){this.path[n].updateScroll()}const e=this.layout;this.layout=this.measure(!1),this.layoutCorrected={x:{min:0,max:0},y:{min:0,max:0}},this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:t}=this.options;t&&t.notify("LayoutMeasure",this.layout.layoutBox,e?e.layoutBox:void 0)}updateScroll(e="measure"){let t=Boolean(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===e&&(t=!1),t){const t=r(this.instance);this.scroll={animationId:this.root.animationId,phase:e,isRoot:t,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:t}}}resetTransform(){if(!o)return;const e=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,t=this.projectionDelta&&!uY(this.projectionDelta),n=this.getTransformTemplate(),r=n?n(this.latestValues,""):void 0,i=r!==this.prevTransformTemplateValue;e&&(t||wW(this.latestValues)||i)&&(o(this.instance,r),this.shouldResetTransform=!1,this.scheduleRender())}measure(e=!0){const t=this.measurePageBox();let n=this.removeElementScroll(t);var r;return e&&(n=this.removeTransform(n)),VY((r=n).x),VY(r.y),{animationId:this.root.animationId,measuredBox:t,layoutBox:n,latestValues:{},source:this.id}}measurePageBox(){var e;const{visualElement:t}=this.options;if(!t)return{x:{min:0,max:0},y:{min:0,max:0}};const n=t.measureViewportBox();if(!((null===(e=this.scroll)||void 0===e?void 0:e.wasRoot)||this.path.some(zY))){const{scroll:e}=this.root;e&&(NW(n.x,e.offset.x),NW(n.y,e.offset.y))}return n}removeElementScroll(e){var t;const n={x:{min:0,max:0},y:{min:0,max:0}};if(nY(n,e),null===(t=this.scroll)||void 0===t?void 0:t.wasRoot)return n;for(let r=0;r<this.path.length;r++){const t=this.path[r],{scroll:o,options:i}=t;t!==this.root&&o&&i.layoutScroll&&(o.wasRoot&&nY(n,e),NW(n.x,o.offset.x),NW(n.y,o.offset.y))}return n}applyTransform(e,t=!1){const n={x:{min:0,max:0},y:{min:0,max:0}};nY(n,e);for(let r=0;r<this.path.length;r++){const e=this.path[r];!t&&e.options.layoutScroll&&e.scroll&&e!==e.root&&PW(n,{x:-e.scroll.offset.x,y:-e.scroll.offset.y}),wW(e.latestValues)&&PW(n,e.latestValues)}return wW(this.latestValues)&&PW(n,this.latestValues),n}removeTransform(e){const t={x:{min:0,max:0},y:{min:0,max:0}};nY(t,e);for(let n=0;n<this.path.length;n++){const e=this.path[n];if(!e.instance)continue;if(!wW(e.latestValues))continue;bW(e.latestValues)&&e.updateSnapshot();const r={x:{min:0,max:0},y:{min:0,max:0}};nY(r,e.measurePageBox()),lY(t,e.latestValues,e.snapshot?e.snapshot.layoutBox:void 0,r)}return wW(this.latestValues)&&lY(t,this.latestValues),t}setTargetDelta(e){this.targetDelta=e,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(e){this.options={...this.options,...e,crossfade:void 0===e.crossfade||e.crossfade}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==zV.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(e=!1){var t;const n=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=n.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=n.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=n.isSharedProjectionDirty);const r=Boolean(this.resumingFrom)||this!==n;if(!(e||r&&this.isSharedProjectionDirty||this.isProjectionDirty||(null===(t=this.parent)||void 0===t?void 0:t.isProjectionDirty)||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:o,layoutId:i}=this.options;if(this.layout&&(o||i)){if(this.resolvedRelativeTargetAt=zV.timestamp,!this.targetDelta&&!this.relativeTarget){const e=this.getClosestProjectingParent();e&&e.layout&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},cW(this.relativeTargetOrigin,this.layout.layoutBox,e.layout.layoutBox),nY(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}var a,s,l;if(this.relativeTarget||this.targetDelta)if(this.target||(this.target={x:{min:0,max:0},y:{min:0,max:0}},this.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}}),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),sW((a=this.target).x,(s=this.relativeTarget).x,(l=this.relativeParent.target).x),sW(a.y,s.y,l.y)):this.targetDelta?(Boolean(this.resumingFrom)?this.target=this.applyTransform(this.layout.layoutBox):nY(this.target,this.layout.layoutBox),CW(this.target,this.targetDelta)):nY(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget){this.attemptToResolveRelativeTarget=!1;const e=this.getClosestProjectingParent();e&&Boolean(e.resumingFrom)===Boolean(this.resumingFrom)&&!e.options.layoutScroll&&e.target&&1!==this.animationProgress?(this.relativeParent=e,this.forceRelativeParentToResolveTarget(),this.relativeTarget={x:{min:0,max:0},y:{min:0,max:0}},this.relativeTargetOrigin={x:{min:0,max:0},y:{min:0,max:0}},cW(this.relativeTargetOrigin,this.target,e.target),nY(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}}}getClosestProjectingParent(){if(this.parent&&!bW(this.parent.latestValues)&&!xW(this.parent.latestValues))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return Boolean((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){var e;const t=this.getLead(),n=Boolean(this.resumingFrom)||this!==t;let r=!0;if((this.isProjectionDirty||(null===(e=this.parent)||void 0===e?void 0:e.isProjectionDirty))&&(r=!1),n&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(r=!1),this.resolvedRelativeTargetAt===zV.timestamp&&(r=!1),r)return;const{layout:o,layoutId:i}=this.options;if(this.isTreeAnimating=Boolean(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!o&&!i)return;nY(this.layoutCorrected,this.layout.layoutBox);const a=this.treeScale.x,s=this.treeScale.y;!function(e,t,n,r=!1){const o=n.length;if(!o)return;let i,a;t.x=t.y=1;for(let s=0;s<o;s++){i=n[s],a=i.projectionDelta;const{visualElement:o}=i.options;o&&o.props.style&&"contents"===o.props.style.display||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&PW(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,CW(e,a)),r&&wW(i.latestValues)&&PW(e,i.latestValues))}t.x<OW&&t.x>AW&&(t.x=1),t.y<OW&&t.y>AW&&(t.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!t.layout||t.target||1===this.treeScale.x&&1===this.treeScale.y||(t.target=t.layout.layoutBox,t.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}});const{target:l}=t;l?(this.projectionDelta&&this.prevProjectionDelta?(rY(this.prevProjectionDelta.x,this.projectionDelta.x),rY(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),aW(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===a&&this.treeScale.y===s&&mY(this.projectionDelta.x,this.prevProjectionDelta.x)&&mY(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l))):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDeltaWithTransform={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}}setAnimationOrigin(e,t=!1){const n=this.snapshot,r=n?n.latestValues:{},o={...this.latestValues},i={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const a={x:{min:0,max:0},y:{min:0,max:0}},s=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(s&&!c&&!0===this.options.crossfade&&!this.path.some(FY));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;var l,p,f,h,m,g;jY(i.x,e.x,n),jY(i.y,e.y,n),this.setTargetDelta(i),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(cW(a,this.layout.layoutBox,this.relativeParent.layout.layoutBox),IY((f=this.relativeTarget).x,(h=this.relativeTargetOrigin).x,(m=a).x,g=n),IY(f.y,h.y,m.y,g),d&&(dY((l=this.relativeTarget).x,(p=d).x)&&dY(l.y,p.y))&&(this.isProjectionDirty=!1),d||(d={x:{min:0,max:0},y:{min:0,max:0}}),nY(d,this.relativeTarget)),s&&(this.animationValues=o,function(e,t,n,r,o,i){o?(e.opacity=SG(0,void 0!==n.opacity?n.opacity:1,ZW(r)),e.opacityExit=SG(void 0!==t.opacity?t.opacity:1,0,JW(r))):i&&(e.opacity=SG(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let a=0;a<WW;a++){const o=`border${KW[a]}Radius`;let i=QW(t,o),s=QW(n,o);void 0===i&&void 0===s||(i||(i=0),s||(s=0),0===i||0===s||XW(i)===XW(s)?(e[o]=Math.max(SG(YW(i),YW(s),r),0),(Uq.test(s)||Uq.test(i))&&(e[o]+="%")):e[o]=s)}(t.rotate||n.rotate)&&(e.rotate=SG(t.rotate||0,n.rotate||0,r))}(o,r,this.latestValues,n,u,c)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=n},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(e){this.notifyListeners("animationStart"),this.currentAnimation&&this.currentAnimation.stop(),this.resumingFrom&&this.resumingFrom.currentAnimation&&this.resumingFrom.currentAnimation.stop(),this.pendingAnimation&&(qV(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=VV.update((()=>{FW.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const r=Pq(e)?e:pH(e);return r.start(NK("",r,t,n)),r.animation}(0,1e3,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onStop:()=>{},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:r,latestValues:o}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&qY(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||{x:{min:0,max:0},y:{min:0,max:0}};const t=oW(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const r=oW(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}nY(t,n),PW(t,o),aW(this.projectionDeltaWithTransform,this.layoutCorrected,t,o)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new gY);this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;const r={};n.z&&wY("z",e,r,this.animationValues);for(let o=0;o<yY.length;o++)wY(`rotate${yY[o]}`,e,r,this.animationValues),wY(`skew${yY[o]}`,e,r,this.animationValues);e.render();for(const o in r)e.setStaticValue(o,r[o]),this.animationValues&&(this.animationValues[o]=r[o]);e.scheduleRender()}getProjectionStyles(e){var t,n;if(!this.instance||this.isSVG)return;if(!this.isVisible)return vY;const r={visibility:""},o=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,r.opacity="",r.pointerEvents=hz(null==e?void 0:e.pointerEvents)||"",r.transform=o?o(this.latestValues,""):"none",r;const i=this.getLead();if(!this.projectionDelta||!this.layout||!i.target){const t={};return this.options.layoutId&&(t.opacity=void 0!==this.latestValues.opacity?this.latestValues.opacity:1,t.pointerEvents=hz(null==e?void 0:e.pointerEvents)||""),this.hasProjected&&!wW(this.latestValues)&&(t.transform=o?o({},""):"none",this.hasProjected=!1),t}const a=i.animationValues||i.latestValues;this.applyTransformsToTarget(),r.transform=function(e,t,n){let r="";const o=e.x.translate/t.x,i=e.y.translate/t.y,a=(null==n?void 0:n.z)||0;if((o||i||a)&&(r=`translate3d(${o}px, ${i}px, ${a}px) `),1===t.x&&1===t.y||(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:e,rotate:t,rotateX:o,rotateY:i,skewX:a,skewY:s}=n;e&&(r=`perspective(${e}px) ${r}`),t&&(r+=`rotate(${t}deg) `),o&&(r+=`rotateX(${o}deg) `),i&&(r+=`rotateY(${i}deg) `),a&&(r+=`skewX(${a}deg) `),s&&(r+=`skewY(${s}deg) `)}const s=e.x.scale*t.x,l=e.y.scale*t.y;return 1===s&&1===l||(r+=`scale(${s}, ${l})`),r||"none"}(this.projectionDeltaWithTransform,this.treeScale,a),o&&(r.transform=o(a,r.transform));const{x:s,y:l}=this.projectionDelta;r.transformOrigin=`${100*s.origin}% ${100*l.origin}% 0`,r.opacity=i.animationValues?i===this?null!==(n=null!==(t=a.opacity)&&void 0!==t?t:this.latestValues.opacity)&&void 0!==n?n:1:this.preserveOpacity?this.latestValues.opacity:a.opacityExit:i===this?void 0!==a.opacity?a.opacity:"":void 0!==a.opacityExit?a.opacityExit:0;for(const c in Aq){if(void 0===a[c])continue;const{correct:e,applyTo:t,isCSSVariable:n}=Aq[c],o="none"===r.transform?a[c]:e(a[c],i);if(t){const e=t.length;for(let n=0;n<e;n++)r[t[n]]=o}else n?this.options.visualElement.renderState.vars[c]=o:r[c]=o}return this.options.layoutId&&(r.pointerEvents=i===this?hz(null==e?void 0:e.pointerEvents)||"":"none"),r}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach((e=>{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(OY),this.root.sharedNodes.clear()}}}function _Y(e){e.updateLayout()}function SY(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:r}=e.layout,{animationType:o}=e.options,i=n.source!==e.layout.source;"size"===o?gW((e=>{const r=i?n.measuredBox[e]:n.layoutBox[e],o=oW(r);r.min=t[e].min,r.max=r.min+o})):qY(o,n.layoutBox,t)&&gW((r=>{const o=i?n.measuredBox[r]:n.layoutBox[r],a=oW(t[r]);o.max=o.min+a,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+a)}));const a={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};aW(a,t,n.layoutBox);const s={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};i?aW(s,e.applyTransform(r,!0),n.measuredBox):aW(s,t,n.layoutBox);const l=!uY(a);let c=!1;if(!e.resumeFrom){const r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:o,layout:i}=r;if(o&&i){const a={x:{min:0,max:0},y:{min:0,max:0}};cW(a,n.layoutBox,o.layoutBox);const s={x:{min:0,max:0},y:{min:0,max:0}};cW(s,t,i.layoutBox),fY(a,s)||(c=!0),r.options.layoutRoot&&(e.relativeTarget=s,e.relativeTargetOrigin=a,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:s,layoutDelta:a,hasLayoutChanged:l,hasRelativeLayoutChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function TY(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function CY(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function AY(e){e.clearSnapshot()}function OY(e){e.clearMeasurements()}function NY(e){e.isLayoutDirty=!1}function RY(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function PY(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function kY(e){e.resolveTargetDelta()}function LY(e){e.calcProjection()}function MY(e){e.resetSkewAndRotation()}function DY(e){e.removeLeadSnapshot()}function jY(e,t,n){e.translate=SG(t.translate,0,n),e.scale=SG(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function IY(e,t,n,r){e.min=SG(t.min,n.min,r),e.max=SG(t.max,n.max,r)}function FY(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const UY={duration:.45,ease:[.4,0,.1,1]},$Y=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),BY=$Y("applewebkit/")&&!$Y("chrome/")?Math.round:PV;function VY(e){e.min=BY(e.min),e.max=BY(e.max)}function qY(e,t,n){return"position"===e||"preserve-aspect"===e&&(r=hY(t),o=hY(n),i=.2,!(Math.abs(r-o)<=i));var r,o,i}function zY(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}const HY=EY({attachResizeListener:(e,t)=>KK(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),GY={current:void 0},KY=EY({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!GY.current){const e=new HY({});e.mount(window),e.setOptions({layoutScroll:!0}),GY.current=e}return GY.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),WY={pan:{Feature:class extends zK{constructor(){super(...arguments),this.removePointerDownListener=PV}onPointerDown(e){this.session=new QK(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:LW(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:IW(e),onStart:IW(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&VV.postRender((()=>r(e,t)))}}}mount(){this.removePointerDownListener=YK(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends zK{constructor(e){super(e),this.removeGroupControls=PV,this.removeListeners=PV,this.controls=new DW(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||PV}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:KY,MeasureLayout:qW}};function YY(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover","Start"===n);const o=r["onHover"+n];o&&VV.postRender((()=>o(t,WK(t))))}function XY(e,t,n){const{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap","Start"===n);const o=r["onTap"+("End"===n?"":n)];o&&VV.postRender((()=>o(t,WK(t))))}const QY=new WeakMap,ZY=new WeakMap,JY=e=>{const t=QY.get(e.target);t&&t(e)},eX=e=>{e.forEach(JY)};function tX(e,t,n){const r=function({root:e,...t}){const n=e||document;ZY.has(n)||ZY.set(n,{});const r=ZY.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(eX,{root:e,...t})),r[o]}(t);return QY.set(e,n),r.observe(e),()=>{QY.delete(e),r.unobserve(e)}}const nX={some:0,all:1};const rX={inView:{Feature:class extends zK{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:o}=e;return tX(this.node.current,{root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:nX[r]},(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,o&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),i=t?n:r;i&&i(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends zK{mount(){const{current:e}=this.node;e&&(this.unmount=nH(e,((e,t)=>(XY(this.node,t,"Start"),(e,{success:t})=>XY(this.node,e,t?"End":"Cancel"))),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends zK{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(tme){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=kG(KK(this.node.current,"focus",(()=>this.onFocus())),KK(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends zK{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[r,o,i]=Kz(e,n),a=e=>{if(!Wz(e))return;const{target:n}=e,r=t(n,e);if("function"!=typeof r||!n)return;const i=e=>{Wz(e)&&(r(e),n.removeEventListener("pointerleave",i))};n.addEventListener("pointerleave",i,o)};return r.forEach((e=>{e.addEventListener("pointerenter",a,o)})),i}(e,((e,t)=>(YY(this.node,t,"Start"),e=>YY(this.node,e,"End")))))}unmount(){}}}},oX={layout:{ProjectionNode:KY,MeasureLayout:qW}},iX={current:null},aX={current:!1};const sX=[...yG,IH,GH],lX=new WeakMap;const cX=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class uX{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:o,visualState:i},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=pG,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const e=aH.now();this.renderScheduledAt<e&&(this.renderScheduledAt=e,VV.render(this.render,!1,!0))};const{latestValues:s,renderState:l,onUpdate:c}=i;this.onUpdate=c,this.latestValues=s,this.baseTarget={...s},this.initialValues=t.initial?{...s}:{},this.renderState=l,this.parent=e,this.props=t,this.presenceContext=n,this.depth=e?e.depth+1:0,this.reducedMotionConfig=r,this.options=a,this.blockInitialAnimation=Boolean(o),this.isControllingVariants=sq(t),this.isVariantNode=lq(t),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=Boolean(e&&e.current);const{willChange:u,...d}=this.scrapeMotionValuesFromProps(t,{},this);for(const p in d){const e=d[p];void 0!==s[p]&&Pq(e)&&e.set(s[p],!1)}}mount(e){this.current=e,lX.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach(((e,t)=>this.bindToMotionValue(t,e))),aX.current||function(){if(aX.current=!0,OV)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>iX.current=e.matches;e.addListener(t),t()}else iX.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||iX.current),"production"!==process.env.NODE_ENV&&eq(!0!==this.shouldReduceMotion,"You have Reduced Motion enabled on your device. Animations may not appear as expected."),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),qV(this.notifyUpdate),qV(this.render),this.valueSubscriptions.forEach((e=>e())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const n=Nq.has(e);n&&this.onBindTransform&&this.onBindTransform();const r=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&VV.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),o=t.on("renderRequest",this.scheduleRender);let i;window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,(()=>{r(),o(),i&&i(),t.owner&&t.stop()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in WV){const t=WV[e];if(!t)continue;const{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){const t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let n=0;n<cX.length;n++){const t=cX[n];this.propEventSubscriptions[t]&&(this.propEventSubscriptions[t](),delete this.propEventSubscriptions[t]);const r=e["on"+t];r&&(this.propEventSubscriptions[t]=this.on(t,r))}this.prevMotionValues=function(e,t,n){for(const r in t){const o=t[r],i=n[r];if(Pq(o))e.addValue(r,o),"development"===process.env.NODE_ENV&&eq("12.4.0"===o.version,`Attempting to mix Motion versions ${o.version} with 12.4.0 may not work as expected.`);else if(Pq(i))e.addValue(r,pH(o,{owner:e}));else if(i!==o)if(e.hasValue(r)){const t=e.getValue(r);!0===t.liveStyle?t.jump(o):t.hasAnimated||t.set(o)}else{const t=e.getStaticValue(r);e.addValue(r,pH(void 0!==t?t:o,{owner:e}))}}for(const r in n)void 0===t[r]&&e.removeValue(r);return t}(this,this.scrapeMotionValuesFromProps(e,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue(),this.onUpdate&&this.onUpdate(this)}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){const t=this.getClosestVariantNode();if(t)return t.variantChildren&&t.variantChildren.add(e),()=>t.variantChildren.delete(e)}addValue(e,t){const n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=pH(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let r=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];return null!=r&&("string"==typeof r&&(fG(r)||AH(r))?r=parseFloat(r):!sX.find(gG(r))&&GH.test(t)&&(r=JH(e,t)),this.setBaseTarget(e,Pq(r)?r.get():r)),Pq(r)?r.get():r}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props;let r;if("string"==typeof n||"object"==typeof n){const o=pz(this.props,n,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);o&&(r=o[e])}if(n&&void 0!==r)return r;const o=this.getBaseTargetFromProps(this.props,e);return void 0===o||Pq(o)?void 0!==this.initialValues[e]&&void 0===r?void 0:this.baseTarget[e]:o}on(e,t){return this.events[e]||(this.events[e]=new cH),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class dX extends uX{constructor(){super(...arguments),this.KeyframeResolver=bG}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;Pq(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}}class pX extends dX{constructor(){super(...arguments),this.type="html",this.renderInstance=wz}readValueFromInstance(e,t){if(Nq.has(t)){const e=ZH(t);return e&&e.default||0}{const n=window.getComputedStyle(e),r=(_q(t)?n.getPropertyValue(t):n[t])||0;return"string"==typeof r?r.trim():r}}measureInstanceViewportBox(e,{transformPagePoint:t}){return kW(e,t)}build(e,t,n){Xq(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return yz(e,t,n)}}class fX extends dX{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=mW,this.updateDimensions=()=>{this.current&&!this.renderState.dimensions&&bz(this.current,this.renderState)}}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(Nq.has(t)){const e=ZH(t);return e&&e.default||0}return t=xz.has(t)?t:hq(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return _z(e,t,n)}onBindTransform(){this.current&&!this.renderState.dimensions&&VV.postRender(this.updateDimensions)}build(e,t,n){az(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,r){Ez(e,t,0,r)}mount(e){this.isSVGTag=lz(e.tagName),super.mount(e)}}const hX=tq(Cz({...GK,...rX,...WY,...oX},((e,t)=>nz(e)?new fX(t):new pX(t,{allowProjection:e!==n.Fragment})))),mX="0123456789abcdef";class gX{constructor(e){this.bytes=e}static ofInner(e){if(16!==e.length)throw new TypeError("not 128-bit length");return new gX(e)}static fromFieldsV7(e,t,n,r){if(!Number.isInteger(e)||!Number.isInteger(t)||!Number.isInteger(n)||!Number.isInteger(r)||e<0||t<0||n<0||r<0||e>0xffffffffffff||t>4095||n>1073741823||r>4294967295)throw new RangeError("invalid field value");const o=new Uint8Array(16);return o[0]=e/2**40,o[1]=e/2**32,o[2]=e/2**24,o[3]=e/65536,o[4]=e/256,o[5]=e,o[6]=112|t>>>8,o[7]=t,o[8]=128|n>>>24,o[9]=n>>>16,o[10]=n>>>8,o[11]=n,o[12]=r>>>24,o[13]=r>>>16,o[14]=r>>>8,o[15]=r,new gX(o)}static parse(e){var t,n,r,o;let i;switch(e.length){case 32:i=null===(t=/^[0-9a-f]{32}$/i.exec(e))||void 0===t?void 0:t[0];break;case 36:i=null===(n=/^([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})$/i.exec(e))||void 0===n?void 0:n.slice(1,6).join("");break;case 38:i=null===(r=/^\{([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})\}$/i.exec(e))||void 0===r?void 0:r.slice(1,6).join("");break;case 45:i=null===(o=/^urn:uuid:([0-9a-f]{8})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{4})-([0-9a-f]{12})$/i.exec(e))||void 0===o?void 0:o.slice(1,6).join("")}if(i){const e=new Uint8Array(16);for(let t=0;t<16;t+=4){const n=parseInt(i.substring(2*t,2*t+8),16);e[t+0]=n>>>24,e[t+1]=n>>>16,e[t+2]=n>>>8,e[t+3]=n}return new gX(e)}throw new SyntaxError("could not parse UUID string")}toString(){let e="";for(let t=0;t<this.bytes.length;t++)e+=mX.charAt(this.bytes[t]>>>4),e+=mX.charAt(15&this.bytes[t]),3!==t&&5!==t&&7!==t&&9!==t||(e+="-");return e}toHex(){let e="";for(let t=0;t<this.bytes.length;t++)e+=mX.charAt(this.bytes[t]>>>4),e+=mX.charAt(15&this.bytes[t]);return e}toJSON(){return this.toString()}getVariant(){const e=this.bytes[8]>>>4;if(e<0)throw new Error("unreachable");if(e<=7)return this.bytes.every((e=>0===e))?"NIL":"VAR_0";if(e<=11)return"VAR_10";if(e<=13)return"VAR_110";if(e<=15)return this.bytes.every((e=>255===e))?"MAX":"VAR_RESERVED";throw new Error("unreachable")}getVersion(){return"VAR_10"===this.getVariant()?this.bytes[6]>>>4:void 0}clone(){return new gX(this.bytes.slice(0))}equals(e){return 0===this.compareTo(e)}compareTo(e){for(let t=0;t<16;t++){const n=this.bytes[t]-e.bytes[t];if(0!==n)return Math.sign(n)}return 0}}class yX{constructor(e){this.timestamp=0,this.counter=0,this.random=null!=e?e:vX()}generate(){return this.generateOrResetCore(Date.now(),1e4)}generateOrAbort(){return this.generateOrAbortCore(Date.now(),1e4)}generateOrResetCore(e,t){let n=this.generateOrAbortCore(e,t);return void 0===n&&(this.timestamp=0,n=this.generateOrAbortCore(e,t)),n}generateOrAbortCore(e,t){if(!Number.isInteger(e)||e<1||e>0xffffffffffff)throw new RangeError("`unixTsMs` must be a 48-bit positive integer");if(t<0||t>0xffffffffffff)throw new RangeError("`rollbackAllowance` out of reasonable range");if(e>this.timestamp)this.timestamp=e,this.resetCounter();else{if(!(e+t>=this.timestamp))return;this.counter++,this.counter>4398046511103&&(this.timestamp++,this.resetCounter())}return gX.fromFieldsV7(this.timestamp,Math.trunc(this.counter/2**30),this.counter&2**30-1,this.random.nextUint32())}resetCounter(){this.counter=1024*this.random.nextUint32()+(1023&this.random.nextUint32())}generateV4(){const e=new Uint8Array(Uint32Array.of(this.random.nextUint32(),this.random.nextUint32(),this.random.nextUint32(),this.random.nextUint32()).buffer);return e[6]=64|e[6]>>>4,e[8]=128|e[8]>>>2,gX.ofInner(e)}}const vX=()=>{if("undefined"!=typeof crypto&&void 0!==crypto.getRandomValues)return new bX;if("undefined"!=typeof UUIDV7_DENY_WEAK_RNG&&UUIDV7_DENY_WEAK_RNG)throw new Error("no cryptographically strong RNG available");return{nextUint32:()=>65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random())}};class bX{constructor(){this.buffer=new Uint32Array(8),this.cursor=65535}nextUint32(){return this.cursor>=this.buffer.length&&(crypto.getRandomValues(this.buffer),this.cursor=0),this.buffer[this.cursor++]}}let wX;const xX=()=>(wX||(wX=new yX)).generate();const EX={all:["stripo"],token:()=>[...EX.all,"token"],editorData:()=>[...EX.all,"editorData"],templates:()=>[...EX.all,"templates"],demoTemplate:()=>[...EX.templates(),"demo"]},_X=async()=>(await Ae(`${p}/editor-data`)).data,SX=e=>ge({queryKey:["stripo","templates",e],queryFn:()=>(async e=>(await Ae(`${p}/template/${e}`)).data)(e),...xe}),TX=({text:e,textSpeed:r=2e3,textColor:o="text-muted-foreground"})=>{const[i,a]=n.useState(0),s=Array.isArray(e)?e:e?[e]:[];return n.useEffect((()=>{if(s.length<=1)return;if(i>=s.length-1)return;const e=setInterval((()=>{a((e=>e<s.length-1?e+1:e))}),r);return()=>clearInterval(e)}),[s.length,r,i]),t.jsxs("div",{className:"flex flex-col items-center justify-center gap-3 @container",children:[t.jsxs("div",{className:"relative h-8 w-8",children:[t.jsx("div",{className:"absolute inset-0 rounded-full border-2 border-primary/20"}),t.jsx("div",{className:"absolute inset-0 animate-spin rounded-full border-2 border-primary border-t-transparent"})]}),s.length>0&&t.jsx("div",{className:`text-center text-sm ${o} animate-fade-in min-w-[200px] max-w-[300px] px-4`,children:t.jsx("div",{className:"break-words",children:s[i]})},i),t.jsx("style",{children:"\n .animate-fade-in {\n animation: fadeIn 0.5s ease-in-out;\n }\n @keyframes fadeIn {\n from {\n opacity: 0;\n transform: translateY(5px);\n }\n to {\n opacity: 1;\n transform: translateY(0);\n }\n }\n "})]})},CX=({children:e,className:n})=>t.jsx(hX.div,{initial:{opacity:0,filter:"blur(8px)"},animate:{opacity:1,filter:"blur(0px)"},exit:{opacity:0,filter:"blur(8px)"},transition:{duration:.3,ease:"easeInOut"},className:n,children:e}),AX={CloseButton:Yu,DropdownMenuTrigger:lu,UserIcon:Gu,UsersIcon:Ku,UserEdit:zu,ScheduleButton:au,SendButton:Iu,BackButton:cu,NextButton:uu,MergeField:Hu,PlusIcon:Mu,AlertCircleIcon:fu,OneTimeBroadcast:Nu,PatronEntersList:_u,DateMilestone:au,RealtimeActivity:iu,EmailIcon:Cu,SmsIcon:Ru,MessagesSent:Tu,LinksClicked:ku,OpenRate:wu,SpamComplies:Vu,TotalBounceRate:Vu,UnsubscribeRate:Uu},OX=e=>({...AX,...e||{}}),NX=Jc(["reach-styles-module__base___gfFyc"],{variants:{variant:{default:"reach-styles-module__default___ny1h7",destructive:"reach-styles-module__destructive___XjBvS",outline:"reach-styles-module__outline___gFp3i",secondary:"reach-styles-module__secondary___Pd-e3",ghost:"reach-styles-module__ghost___GcnJq",link:"reach-styles-module__link___EgS2H"},size:{default:"reach-styles-module__sizeDefault___8kU5A",sm:"reach-styles-module__sizeSm___zPIEh",lg:"reach-styles-module__sizeLg___D2G8z",icon:"reach-styles-module__sizeIcon___5XkYW"}},defaultVariants:{variant:"default",size:"default"}}),RX=i.forwardRef((({className:e,variant:n,size:r,asChild:o=!1,...i},a)=>t.jsx(o?UU:"button",{className:qd(NX({variant:n,size:r,className:e})),ref:a,...i})));RX.displayName="Button";var PX=(e=>(e.ChooseAutomationType="choose-automation-type",e.SetAutomationName="set-automation-name",e))(PX||{});const kX=({onClose:e,currentStep:n,setCurrentStep:r,isDisabled:o,createAutomation:i,disableBackButton:a})=>t.jsx("div",{children:t.jsxs("div",{className:"flex justify-end space-x-4",children:[t.jsx(RX,{variant:"secondary",className:"px-4 py-2",onClick:()=>{if(a)e?.(!1);else if(n===PX.ChooseAutomationType)e?.(!1);else{if(n!==PX.SetAutomationName)throw new Error("Invalid step");r(PX.ChooseAutomationType)}},children:n===PX.ChooseAutomationType||a?"Cancel":"Back"}),t.jsx(RX,{className:"px-4 py-2",onClick:()=>{o||n!==PX.SetAutomationName||i()},disabled:o,children:n===PX.SetAutomationName?"Create":"Next"})]})}),LX=({onClick:e,title:n,subtitle:r,icon:o,selected:i,disabled:a=!1})=>t.jsxs("button",{onClick:e,className:"flex flex-col items-center justify-center rounded-lg border-[3px] p-6 transition-all duration-300 ease-in-out "+(a?"opacity-50 cursor-not-allowed":i?"scale-[1.02] hover:scale-[1.04] [border-color:hsl(var(--reach-primary))] [background-color:hsl(var(--reach-primary)/0.05)]":"border-gray-200 hover:[border-color:hsl(var(--reach-primary))] hover:bg-gray-50"),children:[o,t.jsxs("div",{className:"text-center mt-3",children:[t.jsx("div",{className:"text-sm font-medium text-gray-900",children:n}),t.jsx("div",{className:"text-xs text-gray-500 mt-1",children:r})]})]}),MX="text-3xl mb-8",DX="grid grid-cols-2 gap-6",jX="relative p-6 rounded-lg",IX="mb-4 flex items-center justify-center",FX="text-lg font-medium mb-2",UX="text-sm text-muted-foreground",$X="absolute top-3 right-3 bg-gray-100 text-gray-600 text-xs px-2 py-1 rounded-full",BX=({onNext:e,iconDefinitions:n})=>t.jsxs("div",{className:jX,children:[t.jsx("h1",{className:MX,children:"Choose Your Automation Type"}),t.jsxs("div",{className:DX,children:[t.jsx(LX,{onClick:()=>{e(Me.ONE_TIME)},title:`${tf("engage:one_time")} Broadcast`,subtitle:"Send a single message to your current list, like announcing a sale or newsletter.",icon:t.jsx(n.OneTimeBroadcast,{}),selected:!1}),t.jsx(LX,{onClick:()=>{},title:"Patron Enters a List",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.PatronEntersList,{}),selected:!1,disabled:!0}),t.jsx(LX,{onClick:()=>{},title:"Date Milestone",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.DateMilestone,{}),selected:!1,disabled:!0}),t.jsx(LX,{onClick:()=>{},title:"Realtime Activity",subtitle:"Send whenever someone becomes qualified, like welcoming new subscribers who meet specific criteria.",icon:t.jsx(n.RealtimeActivity,{}),selected:!1,disabled:!0})]})]});function VX(e,t){throw new Error(`Unreachable case statement: ${JSON.stringify(e)}. Valid values are: ${Object.values(t).join(", ")}`)}const qX=i.forwardRef((({className:e,type:n,...r},o)=>t.jsx("input",{type:n,className:qd("flex h-9 w-full rounded-md border border-input bg-transparent px-3 py-1 text-base shadow-sm transition-colors file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:o,...r})));qX.displayName="Input";const zX=i.forwardRef((({className:e,...n},r)=>t.jsx("textarea",{className:qd("flex min-h-[60px] w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-sm placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n})));zX.displayName="Textarea";const HX=({iconDefinitions:e})=>t.jsxs("div",{children:[t.jsx("div",{className:IX,children:t.jsx(e.OneTimeBroadcast,{})}),t.jsxs("h3",{className:FX,children:[tf("engage:one_time")," Broadcast"]}),t.jsx("p",{className:UX,children:"Send a single message to your current list, like announcing a sale or newsletter."})]}),GX=({iconDefinitions:e})=>t.jsxs("div",{children:[t.jsx("div",{className:$X,children:"Coming Soon"}),t.jsx("div",{className:IX,children:t.jsx(e.RealtimeActivity,{})}),t.jsx("h3",{className:FX,children:"Realtime Activity"}),t.jsx("p",{className:UX,children:"Responds to immediate actions your contacts take, like abandoned carts, form submissions, or appointment bookings."})]}),KX=({selectedType:e,setAutomationName:n,automationName:r,iconDefinitions:o,setAutomationDescription:i,automationDescription:a})=>t.jsxs("div",{className:"flex flex-col items-center justify-center p-8 max-w-lg mx-auto",children:[t.jsxs("h2",{className:"text-2xl font-semibold mb-8 text-center",children:["Name Your ",tf("engage:automation")]}),t.jsxs("div",{className:"w-full space-y-6",children:[t.jsx("div",{className:"bg-gray-50 p-6 rounded-xl items-center justify-center text-center",children:(()=>{switch(e){case Me.ONE_TIME:return t.jsx(HX,{iconDefinitions:o});case Me.TRIGGER_BASED:return t.jsx(GX,{iconDefinitions:o});default:throw VX(e,Me)}})()}),t.jsxs("div",{className:"space-y-6",children:[t.jsxs("div",{children:[t.jsxs("div",{className:"flex items-baseline justify-between mb-2",children:[t.jsx("label",{htmlFor:"automationName",className:"block text-sm font-medium text-gray-900",children:"Name"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"Only visible to your team"})]}),t.jsx(qX,{id:"automationName",type:"text",value:r,onChange:e=>n(e.target.value),className:"w-full px-4 py-2 border border-gray-300 rounded-md focus:ring-indigo-500 focus:border-indigo-500 shadow-sm",placeholder:"e.g. April Newsletter Campaign",autoFocus:!0})]}),t.jsxs("div",{children:[t.jsxs("div",{className:"flex items-baseline justify-between mb-2",children:[t.jsx("label",{htmlFor:"automationDescription",className:"block text-sm font-medium text-gray-900",children:"Description"}),t.jsx("span",{className:"text-xs text-muted-foreground",children:"Optional"})]}),t.jsx(zX,{id:"automationDescription",value:a,onChange:e=>i(e.target.value),className:"w-full min-h-[80px] resize-none",placeholder:`Add any helpful context for your team. If left blank, we'll generate one for you when you start the ${tf("engage:automation")}`})]})]})]})]}),WX=({onClose:e,iconDefinitions:r,automationType:o})=>{const{createAutomation:i,isCreating:a}=Pe(),[s,l]=n.useState(!1),c=OX(r),[u,f]=n.useState(o?PX.SetAutomationName:PX.ChooseAutomationType),[h,m]=n.useState(o?{name:void 0,description:void 0,type:o}:{name:void 0,description:void 0,type:void 0}),g=void 0!==h.name&&void 0!==h.type;n.useEffect((()=>{if(h.type&&!h.name){const e=new Date,t=e.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),n=e.toLocaleDateString([],{month:"long",day:"numeric"}),r=`${tf("engage:automation")} ${n} ${t}`,o="";m((e=>({...e,name:r,description:o})))}}),[h]);if(a||s)return t.jsx("div",{className:jX,children:t.jsx(TX,{text:["Creating Automation","Finishing up"]})});return t.jsxs("div",{className:"relative overflow-y-auto h-full p-8",children:[t.jsx(RV,{mode:"wait",children:t.jsx(CX,{children:(()=>{switch(u){case PX.ChooseAutomationType:return t.jsx(BX,{onNext:e=>{m({...h,type:e}),f(PX.SetAutomationName)},iconDefinitions:c});case PX.SetAutomationName:return h.type?t.jsx(KX,{iconDefinitions:c,selectedType:h.type,setAutomationName:e=>{m({...h,name:e})},automationName:h.name??"",setAutomationDescription:e=>{m({...h,description:e})},automationDescription:h.description??""}):null;default:throw function(e,t){throw new Error(`Unreachable case statement: ${JSON.stringify(e)}. Valid values are: ${Object.values(t).join(", ")}`)}(u,PX)}})()},u)}),t.jsx("div",{className:"pt-2",children:t.jsx(kX,{onClose:e,currentStep:u,setCurrentStep:f,isDisabled:!g,createAutomation:async()=>{if(!g||!h.name||!h.type)return;l(!0);i({name:h.name,type:h.type,description:h.description},{onSuccess:async t=>{if(t.id){const n=await(async e=>(await Ae(`${d}`,{method:"POST",body:JSON.stringify(e)})).data)({}),r=xX().toString();await Oe(t.id,{action:[{actionType:"send_communication",actionMetadata:{actionType:"send_communication",communicationGroupId:n.id,currentActionId:r}}]}),await(async e=>{const{automationId:t,actionId:n}=e;return(await Ae(`${p}/template/${t}/${n}`)).data})({automationId:t.id,actionId:r}),e?.(t.id)}else e?.("error")},onError:()=>{e?.("error")},onSettled:()=>{m({name:void 0,description:void 0,type:void 0})}})},disableBackButton:void 0!==o})})]})};function YX({open:e,setOpen:n,onClose:r,iconDefinitions:o,automationType:i}){return t.jsx(uV,{open:e,onOpenChange:n,children:t.jsxs(fV,{className:"flex max-h-[86vh] flex-col gap-0 overflow-visible max-w-4xl w-full p-0",children:[t.jsx(hV,{children:t.jsx("div",{className:"flex items-center justify-between",children:t.jsxs(zU,{children:[t.jsx(mV,{className:"text-3xl font-normal",children:"Create Automation"}),t.jsx(gV,{children:"Create a new automation to send messages to your customers."})]})})}),t.jsx(WX,{onClose:e=>{r?.(e),n(!1)},iconDefinitions:o,automationType:i})]})})}var XX={};Object.defineProperty(XX,"__esModule",{value:!0}),XX.parse=function(e,t){const n=new nQ,r=e.length;if(r<2)return n;const o=t?.decode||iQ;let i=0;do{const t=e.indexOf("=",i);if(-1===t)break;const a=e.indexOf(";",i),s=-1===a?r:a;if(t>s){i=e.lastIndexOf(";",t-1)+1;continue}const l=rQ(e,i,t),c=oQ(e,t,l),u=e.slice(l,c);if(void 0===n[u]){let r=rQ(e,t+1,s),i=oQ(e,s,r);const a=o(e.slice(r,i));n[u]=a}i=s+1}while(i<r);return n},XX.serialize=function(e,t,n){const r=n?.encode||encodeURIComponent;if(!QX.test(e))throw new TypeError(`argument name is invalid: ${e}`);const o=r(t);if(!ZX.test(o))throw new TypeError(`argument val is invalid: ${t}`);let i=e+"="+o;if(!n)return i;if(void 0!==n.maxAge){if(!Number.isInteger(n.maxAge))throw new TypeError(`option maxAge is invalid: ${n.maxAge}`);i+="; Max-Age="+n.maxAge}if(n.domain){if(!JX.test(n.domain))throw new TypeError(`option domain is invalid: ${n.domain}`);i+="; Domain="+n.domain}if(n.path){if(!eQ.test(n.path))throw new TypeError(`option path is invalid: ${n.path}`);i+="; Path="+n.path}if(n.expires){if(!function(e){return"[object Date]"===tQ.call(e)}
|
|
34
34
|
/**
|
|
35
35
|
* react-router v7.5.2
|
|
36
36
|
*
|